Comments (8)
A preemptive scheduler was implemtented for ARM in this commit: fd7cc90
AVR and ESP ports to come. The ESP port wont make much sense since Simba is running as a FreeRTOS thread.
from simba.
Implemented on AVR. Will not implement on ESP.
from simba.
The ARM port does not work when rescheduling from the UART interrupt.
from simba.
Next attempt of the ARM preemptive scheduler looks promising. All tests pass. Closing this issue for now.
from simba.
Hi @eerimoq,
I want to understand ESP8266/32 can't have preemptive scheduler ports in simba framework. I believe esp rtos supports it.
The ESP port won't make much sense since Simba is running as a FreeRTOS thread.
Implemented on AVR. Will not implement on ESP.
:(
Is current cooperative scheduler enough for applications using
sync, inet ( wifi, socket, tcp, data size 512B/32B ), i2c, gpio, pwm together
with 5 ms deadline with precision and repeatability?
Except for wifi and main-print, rest finishes within <<5 ms individually. However, still to profile. 5 ms can go up as the bottleneck is wifi-tx-rx-tcp. I can go till 30 - 40 ms with deterministic repeatability.
This is just an understanding request. And surely not criticizing why esp is not having the preemptive scheduler.
Currently, my application is not able to tx i2c collected data over tcp in targetted time.
I am doing following things currently but not limited to:
- main print / shell use -> thrd_respawn total 3
- i2c thrd -> bus -> main and wifi
- bus -> wifi thrd -> tcp tx -> tcp rx -> bus -> main / * and control * /
- / * bus -> control thrd -> bus -> main and wifi * /
The jitter I am getting is about +/- 30 ms from x ms cycle. Sometimes it goes beyond 3 seconds as well. Maybe something to do with NO_DELAY kind of things in ESP end. Although, the host code can have performance issues.
The expectation from the application might be unrealistic. However, I want to push it.
Reference:
PassionForRobotics/ATOM_DRONE@bbcdcb8 / ISSUE_#16/ros/rosatom and rahuldeo2047/ESP_rtos_eval@e7a5c09 / ISSUE_#5/simba/i2c/sensors
If possible please let me know further steps, in case it is in context of simba repo.
Thank you
from simba.
I doubt that the ESP port will ever be deterministic. I would expect a lot of jitter, unfortunately. =/
from simba.
What could be the reasons for jitters? Is it somehow due to the soc, Simba framework itself or something else. Hope to learn or get some direction towards this issue. :)
from simba.
Likely the WiFi stack will introduce some jitter for example. I have not tested this, so it's my best guess.
from simba.
Related Issues (20)
- Missing serial port configuration parameters for shell example HOT 2
- Use external interrupts with esp01 HOT 5
- Upgrade support for esp family HOT 3
- std_read() HOT 3
- Reduce Memory Usage HOT 2
- SoftwareSerial RS485 Arduino.h to Simba.h HOT 3
- STM32F103C8T6 Support
- Not all ports have nvm_port_vwrite HOT 1
- Fuzzy testing brainstorming
- New user, unable to compile blink in Arduino ESP12E
- Pro Micro blink example not working HOT 2
- Uploading SPIFFS to ESP8266 HOT 1
- Unable to build with DHT from PlatformIO HOT 2
- Is there missing struct initialization? (http_websocket_client_connect) HOT 2
- Timer timeouts in threads are broken. HOT 2
- Vendor link on platformio broken HOT 1
- Request: Comparison Chart HOT 1
- nanoatmega328new board should be mapped to arduino nano HOT 1
- PIN_INPUT_PULL_UP has been deleted HOT 5
- Question about pure MCU work 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 simba.