can_task.h 494 B

12345678910111213141516171819202122
  1. #ifndef __CAN_TASK_H
  2. #define __CAN_TASK_H
  3. #include "can_interface.h"
  4. #define CAN_PGN_PF 0xFFFF00
  5. #define CAN_PGN_PS 0xFF00
  6. extern uint8_t recv_can_id;
  7. typedef struct
  8. {
  9. uint32_t id;
  10. void (*p_func)(pdu_tag);
  11. } can_rx_tab;
  12. void can_rx_callback(CAN_RxHeaderTypeDef rx_header, uint8_t *buff);
  13. void can_tx_callback(void);
  14. void can_process(void);
  15. void can_network_init(void);
  16. uint8_t push_can_message_to_queue(uint32_t id, uint8_t len, uint8_t *p_data);
  17. #endif // __APP_CAN_H