lemmingDev / ESP32-BLE-Gamepad

Bluetooth LE Gamepad library for the ESP32
Other
1.1k stars 183 forks source link

Can't do a custom configuration #232

Open fedekrum opened 1 month ago

fedekrum commented 1 month ago

Hi there,

I'm currently using an Intel Mac with Arduino IDE 2.3.3. The libraries I'm using are NimBLE-Arduino 1.4.1 by h2zero and ESP32-BLE-Gamepad 5.4. The hardware I'm working with is an ESP-WROOM-32 Module. I've selected the "ESP32 Dev Module" and the correct port, and I don't have any issues compiling and uploading any sketches.

The problem arises when I attempt to use the example called "CharacteristicsConfiguration.ino."

To prevent a compilation error, I've commented out the line: //esp_base_mac_addr_set(&newMACAddress[0]); // Set new MAC address

/private/var/folders/2j/3qh45kk54w331n9q5shfcfs00000gr/T/.arduinoIDE-unsaved2024919-45680-1pcuu75.2y8y/CharacteristicsConfiguration/CharacteristicsConfiguration.ino: In function 'void setup()':
/private/var/folders/2j/3qh45kk54w331n9q5shfcfs00000gr/T/.arduinoIDE-unsaved2024919-45680-1pcuu75.2y8y/CharacteristicsConfiguration/CharacteristicsConfiguration.ino:40:5: error: 'esp_base_mac_addr_set' was not declared in this scope
   40 |     esp_base_mac_addr_set(&newMACAddress[0]); // Set new MAC address
      |     ^~~~~~~~~~~~~~~~~~~~~

exit status 1

Compilation error: 'esp_base_mac_addr_set' was not declared in this scope

I've also adjusted the battery level to 50% in the constructor. Unfortunately, it doesn't seem to change the name of the device to "Custom Controller Name."

Here's a screenshot showing the issue: Captura de pantalla 2024-10-19 a la(s) 01 51 47

Do you have any ideas why it's not changing the name?

Thanks in advance.

lemmingDev commented 5 days ago

You need to delete the controller from the operating system and re-add it if you make any changes