Yes I did and it did not work on my system. I don't remember why now. On Thursday, February 18, 2021 at 1:47:29 PM UTC-5 Dennis Bieber wrote:
> On Thu, 18 Feb 2021 08:27:48 -0800 (PST), in > gmane.comp.hardware.beagleboard.user Walter Cromer > <walterc-2dFtBuzUeF/tpnmuczy8b...@public.gmane.org> wrote: > > >I think if I could just find how to read the clock on the PRU with C, I > can > >probably take it from here. And of course, it needs to be giving me > >milliseconds. From what I read the main clock functions don't work below > >seconds. > > Have you even looked at the link I posted some hours ago? Duplicated > below. > > >On Wed, 17 Feb 2021 10:45:49 -0800 (PST), in > >gmane.comp.hardware.beagleboard.user Walter Cromer > ><walterc-2dFtBuzUeF/tpnmuczy8bueocmrvltnr-...@public.gmane.org> wrote: > > > >>You are correct that this application does not need to know the actual > real > >>time but only the relative (elapsed) time since the subroutine began. > I'm > >>familiar with clock_gettime but didn't think it could give me subsecond > >>information. I'll explore it! > >> > > > >https://www.tutorialspoint.com/c_standard_library/c_function_clock.htm > > > > The worst you may have to handle is the wrap-around in a long-running > >program. > > According to the documentation, that function returns clock TICKS > (whatever the tick rate is for the system in question). If you know the > CLOCKS_PER_SECOND you should be able to compute the clocks per > millisecond... > > https://linux.die.net/man/3/clock > > or use > > https://linux.die.net/man/2/times > > or better > > https://linux.die.net/man/2/clock_gettime in which the return structure is > seconds AND NANOSECONDS > > > -- > Dennis L Bieber > > -- For more options, visit http://beagleboard.org/discuss --- You received this message because you are subscribed to the Google Groups "BeagleBoard" group. To unsubscribe from this group and stop receiving emails from it, send an email to beagleboard+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/beagleboard/7daba9f3-4d28-4094-89d5-04226fdb9733n%40googlegroups.com.