Ok I now have something workable, but its still not behaving as I would hope.
I'm using the EasyPIC5 board, with 10K pot set to RA1. The following "abridged" code seems to give a decaying value for the varible D used to store the ADCIN.
Code:
main:
ADCIN 0, D
LCDOUT $FE,$C0, "Chase Speed " ,#D
'DO MAIN PART OF FLASH LEDS IN SEQUENCE HERE'
PAUSE D
NEXT
goto main:
With the post set to +5 it gives a reading (decimal) for D of 40ish, which then drops to 12 and then flucuates between 12 and 16, meaning that the speed at which the LEDS flash can't stay constant.
Any Ideas ?
(I can post full code if require)
Bookmarks