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.
Dependencies: mbed
Diff: main.cpp
- Revision:
- 0:b3a90cb05638
- Child:
- 2:970cd691d7de
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/main.cpp Tue Oct 30 10:26:46 2018 +0000 @@ -0,0 +1,29 @@ +#include "mbed.h" +#include "get_uart.h" +#include "dev16_m_common_number.h" +#include "decode_uart.h" + +Serial pc(USBTX, USBRX); // tx, rx +GetUART prs48; +Decode_UART uart; + +u8 flag_uart_cs=0; +u8 num_uart[LENGTH_UART_DATA]={0}; +u8 mis_command[LENGTH_MISSION_COMMAND]={0}; +u8 flag_uart_timeout=0; + +int main() { + pc.baud(115200); + pc.printf("start\r\n"); + + + while(1) { + prs48.rcv_uart_data_B2M(); + for(int i=0;i<LENGTH_UART_DATA;i++){ + pc.printf("%02x",num_uart[i]); + } + pc.printf("\r\n"); + + uart.decode_uart(num_uart); + } +}