HI,
I'm working on a GPS project. The pic16lf88 may be powered from 1 or/and 2 sources (GPS)
Code:OSCCON =100000 TRISA =010000 TRISB =000101 ANSEL =010000 'an4 analog not used at this time PORTA = 0 PORTB = 0 clear led var porta.0 way1 var portb.0 way4 var portb.2 X VAR WORD pause 10 HIGH PORTA.3 ' powering antenna mainloop: X = X + 1 IF X = 10000 then toggle PORTA.0 'led X = 0 endif IF way1 = 1 and way4 = 1 then low PORTB.4 HIGH PORTB.7 goto mainloop endif if way4 = 1 then PORTB.4 = 1 PORTB.7 = 0 endif if way1 = 1 then PORTB.7 = 1 PORTB.4 = 0 endif goto mainloop
When my pic is powered from
way1 = ok
way2 = ok
way1 + way2 = ok
way1 + way2, then cutting power from way2 = ok
way1 + way2, then cutting power from way1 = NOT OK PORTA.3 (antenna) becomes LOW !!!
I have tried to play with BOREN without success. When enabled the circuit doesn't work at all.
Simulation works great with ISIS, not with real circuit.
Can someone help ?
![]()




Bookmarks