How does it work?
CAN FD 5 Click is based on the UJA1162A, a ‘self-supplied’ high-speed (HS) CAN transceiver integrating an ISO 11898-2:2016 and SAE J2284-1 to SAE J2284-5 compliant CAN transceiver with Sleep Mode from NXP Semiconductors. The UJA1162A provides reliable communication at data rates up to 5 Mbit/s in the CAN FD HS phase, and can be operated in a very low-current Sleep mode with local and bus wake-up capability. A variety of fail-safe and diagnostic features offer enhanced system reliability and advanced power management. The HS CAN transceiver UJA1162A includes a receiver and a transmitter unit, allowing the transceiver to send data to the bus medium and monitors the data from the bus medium at the same time.
The UJA1162A supports five different operating modes: Normal, Standby, Sleep, Overtemp, and Off. Each mode has specific characteristics in terms of quiescent current, data transmission, or failure diagnostic. When the transceiver is in Sleep Mode, the pin routed to the external regulator TLS850B0TBV33 positioned on the back of the Click board™, will be turned off, reducing the power consumption of the external elements. Outputs of those LDOs are routed through the SMD jumpers that can be populated so that the LDOs can be used to power up the mikroBUS™ 3.3V and 5V power rails. However, it should be noted that MikroE does not advise powering up their systems this way – that is why these jumpers are left unpopulated by default.
The CAN FD 5 Click communicates with MCU using the UART interface with the default baud rate of 9600 bps for the data transfer, while the GPIO pins on this Click board™ are used for Sleep Mode control, local wake-up, and an interrupt for CAN transceiver status. CS pin of the mikroBUS™ socket labeled as the SLP can be used for switching between Normal and Stand-By/Sleep Mode by toggling this pin. It also has a Local Wake-Up function routed to the PWM pin on the mikroBUS™, labeled as WAK, which will cause the transition of UJA1162A from Stand-By/Sleep Mode into Normal Mode. Alongside these pins, this Click board™ possesses an interrupt pin labeled as CTS used to indicate to MCU that the transceiver is fully enabled and data can be transmitted and received via the UART TX/RX pins. It is also possible for the user to connect the TX/RX signals of UART communication directly through the UART External header on the left edge of the board.
This Click board™ is designed to be operated with both 3.3V and 5V logic voltage levels that can be selected via VIO SEL jumper. This allows for both 3.3V and 5V capable MCUs to use the UART communication lines properly. However, the Click board™ comes equipped with a library that contains easy to use functions and an example code that can be used as a reference for further development.
Specifications
Type
CAN,CAN FD
Applications
Can be used for a HS CAN networks in automotive applications and networks in industrial applications, in electric power steering (EPS), HVAC climate control, tire pressure monitoring system (TPMS), and many more.
On-board modules
CAN FD 5 Click is based on the UJA1162A, a ‘self-supplied’ high-speed (HS) CAN transceiver integrating an ISO 11898-2:2016 and SAE J2284-1 to SAE J2284-5 compliant CAN transceiver with Sleep Mode from NXP Semiconductors.
Key Features
Under-voltage detection, remote and local wake-up capability, overtemperature shutdown, and a very low quiescent current in Sleep mode, and more.
Interface
UART
Feature
No ClickID
Compatibility
mikroBUS™
Click board size
L (57.15 x 25.4 mm)
Input Voltage
3.3V or 5V
Pinout diagram
This table shows how the pinout on CAN FD 5 corresponds to the pinout on the mikroBUS™ socket (the latter shown in the two middle columns).
Onboard settings and indicators
Label | Name | Default | Description |
---|---|---|---|
LD1 | PWR | – | Power LED Indicator |
JP1 | VIO SEL | Left | Power Supply Voltage Selection 3V3/5V: Left position 3V3, Right position 5V |
JMPR1 – JMPR2 | – | Unpopulated | 3V3/5V LDO Jumpers |
CAN FD 5 Click electrical specifications
Description | Min | Typ | Max | Unit |
---|---|---|---|---|
Supply Voltage | -0.2 | – | +6 | V |
Communication Data Rates | – | – | 5 | Mbit/s |
Voltage between CANH and CANL pins | -24 | – | +40 | V |
Operating Temperature Range | -40 | – | +125 | °C |
Software Support
We provide a library for the CAN FD 5 Click on our LibStock page, as well as a demo application (example), developed using MikroElektronika compilers. The demo can run on all the main MikroElektronika development boards.
Library Description
The library covers all the necessary functions to control CAN FD 5 click board. Library performs a standard UART communication.
Key functions:
void canfd5_write_byte ( uint8_t input )
– Write Single Byte.void canfd5_set_normal_operating_mode ( void )
– Set normal operating mode function.void canfd5_set_operating_mode ( uint8_t op_mode )
– Set operating mode function.
Examples description
The application is composed of three sections :
- System Initialization – Initializes UART, sets CS and PWM pins as output and INT pin as input.
- Application Initialization – Initialization driver enables – UART, performs an normal operating mode, also write log.
- Application Task – (code snippet) This is an example that demonstrates the use of the CAN FD 5 click board. This application task writes message data via UART every 3 seconds. Results are being sent to the Usart Terminal where you can track their changes.
void application_task ( ) { mikrobus_logWrite( "----------------------", _LOG_LINE ); mikrobus_logWrite( "", _LOG_LINE ); canfd5_write_data( &demo_message_data[ 0 ] ); mikrobus_logWrite( " TX Data: ", _LOG_TEXT ); mikrobus_logWrite( demo_message_data, _LOG_LINE ); Delay_ms( 3000 ); }
The full application code, and ready to use projects can be found on our LibStock page.
Other mikroE Libraries used in the example:
- UART
Additional notes and informations
Depending on the development board you are using, you may need USB UART click, USB UART 2 click or RS232 click to connect to your PC, for development systems with no UART to USB interface available on the board. The terminal available in all MikroElektronika compilers, or any other terminal application of your choice, can be used to read the message.
mikroSDK
This Click board™ is supported with mikroSDK – MikroElektronika Software Development Kit. To ensure proper operation of mikroSDK compliant Click board™ demo applications, mikroSDK should be downloaded from the LibStock and installed for the compiler you are using.
For more information about mikroSDK, visit the official page.