diff --git a/config.ini b/config.ini new file mode 100644 index 0000000..46661bf --- /dev/null +++ b/config.ini @@ -0,0 +1,3 @@ +[Default] +AppId=app_id +AccessKey=ttn-account-v2.redacted diff --git a/main.py b/main.py index 342b1a7..6836bc7 100644 --- a/main.py +++ b/main.py @@ -4,9 +4,12 @@ import base64 import message_pb2 import sqlite3 -app_id = "fenceles_grazing" -access_key = "ttn-account-v2.XVvtBVcWzkeby-fe9eLtiJBLRbjQR-b358S4z70Xa-0" +import configparser +config = configparser.ConfigParser() +config.read("config.ini") +app_id = config['Default']['AppId'] +access_key = config['Default']['AccessKey'] # For now use collar id of 1, should look up collar id based on collarname from db def store_coord(collarname, x, y):