Personal / protocol engineering

Teltonika Telemetry Receiver

A standard-library Go receiver for FMC650-oriented AVL telemetry over TCP or server-authenticated TLS.

Period
Jun 2026
Role
Personal-project developer
Delivery
Lab deployment

Overview

Context before technology.

Codec 8 Extended decoding, CRC validation, durable raw journaling before acknowledgement, a fixed-capacity normalized-output queue, and lab routing shaped the receiver design.

Lab ingress and protocol

Durability before acknowledgement.

  1. 01

    FMC650 tracker

    Outbound plain TCP connection

  2. 02

    Public Internet

    Bidirectional packet path

  3. 03

    Lab router

    Public IP and inbound TCP forwarding

  4. 04

    Nginx VM

    TCP stream proxy in separate Proxmox guest

  5. 05

    Receiver LXC

    Go process in separate Proxmox guest

User-confirmed lab ingress path. Admission and AVL acknowledgements return through the same established TCP connection.

Addresses, ports, guest identifiers, device identifiers, and capture data are omitted. Optional server-authenticated TLS exists in source but was not deployed on this path.

  1. 01

    Open TCP

    Tracker opens a plain TCP connection through the lab ingress path.

  2. 02

    Identifier admission

    Length-prefixed numeric identifier is checked against optional allowlist.

  3. 03

    Admission result

    Receiver returns one-byte accept or reject result.

  4. 04

    Read AVL packet

    Receiver reads header, declared data field, and CRC field.

  5. 05

    Validate and decode

    Checks Codec 8 Extended, envelope counts, CRC, and exact record-byte consumption.

  6. 06

    Append and sync

    Complete packet receipt reaches authoritative raw JSONL before positive acknowledgement.

  7. 07

    Acknowledge

    Receiver writes four-byte accepted-record count; derived publication follows only after success.

Protocol path for a complete valid packet. Identifier admission is not cryptographic device authentication or automatic device-model detection.

Persistence failure prevents positive acknowledgement. ACK failure after raw commit can create duplicate receipts on tracker retry; exactly-once delivery is not claimed.

  1. Raw IO

    Preserve received value

    Keep AVL ID, width, and raw bytes.

  2. Profile

    Match local contract

    Configured AVL ID and expected transport fields

  3. Recover

    Recover full CAN byte order

    Only from received tracker value

  4. Verify

    Fail-closed checks

    ISO-TP, Mode 01 service, PID, width, formula, and range

  5. Derived

    Expose or retain raw

    Failure keeps diagnostics and leaves ACK unchanged

Manual CAN annotation path. Receiver processes values already delivered by tracker; it does not sniff, configure, request from, command, or transmit onto vehicle bus.

Receiver boundary

The receiver accepts FMC650-oriented AVL traffic over TCP, with optional server-authenticated TLS. It handles the device handshake and Codec 8 Extended packet framing without external protocol libraries.

It is a protocol-focused lab system, not a fleet platform or production device-management service.

Integrity before acknowledgement

Packet handling validates zero preamble, bounded declared length, Codec 8 Extended, equal envelope record counts, CRC-16/IBM, decoder success, and exact record-byte consumption before positive acknowledgement. Raw events are appended and synchronized before acknowledgement so derived-output failures do not erase the authoritative input record.

Manual CAN and OBD-II fields follow fail-closed handling. Derived records enter a fixed-capacity, non-blocking queue only after successful ACK; this bounds dispatch pressure, not output-file growth.

Deployment and limits

For lab testing, a physical tracker reached a public-facing lab endpoint over plain TCP through router forwarding and an Nginx stream proxy in a separate Proxmox VM, then the Go receiver in a separate Proxmox LXC. Addresses, ports, guest identifiers, device data, and captures are intentionally omitted.

Tests exist but the full suite was not run and one fixture is absent. Codec support is limited to Codec 8 Extended; optional TLS is server-authenticated rather than mutual TLS and was not the deployed tracker path.

Working set

Technology serves the system.

  • Go
  • TCP/TLS
  • Binary protocols
  • Proxmox LXC
  • Nginx