MMS 012c5c360e 7.3.0
Added QP Functional Safety (FuSa) Subsystem
Memory Isolation with MPU
MISRA-C:2023 compliance
Changed comments from C-style to C++ style
Added QAsm abstract state machine base class
Added memory marker to QEvt and rearranged memory layout
Updated: QP-FreeRTOS, QP-ESP-IDF,QP-Zephyr
Added drift-free ticking for QP-POSIX
Reorganized documentation
Updated 3rd_party
2023-09-13 20:25:46 -04:00

114 lines
3.3 KiB
XML

<?xml version="1.0" encoding="UTF-8"?>
<model version="5.3.0" links="1">
<documentation>Start sequence example</documentation>
<!--${qpc}-->
<framework name="qpc"/>
<!--${AOs}-->
<package name="AOs" stereotype="0x02">
<!--${AOs::Gizmo}-->
<class name="Gizmo" superclass="qpc::QActive">
<!--${AOs::Gizmo::inst}-->
<attribute name="inst" type="Gizmo" visibility="0x00" properties="0x01">
<documentation>the only instance of this AO (Singleton)</documentation>
</attribute>
<!--${AOs::Gizmo::SM}-->
<statechart properties="0x03">
<!--${AOs::Gizmo::SM::initial}-->
<initial target="../1">
<action>Q_UNUSED_PAR(par);</action>
<initial_glyph conn="2,2,5,1,20,6,-2">
<action box="1,0,6,2"/>
</initial_glyph>
</initial>
<!--${AOs::Gizmo::SM::init}-->
<state name="init">
<entry brief="self-post START">static QEvt const startEvt = QEVT_INITIALIZER(START_SIG);
QACTIVE_POST(&amp;me-&gt;super, &amp;startEvt, me); // self-post</entry>
<!--${AOs::Gizmo::SM::init::START}-->
<tran trig="START">
<action>QS_BEGIN_ID(QS_USER1, me-&gt;super.prio)
QS_STR(&quot;START&quot;);
QS_END()</action>
<!--${AOs::Gizmo::SM::init::START::[BSP_getStatus()]}-->
<choice target="../../../3">
<guard>BSP_getStatus()</guard>
<choice_glyph conn="26,14,5,0,16,8">
<action box="1,0,16,3"/>
</choice_glyph>
</choice>
<!--${AOs::Gizmo::SM::init::START::[else]}-->
<choice target="../../../2">
<guard brief="else"/>
<choice_glyph conn="26,14,4,1,10,-6">
<action box="-4,10,10,2"/>
</choice_glyph>
</choice>
<tran_glyph conn="2,14,3,-1,24">
<action box="0,-2,10,2"/>
</tran_glyph>
</tran>
<state_glyph node="2,6,18,12">
<entry box="1,2,15,2"/>
</state_glyph>
</state>
<!--${AOs::Gizmo::SM::on_battery}-->
<state name="on_battery">
<state_glyph node="2,22,18,10"/>
</state>
<!--${AOs::Gizmo::SM::on_mains}-->
<state name="on_mains">
<state_glyph node="30,22,15,10"/>
</state>
<state_diagram size="48,34"/>
</statechart>
</class>
<!--${AOs::Gizmo_ctor}-->
<operation name="Gizmo_ctor" type="void" visibility="0x00" properties="0x00">
<code>Gizmo *me = &amp;Gizmo_inst;
QActive_ctor(&amp;me-&gt;super, Q_STATE_CAST(&amp;Gizmo_initial));</code>
</operation>
<!--${AOs::AO_Gizmo}-->
<attribute name="AO_Gizmo" type="QActive * const" visibility="0x00" properties="0x00">
<documentation>// opaque pointer to the Gizmo AO</documentation>
<code>= &amp;Gizmo_inst.super;</code>
</attribute>
</package>
<!--${src}-->
<directory name="src">
<!--${src::gizmo.h}-->
<file name="gizmo.h">
<text>#ifndef GIZMO_H_
#define GIZMO_H_
enum BlinkySignals {
DUMMY_SIG = Q_USER_SIG,
// ...
MAX_PUB_SIG, // the last published signal
START_SIG,
// ...
MAX_SIG // the last signal
};
$declare ${AOs::AO_Gizmo}
$declare ${AOs::Gizmo_ctor}
#endif // GIZMO_H_</text>
</file>
<!--${src::gizmo.c}-->
<file name="gizmo.c">
<text>#include &quot;qpc.h&quot;
#include &quot;bsp.h&quot;
#include &quot;gizmo.h&quot;
//Q_DEFINE_THIS_MODULE(&quot;gizmo&quot;)
$declare ${AOs::Gizmo}
$define ${AOs::AO_Gizmo}
$define ${AOs::Gizmo_ctor}
$define ${AOs::Gizmo}</text>
</file>
</directory>
</model>