Hi,
I've been working to add SAMv7 Qencoder interface and see that Qencoder
driver expects QEIOC_POSITION to be int32_t value. The issue is that SAMv7
has 16 bit timer counter interface and the SW extension to 32 bits (by
adding adding or subtracting UINT16_MAX+1 when counter matches 0x) does
On Thu, Jan 13, 2022 at 8:19 AM Petro Karashchenko <
petro.karashche...@gmail.com> wrote:
> Hi,
>
> I've been working to add SAMv7 Qencoder interface and see that Qencoder
> driver expects QEIOC_POSITION to be int32_t value. The issue is that SAMv7
> has 16 bit timer counter interface and the SW e
Thank you. I would appreciate that, but I think that will work only if
there is no complete cycle between two reads, so it is potentially a
possibility to get wrong position.
I will try experiment more with timer counter interrupts to see if 0 ->
0x and 0x -> 0 situations.
I will apprecia
On Thu, Jan 13, 2022 at 9:50 AM Petro Karashchenko
wrote:
>
> Thank you. I would appreciate that, but I think that will work only if
> there is no complete cycle between two reads, so it is potentially a
> possibility to get wrong position.
Yes, that is correct. If you know what the application w
Ok. So I will leave 0 ... UINT16_MAX to be returned by the driver and will
handle rollover on the application side.
Thanks!
Petro
On Thu, Jan 13, 2022, 5:15 PM Nathan Hartman
wrote:
> On Thu, Jan 13, 2022 at 9:50 AM Petro Karashchenko
> wrote:
> >
> > Thank you. I would appreciate that, but I
Hi,
Is it possible to redirect syslog into a file (maybe even have it both on
UART and a file)? Also a question is there utility like logrotate or any
other so that maximum size for logs can be set and possibly compression
when one log file is closed and new one is open?
Best regards,
Petro
Hello,
Yes, all these exist.
You need to set:
SYSLOG_FILE=y
and then you may attach a file to the logger using:
syslog_file_channel()
If you want to also keep the UART logger active, then also set:
SYSLOG_MAX_CHANNELS=2
SYSLOG_DEFAULT=y
To have automatic rotations of the log files, you may use