kopia lustrzana https://github.com/bristol-seds/pico-tracker
Add some watchdog kicks during startup
microsecond timer is still TODOmain-solar-only
rodzic
d8396d7122
commit
d25f3883bc
|
@ -117,12 +117,11 @@ void init(enum init_type init_t)
|
||||||
* ---------------------------------------------------------------------------
|
* ---------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/* Memory */
|
|
||||||
init_memory();
|
|
||||||
|
|
||||||
/* i2c */
|
/* i2c */
|
||||||
i2c_init(I2C_SERCOM, I2C_SERCOM_SDA_PINMUX, I2C_SERCOM_SCL_PINMUX);
|
i2c_init(I2C_SERCOM, I2C_SERCOM_SDA_PINMUX, I2C_SERCOM_SCL_PINMUX);
|
||||||
|
|
||||||
|
kick_the_watchdog();
|
||||||
|
|
||||||
/* barometer */
|
/* barometer */
|
||||||
barometer_init();
|
barometer_init();
|
||||||
|
|
||||||
|
@ -131,12 +130,14 @@ void init(enum init_type init_t)
|
||||||
telemetry_init();
|
telemetry_init();
|
||||||
|
|
||||||
/* We need to wait for the GPS 32kHz clock to start (~300ms). TODO: more robust method for this */
|
/* We need to wait for the GPS 32kHz clock to start (~300ms). TODO: more robust method for this */
|
||||||
for (int i = 0; i < 1*1000*1000; i++);
|
for (int i = 0; i < 300*1000; i++);
|
||||||
|
|
||||||
/* GPS init */
|
/* GPS init */
|
||||||
gps_init();
|
gps_init();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
kick_the_watchdog();
|
||||||
|
|
||||||
/* Initialise Si4060 interface */
|
/* Initialise Si4060 interface */
|
||||||
si_trx_init();
|
si_trx_init();
|
||||||
}
|
}
|
||||||
|
|
Ładowanie…
Reference in New Issue