|
This function sets the bus timing parameters for the specified CAN controller.
None.
canOK (zero) if success
canERR_xxx (negative) if failure.
The library provides default values for tseg1, tseg2, sjw and noSamp when freq is specified to one of the following pre-defined constants:
Constant | Meaning |
---|---|
BAUD_1M | 1 Mbit/s |
BAUD_500K | 500 kbit/s |
BAUD_250K | 250 kbit/s |
BAUD_125K | 125 kbit/s |
BAUD_100K | 100 kbit/s |
BAUD_62K | 62.5 kbit/s |
BAUD_50K | 50 kbit/s |
If freq is any other value, no default values are supplied by the library.