chVTGetSystemTime() restarts every 4s !!!!
-
jonesrayan
- Posts: 16
- Joined: Sat Oct 01, 2016 5:07 pm
Re: chVTGetSystemTime() restarts every 4s !!!!
Hinthanks for this detailed answer, polled delay function you mean the oroginal funcion of arduino like delaymicroseconds() ??
-
jonesrayan
- Posts: 16
- Joined: Sat Oct 01, 2016 5:07 pm
- Giovanni
- Site Admin
- Posts: 14891
- Joined: Wed May 27, 2009 8:48 am
- Has thanked: 1202 times
- Been thanked: 996 times
Re: chVTGetSystemTime() restarts every 4s !!!!
jonesrayan wrote:Hinthanks for this detailed answer, polled delay function you mean the oroginal funcion of arduino like delaymicroseconds() ??
yes
-
jonesrayan
- Posts: 16
- Joined: Sat Oct 01, 2016 5:07 pm
Re: chVTGetSystemTime() restarts every 4s !!!!
And it does'nt effect the performance of chibios ?? if i put a delaymicroseconds() in a thead ?.
i need those information because i"m building a quadcopter
so i have to know what danger and what's safe
i need those information because i"m building a quadcopter
- Giovanni
- Site Admin
- Posts: 14891
- Joined: Wed May 27, 2009 8:48 am
- Has thanked: 1202 times
- Been thanked: 996 times
Re: chVTGetSystemTime() restarts every 4s !!!!
Of course it does affect the performance, that function wastes time into a loop. Your other option is to use hardware timers to generate those output signals.
You would be served better by an MCU with hardware PWMs.
Giovanni
You would be served better by an MCU with hardware PWMs.
Giovanni