fixed some issue with SoftI2C not working (missing delay)

added code for a waveshare eInk
refactored some old code to match with the new SoftI2C
This commit is contained in:
2020-10-18 10:49:59 +02:00
parent 9c94faa24d
commit ac74587ee7
7 changed files with 426 additions and 44 deletions

View File

@@ -169,6 +169,9 @@ public:
// set output power to 17 dBm
setTxPower(17);
// we use explicit header mode for RX/TX
explicitHeaderMode();
// put in standby mode
idle();
@@ -351,9 +354,9 @@ public:
if (isTransmitting()) {return 0;}
// put in standby mode
idle();
//idle();
explicitHeaderMode();
//explicitHeaderMode();
// reset FIFO address and payload length
writeRegister(REG_FIFO_ADDR_PTR, 0);
@@ -412,7 +415,7 @@ public:
uint8_t irqFlags = readRegister(REG_IRQ_FLAGS);
explicitHeaderMode();
//explicitHeaderMode();
// clear all current IRQ flags
writeRegister(REG_IRQ_FLAGS, irqFlags);