Apache Mynewt Sensor Network Application for STM32 Blue Pill and nRF52 with Visual Rust, NB-IoT, GPS, iBeacon, NimBLE, ESP8266 (WiFi Geolocation) and nRF24L01
/// Also perform WiFi Geolocation if it is enabled. Return 0 if successful.
pubfnstart_network_task() -> i32{
console_print(b"start_network_task\n");
0
}
Immediatly as I saw the video in the medium post I shuddered.
Do proper error handling in Rust!
Don't return ints to indicate errors or failures, use Result<(), ErrorType> instead. This is just one place, but everywhere where you have those ghastly assert!(rc == 0) things, throw them away and burn them! Either use unwrap, or better expect.