Skip to content

Commit 0a5eeeb

Browse files
committed
startup without TFT display
1 parent 143700b commit 0a5eeeb

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

51 files changed

+907
-623
lines changed

CMakeLists.txt

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ add_definitions(-DOPTION_AUX_TEMP_SENSOR=1)
3434
add_definitions(-DOPTION_EXT_RTC=1)
3535
add_definitions(-DOPTION_ENCODER=1)
3636
add_definitions(-DOPTION_EXT_EEPROM=1)
37-
add_definitions(-DOPTION_SDCARD=0)
37+
add_definitions(-DOPTION_SDCARD=1)
3838
add_definitions(-DOPTION_SDRAM=1)
3939
add_definitions(-DEEZ_MCU_REVISION_R1B5=1)
4040

@@ -422,13 +422,15 @@ set(src_eez_modules_mcu
422422
src/eez/modules/mcu/battery.cpp
423423
src/eez/modules/mcu/display.cpp
424424
src/eez/modules/mcu/ethernet.cpp
425-
src/eez/modules/mcu/encoder.cpp)
425+
src/eez/modules/mcu/encoder.cpp
426+
src/eez/modules/mcu/sdram.cpp)
426427
list (APPEND src_files ${src_eez_modules_mcu})
427428
set(header_eez_modules_mcu
428429
src/eez/modules/mcu/battery.h
429430
src/eez/modules/mcu/display.h
430431
src/eez/modules/mcu/encoder.h
431432
src/eez/modules/mcu/ethernet.h
433+
src/eez/modules/mcu/sdram.h
432434
src/eez/modules/mcu/touch.h)
433435
list (APPEND header_files ${header_eez_modules_mcu})
434436
source_group("eez\\modules\\mcu" FILES ${src_eez_modules_mcu} ${header_eez_modules_mcu})

src/eez/apps/psu/persist_conf.h

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,12 @@
3232
#define CHANNELS_VIEW_MODE_IN_MAX_YT 2
3333

3434
namespace eez {
35+
36+
enum {
37+
YT_GRAPH_UPDATE_METHOD_SCROLL,
38+
YT_GRAPH_UPDATE_METHOD_SCAN_LINE
39+
};
40+
3541
namespace psu {
3642

3743
class Channel;

src/eez/apps/psu/psu.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -214,7 +214,7 @@ void init() {
214214
trigger::init();
215215

216216
// TODO move this to some other place
217-
#if OPTION_ENCODER
217+
#if OPTION_DISPLAY && OPTION_ENCODER
218218
mcu::encoder::init();
219219
#endif
220220
}

src/eez/apps/psu/timer.cpp

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,5 +46,19 @@ bool Interval::test(uint32_t tick_usec) {
4646
return false;
4747
}
4848

49+
////////////////////////////////////////////////////////////////////////////////
50+
51+
void Timer::start(uint32_t untilTickCount) {
52+
m_isRunning = true;
53+
m_untilTickCount = untilTickCount;
54+
}
55+
56+
bool Timer::isRunning(uint32_t tickCount) {
57+
if (m_isRunning) {
58+
m_isRunning = (int32_t)(m_untilTickCount - tickCount) > 0;
59+
}
60+
return m_isRunning;
61+
}
62+
4963
} // namespace psu
5064
} // namespace eez

src/eez/apps/psu/timer.h

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,5 +34,17 @@ class Interval {
3434
uint32_t next_tick_usec;
3535
};
3636

37+
class Timer {
38+
public:
39+
void start(uint32_t untilTickCount);
40+
41+
bool isRunning(uint32_t tickCount);
42+
43+
private:
44+
uint32_t m_untilTickCount;
45+
bool m_isRunning;
46+
};
47+
48+
3749
}
3850
} // namespace eez::psu

src/eez/gui/action_impl.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@
1616
* along with this program. If not, see http://www.gnu.org/licenses.
1717
*/
1818

19+
#if OPTION_DISPLAY
20+
1921
#include <eez/gui/dialogs.h>
2022
#include <eez/gui/gui.h>
2123
#include <eez/apps/home/touch_calibration.h>
@@ -1030,3 +1032,5 @@ void action_front_panel_select_slot3() {
10301032

10311033
} // namespace gui
10321034
} // namespace eez
1035+
1036+
#endif

src/eez/gui/assets.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@
1616
* along with this program. If not, see <http://www.gnu.org/licenses/>.
1717
*/
1818

19+
#if OPTION_DISPLAY
20+
1921
#include <eez/gui/assets.h>
2022

2123
#include <assert.h>
@@ -191,3 +193,5 @@ const uint16_t *getColors() {
191193

192194
} // namespace gui
193195
} // namespace eez
196+
197+
#endif

src/eez/gui/data.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@
1616
* along with this program. If not, see <http://www.gnu.org/licenses/>.
1717
*/
1818

19+
#if OPTION_DISPLAY
20+
1921
#include <assert.h>
2022
#include <math.h>
2123
#include <stdio.h>
@@ -630,3 +632,5 @@ void data_slot3_test_result(data::DataOperationEnum operation, data::Cursor &cur
630632

631633
} // namespace gui
632634
} // namespace eez
635+
636+
#endif

src/eez/gui/dialogs.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@
1616
* along with this program. If not, see <http://www.gnu.org/licenses/>.
1717
*/
1818

19+
#if OPTION_DISPLAY
20+
1921
#include <eez/gui/dialogs.h>
2022

2123
#include <math.h>
@@ -213,3 +215,5 @@ void dialogLater() {
213215

214216
} // namespace gui
215217
} // namespace eez
218+
219+
#endif

src/eez/gui/document.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@
1616
* along with this program. If not, see http://www.gnu.org/licenses.
1717
*/
1818

19+
#if OPTION_DISPLAY
20+
1921
#include <eez/gui/document.h>
2022

2123
#include <eez/system.h>
@@ -31,3 +33,5 @@ namespace gui {
3133

3234
} // namespace gui
3335
} // namespace eez
36+
37+
#endif

0 commit comments

Comments
 (0)