README
Virtual Pilot Consumer
This repository holds the Virtual Pilot creation tool which produces:
- virtual-pilot-client
- virtual-pilot-server
Each instance can stream video content, binary data, and transmit control signals that will be executed in order to control devices remotely. Each instance of Virtual Pilot was designed having in mind that the energy consumption and host device capabilities might be limited.
Virtual pilot client
Virtual pilot client is an implementation of Real Time Communication Protocol that aims to transmit and consume video
stream latency free. Client can be summarized by the RTC manifest as RTC peer
that is able to commit to connections
sharing the video data stream, or send messages using binary data stream.
Each client is capable of receiving said streams by connecting to one specific peer using unique identifier.
Virtual pilot server
Virtual pilot server is at its core the same instance of the Virtual pilot client but limited in its functionality and connected to listener instance that is designed to invoke incoming commands.
Commands
start
- starts the server application and opens the listener instancecommit
- commits the changesbuild:dev
- builds all the dev versions of the applicationbuild:prod
- builds all the prod versions of the applicationbuild:dev:client
- builds only dev client version of the applicationbuild:dev:server
- builds only dev server version of the applicationbuild:prod:client
- builds only prod client version of the applicationbuild:prod:server
- builds only prod server version of the applicationlint
- runs the linter, it will also sort all the class methodslint:fix
- runs the linter, forcing fixes, it will also sort all the class methodspretty:watch
- runs prettier spy onsrc
folder
Configuration
All necessary configuration is done by editing the .env.example
file supplied with the repository.
In order to create your own configuration file, copy the .env.example
and rename it to: .env
LISTENER_PORT
- port used for a listener in the server instance, this port will be used for receiving and sending commands. Provide as number.LISTENER_ENDPOINT
- endpoint used for the listener in the server instance. Enclose within quotes, eg:'${value}'
LISTENER_REMOTE_CONFIG
- LIRC configuration file for the remote used for the device manipulation. Enclose within quotes, eg:'${value}'
SERVER_HOST
- server URI, where the Virtual Pilot Provider server is located. Provide without quotesSERVER_PORT
- port for the Virtual Pilot Provider server. Provide as number.SERVER_PATH
- path for the Virtual Pilot Provider server. Provide without quotesSERVER_DEBUG
- leave it at 0. Used only for debugging the WebRTCstun
andturn
communication. Provide as number (0 - 3).
Next step is to configure the src/config.js
file providing the appropriate node elements that will be responsible for
handling user interaction. HTMLNode list is visible either in src/template/client.html
or src/template/server.html