Keil Logo


You can test the programs you create with the Real-Time Library CAN driver (RL-CAN) using the simulation capabilities of the µVision® IDE. Simulation allows you to test your CAN application before the target hardware is ready.

Follow these steps to test an RL-CAN example application using the µVision Simulator.

  1. Copy the example \KEIL\ARM\Boards\Keil\MCBSTM32\RL\CAN\CAN_Ex1 to a new folder.
  2. Select and load the project file (CAN_Ex1.UV2) into µVision. This file is located in the folder copied in step 1. In µVision, use Project —> Open Project...

    Open Project Menu

    Select Project File
  3. Select the target Simulator.

  4. Click on Debug —> Start/Stop Debug Session on the menu bar or click the toolbar button to run the simulation.

    Debug Menu
  5. New windows appear as shown below. These windows show the device peripheral functionality.

    Multiple debug windows
  6. Click on Debug —> Run to start the simulation.

    Debug menu
  7. The communication messages display in the windows.

    CAN Communication Window
  8. Click on the Analog sweep 0 .. 3.3V button, on the Toolbox window, to start the analog value rising from 0 V to 3.3 V and lowering from 3.3 V to 0 V. You can stop the analog value change by clicking on Analog sweep STOP.

    Analog Inputs Dialog
  9. Stop the simulation before exiting µVision by clicking on Debug —> Stop on the Debug menu.

    Debug Menu
  Arm logo
Important information

This site uses cookies to store information on your computer. By continuing to use our site, you consent to our cookies.

Change Settings

Privacy Policy Update

Arm’s Privacy Policy has been updated. By continuing to use our site, you consent to Arm’s Privacy Policy. Please review our Privacy Policy to learn more about our collection, use and transfers
of your data.