Skeleton program for Federico's 4YP project.
Dependencies: WebSocketClient WiflyInterface mbed messages
Fork of IoT_Ex by
Diff: main.cpp
- Revision:
- 10:e8b66718a103
- Parent:
- 9:9b6a54e63942
--- a/main.cpp Tue Nov 29 12:22:14 2016 +0000 +++ b/main.cpp Tue Nov 29 15:02:01 2016 +0000 @@ -37,6 +37,7 @@ #include "Commands.h" #include "Websocket.h" #include "ADC.h" +#include "pwm.h" //#define DEBUG #define INFOMESSAGES @@ -73,12 +74,17 @@ // Connect to the wifi network. It will basically get stuck here until it // connects to the network. SetupNetwork(5000); - + // Configure the baud rate of the wifi shield: // This will make our wireless transmissions much faster. ws.setBaud(115200); wait(0.5f); + // Configure the PWM module: + ConfigurePWM(Duty_us, PwmPeriod_us); + // Turn on the PWM: + TurnOnPWM(true); + // Check to see we are connected to the network: if(IotStatus.CheckFlag(SF_WIRELESSCONNECTED)){ // Try to connect to the WebSocket server: