MCPcopy Create free account
hub / github.com/OpenEPaperLink/OpenEPaperLink / reset

Method reset

ESP32_AP-Flasher/src/zbs_interface.cpp:94–112  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

92}
93
94void ZBS_interface::reset(bool leavepower) {
95 /*
96 if (spi) {
97 spi->end();
98 delete spi;
99 spi = nullptr;
100 }
101 */
102 pinMode(_SS_PIN, INPUT);
103 pinMode(_CLK_PIN, INPUT);
104 pinMode(_MOSI_PIN, INPUT);
105 pinMode(_MISO_PIN, INPUT);
106 digitalWrite(_RESET_PIN, LOW);
107 set_power(ZBS_OFF);
108 delay(500);
109 digitalWrite(_RESET_PIN, HIGH);
110 if (leavepower) set_power(ZBS_ON);
111 pinMode(_RESET_PIN, INPUT);
112}
113
114void ZBS_interface::send_byte(uint8_t data) {
115 digitalWrite(_SS_PIN, LOW);

Callers 7

doForcedAPFlashFunction · 0.45
doAPFlashFunction · 0.45
doAPUpdateFunction · 0.45
doTagFlashFunction · 0.45
processFlasherCommandFunction · 0.45
onClientConnectFunction · 0.45
webFlasherTaskFunction · 0.45

Calls 1

delayFunction · 0.50

Tested by

no test coverage detected