pwm period is now 200us instead of the default 20ms veml6040 config is now AF_BIT | TRIG_BIT
Dependencies: mbed MMA8451Q USBDevice WakeUp vt100
Fork of afero_node_suntory_2017_06_15 by
Diff: main.cpp
- Revision:
- 1:b2a9a6f2c30e
- Parent:
- 0:20bce0dcc921
- Child:
- 2:dfe671e31221
--- a/main.cpp Tue Dec 20 01:51:02 2016 +0000 +++ b/main.cpp Thu Jan 19 09:17:16 2017 +0000 @@ -3,6 +3,7 @@ #include "pin_defines.h" #include "debugIO.h" #include "RTC_Handler.h" +#include "Preferences.hpp" Timer t; @@ -13,16 +14,16 @@ initDebugIO(); RTC_Handler::getInstance()->setUTC(1483228800); time_t t_t = RTC_Handler::getInstance()->getUTC(); - printf("%s",ctime(&t_t)); mbedSPI mbedspi; - DigitalOut ASR1Reset(SPI_SLAVE_ASR_1_RESET, SPI_SLAVE_ASR_1_RESET_DEASSERT); - ASR1Reset = SPI_SLAVE_ASR_1_RESET_ASSERT; - wait_ms(500); - ASR1Reset = SPI_SLAVE_ASR_1_RESET_DEASSERT; - wait_ms(500); + DigitalOut ASR1Reset( + (PinName)PINS::ASR_1::RESET, + PINS::ASR_1::SIG::RESET::DEASSERT); + ASR1Reset = PINS::ASR_1::SIG::RESET::ASSERT; + wait_ms(1000); + ASR1Reset = PINS::ASR_1::SIG::RESET::DEASSERT; + wait_ms(1000); AferoCommHndlr *aHnd = AferoCommHndlr::create(&t,&mbedspi); while(1) { - //SERIAL_PRINT_DBG("HELLO\n"); aHnd->loop(); } }