Skip to content
Snippets Groups Projects
Commit 58389590 authored by Stuart Glaser's avatar Stuart Glaser
Browse files

Driver program informs robot of correct hostname

parent c2080421
Branches
Tags
No related merge requests found
......@@ -413,7 +413,8 @@ def main():
# Sends the program to the robot
sock = socket.create_connection((HOSTNAME, PORT))
with open('prog') as fin:
sock.sendall(fin.read())
program = fin.read()
sock.sendall(program % {"driver_hostname": socket.getfqdn()})
if False:
print "Dump"
......
def driverProg():
HOSTNAME = "10.0.2.97"
HOSTNAME = "%(driver_hostname)s"
MSG_OUT = 1
MSG_QUIT = 2
MSG_JOINT_STATES = 3
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment