Skip to main content

Synapse-compatible sensor emulators for radar, MAVLink, and LiDAR collection

Project description

Sensor Emulator

Standalone Synapse-compatible emulators for:

  • Radar TCP control/data protocol
  • MAVLink telemetry stream
  • LiDAR collector subprocess contract

Why this exists

synapse expects real hardware and device access. This repo emulates the same interfaces so development and CI can run without hardware.

Install

cd sensor-emulator
python3 -m venv .venv
source .venv/bin/activate
pip install -e .[test]

Run emulators

Radar only:

sensor-emulator radar --host 127.0.0.1 --ctrl-port 8100 --data-port 8101

MAVLink only:

sensor-emulator mavlink --host 127.0.0.1 --port 14550 --stream-hz 10

Radar + MAVLink:

sensor-emulator all --host 127.0.0.1 --ctrl-port 8100 --data-port 8101 --mavlink-port 14550

LiDAR collector mode (drop-in for LidarRunner subprocess):

export POINT_CLOUD_CSV_PATH=/tmp/lidar_point_cloud.csv
export IMU_DATA_CSV_PATH=/tmp/lidar_imu_data.csv
sensor-lidar-collector dummy-config-path

Synapse wiring

For Synapse LiDAR:

export LIDAR_EXEC_PATH=$(which python3)
export LIDAR_CONFIG_PATH=/absolute/path/to/sensor-emulator/src/sensor_emulator/lidar_collector.py

For Synapse radar, set RADAR_CONFIG_PATH to a config like:

{
  "ip": "127.0.0.1",
  "ctrlPort": 8100,
  "dataPort": 8101,
  "nSamples": 511,
  "headerFields": 16,
  "sampleBytes": 4,
  "timeout": 1.0
}

For Synapse MAVLink:

Use getMavlinkController(port=\"udpin:127.0.0.1:14550\", ...) in local tests.

Test suite

Run all tests:

pytest -q

Coverage intent:

  • Radar command compatibility (STA?, IRF1, FMT?, #IRF, RUN , STOP)
  • Radar frame binary layout + CSV generation through Synapse RadarController
  • MAVLink heartbeat and required message set + Synapse MavlinkController CSV output
  • LiDAR subprocess env contract + Synapse LidarRunner CSV output

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

aerostacks_sensor_emulator-0.1.0.tar.gz (7.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

aerostacks_sensor_emulator-0.1.0-py3-none-any.whl (10.0 kB view details)

Uploaded Python 3

File details

Details for the file aerostacks_sensor_emulator-0.1.0.tar.gz.

File metadata

File hashes

Hashes for aerostacks_sensor_emulator-0.1.0.tar.gz
Algorithm Hash digest
SHA256 d76ba34bf00cf55dfbe7290236988a6c68d9defb4887f35ab242037a4fddf89f
MD5 1ef6ea470af16e647861e89e09d584c3
BLAKE2b-256 46141c8d44a00a262dd799684932e56b6b982972e28e97540c473610965ab080

See more details on using hashes here.

Provenance

The following attestation bundles were made for aerostacks_sensor_emulator-0.1.0.tar.gz:

Publisher: python-publish.yml on Aerostacks/sensor-emulator

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file aerostacks_sensor_emulator-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for aerostacks_sensor_emulator-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 48a35481cfaee2d6326f16cd104bde3c27de15d3447e6c5f666ef99dfdaea65c
MD5 74f16065bff9e80731614e266e31021c
BLAKE2b-256 b1c26a073f442cd384770316a0b79b773e0ecc935b1f5179e1e6ac25059134cc

See more details on using hashes here.

Provenance

The following attestation bundles were made for aerostacks_sensor_emulator-0.1.0-py3-none-any.whl:

Publisher: python-publish.yml on Aerostacks/sensor-emulator

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page