Hi
This is my testcode & schematic:
'---------------------------------
Include "modedefs.bas"
@ DEVICE HS_OSC
DEFINE OSC 20
ADCON1 = 7
CMCON=7
TRISE.4=0
LED VAR PORTB.5
boot:
Pause 500
Low led
high porta.0
LOOP:
if portc.2 = 1 then high ut10
if portc.3 = 1 then high ut10
if portd.0 = 1 then high ut10
if portd.1 = 1 then high ut10
if portc.5 = 1 then high ut10
if portc.4 = 1 then high ut10
if portd.3 = 1 then high ut10
if portd.2 = 1 then high ut10
pause 1
low ut10
goto loop
'---------------------------------
link to my schematics:
http://www.mediespecialist.se/pic16f874a/874a.gif
and a picture:
http://www.mediespecialist.se/pic16f874a/IMG_2144.JPG
/ Petter
Bookmarks