| Electronic Components Datasheet Search |
|
UM0459 Datasheet(PDF) 8 Page - STMicroelectronics |
|
|
|||||||||||||||||||||||||||||
UM0459 Datasheet(HTML) 8 Page - STMicroelectronics |
|
8 / 29 page ![]() Controller area network (CAN) routines UM0459 8/29 The CAN1 and CAN2 are defined in the st10f27x_can.h file as follows: /* C-CAN modules defintion */ #define CAN1_BASE 0xEF00 #define CAN2_BASE 0xEE00 #define CAN1 ( (CAN_TypeDef *) CAN1_BASE) #define CAN2 ( (CAN_TypeDef *) CAN2_BASE) Note: To use CAN1 and/or CAN2 interfaces, the CAN1EN and/or CAN2EN bits must be set in the XPERCON register before configuring the SYSCON register. 2.2 Software library functions The functions of the CAN library are listed in the following table and are described in the corresponding subsections: IP1R CAN Interrupt Pending 1 Register IP2R CAN Interrupt Pending 2 Register MV1R CAN Message Valid 1 Register MV2R CAN Message Valid 2 Register Table 1. CAN registers (continued) Register Description Table 2. CAN functions Function name (corresponding sections) Description CAN_Init (Section 2.2.1) Initializes the CAN cell and sets the bitrate. CAN_EnterInitMode(Section 2.2.2) Switches the CAN to initialization mode. CAN_LeaveInitMode (Section 2.2.3) Leaves initialization mode (switches to normal mode). CAN_EnterTestMode (Section 2.2.4) Switches the CAN to test mode. CAN_LeaveTestMode(Section 2.2.5) Leaves the current test mode (switches to normal mode). CAN_SetBitrate (Section 2.2.6) Configures a standard CAN bitrate. CAN_SetTiming (Section 2.2.7)Configures the CAN timing with specific parameters. CAN_SetUnusedMsgObj (Section 2.2.8) Configures the message object as unused. CAN_SetTxMsgObj (Section 2.2.10) Configures the message object as TX. CAN_SetRxMsgObj (Section 2.2.11) Configures the message object as RX. CAN_SetUnusedAllMsgObj (Section 2.2.9) Configures all message objects as unused. CAN_ReleaseMessage (Section 2.2.12) Releases the message object. CAN_UpdateMsgObj (Section 2.2.14) Updates the message object. CAN_TransmitRequest (Section 2.2.15) Requests the transmission of a message object. CAN_SendMessage (Section 2.2.13) Updates and starts transmission of a message. |
|
Link URL |
| Does ALLDATASHEET help your business so far? [ DONATE ] |
About Alldatasheet | Advertisement | Contact us | Privacy Policy | Link to Datasheet | Link Exchange | Manufacturer List All Rights Reserved©Alldatasheet.com |
| Russian : Alldatasheetru.com | Korean : Alldatasheet.co.kr | Spanish : Alldatasheet.es | French : Alldatasheet.fr | Italian : Alldatasheetit.com Portuguese : Alldatasheetpt.com | Polish : Alldatasheet.pl | Vietnamese : Alldatasheet.vn Indian : Alldatasheet.in | Mexican : Alldatasheet.com.mx | British : Alldatasheet.co.uk | New Zealand : Alldatasheet.co.nz |
|
Family Site : ic2ic.com |
icmetro.com |