Skip to content

Commit

Permalink
Merge pull request #360 from mariopesch/master
Browse files Browse the repository at this point in the history
Add senseBox MCU-S2 ESP32S2
  • Loading branch information
hathach committed Nov 16, 2023
2 parents ffb0024 + 8ced19e commit 2ced951
Show file tree
Hide file tree
Showing 5 changed files with 389 additions and 0 deletions.
1 change: 1 addition & 0 deletions .github/workflows/build_esp32.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ jobs:
- 'muselab_nanoesp32-s2_wroom'
- 'muselab_nanoesp32-s2_wrover'
- 'olimex_esp32s2_devkit_lipo_vB1'
- 'sensebox_mcu_esp32s2'
- 'targett_mcb_wroom'
- 'targett_mcb_wrover'
- 'unexpectedmaker_feathers2'
Expand Down
2 changes: 2 additions & 0 deletions ports/espressif/boards/sensebox_mcu_esp32s2/board.cmake
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# Apply board specific content here
set(IDF_TARGET "esp32s2")
71 changes: 71 additions & 0 deletions ports/espressif/boards/sensebox_mcu_esp32s2/board.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
/*
* The MIT License (MIT)
*
* Copyright (c) 2020 Ha Thach (tinyusb.org) for Adafruit Industries
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/

#ifndef SENSEBOX_MCU_ESP32S2_H_
#define SENSEBOX_MCU_ESP32S2_H_

//--------------------------------------------------------------------+
// Button
//--------------------------------------------------------------------+

// Enter UF2 mode if GPIO is pressed while 2nd stage bootloader indicator
// is on e.g RGB = Purple. If it is GPIO0, user should not hold this while
// reset since that will instead run the 1st stage ROM bootloader
#define PIN_BUTTON_UF2 0


//--------------------------------------------------------------------+
// LED
//--------------------------------------------------------------------+

// GPIO connected to Neopixel data
#define NEOPIXEL_PIN 1

#define NEOPIXEL_POWER_STATE 1

// Brightness percentage from 1 to 255
#define NEOPIXEL_BRIGHTNESS 0x10

// Number of neopixels
#define NEOPIXEL_NUMBER 1


//--------------------------------------------------------------------+
// USB UF2
//--------------------------------------------------------------------+

#define USB_VID 0x303A
#define USB_PID 0x81BA
#define USB_MANUFACTURER "senseBox"
#define USB_PRODUCT "MCU-S2 ESP32S2"

#define UF2_PRODUCT_NAME USB_MANUFACTURER " " USB_PRODUCT
#define UF2_BOARD_ID "ESP32S2-senseBoxMCUS2-rev2.1"
#define UF2_VOLUME_LABEL "senseBox"
#define UF2_INDEX_URL "https://sensebox.de"

// Use favicon
#define TINYUF2_FAVICON_HEADER "favicon_sensebox_256.h"

#endif
7 changes: 7 additions & 0 deletions ports/espressif/boards/sensebox_mcu_esp32s2/sdkconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# Board Specific Config

# Partition Table
CONFIG_PARTITION_TABLE_CUSTOM_FILENAME="partitions-4MB.csv"

# Serial flasher config
CONFIG_ESPTOOLPY_FLASHSIZE_4MB=y
Loading

0 comments on commit 2ced951

Please sign in to comment.