j1939.Channel Properties
Properties of the j1939.Channel
object
Use the following properties to examine or configure J1939 channel settings. Use
j1939Channel
to create a channel.
Device Information
DeviceVendor
— Device vendor name
char vector
This property is read-only.
The DeviceVendor
property indicates the name of the device
vendor.
Values are automatically defined when you configure the channel with the canChannel
or j1939Channel
function.
Data Types: char
Device
— Channel device type
char vector
This property is read-only.
For National Instruments™ devices, the Device
property displays the device
number on the hardware.
For all other vendors, the Device
property displays information
about the device type to which the CAN or J1939 channel is connected.
Values are automatically defined when you configure the channel with the canChannel
or j1939Channel
function.
Data Types: char
DeviceChannelIndex
— Device channel index
double
This property is read-only.
The DeviceChannelIndex
property indicates the channel index on
which the specified CAN or J1939 channel is configured.
Values are automatically defined when you configure the channel with the canChannel
or j1939Channel
function.
Data Types: double
DeviceSerialNumber
— Device serial number
double | char
This property is read-only.
The DeviceSerialNumber
property displays the serial number of
the device connected to the CAN or J1939 channel.
Values are automatically defined when you configure the channel with the canChannel
or j1939Channel
function.
Data Types: double
| char
Data Details
ParameterGroupsAvailable
— Number of parameter groups available to be received
double
This property is read-only.
The ParameterGroupsAvailable
property displays the total number
of parameter groups available to be received by the channel.
Data Types: double
ParameterGroupsReceived
— Number of parameter groups received by channel
double
This property is read-only.
The ParameterGroupsReceived
property indicates the total number
of parameter groups received since the channel was last started.
Data Types: double
ParameterGroupsTransmitted
— Number of parameter groups transmitted by channel
double
This property is read-only.
The ParameterGroupsTransmitted
property indicates the total
number of parameter groups transmitted since the channel was last started.
Data Types: double
FilterPassList
— List of parameter groups to pass
char | cell
This property is read-only.
FilterPassList
displays a list of parameter group names and
numbers that the channel can pass to the network. The list displays parameter group
names and numbers as character vectors or cell arrays of character vectors and
numbers.
To change the values, use one of the filtering functions: filterAllowOnly
, filterAllowAll
, or filterBlockAll
Data Types: char
| cell
FilterBlockList
— List of parameter groups to block
char | cell
This property is read-only.
FilterBlockList
displays a list of parameter group names and
numbers blocked by the channel. The list displays parameter group names and numbers as
character vectors or cell arrays of character vectors and numbers. To change the values,
use one of the filtering functions.
To change the values, use one of the filtering functions: filterAllowOnly
, filterAllowAll
, or filterBlockAll
Data Types: char
| cell
Channel Information
Running
— Indicate running status of channel
false
(0
) | true
(1
)
This property is read-only.
The Running
property indicates the state of the CAN or J1939
channel, according to the following values:
false
(default) — The channel is offline.true
— The channel is online.
Use the start
function to set your channel
online.
Data Types: logical
BusStatus
— Status of bus
char
This property is read-only.
The BusStatus
property displays information about the state of
the CAN bus or the J1939 bus.
'N/A'
— Property not supported by vendor.'ErrorActive'
— Node transmits Active Error Flags when it detects errors. Note: This status does not necessarily indicate that an error actually exists, but indicates how an error is handled.'ErrorPassive'
— Node transmits Passive Error Flags when it detects errors.'BusOff'
— Node will not transmit anything on the bus.
Data Types: char
InitializationAccess
— Indicate control of device channel
true
(1
) | false
(0
)
This property is read-only.
The InitializationAccess
property indicates if the configured
CAN or J1939 channel object has full control of the device channel, according to the
following values:
true
— Has full control of the hardware channel and can change the property values.false
— Does not have full control and cannot change property values.
You can change some property values of the hardware channel only if the object has full control over the hardware channel.
Note
Only the first channel created on a device is granted initialization access.
Data Types: logical
InitialTimestamp
— Indicate when channel started
datetime
This property is read-only.
The InitialTimestamp
property indicates when the channel was
set online with the start
function or when its start trigger was
received. For National Instruments devices, the time is obtained from the device driver; for devices from
other vendors the time is obtained from the operating system where MATLAB is
running.
Data Types: datetime
SilentMode
— Specify if channel is active or silent
false
(default) | true
Specify whether the channel operates silently, according to the following values:
false
(default) — The channel is in normal or active mode. In this mode, the channel both transmits and receives messages normally and performs other tasks on the network such as acknowledging messages and creating error frames.true
— The channel is in silent mode. You can observe all message activity on the network and perform analysis without affecting the network state or behavior. In this mode, you can only receive messages and not transmit any.
Data Types: logical
TransceiverName
— Name of device transceiver
char
This property is read-only.
TransceiverName
indicates the name of the device transceiver. The
device transceiver translates the digital bit stream going to and coming from the bus
into the real electrical signals present on the bus.
Data Types: char
TransceiverState
— Specify state or mode of transceiver
numeric
If your CAN or J1939 transceiver allows you to control its mode, you can use the
TransceiverState
property to set the mode.
The numeric property value for each mode is defined by the transceiver manufacturer. Refer to your CAN transceiver documentation for the appropriate transceiver modes. Possible modes representing the numeric value specified are:
high speed
high voltage
sleep
wake up
Data Types: single
| double
| int8
| int16
| int32
| int64
| uint8
| uint16
| uint32
| uint64
BusSpeed
— Bit rate of bus transmission
double
This property is read-only.
The BusSpeed
property indicates the speed at which messages are
transmitted in bits per second. The default value is assigned by the vendor driver.
You can set BusSpeed
to a supported bit rate using the
configBusSpeed
function, specifying the
channel name and the bit rate value as input parameters. For example, to change the bus
speed of the CAN channel object canch
to 250,000 bits per second, and
view the result, type
configBusSpeed(canch,250000); bs = canch.BusSpeed
Data Types: double
SJW
— Synchronization jump width (SJW) of bit time segment
double
This property is read-only.
SJW
displays the synchronization jump width of the bit time
segment. To adjust the on-chip bus clock, the controller can shorten or prolong the
length of a bit by an integral number of time segments. The maximum value of these bit
time adjustments are termed the synchronization jump width or
SJW
.
Note
This property is not available for National Instruments CAN
devices. The channel displays NaN
for the value.
Data Types: double
TSEG1,TSEG2
— Allowed number of bits segments to lengthen and shorten sample time
double
This property is read-only.
The TSEG1
and TSEG2
properties indicate
the amount in bit time segments that the channel can lengthen and shorten the sample
time, respectively, to resynchronize or compensate for delay times in the network. The
value is inherited when you configure the bus speed of your CAN channel.
Note
This property is not available for National Instruments CAN
devices. The channel displays NaN
for the value.
Data Types: double
NumOfSamples
— Number of samples available to channel
double
This property is read-only.
The NumOfSamples
property is a bit timing parameter that
indicates the number of bit samples performed for a single bit read on the network. The
value is a positive integer based on the driver settings for the channel.
Note
This property is not available for National Instruments CAN
devices. The channel displays NaN
for the value.
Data Types: double
Other Information
UserData
— Custom data
any data
Enter custom data to be stored in your CAN message or a J1939 parameter group,
channel, or database object using the UserData
property. When you
save an object with UserData
specified, you automatically save the
custom data. When you load an object with UserData
specified, you
automatically load the custom data.
Tip
To avoid unexpected results when you save and load an object with
UserData
, specify your custom data in simple data types and
constructs.
Data Types: single
| double
| int8
| int16
| int32
| int64
| uint8
| uint16
| uint32
| uint64
| logical
| char
| string
| struct
| table
| cell
| function_handle
| categorical
| datetime
| duration
| calendarDuration
| fi
Complex Number Support: Yes
Version History
Introduced in R2015b
See Also
Functions
j1939Channel
|j1939ParameterGroup
|filterAllowOnly
|filterAllowAll
|filterBlockAll
|configBusSpeed
|receive
|transmit
Properties
Topics
MATLAB Command
You clicked a link that corresponds to this MATLAB command:
Run the command by entering it in the MATLAB Command Window. Web browsers do not support MATLAB commands.
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
- América Latina (Español)
- Canada (English)
- United States (English)
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)
Asia Pacific
- Australia (English)
- India (English)
- New Zealand (English)
- 中国
- 日本Japanese (日本語)
- 한국Korean (한국어)