Comments (6)
That said: I am working on a way to include your own function into the loops of M5ez. And then in there you could see if 10 seconds have passed and do something. That is probably a few weeks out though.
Hmmm, maybe I could even do ez.at(moment, yourFunction)
and ez.every(milliseconds, yourFunction)
and keep a list of registered functions and when to call them. That would be spiffy and not too hard...
(But to then have them change the contects of the menu... Hmmm, I would have to think about that one, because the menu may well be only in scope of a single function at that point.)
from m5ez.
I set the caption of a menu item from a xTaskCreate function but wont show the new caption until i change the selected menu item or i select the menu item.
Is it possible to call a function to redraw the menu or to change the selected menu item ?
Can i set a static ip address for wifi connection ?
from m5ez.
from m5ez.
You are right, i got it working now.
I made a task with xTaskCreate and i loop with while (true) with delay.
Thank you for your help.
from m5ez.
Good point. I will make this change affect the menu immediately. Cannot think of a quick workaround right now.
Should be back making some changes to M5ez sometime soon after I have put the finishing touches on ezTime.
from m5ez.
M5ez 2.0.0 is out. It allows for you to add a task to its loop. Use ez.addEvent
to add your function. This function needs to take no arguments and return a uint16_t that holds in how many milliseconds it should be executed again. So returning 1000 would create a function that runs once a second. Simply add a wrapper function if the function you'd like to run does not return a number like that.
(Do note that for some applications, using a FreeRTOS task (or some combination of that and a function in M5ez's loop) may still be the best way to go.
Also menu captions should now update immediately, and you can add a tab (\t) to split between a part of the label that alligns left and a part that alligns to the right side of the menu caption.
from m5ez.
Related Issues (20)
- Upgraded now wont complile HOT 1
- Trying to stop NTP polling HOT 1
- Hangs - Suggestions on troubleshooting? HOT 1
- Added a few new functions to my branch
- Recieving and Sending Bluetooth Commands
- Reading SD card HOT 2
- up and down autorepeat
- change header title
- Demo sysinfo shows wrong SD card size.
- Two more features needed HOT 1
- crash/reboot in writing to SPI?!
- No need for Serial.begin()
- Errors installing from arduino ide and .zip HOT 2
- buttons automatically scroll up (A btn event without pressing)
- ez.events not running HOT 2
- Events are not executed when screen is off HOT 2
- cannot connect to raw.githubusercontent.com for OTA HOT 5
- port to M5Paper HOT 1
- M5Stack Basic (black) uSD card fails
- COMPILATION ERROR HOT 3
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 m5ez.