Skip to content

armgit / flix

Public Imported from GitHub
0

Making an ESP32-based quadcopter from scratch

Fix working on ESP32-S3 (#8)

Zatupitel7d2d54a94dc9
diff --git a/flix/util.h b/flix/util.h
index 8444aaf..a46c034 100644
--- a/flix/util.h
+++ b/flix/util.h
@@ -40,5 +40,5 @@ void printArray(const T (&arr)[N]) {
// Disable reset on low voltage
void disableBrownOut() {
- WRITE_PERI_REG(RTC_CNTL_BROWN_OUT_REG, 0);
+ REG_CLR_BIT(RTC_CNTL_BROWN_OUT_REG, RTC_CNTL_BROWN_OUT_ENA);
}
diff --git a/gazebo/soc/soc.h b/gazebo/soc/soc.h
index f4bdec2..2d3f1e2 100644
--- a/gazebo/soc/soc.h
+++ b/gazebo/soc/soc.h
@@ -1,3 +1,4 @@
// Dummy file to make it possible to compile simulator with Flix' util.h
#define WRITE_PERI_REG(addr, val) {}
+#define REG_CLR_BIT(_r, _b) {}