Problems getting v3 sketch to work

Hi, just got two v3 with OLED display units. Powered them up out of the box and everything worked as expected.
Tried to run the WIFI_LoRa_32 factory test code, sketch and it throws errors along the lines of
error: ‘class Heltec_ESP32’ has no member named ‘display’ Heltec.display->clear();

if I add #define WIFI_LoRa_32 before the #include “heltec.h” this it compiles fine but the processor constantly resets when the code is run
22:01:46.108 -> Guru Meditation Error: Core 1 panic’ed (LoadProhibited). Exception was unhandled.

Looking at heltec.h file there is no mention of the v3 chip, which explains why adding the define gets rid of my errors.
I have reviewed the install process several times, and it all seems to be correct. (0.07 of the Heltec ESP32 series dev board).

At the point now I need some guidance, It works for others so I must have missed something but I am not sure what.

Thanks in advance for your time

Maybe check what version of the FactoryTest you are using—there’s one there specifically for the WiFi_LoRa_32_V3. In my version of that sketch there’s no “heltec.h” #include, only the following:

#include “Arduino.h”
#include “WiFi.h”
#include “images.h”
#include “LoRaWan_APP.h”
#include <Wire.h>
#include “HT_SSD1306Wire.h”

Thanks for the reply, I must be running a different version
My version looks like this

  • HelTec Automation™ WIFI_LoRa_32 factory test code, witch includ
  • follow functions:
    • Basic OLED function test;
    • Basic serial port test(in baud rate 115200);
    • LED blink test;
    • WIFI connect and scan test;
    • LoRa Ping-Pong test (DIO0 – GPIO26 interrup check the new incoming messages);
    • Timer test and some other Arduino basic functions.
  • by Aaron.Lee from HelTec AutoMation, ChengDu, China
  • 鎴愰兘鎯犲埄鐗硅嚜鍔ㄥ寲绉戞妧鏈夐檺鍏徃
  • this project also releases on GitHub:

#include “Arduino.h”
#include “heltec.h”
#include “WiFi.h”
#include “images.h”

Note the github reference, does your file reference a different github repository? if so could you please let me know what it is…

Also note that this page references a ‘Heltec ESP32 develop framework!’. it looks to be pretty dated and it throws a internal error 13 when I try to install it.


The comments and GitHub reference are exactly the same in my [V3] version, but it gets different after that. The V3 example sketch, on my Mac Arduino IDE 2.0.3 installation is at:


This and all the other necessary files are in the 0.0.7 Heltec software ‘package’ which is available on GitHub at:

Thanks that helped, it been a bad day as I upgraded my main system to IDE 204 and now I am getting a can’t fine \esptools.exe error message for all sketches urgh.
Back to this problem, on a second system was able to get everything installed, but the compile is throwing this error message… looks to be pretty deep in the code
c:/users/acver/appdata/local/arduino15/packages/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/…/lib/gcc/xtensa-esp32s3-elf/8.4.0/…/…/…/…/xtensa-esp32s3-elf/bin/ld.exe: C:\Users\acver\AppData\Local\Temp\arduino\sketches\83093BE762D851FD47124A52A7D86BB2\sketch\WiFi_LoRa_32_V3_FactoryTest.ino.cpp.o:(.literal._Z11OnTxTimeoutv+0x0): undefined reference to Radio' c:/users/acver/appdata/local/arduino15/packages/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: C:\Users\acver\AppData\Local\Temp\arduino\sketches\83093BE762D851FD47124A52A7D86BB2\sketch\WiFi_LoRa_32_V3_FactoryTest.ino.cpp.o:(.literal._Z9lora_initv+0x0): undefined reference toMcu’
c:/users/acver/appdata/local/arduino15/packages/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/…/lib/gcc/xtensa-esp32s3-elf/8.4.0/…/…/…/…/xtensa-esp32s3-elf/bin/ld.exe: C:\Users\acver\AppData\Local\Temp\arduino\sketches\83093BE762D851FD47124A52A7D86BB2\sketch\WiFi_LoRa_32_V3_FactoryTest.ino.cpp.o:(.literal._Z9lora_initv+0x20): undefined reference to McuClass::begin()' c:/users/acver/appdata/local/arduino15/packages/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: C:\Users\acver\AppData\Local\Temp\arduino\sketches\83093BE762D851FD47124A52A7D86BB2\sketch\WiFi_LoRa_32_V3_FactoryTest.ino.cpp.o: in functionlora_init()’:
C:\Arduino\WiFi_LoRa_32_V3_FactoryTest/WiFi_LoRa_32_V3_FactoryTest.ino:120: undefined reference to `McuClass::begin()’
collect2.exe: error: ld returned 1 exit status

exit status 1

Compilation error: exit status 1

again thanks for your help…

Hi Pete,
Have being trying to work through this with little luck, time to try a different tact.
Did you install any libraries to support the v3 chipset? So far I have only loaded the board (you referenced it above) and have been using the libraries/examples associated with that. I did have to move the LoraWAN and DISPLAY libraries to my local libraries folder before they would be recognized (which doesn’t seem right). Seems to be a lot work to get this running when it should be a simple process.

My setup was as outlined in this thread (excerpt below).

Basically, I installed the latest Arduino IDE (at the time that was 2.0.3) and the Heltec 0.0.7 release, the link to which is provided in the aforementioned thread. At one point I did a completely fresh install under a new user ID, just to be sure of where things were—just the IDE and the Heltec release, nothing more—and that’s what I’d be recommending if things are just not making sense.

I’m still having trouble switching between V1, V2 and V3 boards (because I have all three, and they all work as I need them to when things are configured correctly, so I’m not about to throw any away just because they’ve been ‘superseded’), so there are clearly some conflicts in there with older software. My solution for the time being (perhaps forever!) is simply to use an old configuration on a separate machine for the earlier boards… not entirely satisfactory from my point of view, but it works and I have too many other things to do at the moment to work out a better solution…

There was also a comment in another thread, as I recall, about avoiding having a space in a user name under Windows.

Agreed, you shouldn’t have to do that, so that would suggest that here’s something not quite right in your current setup.

This point has been made by others… :wink:

Hi Pete, again thanks for your comments.
I uninstalled and reinstalled the IDE deleting the arduino15 directory in the process to get a fresh start. Loaded the Arduino, esp32 and the heltec boards and still have the sample error. I can compile and run the WiFikit_32_V3 sketch without error so it is only the LoRa libraries that are causing me grief. the fact that I have to copy the DISPLAY and LoraWan102 libraries to my local library to get it to work has to be a clue. if I remove them I get an error saying the LoraWan_APP.h file doesn’t exist. If I look at other h files in the sketch they are referencing to files in the esp32 207 directory and not the heltec 007 directory copies. Does anyone know where this information is kept? is it a registry entry or is is kept in a config file? other than this I am nor sure what my next step should be, …
thanks in advance

You shouldn’t need anything other than the Heltec 0.0.7 support library. It sounds to me like the esp32 stuff that you’re also loading is taking precedence over the Heltec files. You should probably be deleting (or moving somewhere out of the way if there’s stuff you want to keep) the entire Arduino directory to get a genuine fresh installation. Having done that, install the IDE and load the Heltec support files. Then try the example sketches.

I have encountered this sort of problem before, I think when I first started out with the CubeCell MCUs. To get that to work, I had to ‘hide’ the libraries that were getting in the way (I just zipped them, leaving the .zip file in place so that the content was there if I needed it again, and deleted them) so that the ‘real’ ones could be used. In such a case though, there should be [multiple library] warning messages generated when you’re compiling your sketch.

Tried several things all without success.
Tried zipping up the esp32 library to force the use of the 007 libraries (this caused more cannot find file errors)
I moved the DISPLAY and the LaraWan_102 directories into the ESP32 library directory, removed them from my local library and was able to compile beyond the can’t find file error,
I also moved the entire 007 library into the esp32 library directory, no additional errors other than the one documented above.
So it looks like the IDE is not looking in the 007 library folder at all, not sure where this is defined or if it is adjustable.
If there were updates in the 007 code that would correct the error I am receiving then I would have expected them to be resolved by the last effort above (i.e. moving the entire 007 library over).
So now I am not sure what is causing the error I am seeing. It is so deep in the code and so specific that is looks like a coding error but then
I am at a loss why you are able to compile without errors and I am not…
Will have to think about what the next step will be ???
please let me know if you have any ideas

There’s pretty clearly a problem with your IDE installation, so I’d be doing a completely fresh installation, as suggested earlier, ideally under a newly created user ID, just to be sure that there’s nothing else in there.

I did a fresh install and was able to get it to compile without the errors I was receiving. The only thing I did differently this time through was I loaded the Heltec board first, then the ESP32. Don’t know if this made a difference but I am up and working
Thanks for you help…