From e11314b2e9fef34f569bb7b042b432aed661cdc0 Mon Sep 17 00:00:00 2001 From: Romain Forlot Date: Tue, 19 Sep 2017 16:43:41 +0200 Subject: Added documentation Change-Id: Iaa6bb0470652d3d0dc97c6320dbf210567ccec80 Signed-off-by: Romain Forlot --- docs/part-1/4-SignalComposerAPI.md | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 docs/part-1/4-SignalComposerAPI.md (limited to 'docs/part-1/4-SignalComposerAPI.md') diff --git a/docs/part-1/4-SignalComposerAPI.md b/docs/part-1/4-SignalComposerAPI.md new file mode 100644 index 0000000..6e53800 --- /dev/null +++ b/docs/part-1/4-SignalComposerAPI.md @@ -0,0 +1,33 @@ +# Signal Composer API + +## get + +You can get a signal value be requesting the API with the verb *get*: + +```json +signal-composer get {"signal": "vehicle_speed", "options": {"average": 10}} +signal-composer get {"signal": "vehicle_speed", "options": {"minimum": 10}} +signal-composer get {"signal": "vehicle_speed", "options": {"maximum": 10}} +signal-composer get {"signal": "vehicle_speed"} +``` + +You apply apply some simple mathematical function by default present in the binding +, by default **last** is used: + +- **average**: make an average on X latest seconds. +- **minimum**: return the minimum value found in the X latest seconds. +- **maximum**: return the maximum value found in the X latest seconds. +- **last**: return the latest value. + +## list + +Verb **list** will output the list of defined signals. + +## loadConf + +Verb **loadConf** let you add new files to be able to add new **sources** or +**signals**. + +```json +signal-composer loadConf {"filepath": "/path/to/your/json/file.json"} +``` -- cgit 1.2.3-korg