Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Diff: payload.cpp
- Revision:
- 8:6105ffbaf237
- Parent:
- 7:e0c7e624c5fa
- Child:
- 9:486f65124378
--- a/payload.cpp Sat Mar 23 07:08:27 2019 +0000 +++ b/payload.cpp Sat Mar 23 09:18:03 2019 +0000 @@ -1,10 +1,21 @@ #include "mbed.h" -extern unsigned char rx[8], tx[8]; +extern unsigned char rx_buffer[8], tx_buffer[8]; extern unsigned char rx_length, tx_length; void analyzePayload() { - printf("analyzePayload\r\n"); + int i; + + printf("analyzePayload thread\r\n"); + while (true) { + osEvent evt = can_queue.get(); + if (evt.status == osEventMessage) { + CANMessage *message = (CANMessage*)evt.value.p; + + mpool.free(message); + } + } + } \ No newline at end of file