variable rename for consistency
This commit is contained in:
parent
72766e2cff
commit
c1ebdd7b16
|
@ -38,13 +38,13 @@ logger.addHandler(ch) # add console log handler
|
|||
# TODO: refactor this to support multiple net#s
|
||||
config = configparser.ConfigParser(allow_no_value=True)
|
||||
config.read('server.cfg') # open config file
|
||||
hog4 = {} # init an empty dictionary
|
||||
servers = {} # init an empty dictionary
|
||||
server = config['hog4'] # section of config file
|
||||
net = server.getint("net", 1) # default to net #1
|
||||
logger.info("Adding Hog device at net# " + str(net))
|
||||
# osc clients are added to the dictionary with the net # as the key
|
||||
hog4[net] = udp_client.SimpleUDPClient(server.get("ip", "10.0.0.1"),
|
||||
server.getint("port", 6600))
|
||||
servers[net] = udp_client.SimpleUDPClient(server.get("ip", "10.0.0.1"),
|
||||
server.getint("port", 6600))
|
||||
|
||||
|
||||
def comment(text):
|
||||
|
@ -53,7 +53,7 @@ def comment(text):
|
|||
stream = antlr4.CommonTokenStream(lexer)
|
||||
parser = CommentMacroParser(stream)
|
||||
tree = parser.prog()
|
||||
oscMacro = OscCommentMacroListener(hog4)
|
||||
oscMacro = OscCommentMacroListener(servers)
|
||||
walker = antlr4.ParseTreeWalker()
|
||||
walker.walk(oscMacro, tree)
|
||||
|
||||
|
|
Loading…
Reference in New Issue