Automotive and Embedded Networks

cancel
Showing results for 
Search instead for 
Did you mean: 

Missing ID's When running Basic Frame Signal Conversion Example.vi Version 8

Hi,

I am using the Basic Frame Signal Conversion Example.vi Version 8 to process my .dbc file. It seems that the VI does not understand the first entries in the dbc file. I do not see it in the Signals Received at Tester array. Here is the first entry in the dbc file. The first number translates to 80078000h:

 

BO_ 2147975168 AFE_Identification: 8 ADM_PC_BP25
SG_ Device_type : 0|8@1+ (1,0) [0|255] "" Vector__XXX
SG_ HW_revision : 8|8@1+ (1,0) [0|255] "" Vector__XXX
SG_ HW_variant : 16|8@1+ (1,0) [0|255] "" Vector__XXX
SG_ Stack_position : 24|8@1+ (1,0) [0|255] "" Vector__XXX
SG_ SN_number : 32|32@1+ (1,0) [0|4294967295] "" Vector__XXX

 

The Second entry is 80078001h:

 

BO_ 2147975169 AFE_FwInfo: 8 ADM_PC_BP25
SG_ FW_info_mux M : 56|8@1+ (1,0) [0|255] "" Vector__XXX
SG_ FW_revision_0 m0 : 0|8@1+ (1,0) [0|255] "" Vector__XXX
SG_ FW_revision_1 m0 : 8|8@1+ (1,0) [0|255] "" Vector__XXX
SG_ FW_revision_2 m0 : 16|8@1+ (1,0) [0|255] "" Vector__XXX
SG_ FW_revision_3 m0 : 24|8@1+ (1,0) [0|255] "" Vector__XXX
SG_ FW_revision_4 m0 : 32|8@1+ (1,0) [0|255] "" Vector__XXX
SG_ FW_revision_5 m0 : 40|8@1+ (1,0) [0|255] "" Vector__XXX
SG_ FW_revision_6 m0 : 48|8@1+ (1,0) [0|255] "" Vector__XXX
SG_ FW_revision_7 m1 : 0|8@1+ (1,0) [0|255] "" Vector__XXX
SG_ FW_revision_8 m1 : 8|8@1+ (1,0) [0|255] "" Vector__XXX
SG_ FW_revision_9 m1 : 16|8@1+ (1,0) [0|255] "" Vector__XXX
SG_ FW_revision_10 m1 : 24|8@1+ (1,0) [0|255] "" Vector__XXX
SG_ FW_revision_11 m1 : 32|8@1+ (1,0) [0|255] "" Vector__XXX
SG_ FW_revision_12 m1 : 40|8@1+ (1,0) [0|255] "" Vector__XXX
SG_ FW_revision_13 m1 : 48|8@1+ (1,0) [0|255] "" Vector__XXX
SG_ FW_datecode_0 m2 : 0|8@1+ (1,0) [0|255] "" Vector__XXX
SG_ FW_datecode_1 m2 : 8|8@1+ (1,0) [0|255] "" Vector__XXX
SG_ FW_datecode_2 m2 : 16|8@1+ (1,0) [0|255] "" Vector__XXX
SG_ FW_datecode_3 m2 : 24|8@1+ (1,0) [0|255] "" Vector__XXX
SG_ FW_datecode_4 m2 : 32|8@1+ (1,0) [0|255] "" Vector__XXX
SG_ FW_datecode_5 m2 : 40|8@1+ (1,0) [0|255] "" Vector__XXX
SG_ FW_datecode_6 m2 : 48|8@1+ (1,0) [0|255] "" Vector__XXX
SG_ FW_datecode_7 m3 : 0|8@1+ (1,0) [0|255] "" Vector__XXX
SG_ FW_datecode_8 m3 : 8|8@1+ (1,0) [0|255] "" Vector__XXX
SG_ FW_datecode_9 m3 : 16|8@1+ (1,0) [0|255] "" Vector__XXX
SG_ FW_datecode_10 m3 : 24|8@1+ (1,0) [0|255] "" Vector__XXX
SG_ FW_datecode_11 m3 : 32|8@1+ (1,0) [0|255] "" Vector__XXX
SG_ FW_datecode_12 m3 : 40|8@1+ (1,0) [0|255] "" Vector__XXX
SG_ FW_datecode_13 m3 : 48|8@1+ (1,0) [0|255] "" Vector__XXX

 

Neither are visible in the Basic Frame Signal Conversion Example.vi Version 8.

 

What is the optimum way to extract these signals from the frames?

 

0 Kudos
Message 1 of 7
(2,038 Views)

Hi,

Sorry, I'm new at working with the CAN bus. I meant to say "Message ID's or identifier". 

SaltyDoug_0-1667278591064.png

I am using the Peak USB CAN hardware and the KDI LabVIEW code to talk to the CAN Bus.

I would like to read the Serial number and the firmware version on Channel 2.

0 Kudos
Message 2 of 7
(2,030 Views)

Thanks for attaching the DBC, that will make it helpful.  What is the signal name you are looking for?  Despite my CAN knowledge I'm not actually that familiar with the DBC structure.  The XNet database parsing code has always worked well enough for me that I don't dig into it.  Are you saying you can't find the signal "Device_type" in the database?  I'm pretty sure it is in there.

 

If you are saying it isn't returned from the Signals Received at Tester, then that information comes from the ECU section of the DBC.  Open the NI-XNet Database Editor (it should be in your start menu), then go to File >> Open, click Browse, and pick your DBC.  You may need to specify a baud rate.  Then under the ECU section you can find the listed ECUs.  In my code when I list out the signals to be sent, and received, it just pulls it from here.  If your signal isn't listed there, then that explains why it isn't populated in the array from my subVI.  You can edit the database or DBC, or you can just perform a build array, adding your own additional signals if you know they are there.  If they aren't you'll get an error when you try to use them.

0 Kudos
Message 3 of 7
(1,995 Views)

Thanks for your help. I know very little about the database as well.

The signals that are in the beginning of the database when opened with Notepad. They are in my first message above.

BO_ 2147975168 AFE_Identification

 

I will try using the Database editor and let you know.

0 Kudos
Message 4 of 7
(1,975 Views)

Hi and thanks for your help. I am not very knowledgeable on the database either.

I used Notepad to open the database file and I pasted the first two message ID's, 2078000hex and 2078001hex in my first message above.

 

At your suggestion I opened the database file with the Database Editor and the two signals were missing there as well.

 

I can see these messages, 2078000hex and 2078001hex, in the CAN bus using a Peak adapter and my VI.

I need to decode them so any help that you can give is much appreciated.

Here is my VI that I have created.

0 Kudos
Message 5 of 7
(1,976 Views)

I'm guessing there is more to adding signals to a DBC then the steps you made.  I'd suggest using NI's XNet Database Editor again.  Here you can add frames, add signals, set scaling, and all kinds of other settings.  Then you can export the whole database into a new DBC using the Database Editor.

0 Kudos
Message 6 of 7
(1,971 Views)

Sorry that I was not clear in my description, I did not modify the database file with Notepad, I only copied the text from the file to this forum message.

 

Doug

0 Kudos
Message 7 of 7
(1,949 Views)