nrf24l01: Increase startup delay.

According to the datasheet of the NRF240L1 chip, 150 μs startup time is
only acceptable when the chip is clocked externally.  Most modules use a
crystal, which require 1.5 ms to settle.  It should be okay to wait more in
both cases, for a reliable startup.

Signed-off-by: Marcell Pünkösd <punkosdmarcell@rocketmail.com>
pull/953/head
marcsello 2024-12-30 15:20:18 +01:00 zatwierdzone przez Damien George
rodzic 98d0a2b69a
commit 3e859d2118
1 zmienionych plików z 1 dodań i 1 usunięć

Wyświetl plik

@ -227,7 +227,7 @@ class NRF24L01:
def send_start(self, buf): def send_start(self, buf):
# power up # power up
self.reg_write(CONFIG, (self.reg_read(CONFIG) | PWR_UP) & ~PRIM_RX) self.reg_write(CONFIG, (self.reg_read(CONFIG) | PWR_UP) & ~PRIM_RX)
utime.sleep_us(150) utime.sleep_us(1500) # needs to be 1.5ms
# send the data # send the data
self.cs(0) self.cs(0)
self.spi.readinto(self.buf, W_TX_PAYLOAD) self.spi.readinto(self.buf, W_TX_PAYLOAD)