Here it is:
@ __config _CONFIG1, _FOSC_INTOSC & _WDTE_OFF & _MCLRE_OFF & _BOREN_OFF & _FCMEN_OFF
@ __config _CONFIG2, _STVREN_OFF & _LVP_OFF
OLO VAR PORTB.5
OLM VAR PORTB.4
OMD VAR PORTB.3
OMH VAR PORTB.2
OHI VAR PORTB.1
DEFINE OSC 32
ANSELA= %00011111
ANSELB= %11000000
CCP1CON=%00000000
CCP2CON=%00000000
CCP3CON=%00000000
CCP4CON=%00000000
OSCCON= %11110000
TRISA = %01111111
TRISB = %11000001
MAIN:
OLO=1 : PAUSE 1000 : OLO=0
OLM=1 : PAUSE 1000 : OLM=0
OMD=1 : PAUSE 1000 : OMD=0
OMH=1 : PAUSE 1000 : OMH=0
OHI=1 : PAUSE 1000 : OHI=0
GOTO MAIN
END
No ADCs, no triac output, nothing but outputs low to high and back.
Results:
Each channel comes on in succession. The first four, however, than simply stay on. The fifth goes on and off exactly as you would expect.
I even tried this on a "fresh" '1827. No difference.
This is why I remain convinced that the problem hides in how I'm configuring something that affects B.2 through B.5 but permits B.1 to operate normally.





Bookmarks