Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHenrik Rentz-Reichert2012-02-23 15:08:01 +0000
committerHenrik Rentz-Reichert2012-02-23 15:08:01 +0000
commit7542ea621d90f804c9703d769372630ecc090804 (patch)
treea52b1704df8d068eb686cebb0ece5385a19c2915 /runtime/org.eclipse.etrice.runtime.c
parent238d6a7eec1393352e05a72eb4245149bf556084 (diff)
downloadorg.eclipse.etrice-7542ea621d90f804c9703d769372630ecc090804.tar.gz
org.eclipse.etrice-7542ea621d90f804c9703d769372630ecc090804.tar.xz
org.eclipse.etrice-7542ea621d90f804c9703d769372630ecc090804.zip
[generator.c, runtime.c] extracted generated generic function to runtime
Diffstat (limited to 'runtime/org.eclipse.etrice.runtime.c')
-rw-r--r--runtime/org.eclipse.etrice.runtime.c/src/etPort.c7
-rw-r--r--runtime/org.eclipse.etrice.runtime.c/src/etPort.h2
2 files changed, 8 insertions, 1 deletions
diff --git a/runtime/org.eclipse.etrice.runtime.c/src/etPort.c b/runtime/org.eclipse.etrice.runtime.c/src/etPort.c
index ce8c5045c..24f22043d 100644
--- a/runtime/org.eclipse.etrice.runtime.c/src/etPort.c
+++ b/runtime/org.eclipse.etrice.runtime.c/src/etPort.c
@@ -21,3 +21,10 @@ void etPort_receive(const etPort* self, const etMessage* msg) {
ET_MSC_LOGGER_SYNC_EXIT
}
+
+void etPort_sendMessage(const etPort* self, etInt16 evtId) {
+ etMessage* msg = etMessageService_getMessageBuffer(self->msgService, sizeof(etMessage));
+ msg->address = self->peerAddress;
+ msg->evtID = evtId;
+ etMessageService_pushMessage(self->msgService, msg);
+}
diff --git a/runtime/org.eclipse.etrice.runtime.c/src/etPort.h b/runtime/org.eclipse.etrice.runtime.c/src/etPort.h
index ff2e1759f..797adb9ad 100644
--- a/runtime/org.eclipse.etrice.runtime.c/src/etPort.h
+++ b/runtime/org.eclipse.etrice.runtime.c/src/etPort.h
@@ -55,7 +55,7 @@ typedef struct {
typedef etPort* InterfaceItemBase;
void etPort_receive(const etPort* self, const etMessage* msg);
-
+void etPort_sendMessage(const etPort* self, etInt16 evtId);

Back to the top