-
Notifications
You must be signed in to change notification settings - Fork 4
Server
SCArtis edited this page Jan 8, 2017
·
3 revisions
#HTTP-Server
The HTTP-Server provides the Webpage and implements real-time functionality in controlling the Laser-guns.
##express.js Web-Framework for NodeJS. Provides Webpage to Browser from our RaspberryPi.
http://expressjs.com ##socket.io JS Library for bi-directional Communication between Web Clients and Servers. Key and value-inputs are emitted to WebServer and "target-hit" alerts are emitted to Webpage.
The Coap-Server sends user-input to dedicated RIOT-Boards using following Transport-protocoll.
##node-coap Client and server library for CoAP, modelled after the http module.
https://github.com/mcollina/node-coap
##Transport-protocoll
- Servo Horizontal single step "/periph/servohstep" values: 0 = left step; 1 = right step; ex: "1"
- Servo Vertical single step "/periph/servovstep" values: 0 = left step; 1 = right step; ex "0"
- Servo Horizontal n steps "/periph/servohnstep" values: -1500 to 0 = left; 0 to 1500 = right; ex: "1337"
- Servo Vertical n steps "/periph/servovnstep" values: -1500 to 0 = left; 0 to 1500 = right; ex: "1337"
- Servo Horizontal angle "/periph/servohangle" values: -90.00 to 90.00 = angle; ex: "13.23"
- Servo Vertical angle "/periph/servovangle" values: -90.00 to 90.00 = angle; ex: "13.23"
- Servos n steps "/periph/servosnstep" values: -1500 to 0 = left; 0 to 1500 = right; ex: "-1230 456"
- Servos angle "/periph/servosangle" values: -90.00 to 90.00 = angle; ex: "23.45 -12.60"
- Laser set "/periph/laser" values: 0 = unset; 1 = set; ex: "1"
- Wellknown Core "/.wellknown/core" return: structure data
- Servos "/periph/servos" return: servo states in json