I will find out when I get to try this soon and report back. All my threads have equal priority, although I have tried increasing the priority of the LVGL thread. Most of the time, all threads are blocked waiting on events (e.g. incoming CAN data - but I have stopped the stream for this investigation; or a USB connection). What has led me to be suspicious of the scheduling is that the LVGL 1ms tick actually only runs every 200ms, with no screen graphics updating needed other than scrolling it which is - and always has been for me - VERY laggy.

I raised on issue via the LVGL got repo related to this and someone pointed out that it was highly likely that 1ms timer was not being allowed to run as intended. Hence my investigations.

A quick look at the NuttX code does seem to support my theory to a degree (but, as said, I'm yet to prove it one way or the other).

For example (from a quick search of CONFIG_RR_INTERVAL)

#ifCONFIG_RR_INTERVAL>0
/* Check if the currently executing task uses round robin scheduling. */
if((rtcb->flags & TCB_FLAG_POLICY_MASK) == TCB_FLAG_SCHED_RR)
{
/* Yes, check if the currently executing task has exceeded its
* timeslice.
*/
ret = nxsched_process_roundrobin(rtcb, elapsed, noswitches);
}
#endif

and

#ifCONFIG_RR_INTERVAL>0
case SCHED_OTHER:
case SCHED_RR:
ptcb->cmn.flags |= TCB_FLAG_SCHED_RR;
ptcb->cmn.timeslice = MSEC2TICK(CONFIG_RR_INTERVAL);
break;
#endif

It all seems to say to me that RR scheduling is the default when CONFIG_RR_INTERVAL==0 with no other way to determine the *default* behaviour. But I could (ought to?) set the scheduling method when I create the threads but I think I have tried that.

Bottom line - treat this as a discussion for now, until such a time as I have more evidence!


On 27/11/2025 11:19, Alan C. Assis wrote:
Hi Philippe,

Yes, this is my understanding too.

Probably the LVGL thread on Tim's configuration is not with the right
priority, if this is the case disabling RR will not help much.

BR,

Alan

On Thu, Nov 27, 2025 at 7:35 AM Philippe Leduc via dev<[email protected]>
wrote:

Hello all,

I'm not sure to understand the problem: the RR time slice shall follow a
strict priority ordering no?
This time slice only applies if threads have the same priority and that
the current one do not yield/sleep.
With a FIFO policy, it would be infinite instead of RR time slice.

What am I missing?

Philippe Leduc

Le 27 nov. 2025 à 02:30, Tomek CEDRO<[email protected]> a écrit :On Thu,
Nov 27, 2025 at 1:37 AM Nathan Hartman<[email protected]>
wrote:
On Wed, Nov 26, 2025 at 5:19 PM Tomek CEDRO<[email protected]> wrote:
On Wed, Nov 26, 2025 at 11:10 PM Nathan Hartman
<[email protected]> wrote:
On Wed, Nov 26, 2025 at 4:48 PM Tomek CEDRO<[email protected]>
wrote:
Another story is about LaTeX.. I want NuttX to have PDF Handbook
generated too for offline work and as part of releases.. there was
initial prototype created and it works. But local LaTeX setup is
complex and heavy and in search for alternatives I found.. ehm Rust
written tiny PDF generator called TYPST.. but its not yet
integrated
with Sphinx and has its own syntax that is not compatible with
LaTeX,
MD, RST (yet) :-P For people that want to quickly generate any
kind of
PDF (i.e. automation) this may be good utility though.. and
templates
generation/application is a lot easier than LaTeX :-)
Maybe it is possible to make a Docker container to generate the LaTeX
manual? Then anyone who wants to hack on the book locally could use
that?
Perhaps it would be even better if the same container had everything
to
hack on the site and documentation... thoughts?

<https://typst.app/>
Uhm I am on BSD no Docker here and I am not docker familiar enough to
create a reference sorry :-(
FreeBSD has bhyve, but I know this only from casually observing the
project
over the years. I used FreeBSD way back in the FreeBSD 3.3 (!!) days but
haven't had a good opportunity to try it again. I am impressed by
everything the project has achieved and would like to come back to it
someday. Anyway back to bhyve, by any chance is that compatible with any
of
the major virtualization platforms? In other words, could a virtual
machine
be created that people on non-FreeBSD platforms could use?
Bhyve is a full virtualization hypervisor native to FreeBSD. Kind of
alternative to VirtualBox. But it does not even have any GUI :-P It
offers however for instance passthrough PCI devices to the virtual
machine. I use this passthrough for USB 3.0 controller board.. on one
hand VBox allows simple port redirection but its only USB 2.0 and
often does not work as expeced. Below is an example how one guy
launched some high end games (i.e. Cyberpunk 2077 or Witcher) while
running windoze on fbsd's bhyve.

https://www.youtube.com/watch?v=_cz0RUAw5p8

Docker is a Linux only solution, it has some kernel level hardcodes,
so its popular but not a portable solution. It does run also on macOS
but people who made that part did not talk well about implementation
:-P

Btw. looking at Typst is seems to be able to convert MD/RST/DOC now
:-) And there are two experimental plugins to Sphinx :-) Maybe soon it
will become a smaller and faster and easier alternative to LaTeX :-)
Typst does indeed look interesting. I read this comparison between TeX
and
Typst some time back:
https://laurmaedje.github.io/posts/layout-models/
I don't know much else about it.

Or perhaps we should approach this differently... Pandoc can convert many
different document formats:
https://pandoc.org/

It could convert our reStructuredText documents to PDF... but wait a
second, I see that it needs pdflatex, lualatex, xelatex, latexmk,
tektonic,
wkhtmltopdf, weasyprint, prince, pagedjs-cli, context, or pdfroff. Do you
have any of those?
I know pdflatex and latexmk this is part of TeXLive package and I use
them to build my documents :-P

Typst may be just a smaller and simpler alternative to anyone
unfamiliar to LaTeX :-P

Said that I would like to rephrase that it would be best to stick to
the RST format and Sphinx as we do currently :D :D

--
CeDeROM, SQ7MHZ,http://www.tomek.cedro.info

Reply via email to