Feb-22-2023, 11:09 PM
I've written a program that uses the SERIAL library. The program seems to work just fine. I have a question about the scope of the methods, such as serial.read. In the main routine I can use serial. read, serial.write, serial.inWaiting etal with no problems. BUT if I try to use a subroutine like this
def CRLF ()
SERIAL.write(LineFeed.encode())
This does not work, yet in the main routine it does. This leads me to believe the scope is not there. How can I make this work? Thanks, Mike
def CRLF ()
SERIAL.write(LineFeed.encode())
This does not work, yet in the main routine it does. This leads me to believe the scope is not there. How can I make this work? Thanks, Mike