No1sonuk Posted August 13, 2023 Posted August 13, 2023 Hi all, I'm having a problem with an ESP32 DCS-BIOS program that won't compile. The error is this: Quote WARNING: library Servo claims to run on avr, megaavr, sam, samd, nrf52, stm32f4, mbed, mbed_nano, mbed_portenta, mbed_rp2040 architecture(s) and may be incompatible with your current board which runs on esp32 architecture(s). In file included from c:\Users\PATH\Documents\Arduino\libraries\dcs-bios-arduino-library-master\src/internal/Servos.h:6, from c:\Users\PATH\Documents\Arduino\libraries\dcs-bios-arduino-library-master\src/DcsBios.h:126, from C:\Users\PATH\Documents\Arduino\DCS_gear_ind_3.3tft_ESP32\DCS_gear_ind_3.3tft_ESP32.ino:11: C:\Users\PATH\AppData\Local\Arduino15\libraries\Servo\src/Servo.h:77:2: error: #error "This library only supports boards with an AVR, SAM, SAMD, NRF52 or STM32F4 processor." #error "This library only supports boards with an AVR, SAM, SAMD, NRF52 or STM32F4 processor." ^~~~~ exit status 1 Compilation error: exit status 1 My code begins like this, as suggested in another post: /* The servo library has to be included before DcsBios see: https://github.com/dcs-bios/dcs-bios/issues/101 */ #include <ESP32Servo.h> #define DCSBIOS_DEFAULT_SERIAL #include "DcsBios.h" #include "SPI.h" Any ideas how to fix it?
lesthegrngo Posted August 13, 2023 Posted August 13, 2023 Vinc and I both had this - copy the servo.h from a previous version and overwrite the new one, and it will work Cheers Les
No1sonuk Posted August 13, 2023 Author Posted August 13, 2023 (edited) 11 minutes ago, lesthegrngo said: Vinc and I both had this - copy the servo.h from a previous version and overwrite the new one, and it will work Cheers Les Thanks. Which library should I use? I don't even want to run servos on it... Edited August 13, 2023 by No1sonuk
Vinc_Vega Posted August 13, 2023 Posted August 13, 2023 (edited) Just use the servo.h from the DcsBios hub version. Regards, Vinc Edited August 13, 2023 by Vinc_Vega Regards, Vinc real life: Royal Bavarian Airforce online: VJS-GermanKnights.de [sIGPIC][/sIGPIC]
No1sonuk Posted August 13, 2023 Author Posted August 13, 2023 Don't know what I'm doing wrong, but I keep getting the error.
Vinc_Vega Posted August 13, 2023 Posted August 13, 2023 (edited) It's not the right one. Take that file: https://github.com/dcs-bios/dcs-bios-arduino-library Edit: The difference is in the nowadays missing #ifdef Servo_h condition. Regards, Vinc Servos.h Edited August 13, 2023 by Vinc_Vega Regards, Vinc real life: Royal Bavarian Airforce online: VJS-GermanKnights.de [sIGPIC][/sIGPIC]
No1sonuk Posted August 13, 2023 Author Posted August 13, 2023 Thanks. I've managed to make it compile. Now it's just not responding to DCS. I was trying to convert my BMP-reading TFT code to the ESP32 to see if it was faster than my Uno - it doesn't appear to be, but I'll try something simpler later.
Vinc_Vega Posted August 13, 2023 Posted August 13, 2023 (edited) Confirmed. I made a CDU screen with the ESP32 and it has almost the same "refresh rate" like with the Nano. So the limit must come from the bus speed. Regards, Vinc Edited August 13, 2023 by Vinc_Vega Regards, Vinc real life: Royal Bavarian Airforce online: VJS-GermanKnights.de [sIGPIC][/sIGPIC]
No1sonuk Posted August 13, 2023 Author Posted August 13, 2023 Tnx. I'm using one of these, so I thought it might be faster: https://www.elecrow.com/esp32-display-3-5-inch-hmi-display-spi-tft-lcd-touch-screen.html It might just be the jpeg reading/decoding from the SD card that's slow. The graphics tests run very quickly. Aaand my non-response issue may be my DCS-BIOS install - the Uno version of my sketch isn't working either. That's an investigation for tomorrow evening... 1
No1sonuk Posted August 14, 2023 Author Posted August 14, 2023 I updated DCS-BIOS, and now it works properly.
lesthegrngo Posted August 15, 2023 Posted August 15, 2023 You updated with the latest flightpanels fork? I had put in a ticket to highlight the ESP32 incompatibility with the Servo.h library, so hopefully that was addressed Les
No1sonuk Posted August 15, 2023 Author Posted August 15, 2023 Ooh. I updated BIOS AFTER I got it compiling, but haven't updated the Arduino library.
Recommended Posts