summaryrefslogtreecommitdiffstats
path: root/afb-source/ctl-binding.c
diff options
context:
space:
mode:
authorFulup Ar Foll <fulup@iot.bzh>2017-08-24 10:27:04 +0200
committerRomain Forlot <romain.forlot@iot.bzh>2018-12-13 15:02:04 +0100
commit2b20a3cc10785c479cb003e0fa9822f023c87ce1 (patch)
tree35aee7d9b3ae226fc5612b9ac6848d7f32345362 /afb-source/ctl-binding.c
parentcc5a4e3c78af19de0ddfca984eed192cc146a5ee (diff)
Clean up module naming
Diffstat (limited to 'afb-source/ctl-binding.c')
-rw-r--r--afb-source/ctl-binding.c13
1 files changed, 10 insertions, 3 deletions
diff --git a/afb-source/ctl-binding.c b/afb-source/ctl-binding.c
index 4f6ecd3..6840b5c 100644
--- a/afb-source/ctl-binding.c
+++ b/afb-source/ctl-binding.c
@@ -22,13 +22,20 @@
#include "ctl-binding.h"
-
-
// Include Binding Stub generated from Json OpenAPI
#include "ctl-apidef.h"
+PUBLIC void ctlapi_ping (afb_req request) {
+ static int count=0;
+
+ count++;
+ AFB_NOTICE ("Controller:ping count=%d", count);
+ afb_req_success(request,json_object_new_int(count), NULL);
+
+ return;
+}
-PUBLIC void ctlapi_monitor (afb_req request) {
+PUBLIC void ctlapi_subscribe (afb_req request) {
// subscribe Client to event
int err = afb_req_subscribe(request, TimerEvtGet());