VeriStand

cancel
Showing results for 
Search instead for 
Did you mean: 

Is there a way to log all traffic on a CAN port in VeriStand?

Hello,

 

I'm looking for a way to log all traffic on a given port in VeriStand.  Basically I'd like to assign a DBC file to that port and then simply log everything but I can't see a way to do this in VeriStand.  I've tried the Raw frame logging and choosing the "log entire bus traffic" option but end up with just a single channel "Engine Timestamp".  I'm currently using the embedded data logger but that requires me to have imported the frames I want to log and the DBC file is simply too big for VeriStand, it doesn't seem to be particularily efficient at adding additional CAN frames and to try and add the entire DBC file essentially locks up VeriStand.  Any suggestions or something I've simply missed?  Thanks.



I saw my father do some work on a car once as a kid and I asked him "How did you know how to do that?" He responded "I didn't, I had to figure it out."
0 Kudos
Message 1 of 18
(6,239 Views)

What are you using to view the file when you only see the EngineTimestamp channel? Are you using DIAdem perhaps?

Jarrod S.
National Instruments
0 Kudos
Message 2 of 18
(6,237 Views)

I was using DIAdem, however I have since solved this issue by creating a logger similar to the Embedded Data Logger but specifically for CAN signals so I can log to directly to MDF, ASC, etc without having to convert post process.



I saw my father do some work on a car once as a kid and I asked him "How did you know how to do that?" He responded "I didn't, I had to figure it out."
Message 3 of 18
(6,148 Views)

Thanks for the update! If anyone else has the same question, the answer is that in order to extract the bus log information in the TDMS file, you should use the DIAdem Bus Log Converter tool. It is expected (though confusing) that the file looks mostly empty in the Data Portal until you use this tool to extract the information.

 

Also, this is a fantastic tutorial from a very bright engineer on how to correlate data from multiple sources, such as raw frame files, in DIAdem. Highly recommended reading. It also has some data on the bus log converter.

 

Jarrod S.
National Instruments
0 Kudos
Message 4 of 18
(6,144 Views)
blackburnite, I also want to log received frames on a CAN. I'm using Raw Frame Data Logging. When I create a new log file,the "Destination " is gray and I can't modify it.The destination is "C——ni-rt—— NIVeristand——XNET——Raw Data Logs" ,whice is not the same with the destination that I set at first. Also ,I don't know whether the "trigger channel" that I specified has some rules. Because when the trigger channel satisfieds the condition ,it doesn't create any .ncl files in my specified destination or in C——ni-rt—— NIVeristand——XNET——Raw Data Logs. Hope for your help!Thanks
0 Kudos
Message 5 of 18
(5,532 Views)

This help article is a good resource for configuring raw frame data logging. You should be able to add additional files you want to log to using this method. Finally, this article contains more detailed information on the effect of the trigger settings. I hope this helps. 

Miles G.
National Instruments
Staff Applications Engineering Specialist
0 Kudos
Message 6 of 18
(5,506 Views)
Miles, Thanks for your answer! I find the probem is that the log file stores in the remote system.So I can't find it on my local computer. I'm using teststand and HIL to do automative test. I want to log the CAN messages whose ID is 0x18DAF100. But the CAN message 0x18DAF100 is muti-frame messages. It changes over time. I hope that Teststand can log all of the messages whose ID are 0x18DAF100.If I can log the CAN messages and put them into an array, I can analyse whether the array has the message I want.Do you have any ideas? Thanks a lot!
0 Kudos
Message 7 of 18
(5,482 Views)

Could you clarify are you using VeriStand at all? Your first message implied that you were using this environment, but your most recent message makes it seem like you might be using TestStand exclusively. Depending on whether you are managing things through VeriStand, or TestStand you will need a different solution. If you are in VeriStand I believe you could use Raw Frame Data Logging, but it would take a bit of research to get the exact configuration settings right. If you are using TestStand I would recommend developing a VI in LabVIEW that uses the XNET driver to log these frames and then calling it as a step. If you are calling VeriStand from TestStand then you would still configure raw frame data logging in your VeriStand system definition. Which of these situations are you dealing with? 

Miles G.
National Instruments
Staff Applications Engineering Specialist
0 Kudos
Message 8 of 18
(5,472 Views)
miles, I am calling VeriStand from TestStand and using the HIL. I can log the messages on the “NI-XNET——CAN——Incoming" bus traffic now.But I still have two problems.Firstly,the logging file‘s format is .ncl. Secondly, the files that I log are saved in the remote system. The remote system’s mode is PXI8110.I need to upload the logging filles from remote system to my local computer which is using Teststand manually. How can Teststand analyse the logging files automotively? I want to analyse the data that whether has the content I want. Thanks!
0 Kudos
Message 9 of 18
(5,462 Views)

What file format do you want the files to be saved as? As for moving the files over, you can set up a LabVIEW step to either WebDAV or FTP the files off of the target in order to make them available for analysis in windows. That, or depending on the type of analysis you want to do, you could write a custom device to do it on the Real-Time side. Though I would say the TestStand LabVIEW method would be much simpler than writing a custom device. 

Miles G.
National Instruments
Staff Applications Engineering Specialist
0 Kudos
Message 10 of 18
(5,433 Views)