You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
delayMicroseconds(50);// why do we need to delay 50us on ESP32? In my experience no extra delays are needed, on any of the architectures I've tested...
187
180
#else
188
-
delayMicroseconds(10);
181
+
delayMicroseconds(1); // delay 1us, the minimum time possible in plain arduino. 350ns is the required time for AMS sensors, 80ns for MA730, MA702
189
182
#endif
190
183
191
184
//Now read the response
192
185
digitalWrite(chip_select_pin, LOW);
193
-
digitalWrite(chip_select_pin, LOW);
194
186
word register_value = spi->transfer16(0x00);
195
187
digitalWrite(chip_select_pin, HIGH);
196
-
digitalWrite(chip_select_pin,HIGH);
197
188
198
-
#if !defined(_STM32_DEF_) // if not stm chips
199
189
//SPI - end transaction
200
190
spi->endTransaction();
201
-
#endif
202
191
203
192
register_value = register_value >> (1 + data_start_bit - bit_resolution); //this should shift data to the rightmost bits of the word
0 commit comments