Page 1 of 1

Time conversion functions in OSAL  Topic is solved

Posted: Wed Apr 22, 2020 3:31 pm
by stertingen
Currently, using OSAL I'm able to convert (Milli-,Micro-)Seconds into system ticks but not vice versa.

It would be nice to get the current time in milliseconds without doing the conversion by hand or depending on the OS's time conversion.

My use case is a ROSSerial client driver for ChibiOS HAL using nothing but the HAL. (https://github.com/ros-drivers/rosserial/pull/493)

Re: Time conversion functions in OSAL

Posted: Thu Apr 23, 2020 8:47 am
by rreignier
I agree with you.

When I did my rosserial_chibios I used the version found in lwip_binding but it is not very handy. Nice macros like in RT would be nice.

Re: Time conversion functions in OSAL

Posted: Wed Apr 29, 2020 8:53 am
by Giovanni
Hi,

Added to trunk code.

Giovanni