candbc_set

Purpose:

Send a CAN message at a particular rate.

Enter:

candbc_set <CanMessageID|MessageName> <SendInterval> [name=Register_name] [count=num_of_msgs] [index] [-c=n]

Where:

CanMessageId
or
MessageName

Specify either:

  • The message ID from the *.dbc file.
  • The message name from the *.dbc file.

SendInterval

Specify the delay time in milliseconds between messages:

  • 0 to disable
  • 1-19 to send once then disable
  • 20+ to send repeatedly)
name Optional. Specify the registered name of the CanDbc.

Index

Optional. Specify an index to send repeated messages at different times. The default is 0.

Count

Optional. Specify the number of times to send the message. Default is infinite.

-c

Optional. Specify the channel number (0 or 1) if multiple channels are in use.

Example:

candbc_set 100 50
Send the message on the default channel.

candbc_set 100 1000 -c=1
Send the message on the second channel.

candbc_set 100 1000 name=CanDbc2
Send the message on the default channel with a CanDbc task started with the register name “CanDbc2”.

candbc_set 100 1000 name=CanDbc2 count=3
Send only 3 messages on the default channel with a CanDbc task started with the register name “CanDbc2”.

Notes:

Channel number must be 0 or 1. Invalid values will cause an error.

See Also:

CanDbc