diff options
Diffstat (limited to 'conf.d/project/etc')
-rw-r--r-- | conf.d/project/etc/control-signal-composer.json | 15 | ||||
-rw-r--r-- | conf.d/project/etc/control-txc-demo.json | 34 | ||||
-rw-r--r-- | conf.d/project/etc/sig-txc.json | 103 | ||||
-rw-r--r-- | conf.d/project/etc/sources-txc.json | 17 | ||||
-rw-r--r-- | conf.d/project/etc/sources.json | 10 |
5 files changed, 161 insertions, 18 deletions
diff --git a/conf.d/project/etc/control-signal-composer.json b/conf.d/project/etc/control-signal-composer.json index d44a8fe..da100e1 100644 --- a/conf.d/project/etc/control-signal-composer.json +++ b/conf.d/project/etc/control-signal-composer.json @@ -5,28 +5,17 @@ "version": "1.0", "api": "signal-composer", "info": "Signal composer Configuration", - "require": ["low-can"] + "require": ["txc"] }, "plugins": [ { - "uid": "low-can-callbacks", - "info": "Manage interaction with low-can service", - "basename": "low-can" - }, - { "uid": "gps-callbacks", "info": "Manage interaction with gps service", "basename": "gps" - }, - { - "uid": "builtin", - "info": "Builtin routine for onReceived or getSignals routines", - "basename": "builtin", - "lua2c": "setSignalValueWrap" } ], "signals": { - "files": ["sig-doors", "sig-demoboard", "sig-geoloc" ] + "files": ["sig-txc" ] }, "sources": { "files": "sources" diff --git a/conf.d/project/etc/control-txc-demo.json b/conf.d/project/etc/control-txc-demo.json new file mode 100644 index 0000000..d44a8fe --- /dev/null +++ b/conf.d/project/etc/control-txc-demo.json @@ -0,0 +1,34 @@ +{ + "$schema": "http://iot.bzh/download/public/schema/json/signal-composer-schema.json", + "metadata": { + "uid": "Signal Composer", + "version": "1.0", + "api": "signal-composer", + "info": "Signal composer Configuration", + "require": ["low-can"] + }, + "plugins": [ + { + "uid": "low-can-callbacks", + "info": "Manage interaction with low-can service", + "basename": "low-can" + }, + { + "uid": "gps-callbacks", + "info": "Manage interaction with gps service", + "basename": "gps" + }, + { + "uid": "builtin", + "info": "Builtin routine for onReceived or getSignals routines", + "basename": "builtin", + "lua2c": "setSignalValueWrap" + } + ], + "signals": { + "files": ["sig-doors", "sig-demoboard", "sig-geoloc" ] + }, + "sources": { + "files": "sources" + } +} diff --git a/conf.d/project/etc/sig-txc.json b/conf.d/project/etc/sig-txc.json new file mode 100644 index 0000000..275eea6 --- /dev/null +++ b/conf.d/project/etc/sig-txc.json @@ -0,0 +1,103 @@ +{ + "$schema": "http://iot.bzh/download/public/schema/json/signal-composer-schema.json", + "signals": [ + { + "uid": "vehicle_speed", + "event": "txc/vehicle_speed", + "retention": 30, + "unit": "km/h", + "getSignalsArgs": { + "event": "vehicle_speed" + } + }, + { + "uid": "engine_speed", + "event": "txc/engine_speed", + "retention": 30, + "unit": "rpm", + "getSignalsArgs": { + "event": "engine_speed" + } + }, + { + "uid": "fuel_level", + "event": "txc/fuel_level", + "retention": 30, + "unit": "liter", + "getSignalsArgs": { + "event": "fuel_level" + } + }, + { + "uid": "accelerator_pedal_position", + "event": "txc/accelerator_pedal_position", + "retention": 30, + "getSignalsArgs": { + "event": "accelerator_pedal_position" + } + }, + { + "uid": "torque_at_transmission", + "event": "txc/torque_at_transmission", + "retention": 30, + "unit": "Nm", + "getSignalsArgs": { + "event": "torque_at_transmission" + } + }, + { + "uid": "steering_wheel_angle", + "event": "txc/steering_wheel_angle", + "retention": 30, + "unit": "degrees", + "getSignalsArgs": { + "event": "steering_wheel_angle" + } + }, + { + "uid": "fuel_consumed_since_restart", + "event": "txc/fuel_consumed_since_restart", + "retention": 30, + "unit": "liter", + "getSignalsArgs": { + "event": "fuel_consumed_since_restart" + } + }, + { + "uid": "odometer", + "event": "txc/odometer", + "retention": 30, + "unit": "km", + "getSignalsArgs": { + "event": "odometer" + } + }, + { + "uid": "latitude", + "event": "txc/latitude", + "retention": 30, + "unit": "degrees", + "getSignalsArgs": { + "event": "latitude" + } + }, + { + "uid": "longitude", + "event": "txc/longitude", + "retention": 30, + "unit": "degrees", + "getSignalsArgs": { + "event": "longitude" + } + }, + { + "uid": "heading", + "depends": ["longitude", "latitude"], + "retention": 30, + "unit": "degrees", + "onReceived": { + "function": "plugin://gps-callbacks/getHeading" + } + } + ] +} diff --git a/conf.d/project/etc/sources-txc.json b/conf.d/project/etc/sources-txc.json new file mode 100644 index 0000000..4404d60 --- /dev/null +++ b/conf.d/project/etc/sources-txc.json @@ -0,0 +1,17 @@ +{ + "$schema": "http://iot.bzh/download/public/schema/json/signal-composer-schema.json", + "sources": [ + { + "uid": "TXC-demo", + "api": "txc", + "info": "Use TXC demo binding as signals provider", + "init": { + "function": "api://txc/start", + "args": {"filename": "var/nyc-downtown-crosstown.json"} + }, + "getSignals": { + "function": "api://txc/subscribe" + } + } + ] +} diff --git a/conf.d/project/etc/sources.json b/conf.d/project/etc/sources.json index 7da3b95..c01ebd1 100644 --- a/conf.d/project/etc/sources.json +++ b/conf.d/project/etc/sources.json @@ -1,7 +1,7 @@ { "$schema": "http://iot.bzh/download/public/schema/json/signal-composer-schema.json", "sources": [ - { + { "uid": "CAN-service", "api": "low-can", "info": "Low level binding to handle CAN bus communications", @@ -21,12 +21,12 @@ }, "getSignals": { "function": "lua://_Simple_Echo_Args" - } + } }, { "uid": "MRAA-service", "api": "mraa", "info": "Low level binding which retrieve different values from several sensors like gyroscope, accelerometer, etc" - } - ] -} + } + ] + } |