firmware merge requestshttps://git.flow3r.garden/card10/firmware/-/merge_requests2021-12-25T18:52:23Zhttps://git.flow3r.garden/card10/firmware/-/merge_requests/306Add menu vibration2021-12-25T18:52:23ZPhileasAdd menu vibrationThis merge request
- add vibration to the menu
- add `smooth_vibration` module for introducing common vibration patterns/mode
I've basically experimented a bit with coming up with ways to trigger the vibration motor.
This is super pri...This merge request
- add vibration to the menu
- add `smooth_vibration` module for introducing common vibration patterns/mode
I've basically experimented a bit with coming up with ways to trigger the vibration motor.
This is super primitive.
- [ ] menu timeout doesn't trigger timeout vibration
- [ ] more sophisticated patterns for vibration motor possible?
- [ ] should we have different vibration modi for going up and down
- [ ] could we add a vibration mode for when you cycled through the entire menu maybe?
- [ ] is the select vibration acceptable
- [ ] (how) should we make vibration configurable?https://git.flow3r.garden/card10/firmware/-/merge_requests/308WIP: Use button_gestures module in ECG app2019-09-16T11:33:43ZxiretzaWIP: Use button_gestures module in ECG appThis MR is mostly for tracking purposes right now - it definitely depends on !304, and I'm happy to wait for !296 to go through as well before rebasing.This MR is mostly for tracking purposes right now - it definitely depends on !304, and I'm happy to wait for !296 to go through as well before rebasing.https://git.flow3r.garden/card10/firmware/-/merge_requests/317support more bhi160 sensors2021-12-25T18:52:13ZFloriansupport more bhi160 sensorsThis adds support for the step counter, the remaining vector sensors "gravity" and "linear acceleration" and the three quaternion rotation sensors.
It does also remove the LOG_WARN statements from bhi160_handle_packet, since logging whi...This adds support for the step counter, the remaining vector sensors "gravity" and "linear acceleration" and the three quaternion rotation sensors.
It does also remove the LOG_WARN statements from bhi160_handle_packet, since logging while holding a hwlock seems to tend to deadlock.rahixcard10@rahix.derahixcard10@rahix.dehttps://git.flow3r.garden/card10/firmware/-/merge_requests/322WIP: Tvbgone fixes2023-08-04T21:42:51ZFrançois RevolWIP: Tvbgone fixesCurrent patches required to use the IR LED for TV-B-GONE.
Still missing PWM support in python.Current patches required to use the IR LED for TV-B-GONE.
Still missing PWM support in python.v1.19rahixcard10@rahix.derahixcard10@rahix.dehttps://git.flow3r.garden/card10/firmware/-/merge_requests/341fix epic_stream_read API2019-10-08T10:38:53ZFlorianfix epic_stream_read APIEpicardium sensor stream use the FreRTOS Queue-API, which transfers
fixed size blobs of bytes. To work correctly, a client of this
API (like pycardium) must interpret the bytes received from the
queue the same way as the sender. Unfortun...Epicardium sensor stream use the FreRTOS Queue-API, which transfers
fixed size blobs of bytes. To work correctly, a client of this
API (like pycardium) must interpret the bytes received from the
queue the same way as the sender. Unfortunately, there is no way to
statically enforce this, so the existing code used a simple heuristic
to detect some misuses of the API: it checks that the size of the
buffer passed by the client to epic_stream_read is a whole multiple of
the sensor data size. But this is prone to errors: if the client
passes a buffer that can hold thirty data packets of size eight, but
accidentally specifies a queue with a packet size of six, the API may
read up to fourty data packets, and if the client doesn't check for
the possibillity that the API returns a number of read packets that is
larger than the maximum requested (which none of the (two) existing
clients did), it will happily read past the end of the buffer,
triggering undefined behavior.
The modified API does instead force the client to pass the size of the
data packets and the maximum number of packets to read, and so makes
sure that the API will never read more packets than requested. If the
client still happens to specify a wrong queue with the right packet
size it will of course still get garbage data.https://git.flow3r.garden/card10/firmware/-/merge_requests/348feat(bma): Add initial support for BMA4002020-02-08T23:13:19ZMichael Meinelfeat(bma): Add initial support for BMA400This merge enables BMA400 support:
- configure device, set power mode
- enable interrupts
- read acceleration and interrupts
Currently, support is implemented for detection of taps and orientation change.This merge enables BMA400 support:
- configure device, set power mode
- enable interrupts
- read acceleration and interrupts
Currently, support is implemented for detection of taps and orientation change.https://git.flow3r.garden/card10/firmware/-/merge_requests/462feat(g_watch): Add ANCS support2021-04-02T20:04:37Zschneiderfeat(g_watch): Add ANCS supportMore a demo of what is possible now. I'm not sure if we should merge this just like that.
An iDevice which is paired to the card10 will now automatically try to connect as fast as possible independent of what the user might want. Maybe ...More a demo of what is possible now. I'm not sure if we should merge this just like that.
An iDevice which is paired to the card10 will now automatically try to connect as fast as possible independent of what the user might want. Maybe we should hide this behind an option menu or even make it it's own app?
![g-watch-ancs](/uploads/2604222c993731db4473f18a1474afb7/g-watch-ancs.mp4)https://git.flow3r.garden/card10/firmware/-/merge_requests/507Draft: "User-space" CTX2022-04-12T19:31:39Zrahixcard10@rahix.deDraft: "User-space" CTXAdd python API for [CTX vector graphics](https://ctx.graphics). **This is a work-in-progress!!!**
There is still lot's missing, see the todo list below. That said, I've opened this PR so people can start playing with CTX on card10. Y...Add python API for [CTX vector graphics](https://ctx.graphics). **This is a work-in-progress!!!**
There is still lot's missing, see the todo list below. That said, I've opened this PR so people can start playing with CTX on card10. You can download a `card10.bin` for this MR from the "Exposed Artifacts" under the CI pipeline below. Documentation is null at the moment, but you can probably get quite far by reading the [HTML5 Canvas Docs](https://developer.mozilla.org/en-US/docs/Web/API/CanvasRenderingContext2D) and consulting
```python
import ctx_graphics
for e in dir(ctx_graphics.Ctx): print(e)
```
on card10 for method and constant names.
As a kick-start, here is some example code:
```python
import ctx_graphics, display, color
ctx = ctx_graphics.Ctx()
# Global Settings
ctx.line_width(5)
ctx.line_cap(ctx.CAP_ROUND)
ctx.line_join(ctx.JOIN_ROUND)
ctx.font_size(30)
ctx.font("ctx-mono")
ctx.text_align(ctx.TEXT_ALIGN_CENTER)
ctx.text_baseline(ctx.TEXT_BASELINE_MIDDLE)
with display.open() as d:
d.clear()
ctx.save()
# Some Lines with nice joints
ctx.stroke_color(color.CHAOSBLUE)
ctx.move_to(10, 10).line_to(10, 70).line_to(150, 70).line_to(150, 10).stroke()
# Draw a rectangle which perfectly fits the text
width = ctx.text_width("Hello CTX!") + 4
ctx.color(color.WHITE).rectangle(80 - width / 2, 20, width, 40).fill()
# Draw some text!
ctx.color(color.CAMPGREEN).fill_text("Hello CTX!", 80, 40)
ctx.restore()
ctx.update(d)
d.update()
```
## TODO
- [ ] Finish covering relevant API surface
- [ ] Implement alpha for color functions
- [ ] Take colors in many formats
- [ ] Cleanup the CTX when the python object gets garbage collected
- [ ] Improve API ergonomicshttps://git.flow3r.garden/card10/firmware/-/merge_requests/508tools: add IAQ example in Python2022-01-02T15:50:41Zschneidertools: add IAQ example in Pythonhttps://git.flow3r.garden/card10/firmware/-/merge_requests/509build: Fix Meson warnings2023-08-18T01:55:48ZFrançois Revolbuild: Fix Meson warningsWARNING: Running the setup command as `meson [options]` instead of `meson setup [options]` is ambiguous and deprecated.
DEPRECATION: c_args in the [properties] section of the machine file is deprecated, use the [built-in options] sectio...WARNING: Running the setup command as `meson [options]` instead of `meson setup [options]` is ambiguous and deprecated.
DEPRECATION: c_args in the [properties] section of the machine file is deprecated, use the [built-in options] section.
DEPRECATION: c_link_args in the [properties] section of the machine file is deprecated, use the [built-in options] section.https://git.flow3r.garden/card10/firmware/-/merge_requests/510Make it work on new ubuntu (22.04) by changing python module to crcmod, and...2023-08-22T12:22:17ZTadeusz MWMake it work on new ubuntu (22.04) by changing python module to crcmod, and...Make it work on new ubuntu (22.04) by changing python module to crcmod, and adding git's safe.directory to bootstrap.sh, fix ubuntu's version in DockerfileMake it work on new ubuntu (22.04) by changing python module to crcmod, and adding git's safe.directory to bootstrap.sh, fix ubuntu's version in Dockerfile