Automotive and Embedded Networks

cancel
Showing results for 
Search instead for 
Did you mean: 

Multiframe Message Implementation

Hi,
im facing a  protocol implementation problem for J1939 which is specified in

SAE I N T E R N A T I O N A L SURFACE VEHICLE RECOMMENDED PRACTICE (J1939-21 ) REV APR 2001 for SAE J1939 Data Link Layer Implementation section 5.10.3.5 and

5.10.4

 in which i have to implement a CAN Message with 2 Periodicities.i.e I have to send a Broadcast Announce Message(BAM) with 5 sec periodicity which will be an announcement for the Nodes that a Multiframe message(Message with 24 bytes) which consisit of 3 frames
coming at 100 ms periodicity.i.e
1.bam messagecoming at 5000ms
2.Tpdt frame follwed by bam at 5100 ms
3.Same tpdt with different data at 5200ms
4.One more tpdt at 5300ms
5.tpdt's  transmition is interrupted till next bam coming at 10300ms then the tpdt cycle proceeds.
The above mentioned cycle is required to initialise some of the Nodes in a network of ECU's.
so i cannot initialise tpdt with fixed periodicity and data content.
Currently Channel api is used for the application to implment CAN.
My question is:
1.is it possible to implement the same with frame API's?
2.How can i modify the channel api to implement the same ?
 
Thax and Regards
Manu Mohan
 

 

 


0 Kudos
Message 1 of 9
(10,969 Views)
Hi Manu Mohan,

It does not look like you should have too much trouble setting that up in the Channel API. You will want to set the CAN channels up in MAX to specify the different  messages that you have. This can be found in the CAN Channels section (pg 34) of the NI-CAN manual that can be found here.

Let us know how it goes!
Rasheel
0 Kudos
Message 2 of 9
(10,947 Views)
Hi Rasheel,
Thax for the info.The problem here is not about creating a message.I already have 2 messages which is defined in a dbc file which i imported to max.
My issue is ,these messages are dependent to each other and one message have a variable periodicity with multiple data for same signal.
Do you think this can be addresses in the driver layer itself instead of moving up to the API Level ?
0 Kudos
Message 3 of 9
(10,938 Views)
Can you give me an example of what you mean by one message depending on another? How are they dependent?

Unfortunately you cannot make any adjustments in the driver layer, we will have to use the API to configure things.
Rasheel
0 Kudos
Message 4 of 9
(10,925 Views)

DMC recently developed a set of J1939 protocol drivers for LabVIEW which are based on the NI-CAN channel API.  The drivers are written in LabVIEW just like the Frame example provided by NI, but they provide functions at a layer above the base CAN channel API layer.  This allows the simultaneous capture of data from both J1939 packets which are simple broadcast CAN frames, or more complex transport using BAM, including extended data frames.

 

When using the Channel API aprroach, you are going to have certain messages in MAX, such as TP packets, which can function in a variety of modes (start / stop / request) based on a mode or parameters channel within the message.  We created a multiplexer in our CAN database to handle this.  I think this way you could send the message at mutliple rates in different CAN channel tasks, one for each 'mode' of the message.  So BAM could be sent at one rate, while TP start at another.

 

Hipe that helps.

0 Kudos
Message 5 of 9
(9,801 Views)

Correct link for J1939 protocol drivers for LabVIEW which are based on the NI-CAN channel API. Smiley Happy

0 Kudos
Message 6 of 9
(9,799 Views)

Hi,

it seems the driver is based on the XNET, is there a driver based on NI-CAN?

0 Kudos
Message 7 of 9
(4,108 Views)

In the future you might want to make a new thread.  This one hasn't seen a reply in 9 years, and most involved are probably not monitoring it.  Next I'd suggest you do searching before making a new thread since the first couple Google results for XNet J1939 seem to suggest there are exampled installed with XNet that show how to do it.

 

https://knowledge.ni.com/KnowledgeArticleDetails?id=kA00Z000000kFycSAE&l=en-US

0 Kudos
Message 8 of 9
(4,099 Views)

This may help.

Several years ago, I developped an NI-CAN J1939 application based on an example from NI.

0 Kudos
Message 9 of 9
(4,091 Views)