Interface for Libcanard CAN interaction with AVR microcontrollers.
More...
Interface for Libcanard CAN interaction with AVR microcontrollers.
- Author
- Matthias Renner renne.nosp@m.rm@e.nosp@m.thz.c.nosp@m.h
-
ETH Zuerich Robotics Systems Lab (http://http://www.rsl.ethz.ch/)
- Version
- 0.1
◆ canardAVRClose()
| int canardAVRClose |
( |
void |
| ) |
|
Deinitialize CAN interface on AVR microcontroller.
- Warning
- Not implemented
- Return values
-
| 1 | Initialisation successful |
| -1 | Error, bitrate not supported |
Definition at line 90 of file canard_avr.c.
◆ canardAVRConfigureAcceptanceFilters()
| int canardAVRConfigureAcceptanceFilters |
( |
uint8_t |
node_id | ) |
|
Set hardware acceptance filters for specific node ID.
- Parameters
-
| [in] | id | node ID for hardware filter |
- Return values
-
| -1 | Error, filters could no be set |
| 1 | Set filter successful |
Definition at line 146 of file canard_avr.c.
◆ canardAVRInit()
| int canardAVRInit |
( |
uint32_t |
bitrate | ) |
|
Initialize CAN interface on AVR microcontroller.
- Warning
- Enables interrupts!
- Parameters
-
| [in] | bitrate | Set CAN bitrate (bits/sec.) |
- Return values
-
| 0 | Successfully initialized. |
Definition at line 18 of file canard_avr.c.
◆ canardAVRReceive()
| int canardAVRReceive |
( |
CanardCANFrame * |
out_frame | ) |
|
Receives a CanardCANFrame from the CAN device.
- Parameters
-
| [out] | out_frame | Canard CAN frame which contains data received |
- Return values
-
| 0 | No new CAN data to be read |
| -1 | Error, data could not be read |
| 1 | Data read successful |
Definition at line 119 of file canard_avr.c.
◆ canardAVRTransmit()
| int canardAVRTransmit |
( |
const CanardCANFrame * |
frame | ) |
|
Transmits a CanardCANFrame to the CAN device.
- Parameters
-
| [in] | frame | Canard CAN frame which contains the data to send |
- Return values
-
| 0 | No CAN send buffer free |
| -1 | Error, data could not be sent |
| 1 | Data sent successful |
Definition at line 95 of file canard_avr.c.