The effect of Interrupt from motor encoder reading
hello,
i using 4 dc motors encoders attached arduino due. use dual channel hall effect encoders? using them provide feedback on motors' actual speed. understand use of interrupt service routine affect accuracy of millis(), have been using millis() in other time-sensitive functions @ range of 100hz.
will use of isp affect accuracy of other time-sensitive functions? if yes, there alternatives can use count time? using millis() make sure fusion sensor algorithm , pid functions called @ fixed intervals.
i using 4 dc motors encoders attached arduino due. use dual channel hall effect encoders? using them provide feedback on motors' actual speed. understand use of interrupt service routine affect accuracy of millis(), have been using millis() in other time-sensitive functions @ range of 100hz.
will use of isp affect accuracy of other time-sensitive functions? if yes, there alternatives can use count time? using millis() make sure fusion sensor algorithm , pid functions called @ fixed intervals.
a little timing jitter should not big problem @ 100hz.
nick gammon wrote interesting page interrupts , timing : http://gammon.com.au/interrupts
you can read on page external interrupt takes 5 µs plus own code.
keep code small, example increment integer, , else outside interrupt routine.
nick gammon wrote interesting page interrupts , timing : http://gammon.com.au/interrupts
you can read on page external interrupt takes 5 µs plus own code.
keep code small, example increment integer, , else outside interrupt routine.
Arduino Forum > Using Arduino > Motors, Mechanics, and Power (Moderator: fabioc84) > The effect of Interrupt from motor encoder reading
arduino
Comments
Post a Comment