“Hello World” Lora sender / receiver pair now working. Thanks again everyone.
WiFi LoRa 32 (V3) -w- ESP32-S3
working on V3 (both the sender & receiver)
Describe how you got it working!!! I have never had so much trouble bringing up a board (V3) on Arduino IDE. I cannot compile practically any sketch and when I do, I cannot load it because it sees the wrong ESP chip. I am about to send these devices back to Amazon (I have 2) because Heltec is not supporting this device with the correct libraries/board/etc environment.
Help from anyone who has V3 working…
I can elaborate later as far as providing step-by-step details. In the meantime, I would suggest reviewing UniquePete’s post from Nov 23rd as it contains links to the V3 board definitions the Arduino IDE needs, along with updated Heltec libraries that support V3
I followed UniquePete and finally got Blink to compile and the following during upload:
Sketch uses 219053 bytes (16%) of program storage space. Maximum is 1310720 bytes.
Global variables use 16088 bytes (4%) of dynamic memory, leaving 311592 bytes for local variables. Maximum is 327680 bytes.
esptool.py v3.3
Serial port COM4
Connecting…
A fatal error occurred: This chip is ESP32-S3 not ESP32. Wrong --chip argument?
Failed uploading: uploading error: exit status 2
Trying to compile other Heltec Lora 32 Examples I get the following for all compiles using just about any board (WiFi Lora V3, WiFi Lora V2, etc:
In file included from c:\users\lawrence01073\appdata\local\arduino15\packages\heltec-esp32\tools\xtensa-esp32s3-elf-gcc\gcc8_4_0-esp-2021r2-patch3\xtensa-esp32s3-elf\include\c++\8.4.0\string:41,
from c:\users\lawrence01073\appdata\local\arduino15\packages\heltec-esp32\tools\xtensa-esp32s3-elf-gcc\gcc8_4_0-esp-2021r2-patch3\xtensa-esp32s3-elf\include\c++\8.4.0\stdexcept:39,
from c:\users\lawrence01073\appdata\local\arduino15\packages\heltec-esp32\tools\xtensa-esp32s3-elf-gcc\gcc8_4_0-esp-2021r2-patch3\xtensa-esp32s3-elf\include\c++\8.4.0\array:39,
from c:\users\lawrence01073\appdata\local\arduino15\packages\heltec-esp32\tools\xtensa-esp32s3-elf-gcc\gcc8_4_0-esp-2021r2-patch3\xtensa-esp32s3-elf\include\c++\8.4.0\tuple:39,
from c:\users\lawrence01073\appdata\local\arduino15\packages\heltec-esp32\tools\xtensa-esp32s3-elf-gcc\gcc8_4_0-esp-2021r2-patch3\xtensa-esp32s3-elf\include\c++\8.4.0\functional:54,
from C:\Users\lawrence01073\Documents\Arduino\hardware\heltec\esp32\cores\esp32/HardwareSerial.h:49,
from C:\Users\lawrence01073\Documents\Arduino\hardware\heltec\esp32\cores\esp32/Arduino.h:173,
from C:\Users\lawrence01073\AppData\Local\Temp\arduino-sketch-D58C91985DA5A30825EF129AB14279FD\sketch\LoRaWan_OLED.ino.cpp:1:
c:\users\lawrence01073\appdata\local\arduino15\packages\heltec-esp32\tools\xtensa-esp32s3-elf-gcc\gcc8_4_0-esp-2021r2-patch3\xtensa-esp32s3-elf\include\c++\8.4.0\bits\allocator.h:46:10: fatal error: bits/c++allocator.h: No such file or directory
#include <bits/c++allocator.h> // Define the base class to std::allocator.
^~~~~~~~~~~~~~~~~~~~~
compilation terminated.
exit status 1
Compilation error: exit status 1
Do you have this link in the Arduino boards manager? It defines V3
V3 has an ESP32-S3 chip
Make sure also you have the most recent version of the Arduino IDE 2.0.2
As far as the libraries, I also experienced some oddities with the Arduino referencing the local AppData folders - not sure why. Here is what I did:
- Deleted all prior libraries (including HELTEC) that I had tried to use to get the V3 board to function from the Documents/Arduino/Libraries folder.
- Extracted the HELTEC esp32-0.0.7 zip file (Link provided by UniquePete)
- Copied ALL of the HELTEC libraries included in the esp32-0.0.7 framework to the Documents/Arduino/Libraries folder. Libraries may or may not be necessary depending on the program. I chose to copy all HELTEC libraries initially just to ensure that any needed dependencies were in place within the Arduini IDE.
- I tested these two example programs: WiFi_LoRa_32_V3_FactoryTest (Lora Receiver) - make sure you set the frequency for your region -&- LoRaSender; again set the frequency.
I am in North America, so I used 915 mHz
/********************************* lora *********************************************/
#define RF_FREQUENCY 915000000 // Hz
If helpful, here is a visual of the 0.0.7 HELTEC libraries after being copied to the Documents/Arduino/Libraries folder. The only non-HELTEC 0.0.7 library is the Adafruit_NeoPixel library.
I am still having the same issues. My library file looks like yours. I am using the Preference that you shared. I have deleted the old files. I am at a complete loss. Maybe being 79 years old (retired Electrical Engineer) does not help… HA!! I seem to have multiple libraries, some under APPdata Local Arduino15, not sure what this all about. I will try again tomorrow. Hopefully you can show me some magic to get this board working. Thanks for your help… Art
Hey Art-
There are two issues in play:
- The board definition. Are you able to upload the blink example with the board definition in place? BTW, it is sometimes helpful to restart the Arduino IDE after making changes. Also, if you use the WiFi_LoRa_32_V3_FactoryTest program as a starter, that should restore the “as received” state of the V3 board.
- The library references related to the other examples. I did also delete some of the temp files in AppData. You can Google procedures - or I could provide a link.
Hi,
thanks for details.
Did you confirm that is not possible to use Heltec.h directly ? (so no Heltec object), and now we must used LoRaWan_APP.h ? (so V2 programs can’t be compatible with 0.0.7 lib version).
In this case, i’m looking for the documentation of this lib, but i didn’t find it in google…
The HELTEC.h library was initially tried and did not function with the V3 boards. I haven’t fully decomposed it, but it contains a number of “if statements”:
#if defined( WIFI_LoRa_32 ) || defined( WIFI_LoRa_32_V2 ) || defined( Wireless_Stick ) || defined( Wireless_Stick_Lite ) || defined( Wireless_Bridge )
…that don’t convey support for V3. It would be nice to have a version matrix that maps boards to compatible libraries
I was NOT able to upload the Blink example with V3 board definition in place. It fails as follows:
A fatal error occurred: This chip is ESP32-S3 not ESP32. Wrong --chip argument?
Failed uploading: uploading error: exit status 2.
I will try to run the WiFi_LoRa_32_V3_FactoryTest program.
I have restarted Arduino IDE to no avail… Thanks for the help
Art
Also note “WiFi LoRa 32(V3)” is shown as the selected board for the project (green tool bar).
…and the V3 board has to be pinned to the proper COM port:
The terminal window in the prior post is displaying the LoRa packet Tx / Rx activity.
Same conclusion for me,
So now need to find document to move v2 program to v3 … thanks Heltec :s
I CANNOT COMPILE any example (including Blink) using a V3 Board. I ALWAYS get the following:
In file included from c:\users\lawrence01073\appdata\local\arduino15\packages\heltec-esp32\tools\xtensa-esp32s3-elf-gcc\gcc8_4_0-esp-2021r2-patch3\xtensa-esp32s3-elf\include\c++\8.4.0\string:41,
from c:\users\lawrence01073\appdata\local\arduino15\packages\heltec-esp32\tools\xtensa-esp32s3-elf-gcc\gcc8_4_0-esp-2021r2-patch3\xtensa-esp32s3-elf\include\c++\8.4.0\stdexcept:39,
from c:\users\lawrence01073\appdata\local\arduino15\packages\heltec-esp32\tools\xtensa-esp32s3-elf-gcc\gcc8_4_0-esp-2021r2-patch3\xtensa-esp32s3-elf\include\c++\8.4.0\array:39,
from c:\users\lawrence01073\appdata\local\arduino15\packages\heltec-esp32\tools\xtensa-esp32s3-elf-gcc\gcc8_4_0-esp-2021r2-patch3\xtensa-esp32s3-elf\include\c++\8.4.0\tuple:39,
from c:\users\lawrence01073\appdata\local\arduino15\packages\heltec-esp32\tools\xtensa-esp32s3-elf-gcc\gcc8_4_0-esp-2021r2-patch3\xtensa-esp32s3-elf\include\c++\8.4.0\functional:54,
from C:\Users\lawrence01073\AppData\Local\Arduino15\packages\Heltec-esp32\hardware\esp32\0.0.7\cores\esp32/HardwareSerial.h:49,
from C:\Users\lawrence01073\AppData\Local\Arduino15\packages\Heltec-esp32\hardware\esp32\0.0.7\cores\esp32/Arduino.h:173,
from C:\Users\lawrence01073\AppData\Local\Temp\arduino-sketch-D0BFB281EB8F33FCCED70BB49FA75722\sketch\GetChipID.ino.cpp:1:
c:\users\lawrence01073\appdata\local\arduino15\packages\heltec-esp32\tools\xtensa-esp32s3-elf-gcc\gcc8_4_0-esp-2021r2-patch3\xtensa-esp32s3-elf\include\c++\8.4.0\bits\allocator.h:46:10: fatal error: bits/c++allocator.h: No such file or directory
#include <bits/c++allocator.h> // Define the base class to std::allocator.
^~~~~~~~~~~~~~~~~~~~~
compilation terminated.
exit status 1
Compilation error: exit status 1
Is this a Path Length problem?? If Yes, I NEED a fix (I have gone into Regedit and increased word size but this does NOT help). I have spent 3 days trying every combination that I can think of to get BLINK to compile but still the same error msg shown above. I think if I can get SOMETHING to compile, I probably could get this damn device working. One other thing, when I power up the device, it always fails to connect (is this the serial connection). I have installed the correct drivers from Silicon Labs. Once the device fails connection, it does WiFi Setup and does Wifi Scan. It then says "waiting lora data!’ Does this make sense?? I am so frustrated now I am ready to throw these devices out the window… PLEASE HELP!!!
Art
Looking at that file, there appears to be an error. The file in question does indeed include the line:
#include <bits/c++allocator.h> // Define the base class to std::allocator.
I certainly can’t see any file with that name, and the path structure looks wrong. It looks like it should be something like:
#include <bits/c++/allocator.h> // Define the base class to std::allocator.
with the extra “/” after the c++, but that then looks like a cyclic reference to me—the file would be including itself.
And, unfortunately, that doesn’t explain why we’re not all seeing the same problem. My installation is on a Mac, yours would appear to be on a PC but my directory structure looks exactly the same as yours.
I think it would be helpful at this point if someone from Heltec could comment on that path string and at least indicate what file it should be pointing to, if not explain why this allocator.h is only impacting some users.