![](/media/cache/group/default_image.jpg.50x50_q85.jpg)
Wireless interface using LoRa technology
Dependencies: AlohaTransceiver RingBuffer SX1276Lib_inAir SerialInterfaceProtocol mbed L3PDU
Diff: main.cpp
- Revision:
- 10:7dcb951ecabd
- Parent:
- 9:86d95e095bb0
- Child:
- 11:c7c0036efdbd
--- a/main.cpp Wed Jul 27 04:42:36 2016 +0000 +++ b/main.cpp Wed Jul 27 05:09:23 2016 +0000 @@ -412,19 +412,27 @@ printf("-----------------------------------------\r\n"); } +void enqueueString(char* s, int len) { + for (int i = 0; i < len; i++) { + SerialInputBuffer.enqueue((uint8_t) s[i]); + } +} + void automaticPacketTransmit() { - SerialInputBuffer.enqueue((uint8_t) '<'); + /*SerialInputBuffer.enqueue((uint8_t) '<'); SerialInputBuffer.enqueue((uint8_t) '0'); SerialInputBuffer.enqueue((uint8_t) '1'); SerialInputBuffer.enqueue((uint8_t) '0'); SerialInputBuffer.enqueue((uint8_t) '0'); SerialInputBuffer.enqueue((uint8_t) 'f'); SerialInputBuffer.enqueue((uint8_t) 'f'); - SerialInputBuffer.enqueue((uint8_t) '>'); + SerialInputBuffer.enqueue((uint8_t) '>');*/ + enqueueString("<0100ff>", 8); } + int main() { // initialize radio module aloha.boardInit();