GCC Code Coverage Report


Directory: ./
File: oled/FPPStatusOLEDPage.h
Date: 2026-10-29 08:11:58
Exec Total Coverage
Lines: 6 8 75.0%
Functions: 2 4 50.0%
Branches: 1 2 50.0%

Line Branch Exec Source
1 #pragma once
2
3 #include "OLEDPages.h"
4 #include <curl/curl.h>
5 #include "fpp-json-fwd.h"
6
7 class MenuOLEDPage;
8
9 class FPPStatusOLEDPage : public OLEDPage {
10 public:
11 FPPStatusOLEDPage();
12 virtual ~FPPStatusOLEDPage();
13
14 12 virtual void displaying() override {
15 12 bool on = true;
16 12 _curPage = 0;
17
1/2
✓ Branch 0 taken 12 times.
✗ Branch 1 not taken.
12 doIteration(on);
18 12 }
19 virtual bool doIteration(bool& displayOn) override;
20 virtual bool doAction(const std::string& action) override;
21
22 int getLinesPage0(std::vector<std::string>& lines,
23 Json::Value& result,
24 bool allowBlank);
25 int getLinesPage1(std::vector<std::string>& lines,
26 Json::Value& result,
27 bool allowBlank);
28
29 void fillInNetworks();
30 int getSignalStrength(char* iwname);
31 void outputNetwork(int idx, int y);
32
33 int outputTopPart(int startY, int count);
34 int outputBottomPart(int startY, int count, bool statusValid, Json::Value& result);
35
36 void cycleTest();
37 void runTest(const std::string& test, bool ms);
38
39 void disableFullStatus() { _doFullStatus = false; }
40
41 5 const std::string& getCurrentMode() const { return currentMode; }
42
43 ✗ bool isMultiSyncTest() const { return _multisyncTest; }
44 ✗ void setMultiSyncTest(bool b) { _multisyncTest = b; }
45
46 private:
47 bool getCurrentStatus(Json::Value& result);
48 bool checkIfStatusChanged(Json::Value& result);
49 bool loadWiFiImage(const std::string& tp = "L");
50 void displayWiFiQR();
51 std::vector<std::string> _lastStatusLines;
52
53 std::vector<std::string> networks;
54 std::vector<int> signalStrength;
55
56 int _iterationCount;
57 bool _fppdSeen = false;
58 std::string _currentTest;
59 int _testSpeed;
60 bool _multisyncTest = false;
61 int _curPage;
62 int _topLine;
63 bool _doFullStatus;
64
65 int _wifiImageWidth = 0;
66 int _wifiImageHeight = 0;
67 std::vector<uint8_t> _wifiImage;
68 int wifiTimer = 0;
69
70 CURL* curl;
71 std::string buffer;
72
73 bool _hasSensors;
74 std::string currentMode;
75
76 MenuOLEDPage* mainMenu;
77 };
78