Deleted.
main.cpp@3:4df7120f6f33, 2011-09-26 (annotated)
- Committer:
- QL
- Date:
- Mon Sep 26 03:32:15 2011 +0000
- Revision:
- 3:4df7120f6f33
- Parent:
- 2:27716f570c3d
4.2.04
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
QL | 0:9601fa787c8b | 1 | ////////////////////////////////////////////////////////////////////////////// |
QL | 0:9601fa787c8b | 2 | // Model: pelican.qm |
QL | 0:9601fa787c8b | 3 | // File: ./main.cpp |
QL | 0:9601fa787c8b | 4 | // |
QL | 0:9601fa787c8b | 5 | // This file has been generated automatically by QP Modeler (QM). |
QL | 0:9601fa787c8b | 6 | // DO NOT EDIT THIS FILE MANUALLY. |
QL | 0:9601fa787c8b | 7 | // |
QL | 0:9601fa787c8b | 8 | // Please visit www.state-machine.com/qm for more information. |
QL | 0:9601fa787c8b | 9 | ////////////////////////////////////////////////////////////////////////////// |
QL | 0:9601fa787c8b | 10 | #include "qp_port.h" |
QL | 0:9601fa787c8b | 11 | #include "pelican.h" |
QL | 0:9601fa787c8b | 12 | #include "bsp.h" |
QL | 0:9601fa787c8b | 13 | |
QL | 0:9601fa787c8b | 14 | // Local-scope objects ------------------------------------------------------- |
QL | 0:9601fa787c8b | 15 | static QEvent const *l_pelicanQueueSto[5]; |
QL | 0:9601fa787c8b | 16 | static QEvent const *l_pedQueueSto[5]; |
QL | 0:9601fa787c8b | 17 | static QSubscrList l_subscrSto[MAX_PUB_SIG]; |
QL | 0:9601fa787c8b | 18 | static union { |
QL | 2:27716f570c3d | 19 | void *e0; |
QL | 2:27716f570c3d | 20 | uint8_t e1[sizeof(QEvent)]; |
QL | 2:27716f570c3d | 21 | // ... other event types to go into this pool |
QL | 0:9601fa787c8b | 22 | } l_smlPoolSto[10]; // storage for the small event pool |
QL | 0:9601fa787c8b | 23 | |
QL | 0:9601fa787c8b | 24 | //............................................................................ |
QL | 0:9601fa787c8b | 25 | int main(void) { |
QL | 0:9601fa787c8b | 26 | BSP_init(); // initialize the BSP |
QL | 0:9601fa787c8b | 27 | QF::init(); // initialize the framework and the underlying RT kernel |
QL | 0:9601fa787c8b | 28 | // object dictionaries... |
QL | 0:9601fa787c8b | 29 | QS_OBJ_DICTIONARY(l_smlPoolSto); |
QL | 0:9601fa787c8b | 30 | QS_OBJ_DICTIONARY(l_pelicanQueueSto); |
QL | 0:9601fa787c8b | 31 | QS_OBJ_DICTIONARY(l_pedQueueSto); |
QL | 0:9601fa787c8b | 32 | |
QL | 0:9601fa787c8b | 33 | QF::psInit(l_subscrSto, Q_DIM(l_subscrSto)); // init publish-subscribe |
QL | 0:9601fa787c8b | 34 | // initialize event pools... |
QL | 0:9601fa787c8b | 35 | QF::poolInit(l_smlPoolSto, sizeof(l_smlPoolSto), sizeof(l_smlPoolSto[0])); |
QL | 0:9601fa787c8b | 36 | |
QL | 0:9601fa787c8b | 37 | // start the active objects... |
QL | 2:27716f570c3d | 38 | AO_Pelican->start(1, l_pelicanQueueSto, Q_DIM(l_pelicanQueueSto), 0, 0); |
QL | 2:27716f570c3d | 39 | AO_Ped ->start(2, l_pedQueueSto, Q_DIM(l_pedQueueSto), 0, 0); |
QL | 0:9601fa787c8b | 40 | |
QL | 0:9601fa787c8b | 41 | QF::run(); // run the QF application |
QL | 0:9601fa787c8b | 42 | |
QL | 0:9601fa787c8b | 43 | return 0; |
QL | 0:9601fa787c8b | 44 | } |