1 Attachment(s)
porta problems during shiftout/shiftin
Hello to all, this is the first post of my life so please excuse for any mistake i'll do.
Is 1 month that i am trying to find a solotion to this: In my project when i useshifin or shift out commands the pin ra.4 (that is not involved) goes low!
And remain low. i can't figure why..why.....why!!!! i am going mad!
Changing the clock pin from porta.1 to portb.x does the job: the porta.4 remain high as i want. This is my spi setup:
'SPI setup
cs var porta.2
sck var porta.1 ;this is the matter
si var portE.0
so var porta.3
output porta.2
output porta.1
output porta.3
input portE.0
the processor is a 18LF4550 (low voltage option version)
i attach a part of my code:
Attachment 7030
i have trying everything, maybe someone will solve this matter....
Thankyou in advance .
Guido
Re: porta problems during shiftout/shiftin
Port A often has analog features. Have you tried making it digital?
(Can't view your code of this phone)
Robert
Re: porta problems during shiftout/shiftin
Hi Demon and thankyou for the fast reply. Yes , with this line
ADCON1=%00001110
i set porta.0 to analog and all the others pins on porta to digital