From 420c0a3fabe3bbe376dde1ffb9c0900a99a2fbf8 Mon Sep 17 00:00:00 2001 From: anschrammh Date: Sat, 16 Mar 2019 22:39:24 +0100 Subject: [PATCH] Minor changes --- documentation/app_class_diagram.mdj | 87 +++++++++++++++-------------- src/app/app.ino | 10 ++-- 2 files changed, 52 insertions(+), 45 deletions(-) diff --git a/documentation/app_class_diagram.mdj b/documentation/app_class_diagram.mdj index 5db86b7..9b43419 100644 --- a/documentation/app_class_diagram.mdj +++ b/documentation/app_class_diagram.mdj @@ -3803,7 +3803,8 @@ }, "visible": false, "font": "Arial;13;0", - "top": 544, + "left": -16, + "top": 656, "height": 13 }, { @@ -3813,8 +3814,8 @@ "$ref": "AAAAAAFpIVCNABPYowM=" }, "font": "Arial;13;1", - "left": 421, - "top": 1271, + "left": 413, + "top": 1327, "width": 153.55615234375, "height": 13, "text": "ViewLinkedList" @@ -3827,7 +3828,8 @@ }, "visible": false, "font": "Arial;13;0", - "top": 544, + "left": -16, + "top": 656, "width": 73.67724609375, "height": 13, "text": "(from Model)" @@ -3840,14 +3842,15 @@ }, "visible": false, "font": "Arial;13;0", - "top": 544, + "left": -16, + "top": 656, "height": 13, "horizontalAlignment": 1 } ], "font": "Arial;13;0", - "left": 416, - "top": 1264, + "left": 408, + "top": 1320, "width": 163.55615234375, "height": 25, "stereotypeLabel": { @@ -3883,8 +3886,8 @@ "$ref": "AAAAAAFpIVFv0xYYyKo=" }, "font": "Arial;13;0", - "left": 421, - "top": 1294, + "left": 413, + "top": 1350, "width": 153.55615234375, "height": 13, "text": "-pData: void*", @@ -3900,8 +3903,8 @@ "$ref": "AAAAAAFpIVHZcha1vLw=" }, "font": "Arial;13;0", - "left": 421, - "top": 1309, + "left": 413, + "top": 1365, "width": 153.55615234375, "height": 13, "text": "-logic_function: boolean*", @@ -3917,8 +3920,8 @@ "$ref": "AAAAAAFpIVKy4BfqLR4=" }, "font": "Arial;13;0", - "left": 421, - "top": 1324, + "left": 413, + "top": 1380, "width": 153.55615234375, "height": 13, "text": "-UID: const int", @@ -3934,8 +3937,8 @@ "$ref": "AAAAAAFpIVL7ehiHAoI=" }, "font": "Arial;13;0", - "left": 421, - "top": 1339, + "left": 413, + "top": 1395, "width": 153.55615234375, "height": 13, "text": "-next: ViewLink*", @@ -3943,8 +3946,8 @@ } ], "font": "Arial;13;0", - "left": 416, - "top": 1289, + "left": 408, + "top": 1345, "width": 163.55615234375, "height": 68 }, @@ -3958,8 +3961,8 @@ "$ref": "AAAAAAFpIVCM/xPV/bU=" }, "font": "Arial;13;0", - "left": 416, - "top": 1357, + "left": 408, + "top": 1413, "width": 163.55615234375, "height": 10 }, @@ -3974,7 +3977,8 @@ }, "visible": false, "font": "Arial;13;0", - "top": 272, + "left": -8, + "top": 328, "width": 10, "height": 10 }, @@ -3989,15 +3993,16 @@ }, "visible": false, "font": "Arial;13;0", - "top": 272, + "left": -8, + "top": 328, "width": 10, "height": 10 } ], "font": "Arial;13;0", "containerChangeable": true, - "left": 416, - "top": 1264, + "left": 408, + "top": 1320, "width": 163.55615234375, "height": 133, "nameCompartment": { @@ -4037,8 +4042,8 @@ }, "visible": false, "font": "Arial;13;0", - "left": 507, - "top": 1244, + "left": 501, + "top": 1273, "height": 13, "alpha": 1.5707963267948966, "distance": 15, @@ -4058,8 +4063,8 @@ }, "visible": null, "font": "Arial;13;0", - "left": 522, - "top": 1243, + "left": 516, + "top": 1273, "height": 13, "alpha": 1.5707963267948966, "distance": 30, @@ -4079,8 +4084,8 @@ }, "visible": false, "font": "Arial;13;0", - "left": 478, - "top": 1247, + "left": 472, + "top": 1274, "height": 13, "alpha": -1.5707963267948966, "distance": 15, @@ -4100,7 +4105,7 @@ }, "visible": false, "font": "Arial;13;0", - "left": 509, + "left": 501, "top": 1261, "height": 13, "alpha": 0.5235987755982988, @@ -4121,8 +4126,8 @@ }, "visible": false, "font": "Arial;13;0", - "left": 522, - "top": 1262, + "left": 515, + "top": 1263, "height": 13, "alpha": 0.7853981633974483, "distance": 40, @@ -4142,8 +4147,8 @@ }, "visible": false, "font": "Arial;13;0", - "left": 481, - "top": 1258, + "left": 474, + "top": 1257, "height": 13, "alpha": -0.5235987755982988, "distance": 25, @@ -4163,8 +4168,8 @@ }, "visible": false, "font": "Arial;13;0", - "left": 507, - "top": 1230, + "left": 502, + "top": 1286, "height": 13, "alpha": -0.5235987755982988, "distance": 30, @@ -4183,8 +4188,8 @@ }, "visible": false, "font": "Arial;13;0", - "left": 520, - "top": 1227, + "left": 515, + "top": 1283, "height": 13, "alpha": -0.7853981633974483, "distance": 40, @@ -4203,8 +4208,8 @@ }, "visible": false, "font": "Arial;13;0", - "left": 480, - "top": 1235, + "left": 474, + "top": 1291, "height": 13, "alpha": 0.5235987755982988, "distance": 25, @@ -4249,7 +4254,7 @@ "$ref": "AAAAAAFpHq11gr6quCs=" }, "lineStyle": 1, - "points": "493:1242;494:1263", + "points": "486:1242;488:1319", "showVisibility": true, "nameLabel": { "$ref": "AAAAAAFpIVDGIBS5fjw=" diff --git a/src/app/app.ino b/src/app/app.ino index d27414f..6d79964 100644 --- a/src/app/app.ino +++ b/src/app/app.ino @@ -8,7 +8,7 @@ SAB sab; unsigned long currentMs = 0, batteryMs = 0, buttonMs = 0; int mySize = 0; unsigned char curView = 0; -View1Packet v1p = {sab.getRtcManager().getDateTime(), sab.getSdCardManager().getSize(GBYTE), sab.getPowerInfo()}; +View1Packet v1p = {sab.getRtcManager().getDateTime(), sab.getSdCardManager().getSize(GBYTE), sab.getPowerInfo(),0}; ViewAPPacket vap = {sab.getConnectivityManager().softAPmacAddress(), sab.getConnectivityManager().softAPSSID(), sab.getConnectivityManager().softAPIP(), sab.getConnectivityManager().softAPgetStationNum()}; void setup() @@ -36,6 +36,7 @@ void loop() { currentMs = millis(); v1p.dateTime = sab.getRtcManager().getDateTime(); + v1p.nbViews = sab.getScreenManager().getViewCount(); vap.ipAddr = sab.getConnectivityManager().softAPIP(); vap.macAddr = sab.getConnectivityManager().softAPmacAddress(); vap.nbOfCon = sab.getConnectivityManager().softAPgetStationNum(); @@ -54,9 +55,10 @@ void loop() { buttonMs = millis(); Serial.println("Changing view"); - curView++; - curView %= 3; - sab.getScreenManager().displayView(curView); + Serial.print("Selected view is : ");Serial.println(sab.getScreenManager().getCurrentViewUID()); + /*curView++; + curView %= 3;*/ + sab.getScreenManager().displayNextView(); } }