-
Notifications
You must be signed in to change notification settings - Fork 20
Chart of KBox source code
Thomas Sarlandie edited this page Dec 17, 2017
·
1 revision
(work in progress)
Note that everything here applies to the new version of KBox in the
develop
branch. Contributors should only take a look at this one. Themaster
branch will be retired soon.
The KBox firmware project contains the source code and build configuration for:
- The main micro-controller on KBox, also called
host
. This micro-controller is similar to a Teensy 3.2 and is programmed in C++. The entry-point issrc/host/main.cpp
. - The WiFi module onboard KBox, also called
esp
. This module is an ESP8266 and is also programmed in C++. The entry-point issrc/esp/main.cpp
. - Tests for KBox. The tests are designed to run on the developer computer (Windows/Mac/Linux). They live in
src/test/
. Tests are automatically executed on every pull-request and test coverage is automatically measured on every pull-request. It should never go down, always up! - The
sktool
program. This is a command line program to use on Windows/Mac/Linux. It accepts NMEA0183 sentences and NMEA2000 PGNs (in Seasmart format) and will convert them to SignalK using the same code that is used by KBox. This is a great and easy way to test conversions without getting wet.
There are other less important components:
- The
esp-program
target is a firmware that you can flash on the main micro-controller and gives you pass-through access to the wifi module. It may be useful sometimes when debugging issues on the wifi firmware. - The
sktool-test.py
program automatically runs conversions withsktool
and checks the output against what we expect. You can also make it run against the official SignalK tool which is a great way to make sure our tests are correct. -
tools/nmea-tester/nmea.py
is a python script to validate and replay NMEA data -
tools/ws-client/ws-client.js
is a very simple websocket client in NodeJS.
All the logic to store "sailing" data and convert it from and to various formats is contained in the folder src/common/signalk
. The idea is that this should become a library in the future and could be used on other projects.
If you want to see what conversions are supported or add new conversions from NMEA2000 or NMEA, you should:
- Add tests in `src/test/