Add loop to keep server active.

This commit is contained in:
Piv
2019-09-29 18:59:44 +09:30
parent 78ba890669
commit d91d666aa9

View File

@@ -60,4 +60,10 @@ class MotorServicer(motorService_pb2_grpc.CarControlServicer):
server.start()
servicer = MotorServicer()
servicer.start_server()
servicer.start_server()
run = True
while run:
inp = input('Please press q to stop the server')
if inp == 'q' or inp == 'Q':
run = False