Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Script/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ def app_loop(switchModel):
# Entry point main function
def main(ForceDbCreation = False, newSwModel = None):
print(f"Starting Spring Loaded Switch application. {getAppVersion()}")
createRtDbFile(ForceDbCreation)
createRtDbFile(ForceDbCreation, SwModel = newSwModel)
print("Database creation done!")
if newSwModel:
print("Updating new Switch Model...")
Expand Down
6 changes: 4 additions & 2 deletions Script/utility.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,11 +33,13 @@ def getAppVersion():
return "0.0.0.0000"


def createRtDbFile(ForceDbCreation = False):
def createRtDbFile(ForceDbCreation = False, SwModel = None):
if SwModel is None:
SwModel = SWT_MODEL_DOUBLE_TYPE_B
if not os.path.exists(RT_DB_FILE) or ForceDbCreation:
blankData = {
"cycleCount": 0,
"switchModel": SWT_MODEL_DOUBLE_TYPE_B,
"switchModel": SwModel,
"motorStatus": 1
}

Expand Down
2 changes: 1 addition & 1 deletion config.yaml
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
appVersion: 1.9.2.1018
appVersion: 1.9.3.1019
maxCount : 7500000
Loading