mirror of
https://github.com/eddyem/stm32samples.git
synced 2026-02-28 11:54:30 +03:00
fixed some bugs in canUART for F103, add some features to usbcan_ringbuffer for F0
This commit is contained in:
@@ -18,7 +18,7 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "hardware.h"
|
||||
#include <stdint.h>
|
||||
|
||||
// amount of filter banks in STM32F0
|
||||
#define STM32F0FBANKNO 28
|
||||
@@ -28,6 +28,8 @@
|
||||
// incoming message buffer size
|
||||
#define CAN_INMESSAGE_SIZE (8)
|
||||
|
||||
extern uint32_t floodT;
|
||||
|
||||
// CAN message
|
||||
typedef struct{
|
||||
uint8_t data[8]; // up to 8 bytes of data
|
||||
@@ -50,6 +52,7 @@ void CAN_setup(uint16_t speed);
|
||||
|
||||
CAN_status can_send(uint8_t *msg, uint8_t len, uint16_t target_id);
|
||||
void can_proc();
|
||||
void printCANerr();
|
||||
|
||||
CAN_message *CAN_messagebuf_pop();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user