whatever
Dependencies: C027 C027_Support M2XStreamClient PowerControl jsonlite mbed-rtos mbed
Fork of PONY_Ph0-uAXIS by
Diff: main.cpp
- Revision:
- 50:bba466f093a4
- Parent:
- 49:a8c40c816199
- Child:
- 51:61a1ec3c56fc
--- a/main.cpp Thu Jan 07 23:03:22 2016 +0000 +++ b/main.cpp Thu Jan 14 21:28:20 2016 +0000 @@ -5,6 +5,11 @@ #include "GPS.h" #include "MDM.h" +// Power control libraries +#include "PowerControl.h" +#include "EthernetPowerControl.h" + + // M2X Support Libraries #include <jsonlite.h> #include "M2XStreamClient.h" @@ -33,8 +38,8 @@ #ifdef THROWAWAY // Codes for a throwaway M2X device -#define M2XAPIKEY "54c6bbf11012f34830bd23cc091ca250" -#define DEVID "b9c57667ee0495dc0b3cddd890f8d2df" +#define M2XAPIKEY "97f6f92f72b9dd1c66e9b81b982bc3ec" +#define DEVID "743fe2502be9d4d0c550ffa9340998a3" #endif #ifndef THROWAWAY @@ -109,6 +114,11 @@ printf("Using PONY_v1.4 M2X device\r\n"); #endif + // POWER MANAGEMENT + PHY_PowerDown(); // Turn off the ethernet interface; -175mW + + //C027 thisBoard; + MDMSerial mdm; MDMParser::DevStatus devStatus = {}; @@ -356,6 +366,11 @@ printf("loop waiting for %i seconds...\r\n---\n\r\n", (kLocLoopDelay / 1000) ); flipper.attach(&flip, 0.5); // LED toggle! // the address of the function to be attached (flip) and the interval (2 seconds) + + // Put this shiz to sleep + + + delay(kLocLoopDelay); led1 = 0; // Turn that LED off!