also, how do i properly paste code/pseudocode in my posts with this new fancy forum?
I need a Python guru to help me understand something:
while True:
data, addr = serverSock.recvfrom(1024)
command = data.decode()
print(data)
print(command)
command
this receives UDP message in external python script, proper and prints, but it doesn’t send ‘command’ into my waiting API script. I cant figure why?
output is:
b’print(robot.homed())\x00’
print(robot.homed())
which is fine and confirms received msg.,
but ‘command’ doesn’t execute anything. Something about data decode makes the received message into a string, but what am i missing to execute that ?