alexeden / adafruit-seesaw Goto Github PK
View Code? Open in Web Editor NEWPlatform-agnostic driver to communicate with devices running Adafruit Seesaw firmware.
License: Apache License 2.0
Platform-agnostic driver to communicate with devices running Adafruit Seesaw firmware.
License: Apache License 2.0
Would you accept a PR adding Adafruit product #5740 ("ANO rotary navigation encoder") to the device
module?
I just picked up a couple of these ANO rotary navigation encoders, and I'm not finding a Rust crate that will easily interface with it.
On a cursory glance, it looks like this crate (with its seesaw_device!
macro) would be a good fit for it.
I'm thinking I'd try reusing the existing EncoderModule
logic with the "button" being the center button. And then follow along with Adafruit's CircuitPython example below to add the 4 extra digital inputs for the up/down/left/right buttons:
Also, if you have any tips or concerns up front, please let me know!
Edit: I just now saw the Creating Your Own Devices part of the readme... whoops, somehow thought it only supported the devices defined internally.
Hi, thanks for building this. I just got a NeoKey1x4, which I'm working on adding to my project.
I'm getting the following error building 0.5.0 (14dc5a):
error[E0635]: unknown feature `const_convert`
--> src/lib.rs:3:27
|
3 | #![feature(array_try_map, const_convert, const_trait_impl, generic_const_exprs)]
| ^^^^^^^^^^^^^
error: const `impl` for trait `From` which is not marked with `#[const_trait]`
--> src/common.rs:9:12
|
9 | impl const From<HardwareId> for u8 {
| ^^^^^^^^^^^^^^^^
|
= note: marking a trait with `#[const_trait]` ensures all default method bodies are `const`
= note: adding a non-const method body in the future would be a breaking change
error: const `impl` for trait `From` which is not marked with `#[const_trait]`
--> src/common.rs:36:12
|
36 | impl const From<Modules> for u8 {
| ^^^^^^^^^^^^^
|
= note: marking a trait with `#[const_trait]` ensures all default method bodies are `const`
= note: adding a non-const method body in the future would be a breaking change
error: const `impl` for trait `From` which is not marked with `#[const_trait]`
--> src/modules/gpio.rs:152:12
|
152 | impl const From<PinMode> for u8 {
| ^^^^^^^^^^^^^
|
= note: marking a trait with `#[const_trait]` ensures all default method bodies are `const`
= note: adding a non-const method body in the future would be a breaking change
error: const `impl` for trait `From` which is not marked with `#[const_trait]`
--> src/modules/gpio.rs:171:12
|
171 | impl const From<InterruptMode> for u8 {
| ^^^^^^^^^^^^^^^^^^^
|
= note: marking a trait with `#[const_trait]` ensures all default method bodies are `const`
= note: adding a non-const method body in the future would be a breaking change
A recent comment on rust-lang/rust#88674 suggests that the const_convert
feature has been removed.
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.