EZR
Dependencies: CRC16 FreescaleIAP FreescaleWatchdog GGSProtocol LM75B PIMA Parameters PersistentCircularQueue SerialNumberV2COM mbed-dev-watchdog_2016_03_04
Fork of smartRamalKW by
announce.h@35:78614a27b9e6, 2016-06-16 (annotated)
- Committer:
- fprado
- Date:
- Thu Jun 16 18:55:57 2016 +0000
- Revision:
- 35:78614a27b9e6
- Parent:
- 26:03c9ca836c79
temporary snapshot
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
tpadovani | 25:2c578b923ea9 | 1 | #ifndef ANNOUNCE_H |
tpadovani | 25:2c578b923ea9 | 2 | #define ANNOUNCE_H |
tpadovani | 25:2c578b923ea9 | 3 | |
tpadovani | 25:2c578b923ea9 | 4 | #include "ggs.h" |
tpadovani | 25:2c578b923ea9 | 5 | #include "pima.h" |
tpadovani | 25:2c578b923ea9 | 6 | #include "appCommands.h" |
tpadovani | 25:2c578b923ea9 | 7 | #include "debug.h" |
tpadovani | 25:2c578b923ea9 | 8 | |
tpadovani | 25:2c578b923ea9 | 9 | class Announce{ |
tpadovani | 25:2c578b923ea9 | 10 | int announceDelayAngCoef; |
tpadovani | 25:2c578b923ea9 | 11 | int announceDelayLinCoef; |
tpadovani | 25:2c578b923ea9 | 12 | int announceIntervalSec; |
tpadovani | 25:2c578b923ea9 | 13 | int silenceIntervalSec; |
tpadovani | 25:2c578b923ea9 | 14 | int delay; |
tpadovani | 25:2c578b923ea9 | 15 | Timeout announceTimeout; |
tpadovani | 25:2c578b923ea9 | 16 | bool sendNow; |
tpadovani | 25:2c578b923ea9 | 17 | char announceBuffer[30]; |
tpadovani | 25:2c578b923ea9 | 18 | void triggerAnnounceSending(); |
tpadovani | 25:2c578b923ea9 | 19 | |
tpadovani | 25:2c578b923ea9 | 20 | public: |
tpadovani | 25:2c578b923ea9 | 21 | Announce(); |
tpadovani | 25:2c578b923ea9 | 22 | void setDelayCoefs(int delayAngCoef, int delayLinCoef); |
tpadovani | 25:2c578b923ea9 | 23 | void setIntervals(int announce, int silence); |
tpadovani | 25:2c578b923ea9 | 24 | void startAnnounceTimer(); |
tpadovani | 25:2c578b923ea9 | 25 | void stopAnnounceTimer(); |
tpadovani | 25:2c578b923ea9 | 26 | void handleAnnounceSending(); |
tpadovani | 25:2c578b923ea9 | 27 | |
tpadovani | 25:2c578b923ea9 | 28 | }; |
tpadovani | 25:2c578b923ea9 | 29 | |
tpadovani | 25:2c578b923ea9 | 30 | extern SerialNumber sn; |
tpadovani | 25:2c578b923ea9 | 31 | extern CommandExecutor exec; |
fprado | 26:03c9ca836c79 | 32 | #ifndef RAMAL |
tpadovani | 25:2c578b923ea9 | 33 | extern Pima pima; |
fprado | 26:03c9ca836c79 | 34 | #endif |
tpadovani | 25:2c578b923ea9 | 35 | extern void enviaRespostaGGS(char * dados, int tamanho); |
tpadovani | 25:2c578b923ea9 | 36 | |
tpadovani | 25:2c578b923ea9 | 37 | #endif |