In SX Microcontrollers, SX/B Compiler and SX-Key Tool, Peter Van der Zee wrote: Hi Kramer; The SX28 really only has the RTCC as a timer, and your challenge is best handled with an ISR. I have attached some assembler code using an 8 channel state machine to determine the low duration of 8 sequential pulses from an RC receiver. Because there is some inconsistency in the "end of sequence" determination among receivers, I'll leave it to yourself to figure that part out. My implementation is meant as a tutorial; it is by no means the best way to do things. Use of subroutines would substantially shorten the code, but would cloud the operation of the state machine somewhat. I have compiled, but NOT yet run this code as that is not convenient time just now, so it may still have some bugs. Hope you can learn from it. Cheers, Peter (pjv) ---------- End of Message ---------- You can view the post on-line at: http://forums.parallax.com/forums/default.aspx?f=7&p=1&m=109161#m109475 Need assistance? Send an email to the Forum Administrator at forumadmin@parallax.com The Parallax Forums are powered by dotNetBB Forums, copyright 2002-2006 (http://www.dotNetBB.com)