DASYLab

cancel
Showing results for 
Search instead for 
Did you mean: 

NI 9862, configuration

Solved!
Go to solution

Hello
So I have at my disposal three kinds of CAN module:
NI-CAN CA, NI-CAN XNET and NI-CAN FA.
When I try to take NI-CAN CA and NI-CAN XNET modules Dasylab tells me to create a pre-task.
But when I use NI-CAN FA it does not cause me any problem.

Capture1.PNG

 


My question is: Does it matter if I use the NI-CAN FA and what is the difference between NI-CAN CA, NI-CAN XNET and NI-CAN FA because I can not find an answer on Internet.
Thank you.

0 Kudos
Message 11 of 21
(3,752 Views)

I've asked the expert to chime in on this, but he's out of the office for a few days. 

I'm sorry for the delay -- contact me directly if you need help more urgently. 

Measurement Computing (MCC) has free technical support. Visit www.mccdaq.com and click on the "Support" tab for all support options, including DASYLab.
Message 12 of 21
(3,748 Views)

Thank you CJ,
I'm going to do some research on my side as long as the expert who works with you gets back to work.
I'm just asking you to keep me informed.
Thank you

0 Kudos
Message 13 of 21
(3,739 Views)
Solution
Accepted by topic author UTC-Aerospace

UTC-Aerospace wrote: [...]

My question is: Does it matter if I use the NI-CAN FA and what is the difference between NI-CAN CA, NI-CAN XNET and NI-CAN FA [...]

I am not really a CAN expert, but... let's try.

 

NI-CAN CA, NI-CAN FA

CA = Channel API

FA = Frame API

 

When using the NI-CAN FA modules, DASYLab gets the specified CAN telegram, the whole frame. For one of the module's channels, you have to tell the module the telegram ID ("object identifier"), and the "size" and "position" of a value in that telegram. A telegram's size is 8 bytes/64bit, so a telegram can carry multiple values. E.g. a devices temperature is in telegram 11, start bit (or byte) 0, size "signed byte", the next value in the same telegram (eg. the todays total kilometers) is starting at byte 1 and of type "unsigned integer", and so on. So, one channel in NI-CAN FA module defines the value from a telegram to output at one of the module's outputs. You can read values from different telegrams in one module.

 

When using the NI-CAN CA modules, DASYLab gets the telegrams' values from the NI-MAX "channel-wise". Now, you have to do the configuration in MAX (define CAN channels). On the previous page of this thread there is a screenshot of the MAX's tree-structure with a context menue: "Create Message". Here you have to tell the MAX, what telegram ID's you are interested in, also you have to specifiy the values that are transported in the telegrams (see attached picture).

When you are done, go to DASYLab and sync the MAX' configuration. In the menubar of DASYLab is an option "NI-CAN CA tasks...". Here, create a "DASYLab task for the MAX' CAN channels", you select from the CAN channels created in MAX the ones you want to use in the DASYLab CAN CA module. Each selected CAN channel provides a value that is output by the DASYLab module.

 

Both DASYLab CAN module types (FA, CA), and the "DASYLab task for MAX' CAN channels", can be configured by using a CANdb file instead of specifiing manually telegram IDs and their signals.

 

NI-XNET

I am not familiar with that kind of hardware, but you can use LIN interfaces in addition to CAN interfaces with DASYLab and NI's XNET hardware.

The configuration part for this modules in DASYLab is similar to that of NI-CAN CA configuration steps. In the menubar you have to find the option to create an "XNET task". But you have to have a database file, that provides information about the communication that takes place on the CAN/LIN bus you are about to listen to. Either a CANdb file, or a FIBEX database file.

You can create such a database using the "NI-XNET-Database-Editor" (Start > Programs > National Instruments).

Here's a white paper ( http://www.ni.com/white-paper/9715/en/ ) as starting point for further exploration.

 

Hardware - NI-CAN FA vs. CA in DASYLab

I am not perfectly sure, but it doesnt matter for DASYLab which way you want to go. Mostly it depends on the hardware, if it support the Frame API or the Channel API. I would prefer using the FA way, because you can configure the CAN telegrams and values in DASYLab without using the MAX ("everything under one roof" 😉 ).

 

Hardware - NI-XNET in DASYLab

You can use XNET devices without using the DASYLab XNET modules, instead you can use the "normal" CAN modules.

But you have to install NI-CAN drivers/software in addition to the XNET drivers/software. Also you will need the "NI-XNET Compatibility Library for NI-CAN".

Here's another link for detailed information: http://www.ni.com/tutorial/9717/de/

M.Sc. Holger Wons | measX GmbH&Co. KG, Mönchengladbach, Germany | DASYLab, DIAdem, LabView --- Support, Projects, Training | Platinum NI Alliance Partner | www.measx.com
Message 14 of 21
(3,707 Views)

Thank you very much for your answer.
Just a single ambiguity, for the CAN FA that is only configured on DasyLab, I found that I could not indicate the position of the byte in a single frame.
For example, if I use only bytes 1 and 6, on the CAN FA module of DasyLab I can only put two successive channels next to each other in the module.
it does not matter to do that ?Capture5.PNG

0 Kudos
Message 15 of 21
(3,676 Views)

The DASYLab module's channels do not correspond to the location of values in telegrams. On one channel page of the module you set the value's location and size for a telegram.

 

If you want to put two values into a telegram, then you need two inputs for the module.

In module's channel 0 you configure the telegram ID and the first value's position+size.

In the module's channel 1, you do the same for the second value. Same telegram ID but different position and possibly different size.

The position of the value inside of the telegram is set using the "Start" value in section "Decoding". If it should be the first byte of the telegram, then Start byte is 0 (8 bytes make one telegram).

The second value should be located in byte 6, so the Start byte is 5 -- in the module's channel 1.

M.Sc. Holger Wons | measX GmbH&Co. KG, Mönchengladbach, Germany | DASYLab, DIAdem, LabView --- Support, Projects, Training | Platinum NI Alliance Partner | www.measx.com
0 Kudos
Message 16 of 21
(3,671 Views)

Very informative what you tell me.
But a last little piece of information, on DasyLab I do not know where to choose the position of the byte in the frame?
Thank you.

0 Kudos
Message 17 of 21
(3,658 Views)

NICANFASend_Start.jpg

 

The (your) picture's configuration puts the value received on module's input number 0 into the telegram CFE6CEEh on byte position 5 of 8 (counting from 0 to 7, so the "four" in the picture is the 5th byte position).

8 bytes of size 1 byte (Signed / Unsigned) fit into a telegram that can carry 8 bytes. 😉

M.Sc. Holger Wons | measX GmbH&Co. KG, Mönchengladbach, Germany | DASYLab, DIAdem, LabView --- Support, Projects, Training | Platinum NI Alliance Partner | www.measx.com
0 Kudos
Message 18 of 21
(3,653 Views)

Ahh !!!
I thought that the "start" checkbox checked the bits of the selected bytes and not the bytes themselves.
Thank you very much.

0 Kudos
Message 19 of 21
(3,645 Views)
Solution
Accepted by topic author UTC-Aerospace

I have some more information for you - 

 

NI support is correct -- you cannot use Tasks in MAX for NI-XNET.  There is a tool in DASYLab where you can create XNET kind of Tasks …

You need to configure the XNET Task within DASYLab.  Use the Measurement, Hardware Setup, NI menu to select the tasks. 

I'm sorry that it took so long to figure this out - I ended up reaching out to an NI CAN expert who figured it out immediately. 

 

2017-07-06_09-04.png

Measurement Computing (MCC) has free technical support. Visit www.mccdaq.com and click on the "Support" tab for all support options, including DASYLab.
0 Kudos
Message 20 of 21
(3,579 Views)