mirror of
https://github.com/lumapu/ahoy.git
synced 2025-08-06 09:58:23 +02:00
fix SH1106 rotation and turn off during night #756
This commit is contained in:
parent
28bd99ed1e
commit
0cc6e09383
3 changed files with 6 additions and 3 deletions
|
@ -42,7 +42,7 @@ class Display {
|
|||
}
|
||||
|
||||
void tickerSecond() {
|
||||
loop();
|
||||
mMono.loop();
|
||||
if (mNewPayload || ((++mLoopCnt % 10) == 0)) {
|
||||
mNewPayload = false;
|
||||
mLoopCnt = 0;
|
||||
|
|
|
@ -27,9 +27,9 @@ DisplayMono::DisplayMono() {
|
|||
|
||||
|
||||
|
||||
void DisplayMono::init(uint8_t type, uint8_t rot, uint8_t cs, uint8_t dc, uint8_t reset, uint8_t clock, uint8_t data, uint32_t *utcTs, const char* version) {
|
||||
void DisplayMono::init(uint8_t type, uint8_t rotation, uint8_t cs, uint8_t dc, uint8_t reset, uint8_t clock, uint8_t data, uint32_t *utcTs, const char* version) {
|
||||
if ((0 < type) && (type < 4)) {
|
||||
u8g2_cb_t *rot = (u8g2_cb_t *)((rot != 0x00) ? U8G2_R2 : U8G2_R0);
|
||||
u8g2_cb_t *rot = (u8g2_cb_t *)((rotation != 0x00) ? U8G2_R2 : U8G2_R0);
|
||||
mType = type;
|
||||
switch(type) {
|
||||
case 1:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue