Skip to content

CAN Database

A CAN database stores configurations for CAN messages/signals and enums that are used by devices to properly structure the CAN data they send out. One database can contain as many CAN messages as needed, each of which can contain as many signals as will fit in the message.

Access CAN Databases

  1. Go to the model editor for the desired model via the Models page.
  2. Click on the CAN Databases section in the section selector.

Messages

CAN messages have two main parts: the ID and the payload. The ID must be unique compared to all other messages in the database so that any device using the database knows which message it’s sending/receiving.

  • Click on the to create a new message.
  • Click on the button to delete the selected message.

Configuration

  • Name
    • Enter the name of the message.
  • CAN ID
    • Specify the unique CAN ID used by the device to recognize data in this message.
  • Type
    • Specify the type of message.
    • This affects the length of the CAN ID.
  • Direction
    • Specify the direction of data flow.
  • Data Length
    • Enter the length (in bytes) of the message.
    • The length must be at minimum long enough to contain all the signals.
  • Send Period
    • Specify the time (in seconds) after which the data needs to be sent or received.
  • Multipacket
    • Toggle whether to allow the sending of data as multiple packets.
  • Logged on device
    • Toggle whether the device should include this message in log data files.
  • Send over MQTT
    • Toggle whether to send/receive the data values over MQTT.
  • Retain
    • Toggle whether the device should retain this message locally.
  • Comment
    • Add comments for reference and documentation purposes.

Signals

A CAN message can have multiple signals based on the data length defined for the message.

  • Click the button to create a new signal.
    • Click on an already defined signal to edit its configuration.
  • To delete signals, check the boxes on the left, then click the button.

Layout

Go to the Layout tab to view a visual representation of the message with all its signals. Each signal is displayed in a different color, with its length corresponding to its configured length (in bits).

The first signal will start at (Byte, Bit) pair (0, 0) and go from right to left.

J1939 Protocol

Current Platform Support

Single-Packet Support
  • The platform can decode J1939 single-packet messages.
Multi-Packet Support
  • The platform correctly handles J1939 multi-packet messages using the transport protocol (RTS/CTS).
  • Pending - Connection management packet parsing and get the CAN ID and data length from RTS packet.