gregbreen / uncannier-thunderboard-react Goto Github PK
View Code? Open in Web Editor NEWThunderboard React made better
Home Page: https://uncannier.com
License: Other
Thunderboard React made better
Home Page: https://uncannier.com
License: Other
Support Over The Air (OTA) Device Firmware Upgrade (DFU) using Gecko Bootloader.
Use Gecko Bootloader because:
Don't bother with security initially. Insecure updates for now.
Using the stock TB React project, it's not possible to generate a Hex or binary image that can be flashed into an erased flash memory. We also need to add the Gecko Bootloader to the project, to generate the first and second stage bootloaders, and then use Simplicity Commander to merge the bootloader and application Hex files. Thus producing a single Hex file that can be flashed into an erased part.
BT SDK 2.11.0 modified the React example app by adding the following FEATURE_LFXO conditional compilation around the sleep flags in main.c:
#if defined(FEATURE_LFXO)
.sleep.flags = SLEEP_FLAGS_DEEP_SLEEP_ENABLE,
#else
.sleep.flags = 0,
#endif // LFXO
FEATURE_LXFO is not set by default in the example app. Pretty sure that's a SiLabs' bug.
Anyway, I brought this change in, and thus broke deep sleep. This was the offending PR: #17
Everything works in a functional sense, but the current draw is much too high. Need to fix it.
Need a starting point. Vanilla TR app, generated from latest Blue Gecko SDK (2.10.0).
By default, the warning level is low. Turn it up, fix easy warnings, disable a handful that are too hard to fix in SiLabs' code.
I also don't lile the default build configuration name of "GNU ARM v7.2.1 - Default". I understand where it comes from, but I prefer the decades old tried and true Debug and Release.
Create a Debug build configuration, with optimization O0. Also define DEBUG macro constant for that build configuration.
The battery level reported by the Thunderboard is noisy and highly inaccurate. It fails to account for how the battery voltage varies greatly with the load current. This changes the voltage much more than the loss of charge.
It also samples at very high frequency given that, in reality, takes about 20 minutes to dissipate 1% of charge (when maximally loaded at ~4mA, streaming IMU data over BLE).
Upgrade both the app and the bootloader to latest SDKs.
This will upgrade Gecko Bootloader to 1.8.0.
Ensure to bring forward any updates to the example source code.
Get the Test configuration building on CircleCI. Generate xUnit output, and save the test results on each build. Save the code coverage as an artifact too.
The firmware version is hard-coded in the Firmware Version characteristic of the Device Information service. Instead:
Add the CppUTest harness to the project. Create a new Test build configuration that makes an x86 build of the Thunderboard application, to allow on-host unit testing of components.
Although I only want to unit test Uncannier components, take the time to get the entire Thunderboard application into the harness. This means making a fairly extensive test seam.
Add GCOV profiling to the Test build configuration. Use LCOV to generate an HTML coverage report every time the unit tests are executed.
Upgrade both the app and the bootloader to latest SDKs.
This will upgrade Gecko Bootloader to 1.8.4.
Ensure to bring forward any updates to the example source code.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.