AUTOSAR COM
Four timing words
Triggered, pending, immediate, deferred. Two are about sending, two are about receiving. Click the two toys below and you will know all four.
Two timing questions
From lesson 1: the application hands COM single values (signals), and COM carries them in packets (I-PDUs). That leaves COM two timing questions to answer. Each one has two possible answers, and those are our four words.
Sending: triggered or pending?
The question: when the application writes a new value, does the packet go out because of it?
set per signal
TRIGGERED
"Send it now." Writing this signal makes the packet go out.
set per signal
PENDING
"No rush." The new value waits in COM and rides along the next time the packet goes out for any other reason.
What other reason? A triggered signal in the same packet, or a timer. Whether there is a timer is a setting of the packet:
set per packet
DIRECT
No timer. The packet only goes out when a triggered signal is written.
set per packet
PERIODIC
Timer only. The packet goes out at a fixed rhythm and nothing else.
set per packet
MIXED
Both. Timer, plus right away when a triggered signal is written.
Try it
One packet carries two signals. Speed is triggered, temperature is pending. Write some values and watch the bus lane. A label like S2 T1 means the packet carried speed 2 and temp 1. Then change the packet setting and try again.
Things to notice. With DIRECT, a temperature you write stays stuck in COM until you write a speed. With PERIODIC, even writing speed does nothing until the timer fires. With MIXED you get both.
Receiving: immediate or deferred?
The question: when a packet arrives, when is the application told?
set per packet
IMMEDIATE
Right now, in the same moment the packet arrives.
set per packet
DEFERRED
A little later. COM keeps the data and tells the application the next time COM's own regular job runs.
That regular job is called COM's main function. The system calls it at a fixed rhythm, like a heartbeat. Deferred is calmer for the system, because the application is never interrupted in the middle of something. Immediate is faster.
Try it
Let a few packets arrive and watch when the application is told. The small dots are the heartbeat.
What you can do now. Read the four words in any COM setup and say what will happen: does a write cause a send, and when does the receiver hear about it.
Check yourself
Optional. Answer from memory, without scrolling up.
The AUTOSAR words
| Plain word here | AUTOSAR word |
|---|---|
| Packet | I-PDU |
| Triggered / pending | The signal's transfer property |
| Direct / periodic / mixed | The I-PDU's transmission mode |
| Immediate / deferred | The I-PDU's signal processing |
| Heartbeat | Main function (Com_MainFunctionRx, Com_MainFunctionTx) |
Source: AUTOSAR COM specification, R25-11, sections 7.2.3.1 and 7.2.5.4 (SWS_Com_00330, SWS_Com_00300, SWS_Com_00301). "Right away" for a triggered send means at the latest when COM's main function next runs. Triggered also has variants: only when the value changed, and with or without repeats (see the next lesson).