You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

15 lines
275 B

  1. #pragma once
  2. #include <stdint.h>
  3. #include "usart.h"
  4. #define BUF_MAX_LEN 256
  5. typedef struct {
  6. uint8_t date[BUF_MAX_LEN];
  7. uint16_t len;
  8. } packet_t;
  9. void tjc_uart_receive(void);
  10. void tjc_date_pack(packet_t* packet);
  11. void tjc_receive_init(UART_HandleTypeDef* uart);