From fbd0d90d27f50e9bbf9a4c405bb282d49f2463f6 Mon Sep 17 00:00:00 2001 From: DiSlord Date: Sat, 4 Jul 2020 14:14:02 +0300 Subject: [PATCH] Only one PE4302 chip present (my mistake) --- si4432.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/si4432.c b/si4432.c index 86b893f..91f8f83 100644 --- a/si4432.c +++ b/si4432.c @@ -659,10 +659,10 @@ void PE4302_shiftOut(uint8_t val) } #endif -static unsigned char old_attenuation[MAX_SI4432] = {0, 0, 0}; +static unsigned char old_attenuation = 0; bool PE4302_Write_Byte(unsigned char DATA ) { - if (old_attenuation[SI4432_Sel] == DATA) + if (old_attenuation == DATA) return false; // chThdSleepMicroseconds(PE4302_DELAY); SPI2_CLK_LOW;