From 08f1789bb595eba43f793ebdfd53302b6ab55c2d Mon Sep 17 00:00:00 2001
From: schneider <schneider@blinkenlichts.net>
Date: Tue, 15 Aug 2023 15:47:53 +0200
Subject: [PATCH] esp32: update to use v1.0.0 BSP

---
 CMakeLists.txt | 17 ++++++++++++++---
 flow3r         |  2 +-
 partitions.csv | 12 +-----------
 3 files changed, 16 insertions(+), 15 deletions(-)
 mode change 100644 => 120000 partitions.csv

diff --git a/CMakeLists.txt b/CMakeLists.txt
index ba6d3c9..daff545 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -1,6 +1,17 @@
-# The following lines of boilerplate have to be in your project's
-# CMakeLists in this exact order for cmake to work correctly
-cmake_minimum_required(VERSION 3.16)
+cmake_minimum_required(VERSION 3.12)
+
+set(IDF_TARGET esp32s3)
 
 include($ENV{IDF_PATH}/tools/cmake/project.cmake)
+
 project(Go_Green)
+
+# Make `1.1` literals into single-point precision float instead of double
+# precision. Also warn any time something gets promoted to a double. We
+# generally don't want doubles, doubles on ESP32 bad.
+idf_component_get_property(flow3r_bsp_lib flow3r_bsp COMPONENT_LIB)
+if("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang")
+    target_compile_options(${flow3r_bsp_lib} PRIVATE -cl-single-precision-constant -Wdouble-promotion)
+else()
+    target_compile_options(${flow3r_bsp_lib} PRIVATE -fsingle-precision-constant -Wdouble-promotion)
+endif()
diff --git a/flow3r b/flow3r
index dd8f80f..869b749 160000
--- a/flow3r
+++ b/flow3r
@@ -1 +1 @@
-Subproject commit dd8f80f4067acc7962ddcc984dea57e3dfd50b92
+Subproject commit 869b749a7636d20f21b28086bf6c950e0f54856b
diff --git a/partitions.csv b/partitions.csv
deleted file mode 100644
index 57902e3..0000000
--- a/partitions.csv
+++ /dev/null
@@ -1,11 +0,0 @@
-# Note: this is a simplified partition table, the real one lives in
-# recovery/partitions.csv. If you flash this project fully, you will end up
-# with a badge with no recovery app! Instead, always use `idf.py app-flash`
-# here, and first do `idf.py erase_flash flash` in the recovery subfolder.
-
-# Name,   Type, SubType, Offset,  Size, Flags
-nvs,      data, nvs,     0x9000,  0x6000,
-phy_init, data, phy,     0xf000,  0x1000,
-# 512KiB gap for recovery app. 
-app,      app,  factory, 0x90000, 0x300000,
-vfs,      data, fat,     0x390000, 0xc70000,
diff --git a/partitions.csv b/partitions.csv
new file mode 120000
index 0000000..9c2bfb4
--- /dev/null
+++ b/partitions.csv
@@ -0,0 +1 @@
+flow3r/partitions.csv
\ No newline at end of file
-- 
GitLab