LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How can I set the timebase in the FPGA API for the NI 9853 CAN module?

Hallo,

is there anybody familiar with cRIO, especially the NI CAN 9853 Modul?

When starting communication with a CAN Bus  you can get a receiving CAN Frames from the FPGA I/O Node with a timestamp.
How can  I set  this  timebase in the CAN Controller, because the CAN communication starts every time with the same timebase.

Compared to the CAN API  on a PC the timebase for the communication is set when the Open Frame API VI is used?
From that time the CAN Contoller assume the timebase from the PC.
Whats about the FPGA API?

Martin

0 Kudos
Message 1 of 3
(2,743 Views)
Hi Martin,
 
The Timestamp starts when the Start is executed for the Module Port. If the Auto Start option is set , it starts immediately after running the program.
otherwise you have to uncheck the auto start option and use instead the start method node. It is always starting from zero and there is no alignment to any OS Timer.
 
DirkW
Message 2 of 3
(2,731 Views)

Hallo Dirk,

 

thanks you for your answerer regarding my question.

 

The last question belongs to my intention, to get absolute Timestamps from the NI 9853 CAN interface. As you said it always starts from zero when starting the application.

 

For my application I would like to get a timestamp with the local time I start the CAN communication and every CAN Frame should be logged with the Timestamp it is actually send on the CAN BUS.

How can I achieve it?

 

My first thoughts were to add up the timestamp for every CAN Frame counted from zero to an absolute Timestamp when starting communication. But I have got some wrong values. Maybe I did something wrong using the high and low part of the Timestamps I got from the CAN API.

 

Do you have a suggestion for me?

 

MartinW      

0 Kudos
Message 3 of 3
(2,705 Views)