Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updates for esp32s2 builds #3693

Merged
merged 1 commit into from
Apr 22, 2024

Conversation

titan098
Copy link
Contributor

Minor update to allow builds for esp32s2 modules to succeed. The esp32s2 doesn't have Bluetooth so exclude various Bluetooth related components to allow for a successful build if the target platform is an esp32s2.

@titan098 titan098 marked this pull request as ready for review April 21, 2024 15:38
Copy link
Member

@caveman99 caveman99 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why don't you just set -DMESHTASTIC_EXCLUDE_PAXCOUNTER and -DMESHTASTIC_EXCLUDE_BLUETOOTH in the arch/esp32s2.ini for S2?

@@ -721,7 +721,7 @@ void AdminModule::handleGetDeviceConnectionStatus(const meshtastic_MeshPacket &r
#if HAS_BLUETOOTH
conn.has_bluetooth = true;
conn.bluetooth.pin = config.bluetooth.fixed_pin;
#ifdef ARCH_ESP32
#if defined(ARCH_ESP32) && !defined(CONFIG_IDF_TARGET_ESP32S2)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this really neccessary? ESP32-S2 should not have HAS_BLUETOOTH defined.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated as suggested.

Following updates were needed:

  • change to PaxCounterModule.cpp is needed as the build will still pull in the cpp file regardless if the define is set
  • change to sleep.cpp to exclude pulling in nimble if MESHTASTIC_EXCLUDE_BLUETOOTH is defined.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Excellent - this way we can dodge the dreaded CONFIG_IDF macros ... :-)

@caveman99 caveman99 force-pushed the updates_for_esp32s2_build branch from 2c902aa to 16b2161 Compare April 22, 2024 07:51
@titan098 titan098 force-pushed the updates_for_esp32s2_build branch from f496b03 to f434f62 Compare April 22, 2024 08:49
@titan098 titan098 force-pushed the updates_for_esp32s2_build branch from f434f62 to 30d4c3a Compare April 22, 2024 09:01
@caveman99 caveman99 merged commit 8b5fad2 into meshtastic:master Apr 22, 2024
70 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants