Arianna autonomous DAQ firmware
Dependencies: mbed SDFileSystemFilinfo AriSnProtocol NetServicesMin AriSnComm MODSERIAL PowerControlClkPatch DS1820OW
SnCommWinUsb.cpp@41:d6f5e2f09e07, 2013-10-08 (annotated)
- Committer:
- uci1
- Date:
- Tue Oct 08 23:44:00 2013 +0000
- Revision:
- 41:d6f5e2f09e07
- Parent:
- 40:1324da35afd4
- Child:
- 56:0bba0ef15697
sbd only, debug on. send iridium signal strength. check first event even if cards off. make serial type explicit as Serial has no vtable. SBD comms: send buffered returns bytes sent out, use checksum of msg from modem, fix EmptyRxBuf, add checkSIgStr
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
uci1 | 37:ff95e7070f26 | 1 | #include "SnCommWinUsb.h" |
uci1 | 37:ff95e7070f26 | 2 | |
uci1 | 37:ff95e7070f26 | 3 | #include "SnCommUsb.h" |
uci1 | 37:ff95e7070f26 | 4 | |
uci1 | 37:ff95e7070f26 | 5 | #ifdef USE_MODSERIAL |
uci1 | 38:9070c17536cd | 6 | #include "MODSERIAL.h" |
uci1 | 37:ff95e7070f26 | 7 | #endif |
uci1 | 37:ff95e7070f26 | 8 | |
uci1 | 41:d6f5e2f09e07 | 9 | SnCommWinUsb::SnCommWinUsb(COMM_SERIALTYPE* cpu) : |
uci1 | 41:d6f5e2f09e07 | 10 | SnCommWin(new SnCommUsb(cpu)) { |
uci1 | 37:ff95e7070f26 | 11 | |
uci1 | 37:ff95e7070f26 | 12 | } |
uci1 | 37:ff95e7070f26 | 13 | |
uci1 | 37:ff95e7070f26 | 14 | SnCommWin::ECommWinResult SnCommWinUsb::OpenWindow(const uint32_t timeout, |
uci1 | 37:ff95e7070f26 | 15 | const bool sendStatus, |
uci1 | 37:ff95e7070f26 | 16 | const SnConfigFrame& conf, |
uci1 | 37:ff95e7070f26 | 17 | const SnEventFrame& evt, |
uci1 | 37:ff95e7070f26 | 18 | const SnPowerFrame& pow, |
uci1 | 37:ff95e7070f26 | 19 | const uint16_t seq, |
uci1 | 37:ff95e7070f26 | 20 | const float thmrate, |
uci1 | 37:ff95e7070f26 | 21 | const float evtrate, |
uci1 | 37:ff95e7070f26 | 22 | char* const genBuf) { |
uci1 | 37:ff95e7070f26 | 23 | #ifdef DEBUG |
uci1 | 37:ff95e7070f26 | 24 | printf("SnCommWinUsb::OpenWindow\r\n"); |
uci1 | 37:ff95e7070f26 | 25 | #endif |
uci1 | 37:ff95e7070f26 | 26 | |
uci1 | 37:ff95e7070f26 | 27 | SnCommWin::ECommWinResult ret = |
uci1 | 37:ff95e7070f26 | 28 | fComm->Connect(timeout) ? SnCommWin::kConnected : SnCommWin::kCanNotConnect; |
uci1 | 37:ff95e7070f26 | 29 | |
uci1 | 37:ff95e7070f26 | 30 | if (sendStatus) { |
uci1 | 37:ff95e7070f26 | 31 | #ifdef DEBUG |
uci1 | 37:ff95e7070f26 | 32 | printf("SnCommWinUsb calling SendStatus\r\n"); |
uci1 | 37:ff95e7070f26 | 33 | #endif |
uci1 | 37:ff95e7070f26 | 34 | ret = SendStatus(conf, evt, pow, seq, thmrate, evtrate, genBuf, timeout); |
uci1 | 37:ff95e7070f26 | 35 | } |
uci1 | 37:ff95e7070f26 | 36 | |
uci1 | 37:ff95e7070f26 | 37 | return ret; |
uci1 | 37:ff95e7070f26 | 38 | } |