Comments (3)
Thanks, that does look like a bug. It should still work fine with the warning, but I will fix this to make sure it doesn't happen.
from arduinocmri.
No problem. I dunno if you want me to make a separate issue, but one feature that would be super useful is a get_bit_change
function. I'm DCCing a turntable with your library (excellent work btw) and I need it to act on whenever a bit changes. I know I can write that part of the program myself, just thought maybe it'd be a useful feature in the library.
from arduinocmri.
Ok updated version committed that fixes this and a couple of other compilation warnings.
Firing an event when a bit changes is a great idea, I will have to think about that. Part of the challenge is that you need to track:
- What the current state of the bit is
- What the previous state of the bit was
- And whether you've checked that the bit has changed
Which means 3x bits for every output bit in the protocol, and I don't really want to introduce that kind of overhead. This is where event-based protocols are quite interesting, as when you get an event, you know it is because that bit has changed. I'll have a think though and see if I come up with something cunning.
from arduinocmri.
Related Issues (10)
- Out of bound checking leads to buffer overflow HOT 1
- The process function does not return the packet type processed
- Unable to load ArduinoCMRI library to the Arduino Web editor
- Delay in transmit prevents usage
- Curious about porting this project for Energia (TI MSP430 Launchpad Family) HOT 7
- Uno support: according to JMRI devs it should work HOT 4
- Bits other than 0 not working? HOT 1
- Errors in the JMRI console? HOT 10
- Example RS485 code not working? HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from arduinocmri.