MATLAB 도움말 센터
Information about CAN database messages
msgInfo = messageInfo(candb)
msgInfo = messageInfo(candb,msgName)
msgInfo = messageInfo(candb,id,msgIsExtended)
msgInfo = messageInfo(candb) returns a structure with information about the CAN messages in the specified database candb.
msgInfo
candb
example
msgInfo = messageInfo(candb,msgName) returns information about the specified message 'msgName'.
msgName
'msgName'
msgInfo = messageInfo(candb,id,msgIsExtended) returns information about the message with the specified standard or extended ID.
id
msgIsExtended
collapse all
Get information from all messages in a CAN database.
candb = canDatabase('J1939DB.dbc'); msgInfo = messageInfo(candb)
msgInfo = 3x1 struct array with fields: Name Comment ID Extended J1939 Length Signals SignalInfo TxNodes Attributes AttributeInfo
You can index into the structure for information on a particular message.
Get information from one message in a CAN database using the message name.
candb = canDatabase('J1939DB.dbc'); msgInfo = messageInfo(candb,'A1')
msgInfo = Name: 'A1' Comment: 'This is an A1 message' ID: 419364350 Extended: 1 J1939: [1x1 struct] Length: 8 Signals: {2x1 cell} SignalInfo: [2x1 struct] TxNodes: {'AerodynamicControl'} Attributes: {4x1 cell} AttributeInfo: [4x1 struct]
Get information from one message in a CAN database using the message ID.
candb = canDatabase('J1939DB.dbc'); msgInfo = messageInfo(candb,419364350,true)
CAN database, specified as a CAN database object. candb identifies the database containing the CAN messages that you want information about.
Example: candb = canDatabase(_____)
candb = canDatabase(_____)
Message name, specified as a character vector or string. Provide the name of the message you want information about.
Example: 'A1'
'A1'
Data Types: char | string
char
string
Message ID, specified as a numeric value. id is the numeric identifier of the specified message, in either extended or standard form.
Example: 419364350
419364350
Data Types: single | double | int8 | int16 | int32 | int64 | uint8 | uint16 | uint32 | uint64
single
double
int8
int16
int32
int64
uint8
uint16
uint32
uint64
Message ID format, specified as a logical. Specify whether the message ID is in standard or extended type. Use the logical value true if extended, or false if standard. There is no default; you must provide this argument when using a message ID.
true
false
Example: true
Data Types: logical
logical
Message information, returned as a structure or array of structures for the specified CAN database and messages.
Introduced in R2009a
canDatabase
attributeInfo
nodeInfo
signalInfo
canMessage
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.
웹사이트 선택
번역된 콘텐츠를 보고 지역별 이벤트와 혜택을 살펴보려면 웹사이트를 선택하십시오. 현재 계신 지역에 따라 다음 웹사이트를 권장합니다:
또한 다음 목록에서 웹사이트를 선택하실 수도 있습니다.
사이트 성능 최적화 방법
최고의 사이트 성능을 위해 중국 사이트(중국어 또는 영어)를 선택하십시오. 현재 계신 지역에서는 다른 국가의 MathWorks 사이트 방문이 최적화되지 않았습니다.
미주
유럽
아시아 태평양
지역별 지사에 문의