import sys
import time

import serial

if __name__ == '__main__':

	ser = serial.Serial('/dev/ttyS0', 9600, timeout=5, write_timeout=3)
	time.sleep(2)

	while True:
		command = input("Enter command: led; - toggle LED, e - exit ")
		if command == 'led;':
			ser.write(command.encode('utf-8'))
		elif command == 'e':
			print('System exit.')
			break

	ser.close()
	sys.exit()

b2000904564f378d631af85b7c590957c02f6c7b
<mask token>

<mask token>
if __name__ == '__main__':
    ser = serial.Serial('/dev/ttyS0', 9600, timeout=5, write_timeout=3)
    time.sleep(2)
    while True:
        command = input('Enter command: led; - toggle LED, e - exit ')
        if command == 'led;':
            ser.write(command.encode('utf-8'))
        elif command == 'e':
            print('System exit.')
            break
    ser.close()
    sys.exit()

import sys
import time
import serial
if __name__ == '__main__':
    ser = serial.Serial('/dev/ttyS0', 9600, timeout=5, write_timeout=3)
    time.sleep(2)
    while True:
        command = input('Enter command: led; - toggle LED, e - exit ')
        if command == 'led;':
            ser.write(command.encode('utf-8'))
        elif command == 'e':
            print('System exit.')
            break
    ser.close()
    sys.exit()

import sys
import time

import serial

if __name__ == '__main__':

	ser = serial.Serial('/dev/ttyS0', 9600, timeout=5, write_timeout=3)
	time.sleep(2)

	while True:
		command = input("Enter command: led; - toggle LED, e - exit ")
		if command == 'led;':
			ser.write(command.encode('utf-8'))
		elif command == 'e':
			print('System exit.')
			break

	ser.close()
	sys.exit()
