ni/niveristand-aim-milStd1553-custom-device

How To Set Execution Time of Messages Within Minor Frame

Opened this issue · 2 comments

KHsu2 commented

I would like to set the time each message is sent in a minor frame, relative to the start of the minor frame. As far as I can tell from the documentation the only timing that may be set is the period of each minor frame. Am I correct in this? How is the timing of each message determined? Does it launch each message in a minor frame as quickly as it can, waits until the minor frame ends, then executes the following minor frame? Is there any workaround to setting the execution time of each message?

After looking at the code, I think the documentation in the Frame section of the Parameters file is not accurate. When the Bus Controller is initialized, one Minor Frame Time value is set for all minor frame transmissions.

image

The AIM API help for the ApiCmdBCStart function says the frame time is the time from the start of one minor frame to the start of the next.
image

Although you can define per the XML schema a frame time per minor frame, I'm assuming that the custom device only persists the first value and uses it across all messages.

KHsu2 commented

Thanks for the quick response!

I am fine with the minor frame duration being the same across all minor frames. In my case, I am planning to have multiple messages in a minor frame but I want to be able to customize when those messages execute within the minor frame duration. Does this sound reasonable / possible?

So far, it sounds like the best way to implement what I want is to set up a ton of minor frames with a shorter duration, and populate the minor frames with a single message that occur at the time that I want the message to execute. This sounds less than ideal.