Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: mbed SakuraIO MPU9250_SPI BME280 gps AQM0802A
Revision 2:48e7e85cb169, committed 2018-11-27
- Comitter:
 - punix
 - Date:
 - Tue Nov 27 06:51:52 2018 +0000
 - Parent:
 - 1:11957db1faa5
 - Commit message:
 - ??????
 
Changed in this revision
| main.cpp | Show annotated file Show diff for this revision Revisions of this file | 
--- a/main.cpp	Thu Nov 22 08:09:12 2018 +0000
+++ b/main.cpp	Tue Nov 27 06:51:52 2018 +0000
@@ -46,7 +46,11 @@
 mpu9250_spi mpu9250(internal_mpu9250_spi, SPI_MPU_CS);
 
 // sakura.io
-SakuraIO_I2C sakuraio(I2C_SDA, I2C_SCL);
+//SakuraIO_I2C sakuraio(I2C_SDA, I2C_SCL);
+#define SPI_FREQ (350000)
+SPI sakuraio_spi(PB_15, PB_14, PB_13);
+DigitalOut sakuraio_cs(PB_12);
+SakuraIO_SPI sakuraio(sakuraio_spi, sakuraio_cs);
 
 SensorData sensor_data;
 
@@ -63,9 +67,9 @@
 
 void gps_uart_buffering_handler();
 
-const int SEND_INTERVAL_TICKS_PAR_COUNT = 25;
+const int SEND_INTERVAL_TICKS_PAR_COUNT = 1500;
 
-const int RETRY_INTERVAL_TICKS_PAR_COUNT = 25;
+const int RETRY_INTERVAL_TICKS_PAR_COUNT = 50;
 
 void setup()
 {