Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include "H4AsyncTCP.h"
- #include <ArmadilloHTTP.h>
- #include "WiFi.h"
- ArmadilloHTTP aClient;
- void responseHandler(ARMA_HTTP_REPLY r){ // r is a struct will all the reply fields you might need
- Serial.printf("\nRaw Data\n");
- dumphex(r.data,r.length);
- }
- void setup() {
- Serial.begin(115200);
- WiFi.begin("bw-compat", "growhouse");
- WiFi.waitForConnectResult();
- Serial.printf("Connected %s\n",WiFi.localIP().toString());
- aClient.GET("http://jsonip.com",responseHandler); // <--- Yup, that's pretty much it!
- }
- void loop() {}
- //im getting error at compile
- Linking .pio\build\esp32dev\chip-2.1.3-esp32.elf
- c:/users/dr3ad/.platformio/packages/toolchain-xtensa-esp32/bin/../lib/gcc/xtensa-esp32-elf/8.4.0/../../../../xtensa-esp32-elf/bin/ld.exe: .pio\build\esp32dev\lib07e\libH4.a(H4.cpp.o): in function `setup()':
- C:\Users\dr3ad\Documents\hamza/.pio/libdeps/esp32dev/H4/src/H4.cpp:358: multiple definition of `setup()'; .pio\build\esp32dev\src\test.ino.cpp.o:C:/Users/dr3ad/Documents/hamza/src/test.ino:11: first defined here
- c:/users/dr3ad/.platformio/packages/toolchain-xtensa-esp32/bin/../lib/gcc/xtensa-esp32-elf/8.4.0/../../../../xtensa-esp32-elf/bin/ld.exe: .pio\build\esp32dev\lib07e\libH4.a(H4.cpp.o): in function `loop()':
- C:\Users\dr3ad\Documents\hamza/.pio/libdeps/esp32dev/H4/src/H4.cpp:364: multiple definition of `loop()'; .pio\build\esp32dev\src\test.ino.cpp.o:C:/Users/dr3ad/Documents/hamza/src/test.ino:20: first defined here
- c:/users/dr3ad/.platformio/packages/toolchain-xtensa-esp32/bin/../lib/gcc/xtensa-esp32-elf/8.4.0/../../../../xtensa-esp32-elf/bin/ld.exe: .pio\build\esp32dev\libf24\libH4AsyncTCP.a(H4AsyncTCP.cpp.o):(.literal._Z10_raw_errorPva+0xc): undefined reference to `h4'
- c:/users/dr3ad/.platformio/packages/toolchain-xtensa-esp32/bin/../lib/gcc/xtensa-esp32-elf/8.4.0/../../../../xtensa-esp32-elf/bin/ld.exe: .pio\build\esp32dev\libc7f\libH4Tools.a(mbx.cpp.o):(.literal._ZN3mbx5clearEPh+0x0): undefined reference to `mbx::pool'
- c:/users/dr3ad/.platformio/packages/toolchain-xtensa-esp32/bin/../lib/gcc/xtensa-esp32-elf/8.4.0/../../../../xtensa-esp32-elf/bin/ld.exe: .pio\build\esp32dev\libc7f\libH4Tools.a(mbx.cpp.o):(.literal._ZN3mbx5clearEPh+0x4): undefined reference to `mbx::pool'
- collect2.exe: error: ld returned 1 exit status
- *** [.pio\build\esp32dev\chip-2.1.3-esp32.elf] Error 1
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement