Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHenrik Rentz-Reichert2018-01-05 21:16:05 +0000
committerHenrik Rentz-Reichert2018-01-08 19:47:48 +0000
commit33e5411e9632baa741e2e93e91922cd40693cfd3 (patch)
tree1814b0a170406345b83937901b928040fd58c6a9 /runtime/org.eclipse.etrice.modellib.c/model/PInterrupt.room
parent97db531e8fa6d639abf4ac2bbbb1dbdb5ad79f15 (diff)
downloadorg.eclipse.etrice-33e5411e9632baa741e2e93e91922cd40693cfd3.tar.gz
org.eclipse.etrice-33e5411e9632baa741e2e93e91922cd40693cfd3.tar.xz
org.eclipse.etrice-33e5411e9632baa741e2e93e91922cd40693cfd3.zip
Bug 529445 - [newfsmgen] make old style transition data deprecated
Implementation as suggested in the bug. Change-Id: I6a6f6ea966e4060646427078d82cb2b12eb046b6
Diffstat (limited to 'runtime/org.eclipse.etrice.modellib.c/model/PInterrupt.room')
-rw-r--r--runtime/org.eclipse.etrice.modellib.c/model/PInterrupt.room48
1 files changed, 22 insertions, 26 deletions
diff --git a/runtime/org.eclipse.etrice.modellib.c/model/PInterrupt.room b/runtime/org.eclipse.etrice.modellib.c/model/PInterrupt.room
index d39e11980..bc435f106 100644
--- a/runtime/org.eclipse.etrice.modellib.c/model/PInterrupt.room
+++ b/runtime/org.eclipse.etrice.modellib.c/model/PInterrupt.room
@@ -8,33 +8,29 @@ RoomModel room.basic.service.pinterrupt {
}
conjugated PortClass
{
- usercode {
- "#include \"messaging/etMessageService.h\""
- }
+ usercode '''#include "messaging/etMessageService.h"'''
handle
- incoming event {
- "// the message should be sent via the fire operation !!"
- }
- Operation export(): PInterruptConjPort ref {
- "msg.address = self->peerAddress;"
- "msg.evtID = PInterrupt_IN_event;"
- "callback.func=(void (*)(void*))PInterruptConjPort_dispatch;"
- "callback.param=(void *)self;"
- "etMessageService_registerHighPrioFunc(self->msgService,&callback);"
- "return self;"
- }
- Operation dispatch() {
- "// this operation will be executed from the message service"
- "if (enable){"
- " enable=0;"
- " self->msgService->msgDispatcher(&msg);"
- "}"
- }
- Operation fire() {
- "// this method runs on interrupt level"
- "enable=1;"
- "etSema_wakeupFromISR(&self->msgService->executionSemaphore);"
- }
+ incoming event '''// the message should be sent via the fire operation !!'''
+ Operation export(): PInterruptConjPort ref '''
+ msg.address = self->peerAddress;
+ msg.evtID = PInterrupt_IN_event;
+ callback.func=(void (*)(void*))PInterruptConjPort_dispatch;
+ callback.param=(void *)self;
+ etMessageService_registerHighPrioFunc(self->msgService,&callback);
+ return self;
+ '''
+ Operation dispatch() '''
+ // this operation will be executed from the message service
+ if (enable){
+ enable=0;
+ self->msgService->msgDispatcher(&msg);
+ }
+ '''
+ Operation fire() '''
+ // this method runs on interrupt level
+ enable=1;
+ etSema_wakeupFromISR(&self->msgService->executionSemaphore);
+ '''
Attribute msg: etMessage = "0"
Attribute callback: etHighPrioFunc = "{0,0}"
Attribute enable: uint8 = "0"

Back to the top