Automotive and Embedded Networks

cancel
Showing results for 
Search instead for 
Did you mean: 

LabVIEW ECU MC Examples

Hi i'm a bit confused.

I have executed the XCP TestECU.vi successfully with LabVIEW and Veristand as a ECU Simulator.

 

Later, I tried to control a real ECU with the Veristand XCP Master Custom Device, and I didn't succeed.

 

I know that the Custom Device uses LabVIEW code. How can I control the ECU directly from the LabVIEW ECU MC examples? Is it possible?

 

Regards.

ecu.PNG

 

 

 

=======
My Channel: https://www.youtube.com/@LV_Lab

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

Can you provide more information about your attempts to use the custom device? What went wrong? Were you getting errors?

 

The LabVIEW examples were designed to work with the Demo ECU shipping examples but they can also work with live ECUs. They require an A2L file for the ECU in question just like the VeriStand Custom device does. With that, you can achieve the same functionality in LabVIEW as you would in VeriStand plus additional flexibility.

Jeff L
National Instruments
0 Kudos
Message 2 of 7
(4,563 Views)

https://forums.ni.com/t5/Automotive-and-Embedded-Networks/XCP-CCP-Custom-Device-Communication-errors... here is the information. But I couldn't follow because I couldn't do what you told me to do. I got more errors.

 

Oh ok thanks! So instead of running the VI XcpECU I turn my ECU on and load my a2l file into any VI from the Examples from NI, right?

 

I was trying to open my a2l file with the READ A2L FUNCTION.vi but I didn't work. It opens the XcpECU.a2l without problems and also another a2l file I found on Internet. But not my a2l file.

 

The M_C Explorer.vi does open my a2l file. And I think this is strange.

 

I was comparing the a2l files and I found some important differences. In the XcpECU.a2l file I removed or changed some parts to be the same as in the a2l file that doesnt work. But it still work on LabVIEW.

 

But then when I open the files that I modified in software from VECTOR I can see that the changes I made corrupted the a2l file. But it still works on LabVIEW.

=======
My Channel: https://www.youtube.com/@LV_Lab

0 Kudos
Message 3 of 7
(4,547 Views)

Can you attach your original and modified A2L files for review?  I know that we would have to perform some minor changes primarily to the configuration part of the A2L file when using the Vector CANTech DBC files that we would save as with the ASAP2 option.

Help the Community (and future reviewers) by marking posts as follows:
If it helped - KUDOS
If it answers the issue - SOLUTION
0 Kudos
Message 4 of 7
(4,543 Views)

If you can't post the A2L publicly would you be able to send them to me via direct message? I can take a look at them and see if I can find anything wrong.

Jeff L
National Instruments
Message 5 of 7
(4,538 Views)

Try using the A2L Viewer utility that installs with ECUMC. You can find it in the start menu under National Instruments.

 

The short A2L file opens fine and when the "Error List" button is pressed it checks the A2L for problems but finds none. This A2L should be good.

 

The long A2L has some problems. When you analyze the file, it will report quite a few problems with certain characteristics. It will tell you that the error code is "301002" and the property for the error is the "Unit" property. This error indicates that there is no unit information for that specific characteristic in the A2L. You can click the "Characteristic" item in the tree view on the left, type the name of a characteristic that was in the error list into the Filter text box, and then you can see that the "Unit" field of the characteristic is red. Indicating this data wasn't contained in the A2L.

 

Notice this isn't a negative error number so it is just a warning. You may be able to ignore it. It isn't very clear why you are trying to read the A2L using the MC Read A2L.vi. To interact with the ECU using the API, you would typically start with the MC ECU Open.vi which takes a file reference for the A2L as an input. I don't have an ECU to test with but the MC ECU Open.vi parsed both A2L files without issue.

Jeff L
National Instruments
Message 6 of 7
(4,523 Views)

I was trying to use MC Read A2L.vi just to confirm that LabView doesnt have any problem reading the a2l file.

It's really strange that you were able to open it, i'm using LabVIEW 2016 and ECU MC 2018 but I don't think that matters.

 

Thank you for taking your time i will keep trying.

 

 

=======
My Channel: https://www.youtube.com/@LV_Lab

0 Kudos
Message 7 of 7
(4,519 Views)