* --print-buffer-syncdelay, lib/cobalt/init.c:cobalt_help()
@ 2019-05-02 16:37 Steve Freyder
0 siblings, 0 replies; 2+ messages in thread
From: Steve Freyder @ 2019-05-02 16:37 UTC (permalink / raw)
To: xenomai@xenomai.org
Greetings,
I had a dev complain about losing stdio output in a Xenomai app, and
had never looked at rt_printf() and friends before. I had
problems attempting to use --print-buffer-syncdelay=1 to reduce the
delay to 1(ms), I found that my programs started complaining about an
invalid switch. Found that cobalt_help() was out of sync with the
actual switch name definition --print-sync-delay.
Here's a lame attempt at a patch.
Regards,
Steve
------------------------------------------------------------------------
lib/cobalt:
------------------------------------------------------------------------
diff -Naur a/init.c b/init.c
--- a/init.c 2018-06-15 10:26:19.692062099 -0500
+++ b/init.c 2019-05-02 11:16:07.894454047 -0500
@@ -349,7 +349,7 @@
fprintf(stderr, "--main-prio=<prio> main thread
priority\n");
fprintf(stderr, "--print-buffer-size=<bytes> size of a print
relay buffer (16k)\n");
fprintf(stderr, "--print-buffer-count=<num> number of print
relay buffers (4)\n");
- fprintf(stderr, "--print-buffer-syncdelay=<ms> max delay of
output synchronization (100 ms)\n");
+ fprintf(stderr, "--print-sync-delay=<ms> max delay of
output synchronization (100 ms)\n");
}
static struct setup_descriptor cobalt_interface = {
------------------------------------------------------------------------
^ permalink raw reply [flat|nested] 2+ messages in thread
* RE: --print-buffer-syncdelay, lib/cobalt/init.c:cobalt_help()
@ 2019-11-15 23:26 Jeff Webb
0 siblings, 0 replies; 2+ messages in thread
From: Jeff Webb @ 2019-11-15 23:26 UTC (permalink / raw)
To: xenomai@xenomai.org
I was converting an old Xenomai 2.6 application to 3.1, and had to adjust the RT print buffer settings from environment variables to command-line options. I had trouble with xenomai_init() not removing one of the command-line arguments it should have processed. After doing a web search, I came across this:
https://www.xenomai.org/pipermail/xenomai/2019-May/040883.html
It looks like a fix for this hasn't made it into 3.1 yet.
To summarize, a xenomai application's --help output says:
--print-buffer-syncdelay=<ms> max delay of output synchronization (100 ms)
But xenomai_init() doesn't remove this option from argv, so I don't think it recognizes it. Based on the above mailing list post, I tried:
--print-sync-delay=100
and it then removes the option from argv, so I assume this is the option name it is looking for. I didn't try the patch posted in the original email to see if it worked.
-Jeff
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2019-11-15 23:26 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-05-02 16:37 --print-buffer-syncdelay, lib/cobalt/init.c:cobalt_help() Steve Freyder
-- strict thread matches above, loose matches on Subject: below --
2019-11-15 23:26 Jeff Webb
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.