network.rs — UDP & Dummy Simulator
This file is work in progress
Exposes commands related to the UDP connection and the development simulator.
Commands
send_ping_cmd(packet_type) Intended to send a ping packet to the rover over UDP. Currently logs to console — full implementation pending.
start_dummy_streams() Starts the full multi-stream simulator. Sends fake protobuf packets to 127.0.0.1:9000 mimicking live rover data. Useful for UI development without hardware. Simulator config:
- Jitter: 30ms
- Simulated packet loss: 2%
start_detection_sim() Starts a single stream for the detection object stream dummy data.
stop_dummy_streams() Signals the running simulator to stop by setting a shared cancellation flag.
The DummyStreamHandle struct (managed Tauri state) holds the cancellation handle so any command can stop the simulator.
No comments to display
No comments to display