teste de publish
Dependencies: DS1820 HighSpeedAnalogIn devices mbed
Diff: diversos.h
- Revision:
- 0:1c0a769988ee
- Child:
- 1:0e0967c88590
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/diversos.h Fri Mar 24 15:54:41 2017 +0000 @@ -0,0 +1,61 @@ +#ifndef _diversos_h_ +#define _diversos_h_ +#include "mbed.h" +#include "serialPC.h" +#include "funcoesSDCard.h" +#define tamBufferCommands 192 +#include <cstdlib> + +/* +// On reset, indicate a watchdog reset or a pushbutton reset on LED 4 or 3 +if ((LPC_WDT->WDMOD >> 2) & 1) + myled4 = 1; else myled3 = 1; +*/ + +class WatchdogTimer { +public: + //void WatchdogTimer(void); + + // Load timeout value in watchdog timer and enable + void kick(float); + + // "kick" or "feed" the dog - reset the watchdog timer + // by writing this required bit pattern + void kick(); +}; + + + +namespace eventosRTC{ + //Variaveis + extern bool segundos; + extern bool minutos; + //extern bool hora_completa; + extern bool rotina10Segundos; + extern bool rotina15Minutos; + extern bool rotina1hora; + extern bool rotina1segundo; + + //Funções +} + +namespace diversos{ + //Variaveis + extern WatchdogTimer wdt; + extern char msg[200]; + + //Funções + uint32_t memAvailable(); + void progressBar(uint32_t,uint32_t); + //double stringToFloat(char *,uint16_t); //Ponteiro pra string e max tam da string por segurança +} + +namespace commands{ + //Variaveis + extern char buffer[tamBufferCommands]; + + //Funções + void exec(uint8_t); +} + +#endif