-
Notifications
You must be signed in to change notification settings - Fork 9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Arduino Async Lib #3
Comments
Hi there! I haven't worked on this project in a long while, but I'm always open to talk. I'm not sure that an event loop model would work well on embedded systems like Arduino. You need a kernel to send signals to your process and schedule it when work is available. I'm not sure that there is a comparable thing in an embedded device. Admittedly my knowledge of Arduino is only at a hobbyist level, so I could be entirely wrong. You may also want to check out rili, it is basically |
Looked at Also think and event loop model would work alright on arduino, but do we need it? Promise is just an interface, right? does it really need to hooked into the event loop ? |
If you would like to fully implement the Promises/A+ spec then you do need an event loop. According to spec the executor (the function passed to (new Promise((resolve) => {
console.log('first')
resolve()
})).then(() => console.log('third'))
console.log('second')
// ----------------------------
(new Promise((resolve) => {
console.log('first')
setImmediate(resolve)
})).then(() => console.log('third'))
console.log('second') Though, I suppose you could have a queue of functions that you iterate over and call at the start of Arduino's |
HEHEH, come on, lets do it :P ive also got I think we could even use an event loop (striped down). Also i want to add some more async programing styles like Events (Event Emitter), Tasks, Timeouts, maybe observables, still thinking about things though |
I don't have a lot of spare bandwidth between work and my own super secret project, but I'd be down to offer advice and some code when I can. Send me a link to the repo once you've got it started and I'll try to help. |
In the same boat, thank you :) anything is greatly appreciated. |
Hi, I'm trying to create a lib for Async style Programing for Arduino. Wondering if you'd be okay for me to pull some ideas from this lib / if you wanted to work with me on this. You have much more knowledge and I'd like to ask for your opinions...
Would be awesome to talk to you, thanks
The text was updated successfully, but these errors were encountered: