Implement Integral Data Types (#13)
**Rationale:** Integral Types were missing and are needed for Project Nautilus. **Changes:** - Implements Integral Data Types - u64 and i64 implemented through bigint Reviewed-on: #13 Co-authored-by: Sergey Savelyev <sergeysav.nn@gmail.com> Co-committed-by: Sergey Savelyev <sergeysav.nn@gmail.com>
This commit was merged in pull request #13.
This commit is contained in:
@@ -12,6 +12,7 @@ import {
|
||||
} from 'vue';
|
||||
import type { TelemetryDefinition } from '@/composables/telemetry';
|
||||
import { onDocumentVisibilityChange } from '@/composables/document.ts';
|
||||
import { parseJsonString, toJsonString } from '@/composables/json.ts';
|
||||
|
||||
export interface TelemetryDataItem {
|
||||
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
||||
@@ -71,7 +72,7 @@ export class WebsocketHandle {
|
||||
}
|
||||
});
|
||||
this.websocket.addEventListener('message', (event) => {
|
||||
const message = JSON.parse(event.data);
|
||||
const message = parseJsonString(event.data);
|
||||
if (message['TlmValue']) {
|
||||
const tlm_value = message['TlmValue'] as TlmValue;
|
||||
const listeners = this.on_telem_value.get(tlm_value.uuid);
|
||||
@@ -126,7 +127,7 @@ export class WebsocketHandle {
|
||||
([uuid_value, connected, enabled, min_sep, live_value]) => {
|
||||
if (connected && enabled && uuid_value && live_value) {
|
||||
this.websocket?.send(
|
||||
JSON.stringify({
|
||||
toJsonString({
|
||||
RegisterTlmListener: {
|
||||
uuid: uuid_value,
|
||||
minimum_separation_ms: min_sep,
|
||||
@@ -142,7 +143,7 @@ export class WebsocketHandle {
|
||||
this.on_telem_value.get(uuid_value)?.push(callback_fn);
|
||||
onWatcherCleanup(() => {
|
||||
this.websocket?.send(
|
||||
JSON.stringify({
|
||||
toJsonString({
|
||||
UnregisterTlmListener: {
|
||||
uuid: uuid_value,
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user