Disabling UART Tx when entering SLEEP mode
Posted: Tue Oct 03, 2017 5:49 am
Hi everyone,
Can somebody please advise me what is the best way of disabling the UART Transmitter pin and converting it to input during SLEEP() mode?
I'm controlling the power of the peripherals, and I shut down all power on the board before entering the SLEEP(), but in SLEEP mode the UART remains active (Tx pin is high on +3.3V basically powering my GPS receiver).
I'm using UART (RS232) serial comm component. I noticed just now that the UART CAL has ability to be 'deinitilised' and release resources, but before i change my entire project (and by now it is basically finished and very large) i'm hoping that there is some way where i can disable transmit by simple C code statement. I tried to use 'Input' entry Flowcode macro by reading the input from the port just before entering the SLEEP, but this is doing nothing here.
The processor is PIC18F47J53 but this subject is i believe quite generic.
Thanks,
Igor
Can somebody please advise me what is the best way of disabling the UART Transmitter pin and converting it to input during SLEEP() mode?
I'm controlling the power of the peripherals, and I shut down all power on the board before entering the SLEEP(), but in SLEEP mode the UART remains active (Tx pin is high on +3.3V basically powering my GPS receiver).
I'm using UART (RS232) serial comm component. I noticed just now that the UART CAL has ability to be 'deinitilised' and release resources, but before i change my entire project (and by now it is basically finished and very large) i'm hoping that there is some way where i can disable transmit by simple C code statement. I tried to use 'Input' entry Flowcode macro by reading the input from the port just before entering the SLEEP, but this is doing nothing here.
The processor is PIC18F47J53 but this subject is i believe quite generic.
Thanks,
Igor