Automatically initialize the CAN id after the system is powered on.
Syntax
void CAN_ID_Init_on_Startup(void);
Description
When the system is powered on and the peripherals
are initialized, the CAN peripherals do not work directly.
The following are the steps for automatic CAN id initialization:
- Host(BCU) send wake up pattern to node #1 wake_in pin.
- Node#1 receive wake_in IO high, and set ID
command, data on CAN bus message, then sets CANID,
belonging to Node#1.
- Node#1 send wake up pattern from wake_out IO to wake up the Node#2, and send the set ID command with CANID+1 CAN message to Node#2.
- Node#2 receive wake up pattern, and set ID
command, data on CAN bus message, then sets CANID+1,
belonging to Node#2.
- Other nodes follow the same steps to complete the automatic CAN ID setting.