Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
35 commits
Select commit Hold shift + click to select a range
df5bf27
esp32c5
bmorcelli Aug 8, 2025
f25cd41
Serial interface enabled
bmorcelli Aug 11, 2025
ad40da6
improvements
bmorcelli Aug 11, 2025
68c2ff4
BLE and RFID compatibility, change flags
bmorcelli Aug 12, 2025
d711740
working RF
bmorcelli Aug 13, 2025
ed517b3
teste
bmorcelli Aug 16, 2025
0dd2ddd
simplificar
bmorcelli Aug 16, 2025
58939a2
fix(rf): update RMT handling and stack safety
bmorcelli Aug 17, 2025
f751d9d
Merge pull request #17 from bmorcelli/codex/identify-conflicting-libr…
bmorcelli Aug 17, 2025
6d26609
BLE connections
bmorcelli Aug 18, 2025
3b4275b
simplificar
bmorcelli Aug 19, 2025
c0fe4c1
mic and audio
bmorcelli Aug 24, 2025
97cdad7
restore boards
bmorcelli Aug 24, 2025
5e0301c
MassStorage Workaround
bmorcelli Aug 24, 2025
c56ebd4
Check netif readiness before ARP scan
bmorcelli Aug 25, 2025
999cf0e
Merge pull request #18 from bmorcelli/codex/fix-arpscanner-function-e…
bmorcelli Aug 25, 2025
e1ee4da
arp issue solved
bmorcelli Aug 25, 2025
99cffad
some fixes
bmorcelli Aug 27, 2025
08ba579
create the binary
bmorcelli Aug 27, 2025
ab846db
mmc fix and compatibilizations
bmorcelli Aug 27, 2025
2677b7d
mic issue
bmorcelli Aug 27, 2025
3e7fbb0
full build
bmorcelli Aug 28, 2025
91b544d
Merge branch 'dev' into ide5.5_teste
bmorcelli Aug 29, 2025
4b7d4d4
Reduce Log level to errors
bmorcelli Aug 29, 2025
55f2985
fix merge issue
bmorcelli Aug 29, 2025
6385a3d
warnings control
bmorcelli Aug 31, 2025
85bdf90
Merge branch 'main' into ide5.5_teste
bmorcelli Sep 3, 2025
f230521
Merge branch 'main' into ide5.5_teste
bmorcelli Sep 5, 2025
20b8045
remove dpwo and openheystack
bmorcelli Sep 5, 2025
82e88cb
fix warnings
bmorcelli Sep 6, 2025
9bbfc90
Navigator
bmorcelli Sep 6, 2025
12568ad
enhancements serial reader
bmorcelli Sep 6, 2025
ecd3b4f
serial reader
bmorcelli Sep 6, 2025
183b298
logger optimization
bmorcelli Sep 7, 2025
f6ee35f
mirroring through Serial enhancement
bmorcelli Sep 9, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/workflows/PR_All_envs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ jobs:
- { env: "m5stack-core4mb", family: "ESP32",}
- { env: "m5stack-cores3", family: "ESP32-S3",}
- { env: "esp32-s3-devkitc-1", family: "ESP32-S3",}
- { env: "esp32-c5", family: "ESP32-C5",}
- { env: "CYD-2432S028", family: "ESP32",}
- { env: "CYD-2USB", family: "ESP32",}
- { env: "CYD-2432W328C", family: "ESP32",}
Expand Down
5 changes: 5 additions & 0 deletions .github/workflows/PR_check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,11 @@ jobs:
env: "LAUNCHER_CYD-2432S028",
partitions: { bootloader_addr: "0x1000" },
}
- {
name: "ESP32-C5",
env: "esp32-c5",
partitions: { bootloader_addr: "0x2000" },
}
steps:
- uses: actions/checkout@v4

Expand Down
1 change: 1 addition & 0 deletions .github/workflows/buil_parallel.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ jobs:
- { env: "m5stack-core4mb", family: "ESP32",}
- { env: "m5stack-cores3", family: "ESP32-S3",}
- { env: "esp32-s3-devkitc-1", family: "ESP32-S3",}
- { env: "esp32-c5", family: "ESP32-C5",}
- { env: "CYD-2432S028", family: "ESP32",}
- { env: "CYD-2USB", family: "ESP32",}
- { env: "CYD-2432W328C", family: "ESP32",}
Expand Down
16 changes: 15 additions & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,21 @@
"*.tpp": "cpp",
"condition_variable": "cpp",
"mutex": "cpp",
"thread": "cpp"
"thread": "cpp",
"bit": "cpp",
"charconv": "cpp",
"compare": "cpp",
"concepts": "cpp",
"netfwd": "cpp",
"source_location": "cpp",
"format": "cpp",
"numbers": "cpp",
"semaphore": "cpp",
"span": "cpp",
"stop_token": "cpp",
"text_encoding": "cpp",
"variant": "cpp",
"usb_serial_jtag.h": "c"
},
"files.trimTrailingWhitespace": true,
"files.insertFinalNewline": true,
Expand Down
11 changes: 5 additions & 6 deletions 2.0_road_path.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,12 @@
the objective of 2.0 is changing the Framework to Arduino-ESP32 v3.+, to be able to program to ESP32-C5 chips

## Downsides
- Incompatibility with WireGuard
- Remove OpenHeystack (hard to use and not that usefull)
- Remove DPWO (turn it into a Javascript thing)
- [x] Remove OpenHeystack (hard to use and not that usefull)
- [x] Remove DPWO (turn it into a Javascript thing)

## Enhancements
- Using newer version of C++
- Availability to program to ESP32-C5 (5ghz wifi chip)
- [x] Using newer version of C++
- [x] Availability to program to ESP32-C5 (5ghz wifi chip)

## Things to change on 2.0
- [] InputHadler common codes, defined within #defines structures, not programmin functions to each device
Expand All @@ -20,7 +19,7 @@ the objective of 2.0 is changing the Framework to Arduino-ESP32 v3.+, to be able
## Things to add on 2.0

### Wifi
- [] Wifi 5Ghz support
- [x] Wifi 5Ghz support

### BLE
- [] Session hijacking
Expand Down
4 changes: 1 addition & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,6 @@ Also, [read our FAQ](https://github.com/pr3y/Bruce/wiki/FAQ)
- [x] [RAW Sniffer](https://github.com/pr3y/Bruce/wiki/WiFi#raw-sniffer)
- [x] [TCP Client](https://github.com/pr3y/Bruce/wiki/WiFi#tcp-client)
- [x] [TCP Listener](https://github.com/pr3y/Bruce/wiki/WiFi#tcp-listener)
- [x] [DPWO-ESP32](https://github.com/pr3y/Bruce/wiki/WiFi#dpwo-esp32)
- [x] [Evil Portal](https://github.com/pr3y/Bruce/wiki/WiFi#evil-portal)
- [x] [Scan Hosts](https://github.com/pr3y/Bruce/wiki/WiFi#evil-portal)
- [x] [Wireguard Tunneling](https://github.com/pr3y/Bruce/wiki/WiFi#wireguard-tunneling)
Expand Down Expand Up @@ -174,7 +173,6 @@ Also, [read our FAQ](https://github.com/pr3y/Bruce/wiki/FAQ)
- [x] Megalodon
- [x] [BADUsb (New features, LittleFS and SDCard)](https://github.com/pr3y/Bruce/wiki/Others#badusb)
- [x] USB Keyboard - Cardputer and T-Deck Only
- [x] [Openhaystack](https://github.com/pr3y/Bruce/wiki/Others#openhaystack)
- [x] [iButton](https://github.com/pr3y/Bruce/wiki/Others#ibutton)
- [x] [LED Control](https://github.com/pr3y/Bruce/wiki/Others#led-control)
</details>
Expand Down Expand Up @@ -228,7 +226,7 @@ Also, [read our FAQ](https://github.com/pr3y/Bruce/wiki/FAQ)
² CYD have a LITE_VERSION version for Launcher Compatibility
¹ Core, CYD and StickCs Bad-USB: [here](https://github.com/pr3y/Bruce/wiki/Others#badusb)

*LITE_VERSION*: TelNet, SSH, DPWO, WireGuard, ScanHosts, RawSniffer, Brucegotchi, BLEBacon, BLEScan, Interpreter and OpenHaystack are NOT available for M5Launcher Compatibility
*LITE_VERSION*: TelNet, SSH, WireGuard, ScanHosts, RawSniffer, Brucegotchi, BLEBacon, BLEScan and Interpreter are NOT available for M5Launcher Compatibility


## :sparkles: Why and how does it look?
Expand Down
29 changes: 15 additions & 14 deletions boards/CYD-2432S028/CYD-2432S028.ini
Original file line number Diff line number Diff line change
Expand Up @@ -182,12 +182,12 @@ build_flags =

[env:LAUNCHER_CYD-2USB]
extends=env:CYD-2432S028
board_build.partitions = custom_4Mb.csv
build_flags =
${env:CYD-2432S028.build_flags}
-DCONFIG_ESP32_JTAG_SUPPORT_DISABLE=1
-DTFT_INVERSION_ON
-DLITE_VERSION=1
-DDEVICE_NAME='"LAUNCHER_CYD-2USB"'
${env_light.build_flags}
lib_deps =
${env_light.lib_deps}

[env:CYD-2432W328C]
extends = CYD_base
Expand All @@ -204,11 +204,12 @@ build_flags =

[env:LAUNCHER_CYD-2432S028]
extends=env:CYD-2432S028
board_build.partitions = custom_4Mb.csv
build_flags =
${env:CYD-2432S028.build_flags}
-DCONFIG_ESP32_JTAG_SUPPORT_DISABLE=1
-DLITE_VERSION=1
-DDEVICE_NAME='"LAUNCHER_CYD-2432S028"'
${env_light.build_flags}
lib_deps =
${env_light.lib_deps}

[env:CYD-2432W328C_2] # commom to CYD-2432S024 Capacitive board
extends = env:CYD-2432W328C
Expand All @@ -218,11 +219,12 @@ build_unflags =

[env:LAUNCHER_CYD-2432W328C]
extends=env:CYD-2432W328C
board_build.partitions = custom_4Mb.csv
build_flags =
${env:CYD-2432W328C.build_flags}
-DCONFIG_ESP32_JTAG_SUPPORT_DISABLE=1
-DLITE_VERSION=1
-DDEVICE_NAME='"LAUNCHER_CYD-2432W328C"'
${env_light.build_flags}
lib_deps =
${env_light.lib_deps}

[env:CYD-2432W328R-or-S024R]
extends = CYD_base
Expand All @@ -244,9 +246,8 @@ extends = env:CYD-2432W328R-or-S024R
board_build.partitions = custom_4Mb.csv
build_flags =
${env:CYD-2432W328R-or-S024R.build_flags}
-DCORE_DEBUG_LEVEL=0
-DCONFIG_ESP32_JTAG_SUPPORT_DISABLE=1
-DLITE_VERSION=1
-DDEVICE_NAME='"LAUNCHER_CYD-2432W328R-or-S024R"'
${env_light.build_flags}
lib_deps =
${env_light.lib_deps}

################################# END OF CYD MODELS ####################################################
3 changes: 1 addition & 2 deletions boards/CYD-2432S028/interface.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -79,8 +79,7 @@ void _post_setup_gpio() {

// Brightness control must be initialized after tft in this case @Pirata
pinMode(TFT_BL, OUTPUT);
ledcSetup(TFT_BRIGHT_CHANNEL, TFT_BRIGHT_FREQ, TFT_BRIGHT_Bits); // Channel 0, 10khz, 8bits
ledcAttachPin(TFT_BL, TFT_BRIGHT_CHANNEL);
ledcAttach(TFT_BL, TFT_BRIGHT_FREQ, TFT_BRIGHT_Bits);
ledcWrite(TFT_BRIGHT_CHANNEL, 255);
}

Expand Down
2 changes: 1 addition & 1 deletion boards/ESP-General/interface.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
** Location: main.cpp
** Description: initial setup for the device
***************************************************************************************/
void _setup_gpio() {}
void _setup_gpio() { bruceConfig.startupApp = "WebUI"; }

/***************************************************************************************
** Function name: getBattery()
Expand Down
116 changes: 116 additions & 0 deletions boards/ESP32-C5/ESP32-C5.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,116 @@
; PlatformIO Project Configuration File
;
; Build options: build flags, source filter
; Upload options: custom upload port, speed and extra flags
; Library options: dependencies, extra library storages
; Advanced options: extra scripting
;
; Please visit documentation for the other options and examples
; https://docs.platformio.org/page/projectconf.html

[env:esp32-c5]
board = esp32-c5-devkitc-1
board_build.partitions = custom_8Mb.csv
extra_scripts =
pre:patch-c5.py
pre:pre_build_current_year.py
post:build.py
build_src_filter =${env.build_src_filter} +<../boards/ESP32-C5>
build_flags =
${env.build_flags}
-Iboards/ESP32-C5
-DDEVICE_NAME='"ESP32-C5"'
-DARDUINO_USB_CDC_ON_BOOT=1
-DARDUINO_USB_MODE=1
-DCORE_DEBUG_LEVEL=1
-DBAD_RX=4
-DBAD_TX=5
; grove pins
; defaults from https://github.com/espressif/arduino-esp32/blob/master/variants/esp32s3/pins_arduino.h
-DGROVE_SDA=0 ; default RF TX pin
-DGROVE_SCL=1 ; default IR/RF RX pin
;-DALLOW_ALL_GPIO_FOR_IR_RF=1 ; Set this option to make use of all GPIOs, from 1 to 44 to be chosen, except TFT and SD pins

; ir led pin
-DIR_TX_PINS='{{"Grove W", GROVE_SCL}, {"Grove Y", GROVE_SDA}}'
-DIR_RX_PINS='{{"Grove W", GROVE_SCL}, {"Grove Y", GROVE_SDA}}'
-DLED=27
-DLED_ON=HIGH
-DLED_OFF=LOW

;Radio Frequency (one pin modules) pin setting
-DRF_TX_PINS='{{"Grove W", GROVE_SCL}, {"Grove Y", GROVE_SDA}}'
-DRF_RX_PINS='{{"Grove W", GROVE_SCL}, {"Grove Y", GROVE_SDA}}'

; sd card pins
; suggested https://github.com/espressif/esp-idf/tree/master/examples/storage/sd_card/sdmmc
-DSDCARD_CS=-1
-DSDCARD_SCK=-1
-DSDCARD_MISO=-1
-DSDCARD_MOSI=-1

; tft vars
-DROTATION=1
-DBACKLIGHT=-1 ; tft backlight pin
-DMINBRIGHT=160 ; unused?
-DUSER_SETUP_LOADED=1 ; dont redefine pins
-DILI9341_DRIVER=1 ; example only
-DSMOOTH_FONT=1
-DTFT_DISPON=0x29
-DTFT_DISPOFF=0x28
-DTFT_CS=-1
-DTFT_DC=-1
-DTFT_RST=-1
-DTOUCH_CS=-1
-DTFT_MOSI=-1
-DTFT_SCLK=-1
-DTFT_BL=-1
; text sizes
-DFP=1
-DFM=2
-DFG=3
; ui control buttons
;-DSEL_BTN=1
;-DUP_BTN=2 ; also work as ESC
;-DDW_BTN=3 ; also work as NEXT
-DBTN_ALIAS='"OK"'

;FM Radio
;-DFM_SI4713=1 ;Uncomment to activate FM Radio using Adafruit Si4713
;Microphone
;-DMIC_SPM1423=1 ; uncomment to enable Applicable for SPM1423 device
;-DPIN_CLK=-1
;-DI2S_SCLK_PIN=-1
;-DI2S_DATA_PIN=-1
;-DPIN_DATA=-1

;CC1101 SPI connection pins
; best connection pins for higher speed https://docs.espressif.com/projects/esp-idf/en/latest/esp32s3/api-reference/peripherals/spi_master.html#gpio-matrix-and-io-mux
-DUSE_CC1101_VIA_SPI
-DCC1101_GDO0_PIN=-1
-DCC1101_SS_PIN=SPI_SS_PIN
-DCC1101_MOSI_PIN=SPI_MOSI_PIN
-DCC1101_SCK_PIN=SPI_SCK_PIN
-DCC1101_MISO_PIN=SPI_MISO_PIN
;-DCC1101_GDO2_PIN=14 ; optional

; connections are the same as CC1101
;-DUSE_NRF24_VIA_SPI
;-DNRF24_CE_PIN=5
;-DNRF24_SS_PIN=SPI_SS_PIN ; chip select
;-DNRF24_MOSI_PIN=SPI_MOSI_PIN
;-DNRF24_SCK_PIN=SPI_SCK_PIN
;-DNRF24_MISO_PIN=SPI_MISO_PIN

-DSPI_SCK_PIN=-1
-DSPI_MOSI_PIN=-1
-DSPI_MISO_PIN=-1
-DSPI_SS_PIN=-1

; connections are the same as W5500
; -DUSE_W5500_VIA_SPI
; -DW5500_SS_PIN=SPI_SS_PIN
; -DW5500_MOSI_PIN=SPI_MOSI_PIN
; -DW5500_SCK_PIN=SPI_SCK_PIN
; -DW5500_MISO_PIN=SPI_MISO_PIN
; -DW5500_INT_PIN=5
49 changes: 49 additions & 0 deletions boards/ESP32-C5/interface.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
#include "core/powerSave.h"
#include <interface.h>

/***************************************************************************************
** Function name: _setup_gpio()
** Location: main.cpp
** Description: initial setup for the device
***************************************************************************************/
void _setup_gpio() { bruceConfig.startupApp = "WebUI"; }

/***************************************************************************************
** Function name: getBattery()
** location: display.cpp
** Description: Delivers the battery value from 1-100
***************************************************************************************/
int getBattery() { return 0; }

/***************************************************************************************
** Function name: isCharging()
** Description: Default implementation that returns false
***************************************************************************************/
bool isCharging() { return false; }

/*********************************************************************
** Function: setBrightness
** location: settings.cpp
** set brightness value
**********************************************************************/
void _setBrightness(uint8_t brightval) {}

/*********************************************************************
** Function: InputHandler
** Handles the variables PrevPress, NextPress, SelPress, AnyKeyPress and EscPress
**********************************************************************/
void InputHandler(void) {}

/*********************************************************************
** Function: powerOff
** location: mykeyboard.cpp
** Turns off the device (or try to)
**********************************************************************/
void powerOff() {}

/*********************************************************************
** Function: checkReboot
** location: mykeyboard.cpp
** Btn logic to turnoff the device (name is odd btw)
**********************************************************************/
void checkReboot() {}
Loading