Re: Rtai Digest, Vol 123, Issue 1
Jim Montoya <[email protected]> Thu, 1 Mar 2018 06:32:56 -0500
| Newsgroups | gmane.linux.real-time.rtai |
|---|---|
| Message-ID | <CAEya4k8jkM=Rw6F8wSg50EmHR7HP3SKOyfn=L7+9-pqhk1JsRg@mail.gmail.com> |
--===============5854370806289650753== Content-Type: multipart/alternative; boundary="001a113ec948af612a05665838e9" --001a113ec948af612a05665838e9 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hello Please unsubscribe. Thank you. El 01/03/2018 05:23, <[email protected]> escribi=C3=B3: > Send Rtai mailing list submissions to > [email protected] > > To subscribe or unsubscribe via the World Wide Web, visit > https://mail.rtai.org/cgi-bin/mailman/listinfo/rtai > or, via email, send a message with subject or body 'help' to > [email protected] > > You can reach the person managing the list at > [email protected] > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of Rtai digest..." > > > Today's Topics: > > 1. Please unsubscribe (Mile Erlic) > 2. Re: Please unsubscribe (Alec Ari) > 3. Re: RTAI in debian9 (Paul Pfeiffer) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: Wed, 28 Feb 2018 22:31:45 +0000 > From: Mile Erlic <[email protected]> > To: "[email protected]" <[email protected]> > Subject: [Rtai] Please unsubscribe > Message-ID: > <YTXPR01MB05263CFC8486B1CEC0042159B9C70@YTXPR01MB0526. > CANPRD01.PROD.OUTLOOK.COM> > > Content-Type: text/plain; charset=3D"us-ascii" > > Hello > > Please unsubscribe. Thank you. > > Mile Erlic, President > Polaris Motion > 512 Frances Avenue, Unit 3 > Victoria, B.C., V8Z 1A1 > Tel: 1-250-382-7249 > Email: [email protected]<mailto:[email protected]> > Web: www.pmdi.com > [PolarisLogoOrangeEmail] > > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: <http://mail.rtai.org/pipermail/rtai/attachments/ > 20180228/1304d625/attachment-0001.html> > -------------- next part -------------- > A non-text attachment was scrubbed... > Name: image001.jpg > Type: image/jpeg > Size: 4553 bytes > Desc: image001.jpg > URL: <http://mail.rtai.org/pipermail/rtai/attachments/ > 20180228/1304d625/attachment-0001.jpg> > > ------------------------------ > > Message: 2 > Date: Thu, 1 Mar 2018 06:01:09 +0000 (UTC) > From: Alec Ari <[email protected]> > To: RTAI RTAI <[email protected]> > Subject: Re: [Rtai] Please unsubscribe > Message-ID: <[email protected]> > Content-Type: text/plain; charset=3DUTF-8 > > I'll unsubscribe if I feel like it! Don't tell me what to do! > > Alec Ari > > > ------------------------------ > > Message: 3 > Date: Thu, 1 Mar 2018 11:23:50 +0100 > From: Paul Pfeiffer <[email protected]> > To: Paolo Mantegazza <[email protected]>, "[email protected]" > <[email protected]> > Subject: Re: [Rtai] RTAI in debian9 > Message-ID: <[email protected]> > Content-Type: text/plain; charset=3Dwindows-1252; format=3Dflowed > > Thanks for the explanation. > > I cannot run the test from the root directory of the RTAI installation, > because the run script has relative references to executables. But I > could run the preempt test directly in the preempt directory, because > there was already a .runinfo file. The results are attached. > > However, starting the Kernel latency test, crashed the machine... maybe > this is a hint towards the problem? > > I digged a little bit into the source code and found the > call_usermodehelper function in base/sched/sched.c in the calibrate > function. Am I right that this is a call to the executable defined in > /base/arch/x86/calibration/calibrate.c? Then, it seems that the crash > happens in the else branch of the main function, where no latencies file > is present. Important calls seem to be rt_thread_init, > rt_make_hard_real_time and rt_make_soft_real_time. Any idea what could > go wrong? > > Thank you, Paul > > ___ > > # Running tests > > dynclamp@abbott:~/Documents$ cd /usr/realtime/testsuite/ > > ## User test > > dynclamp@abbott:/usr/realtime/testsuite$ cd user/latency > dynclamp@abbott:/usr/realtime/testsuite/user/latency$ sudo ./run > [sudo] password for dynclamp: > > RTAI Testsuite - USER space latency test (output data in nanoseconds) > > *** latency verification tool with real time hardened user space > processes/threads *** > ***??? period =3D 100000 (ns),? avrgtime =3D 1 (s)??? *** > > RTAI Testsuite - USER latency (all data in nanoseconds) > 2018/03/1 10:33:45 > RTH|??? lat min|??? ovl min|??? lat avg|??? lat max|??? ovl max| overruns > RTD|?????? -230|?????? -230|???????? 19|????? 12676| 12676|????????? 0 > RTD|?????? -168|?????? -230|???????? 35|????? 14333| 14333|????????? 0 > RTD|?????? -169|?????? -230|???????? 14|?????? 5108| 14333|????????? 0 > RTD|?????? -180|?????? -230|???????? 16|?????? 7970| 14333|????????? 0 > RTD|?????? -263|?????? -263|???????? 14|?????? 4522| 14333|????????? 0 > RTD|?????? -141|?????? -263|???????? 20|?????? 4838| 14333|????????? 0 > RTD|?????? -161|?????? -263|???????? 16|?????? 3436| 14333|????????? 0 > RTD|?????? -144|?????? -263|???????? 19|?????? 2030| 14333|????????? 0 > RTD|??????? -70|?????? -263|???????? 17|?????? 2639| 14333|????????? 0 > RTD|??????? -73|?????? -263|???????? 41|?????? 2836| 14333|????????? 0 > RTD|?????? -136|?????? -263|???????? 34|?????? 3806| 14333|????????? 0 > RTD|?????? -161|?????? -263|???????? 29|?????? 5334| 14333|????????? 0 > RTD|?????? -142|?????? -263|???????? 41|?????? 4396| 14333|????????? 0 > RTD|??????? -38|?????? -263|???????? 59|?????? 4724| 14333|????????? 0 > RTD|?????? -222|?????? -263|???????? 42|?????? 3530| 14333|????????? 0 > RTD|?????? -162|?????? -263|???????? 30|?????? 3017| 14333|????????? 0 > RTD|?????? -170|?????? -263|???????? 18|?????? 2422| 14333|????????? 0 > RTD|?????? -133|?????? -263|???????? 18|?????? 3717| 14333|????????? 0 > RTD|?????? -240|?????? -263|???????? 28|?????? 5888| 14333|????????? 0 > RTD|?????? -102|?????? -263|???????? 41|?????? 4356| 14333|????????? 0 > RTD|?????? -102|?????? -263|???????? 41|?????? 4356| 14333|????????? 0 > ^C > >>> S =3D 98.696, EXECTIME =3D 0.0107068 > rmmod: ERROR: Module rtai_msg is not currently loaded > rmmod: ERROR: Module rtai_mbx is not currently loaded > rmmod: ERROR: Module rtai_sem is not currently loaded > rmmod: ERROR: Module rtai_sched is not currently loaded > rmmod: ERROR: Module rtai_hal is not currently loaded > dynclamp@abbott:/usr/realtime/testsuite/user/latency$ cd ../preempt/ > dynclamp@abbott:/usr/realtime/testsuite/user/preempt$ sudo ./run > * > * > * Type ^C to stop this application. > * > * > RTAI Testsuite - LXRT preempt (all data in nanoseconds) > RTH|???? lat min|???? lat avg|???? lat max|??? jit fast|??? jit slow > RTD|??????? -401|??????? -127|??????? 2382|??????? 5393|??????? 1792 > RTD|??????? -406|??????? -133|??????? 2382|??????? 5393|??????? 1792 > RTD|??????? -406|??????? -131|??????? 2382|??????? 5393|??????? 2016 > RTD|??????? -406|??????? -129|??????? 3134|??????? 5393|??????? 3302 > RTD|??????? -406|??????? -127|??????? 3623|??????? 5393|??????? 3302 > RTD|??????? -406|??????? -133|??????? 3623|??????? 5393|??????? 3302 > RTD|??????? -406|??????? -132|??????? 3623|??????? 5393|??????? 3302 > RTD|??????? -406|??????? -134|??????? 3623|??????? 5393|??????? 4961 > RTD|??????? -406|??????? -134|??????? 5743|??????? 5393|??????? 4961 > RTD|??????? -406|??????? -132|??????? 5743|??????? 5393|??????? 4961 > RTD|??????? -406|??????? -136|??????? 5743|??????? 5393|??????? 4961 > RTD|??????? -406|??????? -134|??????? 5743|??????? 5393|??????? 4961 > RTD|??????? -408|??????? -126|??????? 5743|??????? 5393|??????? 4961 > RTD|??????? -408|??????? -133|??????? 5743|??????? 5393|??????? 4961 > RTD|??????? -408|??????? -131|??????? 6401|??????? 6292|??????? 4961 > RTD|??????? -408|??????? -127|??????? 6701|??????? 8385|??????? 4961 > RTD|??????? -408|??????? -121|??????? 6701|??????? 8385|??????? 4961 > ^CRTD|??????? -408|??????? -121|??????? 6701|??????? 8385| 4961 > > ## Kernel tests > > cd ../../kern/latency > > sudo ./run > > CRASH > > > On 02/28/2018 09:46 PM, Paolo Mantegazza wrote: > > The third number is the assumed default period used for the calibration= , > if it succeeded and you did not set it to a different one when configurin= g > RTAI. > > Clearly, when set by hands, it has little meaning, albeit being needed > when rtai_sched is insmoded. > > > > It is strange that, once you ran latency, the preempt test do not run. > Recall that you are assumed to run those tests from the RTAI install dir. > Be sure of doing it in such a way and let me know. > > > > Now that you ran rtai_sched using the latencies file, the > call_userhelper support seems to be working also on your system. So I've > even less clues than before on the why it did not calibrate. In fact the > automatic calibration is nothing but the latency test in disguise, couple= d > to a trivial Kalman filter to estimate the expected latency on the fly. > > > > Thanks for your feedback, Paolo. > > > > _______________________________________ > > From: Paul Pfeiffer [[email protected]] > > Sent: Wednesday, February 28, 2018 7:14 PM > > To: Paolo Mantegazza; [email protected] > > Subject: Re: [Rtai] RTAI in debian9 > > > > Thanks for the feedback. > > > > I added the latencies file and now the rtai_sched module can be loaded > > without specifiying user or kernel latency. In the kernel output, I see > > that the kernel latency is now 440ns and the user latency 880ns. What i= s > > the meaning of the third number? > > > > I tried running the other tests, but they do not work, because of a > > missing .runinfo file. Do I have to create this? What should be in this > > file? > > > > We will use the RTAI patched kernel to perform recordings from neurons > > with real time feedback loops. I will update you, when we have tried th= e > > new RTAI patch within this application. > > > > Best, Paul > > > > > > On 02/27/2018 10:59 PM, Paolo Mantegazza wrote: > >> Your system seems OK. If you edit a file, named "latencies", with a > single line containing: > >> 440 880 10000 > >> and copy it into "rtai_installdir/calibration/latencies. > >> you'll have what the calibration should have done and there will be no= n > need to set those latencies at rtai_sched.ko insmod. > >> In any case, once you have done what above, may test both latency and > preempt, in user, kern and kthread directories of yout rtai_installdir an= d > then report what happened? > >> Do not test switches, It locks the cpu for a bit of time and may be > risky. I'll not be surprised of a muted system. > >> As for why it does not work on your system, without a diagnose hands > on, I've no clue. > >> Moreover I'll be glad to hear of some further checks with a production > code of yours, if any. > >> > >> Thanks, Paolo > >> > >> ________________________________________the > >> From: Rtai [[email protected]] on behalf of Paul Pfeiffer [ > [email protected]] > >> Sent: Tuesday, February 27, 2018 4:41 PM > >> To: [email protected] > >> Subject: Re: [Rtai] RTAI in debian9 > >> > >> Hi, > >> > >> thanks for the nice discussion in this thread. I have a similar issue = to > >> the one described by josu, but on a real machine. > >> > >> Setup: Linux kernel 4.9.76 and RTAI 5.1 > >> > >> For patching the kernel and compilation of the kernel modules, I > >> followed the instructions from Jan Benda, here > >> http://relacs.sourceforge.net/plugins/rtaicomedi/ > >> > >> Insertion of the rtai_hal module works, but insertion of rtai_sched > >> kills the system. > >> > >> Like Paolo suggested, I also tried loading the rtai_sched with > >> kernel_latency and user_latency set to 1000. This works. Does this mea= n > >> that the calibration is the problem? How could I solve this for my > setup? > >> > >> Also, I ran the suggested modified latency test. However, like josu, I > >> had to change the insertion of the rtai_sched module to > >> > >> ``` > >> > >> insmod $MODULES/rtai_sched.ko kernel_latency=3D1 user_latency=3D1 > >> > >> ``` > >> > >> otherwise the system would stop responding. > >> > >> Please find below the output of the test and the corresponding kernel > >> messages. > >> > >> Thank you, Paul > >> > >> ________________ > >> > >> $ sudo ./testsuite/user/latency/run > >> > >> RTAI Testsuite - USER space latency test (output data in nanoseconds) > >> > >> *** latency verification tool with real time hardened user space > >> processes/threads *** > >> *** period =3D 100000 (ns), avrgtime =3D 1 (s) *** > >> > >> RTAI Testsuite - USER latency (all data in nanoseconds) > >> 2018/02/27 16:18:13 > >> RTH|??? lat min|??? ovl min|??? lat avg|??? lat max|??? ovl max| > overruns > >> RTD|??????? 726|??????? 726|??????? 887|?????? 5216| 5216|????????? 0 > >> RTD|??????? 705|??????? 705|??????? 884|?????? 2667| 5216|????????? 0 > >> RTD|??????? 545|??????? 545|??????? 884|?????? 3267| 5216|????????? 0 > >> RTD|??????? 599|??????? 545|??????? 890|?????? 8122| 8122|????????? 0 > >> RTD|??????? 711|??????? 545|??????? 884|????? 15637| 15637|????????? 0 > >> RTD|??????? 638|??????? 545|??????? 882|?????? 6058| 15637|????????? 0 > >> RTD|??????? 722|??????? 545|??????? 877|?????? 3233| 15637|????????? 0 > >> RTD|??????? 741|??????? 545|??????? 881|?????? 2186| 15637|????????? 0 > >> RTD|??????? 733|??????? 545|??????? 874|?????? 3213| 15637|????????? 0 > >> RTD|??????? 734|??????? 545|??????? 874|?????? 2666| 15637|????????? 0 > >> RTD|??????? 718|??????? 545|??????? 874|?????? 1823| 15637|????????? 0 > >> RTD|??????? 729|???? 545|??????? 874|?????? 2813| 15637|????????? 0 > >> RTD|??????? 709|??????? 545|??????? 883|?????? 5861| 15637|????????? 0 > >> RTD|??????? 722|??????? 545|??????? 897|????? 12125| 15637|????????? 0 > >> RTD|??????? 721|??????? 545|??????? 895|?????? 3858| 15637|????????? 0 > >> RTD|??????? 598|??????? 545|??????? 891|?????? 2384| 15637|????????? 0 > >> RTD|??????? 701|??????? 545|??????? 877|?????? 2205| 15637|????????? 0 > >> RTD|??????? 642|??????? 545|??????? 878|?????? 3895| 15637|????????? 0 > >> RTD|??????? 590|??????? 545|??????? 880|?????? 1844| 15637|????????? 0 > >> RTD|??????? 725|??????? 545|??????? 877|?????? 3841| 15637|????????? 0 > >> RTD|??????? 549|??????? 545|??????? 884|?????? 2105| 15637|????????? 0 > >> 2018/02/27 16:18:35 > >> RTH|??? lat min|??? ovl min|??? lat avg|??? lat max|??? ovl max| > overruns > >> RTD|??????? 708|??????? 545|??????? 880|?????? 3730| 15637|????????? 0 > >> RTD|??????? 717|??????? 545|??????? 875|?????? 3596| 15637|????????? 0 > >> RTD|??????? 721|??????? 545|??????? 878|?????? 1470| 15637|????????? 0 > >> ^CRTD|??????? 721|??????? 545|??????? 878|?????? 1470| 15637|?????????= 0 > >> > >> >>> S =3D 98.696, EXECTIME =3D 0.0105475 > >> > >> > >> $sudo dmesg -T -w > >> > >> [Tue Feb 27 16:18:12 2018] I-pipe: head domain RTAI registered. > >> [Tue Feb 27 16:18:12 2018] RTAI[hal]: mounted. ISOL_CPUS_MASK: 0. > >> [Tue Feb 27 16:18:12 2018] SYSINFO - # CPUs: 4, TIMER NAME: 'lapic', > >> TIMER IRQ: 4354, TIMER FREQ: 437999993, CLOCK NAME: 'tsc', CLOCK FREQ: > >> 3500000000, CPU FREQ: 3500000000, LINUX TIMER IRQ: 4354. > >> [Tue Feb 27 16:18:12 2018] > >> REMARK: RTAI WILL NOT ACCESS USER SPACE = ON > >> STACKS ARGS ITS WAY. > >> > >> [Tue Feb 27 16:18:12 2018] RTAI[malloc]: global heap size =3D 2097152 > >> bytes, <BSD>. > >> [Tue Feb 27 16:18:12 2018] , kstacks pool size =3D 524288 bytes > >> [Tue Feb 27 16:18:12 2018] . > >> [Tue Feb 27 16:18:12 2018] RTAI[sched]: hard timer type/freq =3D > >> lapic/437999993(Hz); timing: ONESHOT; > >> [Tue Feb 27 16:18:12 2018] linear timed lists. > >> [Tue Feb 27 16:18:12 2018] RTAI[sched]: Linux timer freq =3D 250 (Hz), > >> TimeBase freq =3D 3500000000 hz. > >> [Tue Feb 27 16:18:12 2018] RTAI[sched]: timer setup =3D 66 ns, resched > >> latency =3D 0 ns. > >> [Tue Feb 27 16:18:12 2018] FINAL CALIBRATION SUMMARY (ns): KernelLaten= cy > >> 0, UserLatency 0. > >> [Tue Feb 27 16:18:39 2018] RTAI[malloc]: unloaded. > >> [Tue Feb 27 16:18:39 2018] RTAI[sched]: unloaded (forced hard/soft/har= d > >> transitions: traps 0, syscalls 0). > >> [Tue Feb 27 16:18:39 2018] I-pipe: head domain RTAI unregistered. > >> [Tue Feb 27 16:18:39 2018] RTAI[hal]: unmounted. > >> > >> > >> On 02/24/2018 12:20 AM, josu wrote: > >>> Yes, of course, I can?t get real time (much less, 100 us period), onl= y > test the procedure. However, setting deadline to 1 (and not 0), the > programs run, without hanging the VM. > >>> > >>> Although the meaning is not at all the same that in a real system, th= e > latency test are able to run with your run script (setting a number > greater than 0). This is the result: > >>> > >>> root@debianRB:/usr/realtime/testsuite/user/latency# ./run > >>> RTAI Testsuite - USER space latency test (output data in nanoseconds) > >>> > >>> *** latency verification tool with real time hardened user space > processes/threads *** > >>> *** period =3D 100000 (ns), avrgtime =3D 1 (s) *** > >>> > >>> RTAI Testsuite - USER latency (all data in nanoseconds) > >>> 2018/02/23 22:47:06 > >>> RTH| lat min| ovl min| lat avg| lat max| ovl max| > overruns > >>> RTD| 0| 0| 25068| 870103| 870103| > 67 > >>> RTD| 0| 0| 25608| 1007163| 1007163| > 95 > >>> RTD| 0| 0| 25288| 886190| 1007163| > 124 > >>> RTD| 0| 0| 25275| 985017| 1007163| > 155 > >>> RTD| 0| 0| 24564| 832423| 1007163| > 179 > >>> RTD| 0| 0| 25620| 199742| 1007163| > 194 > >>> RTD| 0| 0| 25393| 881237| 1007163| > 226 > >>> RTD| 0| 0| 25067| 874862| 1007163| > 253 > >>> RTD| 0| 0| 25247| 827829| 1007163| > 274 > >>> RTD| 0| 0| 25566| 855516| 1007163| > 310 > >>> RTD| 0| 0| 24899| 1035597| 1035597| > 360 > >>> RTD| 0| 0| 25403| 202992| 1035597| > 376 > >>> RTD| 0| 0| 25288| 771628| 1035597| > 398 > >>> RTD| 0| 0| 25288| 771628| 1035597| > 398 > >>> ^C > >>>>>> S =3D 98.696, EXECTIME =3D 0.0663255 > >>>> On 24 Feb 2018, at 00:11, Paolo Mantegazza < > [email protected]> wrote: > >>>> > >>>> VM changes the matter a lot. Anticipating the scheduling deadline b= y > 1 ns does not change anything with respect to 0. > >>>> In any case it served to indicate that you cannot run the RTAI tests= , > simply because VM cannot provide true real time. In particular it cannot > support a 100 us period. > >>>> I dare saying that if you configure RTAI to use a lower calibrating > frequency, say 2000 Hz , in place of the default 10000 Hz, you might > succeed in trying the RTAI latency tests, along with the hidden latency > calibration. > >>>> In any case hard real time will likely be a no hope matter. > >>>> > >>>> Paolo > >>>> > >>>> ________________________________________ > >>>> From: josu [[email protected]] > >>>> Sent: Friday, February 23, 2018 10:57 PM > >>>> To: Paolo Mantegazza > >>>> Cc: RTAI RTAI > >>>> Subject: Re: [Rtai] RTAI in debian9 > >>>> > >>>> Hi again: > >>>> > >>>> First, I want to clarify than I am testing with a VM. Sorry for the > possible misunderstanding. I have been very busy and I have forgot to say > this important point. > >>>> > >>>> In any case, I have test your script and the system hangs. However, > making the next change: > >>>> > >>>> insmod $MODULES/rtai_sched.ko kernel_latency=3D1 user_latency=3D1 > >>>> > >>>> I have obtained the result attached below. > >>>> > >>>> josu > >>>> > >>>> [cid:[email protected]] > >>>> > >>>> On 23 Feb 2018, at 18:56, Paolo Mantegazza < > [email protected]<mailto:[email protected]>> wrote: > >>>> > >>>> May you try the "testsuite/user/latency" test, in your RTAI install > dir, after saving and substituting the existing "run" script with the one > below and then let me know what happened? > >>>> Do it on an unloaded machined and, if possible, after seeing a > stabilized average latency, attach to your answer also a short snapshot o= f > what appears on the screen. > >>>> Thanks, Paolo > >>>> ------------------------------------------------------------ > ----------------------------------------------- > >>>> #!/bin/sh > >>>> > >>>> prefix=3D`rtai-config --prefix` > >>>> > >>>> if test "$prefix" =3D ""; then > >>>> echo "ERROR: please set your PATH variable to <rtai-install>/bin" > >>>> exit > >>>> fi > >>>> > >>>> MODULES=3D$prefix/modules > >>>> > >>>> libpath=3D`rtai-config --library-dir` > >>>> > >>>> if test "$libpath" =3D ""; then > >>>> echo "ERROR: please set your PATH variable to <rtai-install>/bin" > >>>> exit > >>>> fi > >>>> > >>>> export LD_LIBRARY_PATH=3D$libpath:$LD_LIBRARY_PATH > >>>> > >>>> cleanup () { > >>>> rmmod rtai_msg > >>>> rmmod rtai_mbx > >>>> rmmod rtai_sem > >>>> rmmod rtai_sched > >>>> rmmod rtai_hal > >>>> } > >>>> > >>>> trap cleanup INT ALRM TERM HUP KILL > >>>> > >>>> insmod $MODULES/rtai_hal.ko > >>>> insmod $MODULES/rtai_sched.ko kernel_latency=3D0 user_latency=3D0 > >>>> insmod $MODULES/rtai_sem.ko; > >>>> insmod $MODULES/rtai_mbx.ko; > >>>> insmod $MODULES/rtai_msg.ko; > >>>> > >>>> ./latency & > >>>> until(`ps -a | grep -q latency`); do sleep 1; done > >>>> ./display > >>>> > >>>> cleanup > >>>> ------------------------------------------------------------ > ----------------------------------- > >>>> > >>>> ________________________________________ > >>>> From: josu jugo [[email protected]<mailto:[email protected]>] > >>>> Sent: Friday, February 23, 2018 5:37 PM > >>>> To: Paolo Mantegazza > >>>> Cc: RTAI RTAI > >>>> Subject: Re: [Rtai] RTAI in debian9 > >>>> > >>>> Hi again: > >>>> > >>>> I have test a simple program obtained with rtai-lab (scicoslab > version), monitoring with qrtailab and the system is working. > >>>> > >>>> I have load rtai_sched with kernel_latency=3D1000 and user_latency= =3D1000 > >>>> > >>>> josu > >>>> > >>>> On 23 Feb 2018, at 12:51, josu jugo <[email protected]<mailto:josu > [email protected]><mailto:[email protected]>> wrote: > >>>> > >>>> > >>>> > >>>> > >>>> <Screen Shot 2018-02-23 at 22.47.37.png> > >>> _______________________________________________ > >>> Rtai mailing list > >>> [email protected] > >>> https://mail.rtai.org/cgi-bin/mailman/listinfo/rtai > >> _______________________________________________ > >> Rtai mailing list > >> [email protected] > >> https://mail.rtai.org/cgi-bin/mailman/listinfo/rtai > > > > ------------------------------ > > Subject: Digest Footer > > _______________________________________________ > Rtai mailing list > [email protected] > https://mail.rtai.org/cgi-bin/mailman/listinfo/rtai > > ------------------------------ > > End of Rtai Digest, Vol 123, Issue 1 > ************************************ > --001a113ec948af612a05665838e9 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable <p dir=3D"ltr">Hello</p> <p dir=3D"ltr">Please unsubscribe. Thank you.</p> <div class=3D"gmail_quote">El 01/03/2018 05:23, <<a href=3D"mailto:rtai= [email protected]">[email protected]</a>> escribi=C3=B3:<br type=3D"= attribution"><blockquote class=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;b= order-left:1px #ccc solid;padding-left:1ex">Send Rtai mailing list submissi= ons to<br> =C2=A0 =C2=A0 =C2=A0 =C2=A0 <a href=3D"mailto:[email protected]">[email protected]<= /a><br> <br> To subscribe or unsubscribe via the World Wide Web, visit<br> =C2=A0 =C2=A0 =C2=A0 =C2=A0 <a href=3D"https://mail.rtai.org/cgi-bin/mailma= n/listinfo/rtai" rel=3D"noreferrer" target=3D"_blank">https://mail.rtai.org= /cgi-bin/<wbr>mailman/listinfo/rtai</a><br> or, via email, send a message with subject or body 'help' to<br> =C2=A0 =C2=A0 =C2=A0 =C2=A0 <a href=3D"mailto:[email protected]">rtai-r= [email protected]</a><br> <br> You can reach the person managing the list at<br> =C2=A0 =C2=A0 =C2=A0 =C2=A0 <a href=3D"mailto:[email protected]">rtai-own= [email protected]</a><br> <br> When replying, please edit your Subject line so it is more specific<br> than "Re: Contents of Rtai digest..."<br> <br> <br> Today's Topics:<br> <br> =C2=A0 =C2=A01. Please unsubscribe (Mile Erlic)<br> =C2=A0 =C2=A02. Re: Please unsubscribe (Alec Ari)<br> =C2=A0 =C2=A03. Re: RTAI in debian9 (Paul Pfeiffer)<br> <br> <br> ------------------------------<wbr>------------------------------<wbr>-----= -----<br> <br> Message: 1<br> Date: Wed, 28 Feb 2018 22:31:45 +0000<br> From: Mile Erlic <<a href=3D"mailto:[email protected]">[email protected]</a>= ><br> To: "<a href=3D"mailto:[email protected]">[email protected]</a>" <<a h= ref=3D"mailto:[email protected]">[email protected]</a>><br> Subject: [Rtai] Please unsubscribe<br> Message-ID:<br> =C2=A0 =C2=A0 =C2=A0 =C2=A0 <<a href=3D"mailto:YTXPR01MB05263CFC8486B1CE= [email protected]">YTXPR01MB05263CFC848= 6B1CEC004<wbr>2159B9C70@YTXPR01MB0526.<wbr>CANPRD01.PROD.OUTLOOK.COM</a>>= ;<br> <br> Content-Type: text/plain; charset=3D"us-ascii"<br> <br> Hello<br> <br> Please unsubscribe. Thank you.<br> <br> Mile Erlic, President<br> Polaris Motion<br> 512 Frances Avenue, Unit 3<br> Victoria, B.C., V8Z 1A1<br> Tel: 1-250-382-7249<br> Email: <a href=3D"mailto:[email protected]">[email protected]</a><mailto:<a = href=3D"mailto:[email protected]">merlic@<wbr>pmdi.com</a>><br> Web: <a href=3D"http://www.pmdi.com" rel=3D"noreferrer" target=3D"_blank">w= ww.pmdi.com</a><br> [PolarisLogoOrangeEmail]<br> <br> <br> -------------- next part --------------<br> An HTML attachment was scrubbed...<br> URL: <<a href=3D"http://mail.rtai.org/pipermail/rtai/attachments/2018022= 8/1304d625/attachment-0001.html" rel=3D"noreferrer" target=3D"_blank">http:= //mail.rtai.org/<wbr>pipermail/rtai/attachments/<wbr>20180228/1304d625/atta= chment-<wbr>0001.html</a>><br> -------------- next part --------------<br> A non-text attachment was scrubbed...<br> Name: image001.jpg<br> Type: image/jpeg<br> Size: 4553 bytes<br> Desc: image001.jpg<br> URL: <<a href=3D"http://mail.rtai.org/pipermail/rtai/attachments/2018022= 8/1304d625/attachment-0001.jpg" rel=3D"noreferrer" target=3D"_blank">http:/= /mail.rtai.org/<wbr>pipermail/rtai/attachments/<wbr>20180228/1304d625/attac= hment-<wbr>0001.jpg</a>><br> <br> ------------------------------<br> <br> Message: 2<br> Date: Thu, 1 Mar 2018 06:01:09 +0000 (UTC)<br> From: Alec Ari <<a href=3D"mailto:[email protected]">neotheuser@ymail= .com</a>><br> To: RTAI RTAI <<a href=3D"mailto:[email protected]">[email protected]</a>><br= > Subject: Re: [Rtai] Please unsubscribe<br> Message-ID: <<a href=3D"mailto:[email protected]= oo.com">1034034682.8278740.<wbr>[email protected]</a>><br> Content-Type: text/plain; charset=3DUTF-8<br> <br> I'll unsubscribe if I feel like it! Don't tell me what to do!<br> <br> Alec Ari<br> <br> <br> ------------------------------<br> <br> Message: 3<br> Date: Thu, 1 Mar 2018 11:23:50 +0100<br> From: Paul Pfeiffer <<a href=3D"mailto:[email protected]">pfeiffe= [email protected]</a>><br> To: Paolo Mantegazza <<a href=3D"mailto:[email protected]">paol= [email protected]</a>>, "<a href=3D"mailto:[email protected]">rtai= @rtai.org</a>"<br> =C2=A0 =C2=A0 =C2=A0 =C2=A0 <<a href=3D"mailto:[email protected]">rtai@rtai.= org</a>><br> Subject: Re: [Rtai] RTAI in debian9<br> Message-ID: <<a href=3D"mailto:b198a2bf-0e83-e4ea-061c-9211d20d07dd@gmai= l.com">b198a2bf-0e83-e4ea-061c-<wbr>[email protected]</a>><br> Content-Type: text/plain; charset=3Dwindows-1252; format=3Dflowed<br> <br> Thanks for the explanation.<br> <br> I cannot run the test from the root directory of the RTAI installation,<br> because the run script has relative references to executables. But I<br> could run the preempt test directly in the preempt directory, because<br> there was already a .runinfo file. The results are attached.<br> <br> However, starting the Kernel latency test, crashed the machine... maybe<br> this is a hint towards the problem?<br> <br> I digged a little bit into the source code and found the<br> call_usermodehelper function in base/sched/sched.c in the calibrate<br> function. Am I right that this is a call to the executable defined in<br> /base/arch/x86/calibration/<wbr>calibrate.c? Then, it seems that the crash<= br> happens in the else branch of the main function, where no latencies file<br= > is present. Important calls seem to be rt_thread_init,<br> rt_make_hard_real_time and rt_make_soft_real_time. Any idea what could<br> go wrong?<br> <br> Thank you, Paul<br> <br> ___<br> <br> # Running tests<br> <br> dynclamp@abbott:~/Documents$ cd /usr/realtime/testsuite/<br> <br> ## User test<br> <br> dynclamp@abbott:/usr/realtime/<wbr>testsuite$ cd user/latency<br> dynclamp@abbott:/usr/realtime/<wbr>testsuite/user/latency$ sudo ./run<br> [sudo] password for dynclamp:<br> <br> RTAI Testsuite - USER space latency test (output data in nanoseconds)<br> <br> *** latency verification tool with real time hardened user space<br> processes/threads ***<br> ***??? period =3D 100000 (ns),? avrgtime =3D 1 (s)??? ***<br> <br> RTAI Testsuite - USER latency (all data in nanoseconds)<br> 2018/03/1 10:33:45<br> RTH|??? lat min|??? ovl min|??? lat avg|??? lat max|??? ovl max| overruns<b= r> RTD|?????? -230|?????? -230|???????? 19|????? 12676| 12676|????????? 0<br> RTD|?????? -168|?????? -230|???????? 35|????? 14333| 14333|????????? 0<br> RTD|?????? -169|?????? -230|???????? 14|?????? 5108| 14333|????????? 0<br> RTD|?????? -180|?????? -230|???????? 16|?????? 7970| 14333|????????? 0<br> RTD|?????? -263|?????? -263|???????? 14|?????? 4522| 14333|????????? 0<br> RTD|?????? -141|?????? -263|???????? 20|?????? 4838| 14333|????????? 0<br> RTD|?????? -161|?????? -263|???????? 16|?????? 3436| 14333|????????? 0<br> RTD|?????? -144|?????? -263|???????? 19|?????? 2030| 14333|????????? 0<br> RTD|??????? -70|?????? -263|???????? 17|?????? 2639| 14333|????????? 0<br> RTD|??????? -73|?????? -263|???????? 41|?????? 2836| 14333|????????? 0<br> RTD|?????? -136|?????? -263|???????? 34|?????? 3806| 14333|????????? 0<br> RTD|?????? -161|?????? -263|???????? 29|?????? 5334| 14333|????????? 0<br> RTD|?????? -142|?????? -263|???????? 41|?????? 4396| 14333|????????? 0<br> RTD|??????? -38|?????? -263|???????? 59|?????? 4724| 14333|????????? 0<br> RTD|?????? -222|?????? -263|???????? 42|?????? 3530| 14333|????????? 0<br> RTD|?????? -162|?????? -263|???????? 30|?????? 3017| 14333|????????? 0<br> RTD|?????? -170|?????? -263|???????? 18|?????? 2422| 14333|????????? 0<br> RTD|?????? -133|?????? -263|???????? 18|?????? 3717| 14333|????????? 0<br> RTD|?????? -240|?????? -263|???????? 28|?????? 5888| 14333|????????? 0<br> RTD|?????? -102|?????? -263|???????? 41|?????? 4356| 14333|????????? 0<br> RTD|?????? -102|?????? -263|???????? 41|?????? 4356| 14333|????????? 0<br> ^C<br> =C2=A0>>> S =3D 98.696, EXECTIME =3D 0.0107068<br> rmmod: ERROR: Module rtai_msg is not currently loaded<br> rmmod: ERROR: Module rtai_mbx is not currently loaded<br> rmmod: ERROR: Module rtai_sem is not currently loaded<br> rmmod: ERROR: Module rtai_sched is not currently loaded<br> rmmod: ERROR: Module rtai_hal is not currently loaded<br> dynclamp@abbott:/usr/realtime/<wbr>testsuite/user/latency$ cd ../preempt/<b= r> dynclamp@abbott:/usr/realtime/<wbr>testsuite/user/preempt$ sudo ./run<br> *<br> *<br> * Type ^C to stop this application.<br> *<br> *<br> RTAI Testsuite - LXRT preempt (all data in nanoseconds)<br> RTH|???? lat min|???? lat avg|???? lat max|??? jit fast|??? jit slow<br> RTD|??????? -401|??????? -127|??????? 2382|??????? 5393|??????? 1792<br> RTD|??????? -406|??????? -133|??????? 2382|??????? 5393|??????? 1792<br> RTD|??????? -406|??????? -131|??????? 2382|??????? 5393|??????? 2016<br> RTD|??????? -406|??????? -129|??????? 3134|??????? 5393|??????? 3302<br> RTD|??????? -406|??????? -127|??????? 3623|??????? 5393|??????? 3302<br> RTD|??????? -406|??????? -133|??????? 3623|??????? 5393|??????? 3302<br> RTD|??????? -406|??????? -132|??????? 3623|??????? 5393|??????? 3302<br> RTD|??????? -406|??????? -134|??????? 3623|??????? 5393|??????? 4961<br> RTD|??????? -406|??????? -134|??????? 5743|??????? 5393|??????? 4961<br> RTD|??????? -406|??????? -132|??????? 5743|??????? 5393|??????? 4961<br> RTD|??????? -406|??????? -136|??????? 5743|??????? 5393|??????? 4961<br> RTD|??????? -406|??????? -134|??????? 5743|??????? 5393|??????? 4961<br> RTD|??????? -408|??????? -126|??????? 5743|??????? 5393|??????? 4961<br> RTD|??????? -408|??????? -133|??????? 5743|??????? 5393|??????? 4961<br> RTD|??????? -408|??????? -131|??????? 6401|??????? 6292|??????? 4961<br> RTD|??????? -408|??????? -127|??????? 6701|??????? 8385|??????? 4961<br> RTD|??????? -408|??????? -121|??????? 6701|??????? 8385|??????? 4961<br> ^CRTD|??????? -408|??????? -121|??????? 6701|??????? 8385| 4961<br> <br> ## Kernel tests<br> <br> cd ../../kern/latency<br> <br> sudo ./run<br> <br> CRASH<br> <br> <br> On 02/28/2018 09:46 PM, Paolo Mantegazza wrote:<br> > The third number is the assumed default period used for the calibratio= n, if it succeeded and you did not set it to a different one when configuri= ng RTAI.<br> > Clearly, when set by hands, it has little meaning, albeit being needed= when rtai_sched is insmoded.<br> ><br> > It is strange that, once you ran latency, the preempt test do not run.= Recall that you are assumed to run those tests from the RTAI install dir. = Be sure of doing it in such a way and let me know.<br> ><br> > Now that you ran rtai_sched using the latencies file, the call_userhel= per support seems to be working also on your system. So I've even less = clues than before on the why it did not calibrate. In fact the automatic ca= libration is nothing but the latency test in disguise, coupled to a trivial= Kalman filter to estimate the expected latency on the fly.<br> ><br> > Thanks for your feedback, Paolo.<br> ><br> > ______________________________<wbr>_________<br> > From: Paul Pfeiffer [<a href=3D"mailto:[email protected]">pfeif= [email protected]</a>]<br> > Sent: Wednesday, February 28, 2018 7:14 PM<br> > To: Paolo Mantegazza; <a href=3D"mailto:[email protected]">[email protected]</= a><br> > Subject: Re: [Rtai] RTAI in debian9<br> ><br> > Thanks for the feedback.<br> ><br> > I added the latencies file and now the rtai_sched module can be loaded= <br> > without specifiying user or kernel latency. In the kernel output, I se= e<br> > that the kernel latency is now 440ns and the user latency 880ns. What = is<br> > the meaning of the third number?<br> ><br> > I tried running the other tests, but they do not work, because of a<br= > > missing .runinfo file. Do I have to create this? What should be in thi= s<br> > file?<br> ><br> > We will use the RTAI patched kernel to perform recordings from neurons= <br> > with real time feedback loops. I will update you, when we have tried t= he<br> > new RTAI patch within this application.<br> ><br> > Best, Paul<br> ><br> ><br> > On 02/27/2018 10:59 PM, Paolo Mantegazza wrote:<br> >> Your system seems OK. If you edit a file, named "latencies&qu= ot;, with a single line containing:<br> >> 440 880 10000<br> >> and copy it into "rtai_installdir/calibration/<wbr>latencies.= <br> >> you'll have what the calibration should have done and there wi= ll be non need to set those latencies at rtai_sched.ko insmod.<br> >> In any case, once you have done what above, may test both latency = and preempt, in user, kern and kthread directories of yout rtai_installdir = and then report what happened?<br> >> Do not test switches, It locks the cpu for a bit of time and may b= e risky. I'll not be surprised of a muted system.<br> >> As for why it does not work on your system, without a diagnose han= ds on, I've no clue.<br> >> Moreover I'll be glad to hear of some further checks with a pr= oduction code of yours, if any.<br> >><br> >> Thanks, Paolo<br> >><br> >> ______________________________<wbr>__________the<br> >> From: Rtai [<a href=3D"mailto:[email protected]">rtai-bounces@= rtai.org</a>] on behalf of Paul Pfeiffer [<a href=3D"mailto:pfeifferpaul90@= gmail.com">[email protected]</a>]<br> >> Sent: Tuesday, February 27, 2018 4:41 PM<br> >> To: <a href=3D"mailto:[email protected]">[email protected]</a><br> >> Subject: Re: [Rtai] RTAI in debian9<br> >><br> >> Hi,<br> >><br> >> thanks for the nice discussion in this thread. I have a similar is= sue to<br> >> the one described by josu, but on a real machine.<br> >><br> >> Setup: Linux kernel 4.9.76 and RTAI 5.1<br> >><br> >> For patching the kernel and compilation of the kernel modules, I<b= r> >> followed the instructions from Jan Benda, here<br> >> <a href=3D"http://relacs.sourceforge.net/plugins/rtaicomedi/" rel= =3D"noreferrer" target=3D"_blank">http://relacs.sourceforge.net/<wbr>plugin= s/rtaicomedi/</a><br> >><br> >> Insertion of the rtai_hal module works, but insertion of rtai_sche= d<br> >> kills the system.<br> >><br> >> Like Paolo suggested, I also tried loading the rtai_sched with<br> >> kernel_latency and user_latency set to 1000. This works. Does this= mean<br> >> that the calibration is the problem? How could I solve this for my= setup?<br> >><br> >> Also, I ran the suggested modified latency test. However, like jos= u, I<br> >> had to change the insertion of the rtai_sched module to<br> >><br> >> ```<br> >><br> >> insmod $MODULES/rtai_sched.ko kernel_latency=3D1 user_latency=3D1<= br> >><br> >> ```<br> >><br> >> otherwise the system would stop responding.<br> >><br> >> Please find below the output of the test and the corresponding ker= nel<br> >> messages.<br> >><br> >> Thank you, Paul<br> >><br> >> ________________<br> >><br> >> $ sudo ./testsuite/user/latency/run<br> >><br> >> RTAI Testsuite - USER space latency test (output data in nanosecon= ds)<br> >><br> >> *** latency verification tool with real time hardened user space<b= r> >> processes/threads ***<br> >> ***=C2=A0 =C2=A0 period =3D 100000 (ns),=C2=A0 avrgtime =3D 1 (s)= =C2=A0 =C2=A0 ***<br> >><br> >> RTAI Testsuite - USER latency (all data in nanoseconds)<br> >> 2018/02/27 16:18:13<br> >> RTH|??? lat min|??? ovl min|??? lat avg|??? lat max|??? ovl max| o= verruns<br> >> RTD|??????? 726|??????? 726|??????? 887|?????? 5216| 5216|????????= ? 0<br> >> RTD|??????? 705|??????? 705|??????? 884|?????? 2667| 5216|????????= ? 0<br> >> RTD|??????? 545|??????? 545|??????? 884|?????? 3267| 5216|????????= ? 0<br> >> RTD|??????? 599|??????? 545|??????? 890|?????? 8122| 8122|????????= ? 0<br> >> RTD|??????? 711|??????? 545|??????? 884|????? 15637| 15637|???????= ?? 0<br> >> RTD|??????? 638|??????? 545|??????? 882|?????? 6058| 15637|???????= ?? 0<br> >> RTD|??????? 722|??????? 545|??????? 877|?????? 3233| 15637|???????= ?? 0<br> >> RTD|??????? 741|??????? 545|??????? 881|?????? 2186| 15637|???????= ?? 0<br> >> RTD|??????? 733|??????? 545|??????? 874|?????? 3213| 15637|???????= ?? 0<br> >> RTD|??????? 734|??????? 545|??????? 874|?????? 2666| 15637|???????= ?? 0<br> >> RTD|??????? 718|??????? 545|??????? 874|?????? 1823| 15637|???????= ?? 0<br> >> RTD|??????? 729|????=C2=A0 =C2=A0 545|??????? 874|?????? 2813| 156= 37|????????? 0<br> >> RTD|??????? 709|??????? 545|??????? 883|?????? 5861| 15637|???????= ?? 0<br> >> RTD|??????? 722|??????? 545|??????? 897|????? 12125| 15637|???????= ?? 0<br> >> RTD|??????? 721|??????? 545|??????? 895|?????? 3858| 15637|???????= ?? 0<br> >> RTD|??????? 598|??????? 545|??????? 891|?????? 2384| 15637|???????= ?? 0<br> >> RTD|??????? 701|??????? 545|??????? 877|?????? 2205| 15637|???????= ?? 0<br> >> RTD|??????? 642|??????? 545|??????? 878|?????? 3895| 15637|???????= ?? 0<br> >> RTD|??????? 590|??????? 545|??????? 880|?????? 1844| 15637|???????= ?? 0<br> >> RTD|??????? 725|??????? 545|??????? 877|?????? 3841| 15637|???????= ?? 0<br> >> RTD|??????? 549|??????? 545|??????? 884|?????? 2105| 15637|???????= ?? 0<br> >> 2018/02/27 16:18:35<br> >> RTH|??? lat min|??? ovl min|??? lat avg|??? lat max|??? ovl max| o= verruns<br> >> RTD|??????? 708|??????? 545|??????? 880|?????? 3730| 15637|???????= ?? 0<br> >> RTD|??????? 717|??????? 545|??????? 875|?????? 3596| 15637|???????= ?? 0<br> >> RTD|??????? 721|??????? 545|??????? 878|?????? 1470| 15637|???????= ?? 0<br> >> ^CRTD|??????? 721|??????? 545|??????? 878|?????? 1470| 15637|?????= ???? 0<br> >><br> >>=C2=A0 =C2=A0 >>> S =3D 98.696, EXECTIME =3D 0.0105475<br> >><br> >><br> >> $sudo dmesg -T -w<br> >><br> >> [Tue Feb 27 16:18:12 2018] I-pipe: head domain RTAI registered.<br= > >> [Tue Feb 27 16:18:12 2018] RTAI[hal]: mounted. ISOL_CPUS_MASK: 0.<= br> >> [Tue Feb 27 16:18:12 2018] SYSINFO - # CPUs: 4, TIMER NAME: 'l= apic',<br> >> TIMER IRQ: 4354, TIMER FREQ: 437999993, CLOCK NAME: 'tsc',= CLOCK FREQ:<br> >> 3500000000, CPU FREQ: 3500000000, LINUX TIMER IRQ: 4354.<br> >> [Tue Feb 27 16:18:12 2018]<br> >>=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0REMARK: RTAI WILL NOT ACCESS U= SER SPACE ON<br> >> STACKS ARGS ITS WAY.<br> >><br> >> [Tue Feb 27 16:18:12 2018] RTAI[malloc]: global heap size =3D 2097= 152<br> >> bytes, <BSD>.<br> >> [Tue Feb 27 16:18:12 2018] , kstacks pool size =3D 524288 bytes<br= > >> [Tue Feb 27 16:18:12 2018] .<br> >> [Tue Feb 27 16:18:12 2018] RTAI[sched]: hard timer type/freq =3D<b= r> >> lapic/437999993(Hz); timing: ONESHOT;<br> >> [Tue Feb 27 16:18:12 2018] linear timed lists.<br> >> [Tue Feb 27 16:18:12 2018] RTAI[sched]: Linux timer freq =3D 250 (= Hz),<br> >> TimeBase freq =3D 3500000000 hz.<br> >> [Tue Feb 27 16:18:12 2018] RTAI[sched]: timer setup =3D 66 ns, res= ched<br> >> latency =3D 0 ns.<br> >> [Tue Feb 27 16:18:12 2018] FINAL CALIBRATION SUMMARY (ns): KernelL= atency<br> >> 0, UserLatency 0.<br> >> [Tue Feb 27 16:18:39 2018] RTAI[malloc]: unloaded.<br> >> [Tue Feb 27 16:18:39 2018] RTAI[sched]: unloaded (forced hard/soft= /hard<br> >> transitions: traps 0, syscalls 0).<br> >> [Tue Feb 27 16:18:39 2018] I-pipe: head domain RTAI unregistered.<= br> >> [Tue Feb 27 16:18:39 2018] RTAI[hal]: unmounted.<br> >><br> >><br> >> On 02/24/2018 12:20 AM, josu wrote:<br> >>> Yes, of course, I can?t get real time (much less, 100 us perio= d), only test the procedure. However, setting deadline to 1 (and not 0), th= e programs run, without hanging the VM.<br> >>><br> >>> Although the meaning is not at all the same that in a real sys= tem, the latency test are able to run with your run script=C2=A0 (setting a= number greater than 0). This is the result:<br> >>><br> >>> root@debianRB:/usr/realtime/<wbr>testsuite/user/latency# ./run= <br> >>> RTAI Testsuite - USER space latency test (output data in nanos= econds)<br> >>><br> >>> *** latency verification tool with real time hardened user spa= ce processes/threads ***<br> >>> ***=C2=A0 =C2=A0 period =3D 100000 (ns),=C2=A0 avrgtime =3D 1 = (s)=C2=A0 =C2=A0 ***<br> >>><br> >>> RTAI Testsuite - USER latency (all data in nanoseconds)<br> >>> 2018/02/23 22:47:06<br> >>> RTH|=C2=A0 =C2=A0 lat min|=C2=A0 =C2=A0 ovl min|=C2=A0 =C2=A0 = lat avg|=C2=A0 =C2=A0 lat max|=C2=A0 =C2=A0 ovl max|=C2=A0 =C2=A0overruns<b= r> >>> RTD|=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 0|=C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 0|=C2=A0 =C2=A0 =C2=A0 25068|=C2=A0 =C2=A0 =C2=A0870103|=C2= =A0 =C2=A0 =C2=A0870103|=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A067<br> >>> RTD|=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 0|=C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 0|=C2=A0 =C2=A0 =C2=A0 25608|=C2=A0 =C2=A0 1007163|=C2=A0 =C2= =A0 1007163|=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A095<br> >>> RTD|=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 0|=C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 0|=C2=A0 =C2=A0 =C2=A0 25288|=C2=A0 =C2=A0 =C2=A0886190|=C2= =A0 =C2=A0 1007163|=C2=A0 =C2=A0 =C2=A0 =C2=A0 124<br> >>> RTD|=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 0|=C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 0|=C2=A0 =C2=A0 =C2=A0 25275|=C2=A0 =C2=A0 =C2=A0985017|=C2= =A0 =C2=A0 1007163|=C2=A0 =C2=A0 =C2=A0 =C2=A0 155<br> >>> RTD|=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 0|=C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 0|=C2=A0 =C2=A0 =C2=A0 24564|=C2=A0 =C2=A0 =C2=A0832423|=C2= =A0 =C2=A0 1007163|=C2=A0 =C2=A0 =C2=A0 =C2=A0 179<br> >>> RTD|=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 0|=C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 0|=C2=A0 =C2=A0 =C2=A0 25620|=C2=A0 =C2=A0 =C2=A0199742|=C2= =A0 =C2=A0 1007163|=C2=A0 =C2=A0 =C2=A0 =C2=A0 194<br> >>> RTD|=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 0|=C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 0|=C2=A0 =C2=A0 =C2=A0 25393|=C2=A0 =C2=A0 =C2=A0881237|=C2= =A0 =C2=A0 1007163|=C2=A0 =C2=A0 =C2=A0 =C2=A0 226<br> >>> RTD|=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 0|=C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 0|=C2=A0 =C2=A0 =C2=A0 25067|=C2=A0 =C2=A0 =C2=A0874862|=C2= =A0 =C2=A0 1007163|=C2=A0 =C2=A0 =C2=A0 =C2=A0 253<br> >>> RTD|=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 0|=C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 0|=C2=A0 =C2=A0 =C2=A0 25247|=C2=A0 =C2=A0 =C2=A0827829|=C2= =A0 =C2=A0 1007163|=C2=A0 =C2=A0 =C2=A0 =C2=A0 274<br> >>> RTD|=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 0|=C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 0|=C2=A0 =C2=A0 =C2=A0 25566|=C2=A0 =C2=A0 =C2=A0855516|=C2= =A0 =C2=A0 1007163|=C2=A0 =C2=A0 =C2=A0 =C2=A0 310<br> >>> RTD|=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 0|=C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 0|=C2=A0 =C2=A0 =C2=A0 24899|=C2=A0 =C2=A0 1035597|=C2=A0 =C2= =A0 1035597|=C2=A0 =C2=A0 =C2=A0 =C2=A0 360<br> >>> RTD|=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 0|=C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 0|=C2=A0 =C2=A0 =C2=A0 25403|=C2=A0 =C2=A0 =C2=A0202992|=C2= =A0 =C2=A0 1035597|=C2=A0 =C2=A0 =C2=A0 =C2=A0 376<br> >>> RTD|=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 0|=C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 0|=C2=A0 =C2=A0 =C2=A0 25288|=C2=A0 =C2=A0 =C2=A0771628|=C2= =A0 =C2=A0 1035597|=C2=A0 =C2=A0 =C2=A0 =C2=A0 398<br> >>> RTD|=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 0|=C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 0|=C2=A0 =C2=A0 =C2=A0 25288|=C2=A0 =C2=A0 =C2=A0771628|=C2= =A0 =C2=A0 1035597|=C2=A0 =C2=A0 =C2=A0 =C2=A0 398<br> >>> ^C<br> >>>>>> S =3D 98.696, EXECTIME =3D 0.0663255<br> >>>> On 24 Feb 2018, at 00:11, Paolo Mantegazza <<a href=3D"= mailto:[email protected]">[email protected]</a>> wrote= :<br> >>>><br> >>>> VM changes the matter a lot.=C2=A0 Anticipating the schedu= ling deadline by 1 ns does not change anything with respect to 0.<br> >>>> In any case it served to indicate that you cannot run the = RTAI tests, simply because VM cannot provide true real time. In particular = it cannot support a 100 us period.<br> >>>> I dare saying that if you configure RTAI to use a lower ca= librating frequency, say 2000 Hz , in place of the default 10000 Hz, you mi= ght succeed in trying the RTAI latency tests, along with the hidden latency= calibration.<br> >>>> In any case hard real time will likely be a no hope matter= .<br> >>>><br> >>>> Paolo<br> >>>><br> >>>> ______________________________<wbr>__________<br> >>>> From: josu [<a href=3D"mailto:[email protected]">josujugo= @gmail.com</a>]<br> >>>> Sent: Friday, February 23, 2018 10:57 PM<br> >>>> To: Paolo Mantegazza<br> >>>> Cc: RTAI RTAI<br> >>>> Subject: Re: [Rtai] RTAI in debian9<br> >>>><br> >>>> Hi again:<br> >>>><br> >>>> First, I want to clarify than I am testing with a VM. Sorr= y for the possible misunderstanding. I have been very busy and I have forgo= t to say this important point.<br> >>>><br> >>>> In any case, I have test your script and the system hangs.= However, making the next change:<br> >>>><br> >>>> insmod $MODULES/rtai_sched.ko kernel_latency=3D1 user_late= ncy=3D1<br> >>>><br> >>>> I have obtained the result attached below.<br> >>>><br> >>>> josu<br> >>>><br> >>>> [<a href=3D"mailto:cid%3A918D06AA-2ABC-4FD7-8085-86263136F= [email protected]">cid:918D06AA-2ABC-4FD7-8085-<wbr>[email protected]</a>]<br> >>>><br> >>>> On 23 Feb 2018, at 18:56, Paolo Mantegazza <<a href=3D"= mailto:[email protected]">[email protected]</a><<wbr>m= ailto:<a href=3D"mailto:[email protected]">paolo.mantegazza@<wbr>p= olimi.it</a>>> wrote:<br> >>>><br> >>>> May you try the "testsuite/user/latency" test, i= n your RTAI install dir, after saving and substituting the existing "r= un" script with the one below and then let me know what happened?<br> >>>> Do it on an unloaded machined and, if possible, after seei= ng a stabilized average latency, attach to your answer also a short snapsho= t of what appears on the screen.<br> >>>> Thanks, Paolo<br> >>>> ------------------------------<wbr>-----------------------= -------<wbr>------------------------------<wbr>-----------------<br> >>>> #!/bin/sh<br> >>>><br> >>>> prefix=3D`rtai-config --prefix`<br> >>>><br> >>>> if test "$prefix" =3D ""; then<br> >>>> echo "ERROR: please set your PATH variable to <rta= i-install>/bin"<br> >>>> exit<br> >>>> fi<br> >>>><br> >>>> MODULES=3D$prefix/modules<br> >>>><br> >>>> libpath=3D`rtai-config --library-dir`<br> >>>><br> >>>> if test "$libpath" =3D ""; then<br> >>>> echo "ERROR: please set your PATH variable to <rta= i-install>/bin"<br> >>>> exit<br> >>>> fi<br> >>>><br> >>>> export LD_LIBRARY_PATH=3D$libpath:$LD_<wbr>LIBRARY_PATH<br= > >>>><br> >>>> cleanup () {<br> >>>> rmmod rtai_msg<br> >>>> rmmod rtai_mbx<br> >>>> rmmod rtai_sem<br> >>>> rmmod rtai_sched<br> >>>> rmmod rtai_hal<br> >>>> }<br> >>>><br> >>>> trap cleanup INT ALRM TERM HUP KILL<br> >>>><br> >>>> insmod $MODULES/rtai_hal.ko<br> >>>> insmod $MODULES/rtai_sched.ko kernel_latency=3D0 user_late= ncy=3D0<br> >>>> insmod $MODULES/rtai_sem.ko;<br> >>>> insmod $MODULES/rtai_mbx.ko;<br> >>>> insmod $MODULES/rtai_msg.ko;<br> >>>><br> >>>> ./latency &<br> >>>> until(`ps -a | grep -q latency`); do sleep 1; done<br> >>>> ./display<br> >>>><br> >>>> cleanup<br> >>>> ------------------------------<wbr>-----------------------= -------<wbr>------------------------------<wbr>-----<br> >>>><br> >>>> ______________________________<wbr>__________<br> >>>> From: josu jugo [[email protected]<mailto:<a href=3D"ma= ilto:[email protected]">josu<wbr>[email protected]</a>>]<br> >>>> Sent: Friday, February 23, 2018 5:37 PM<br> >>>> To: Paolo Mantegazza<br> >>>> Cc: RTAI RTAI<br> >>>> Subject: Re: [Rtai] RTAI in debian9<br> >>>><br> >>>> Hi again:<br> >>>><br> >>>> I have test a simple program obtained with rtai-lab=C2=A0 = (scicoslab version), monitoring with qrtailab and the system is working.<br= > >>>><br> >>>> I have load rtai_sched with kernel_latency=3D1000 and user= _latency=3D1000<br> >>>><br> >>>> josu<br> >>>><br> >>>> On 23 Feb 2018, at 12:51, josu jugo <[email protected]&= lt;mailto:<a href=3D"mailto:[email protected]">josu<wbr>[email protected]</a>&g= t;<mailto:<a href=3D"mailto:[email protected]">josu.<wbr>[email protected]</a= >>> wrote:<br> >>>><br> >>>><br> >>>><br> >>>><br> >>>> <Screen Shot 2018-02-23 at 22.47.37.png><br> >>> ______________________________<wbr>_________________<br> >>> Rtai mailing list<br> >>> <a href=3D"mailto:[email protected]">[email protected]</a><br> >>> <a href=3D"https://mail.rtai.org/cgi-bin/mailman/listinfo/rtai= " rel=3D"noreferrer" target=3D"_blank">https://mail.rtai.org/cgi-bin/<wbr>m= ailman/listinfo/rtai</a><br> >> ______________________________<wbr>_________________<br> >> Rtai mailing list<br> >> <a href=3D"mailto:[email protected]">[email protected]</a><br> >> <a href=3D"https://mail.rtai.org/cgi-bin/mailman/listinfo/rtai" re= l=3D"noreferrer" target=3D"_blank">https://mail.rtai.org/cgi-bin/<wbr>mailm= an/listinfo/rtai</a><br> <br> <br> <br> ------------------------------<br> <br> Subject: Digest Footer<br> <br> ______________________________<wbr>_________________<br> Rtai mailing list<br> <a href=3D"mailto:[email protected]">[email protected]</a><br> <a href=3D"https://mail.rtai.org/cgi-bin/mailman/listinfo/rtai" rel=3D"nore= ferrer" target=3D"_blank">https://mail.rtai.org/cgi-bin/<wbr>mailman/listin= fo/rtai</a><br> <br> ------------------------------<br> <br> End of Rtai Digest, Vol 123, Issue 1<br> ******************************<wbr>******<br> </blockquote></div> --001a113ec948af612a05665838e9-- --===============5854370806289650753== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Rtai mailing list [email protected] https://mail.rtai.org/cgi-bin/mailman/listinfo/rtai --===============5854370806289650753==--