Easy IoT General

FireBeetle ESP32 and Arduino 1.8.4

userHead kington 2017-08-26 16:59:11 16113 Views19 Replies
I cannot get simple sketch "blink" to verify / compile
This is the errors I get.......
Arduino: 1.8.4 (Windows XP), Board: "FireBeetle-ESP32, 80MHz, 115200"

In file included from c:\documents and settings\yyy\local settings\application data\arduino15\packages\esp32\tools\xtensa-esp32-elf-gcc\1.22.0-61-gab8375a-5.2.0\xtensa-esp32-elf\include\c++\5.2.0\memory:63:0,

from C:\Documents and Settings\yyy\Local Settings\Application Data\Arduino15\packages\esp32\hardware\DFRobot_FireBeetle-ESP32\0.0.3\cores\esp32\Esp.cpp:25:

c:\documents and settings\yyy\local settings\application data\arduino15\packages\esp32\tools\xtensa-esp32-elf-gcc\1.22.0-61-gab8375a-5.2.0\xtensa-esp32-elf\include\c++\5.2.0\bits\allocator.h:46:75: fatal error: bits/c++allocator.h: No such file or directory

compilation terminated.

exit status 1
Error compiling for board FireBeetle-ESP32.

I have followed the procedures in the tutorials and manual and can compile sketches for other boards OK ( not esp32 types)
I have tried various sketches. the output above is for the "blink" . I can see the boards in board manager and can see it in the com port device manager. I am using windows XP.
2017-09-01 07:24:15 From the manual pdf.......
---------------------------------------------------------
"Once the upload finishes, open the built-in serial monitor of Arduino IDE, touch D9 with your hand
(T2 corresponds to D9) print 1 show below
Code analysis:
Obtaining GPIO state of the capacitance sensors only requiring calling touchRead. The antitype
of touchRead is as below:
uint16_t touchRead(uint8_t pin)
0 means no touch, 1 means touch. From T0 to T9 are pins, the corresponding pins of Firebeetle
shown in the list as below."
--------------------------------------------------------------
This T2 is the only one that does this..... Is it in some other mode of oreration...?????
The rest of the touch pins change from say 350 to 25 when touched....?????

I dont get any response when T1 is touched.... it reads 1 always.....???? It it already connected to other components on board...???

From the manual pdf.......
---------------------------------------------------------
Caution: Please do not use T8/T9 for touch input. They have already been connect to outer crystals
of 32.768 KHz.
-------------------------------------------------
So does this mean T8/T9 can not be used for touch at anytime...?????

If I dont need the realtime clock to keep real time can the crystal be removed or put on other pins..???

Is there a schematic diagram available for the board....????
userHeadPic kington
2017-09-01 07:24:15 From the manual pdf.......
---------------------------------------------------------
"Once the upload finishes, open the built-in serial monitor of Arduino IDE, touch D9 with your hand
(T2 corresponds to D9) print 1 show below
Code analysis:
Obtaining GPIO state of the capacitance sensors only requiring calling touchRead. The antitype
of touchRead is as below:
uint16_t touchRead(uint8_t pin)
0 means no touch, 1 means touch. From T0 to T9 are pins, the corresponding pins of Firebeetle
shown in the list as below."
--------------------------------------------------------------
This T2 is the only one that does this..... Is it in some other mode of oreration...?????
The rest of the touch pins change from say 350 to 25 when touched....?????

I dont get any response when T1 is touched.... it reads 1 always.....???? It it already connected to other components on board...???

From the manual pdf.......
---------------------------------------------------------
Caution: Please do not use T8/T9 for touch input. They have already been connect to outer crystals
of 32.768 KHz.
-------------------------------------------------
So does this mean T8/T9 can not be used for touch at anytime...?????

If I dont need the realtime clock to keep real time can the crystal be removed or put on other pins..???

Is there a schematic diagram available for the board....????
userHeadPic kington
2017-09-01 05:29:56 I have tried the touch example sketch modified to test each touch pin. It all compiled and downloaded and run.
But T1 and T2 are reading very low values and dont respond when touched...???? also I cannot find pins for T8 and T9. According to the pins_arduino.h file in the board library it shoe T8=33 and T9=32.. I dont see IO32 or IO33 on the pinout diagram...??? Do the need to be enabled somewhere..??

Attached is screenshot of the sketch I am using and the terminal output corresponding
userHeadPic kington
2017-09-01 05:29:56 I have tried the touch example sketch modified to test each touch pin. It all compiled and downloaded and run.
But T1 and T2 are reading very low values and dont respond when touched...???? also I cannot find pins for T8 and T9. According to the pins_arduino.h file in the board library it shoe T8=33 and T9=32.. I dont see IO32 or IO33 on the pinout diagram...??? Do the need to be enabled somewhere..??

Attached is screenshot of the sketch I am using and the terminal output corresponding
userHeadPic kington
2017-08-31 17:22:29 This is a tree view of the FireBeetle ESP32 files installed by copying the link on setup tutorial to the addition board manager link field in Arduino preferences. All are installed in Document and settings/ .... etc../etc.../ .....Arduino15 folder

The files that the compiler had probblems finding are shown with Red pointers.

Just wondering are any other files/folders missing or in wrong place....????
userHeadPic kington
2017-08-31 17:22:29 This is a tree view of the FireBeetle ESP32 files installed by copying the link on setup tutorial to the addition board manager link field in Arduino preferences. All are installed in Document and settings/ .... etc../etc.../ .....Arduino15 folder

The files that the compiler had probblems finding are shown with Red pointers.

Just wondering are any other files/folders missing or in wrong place....????
userHeadPic kington
2017-08-30 17:23:04 The blink sketch does actually work now after copy in the missing files as last post. The blue LED is now flashing as per the sketch LED_BUILTIN is gpio2 or pin 2 in Arduino. The red LED only flashes momentarily when USB power is plugged in. Should it stay on when battery is plugged in and USB power is plugged in...???? userHeadPic kington
2017-08-30 17:23:04 The blink sketch does actually work now after copy in the missing files as last post. The blue LED is now flashing as per the sketch LED_BUILTIN is gpio2 or pin 2 in Arduino. The red LED only flashes momentarily when USB power is plugged in. Should it stay on when battery is plugged in and USB power is plugged in...???? userHeadPic kington
2017-08-29 06:37:51 I found a c++allocator.h file on internet and copied it in to the folder where it was missing.
=====================================================================

// Base to std::allocator -*- C++ -*-

// Copyright (C) 2004-2014 Free Software Foundation, Inc.
//
// This file is part of the GNU ISO C++ Library. This library is free
// software; you can redistribute it and/or modify it under the
// terms of the GNU General Public License as published by the
// Free Software Foundation; either version 3, or (at your option)
// any later version.

// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or dfrobot FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.

// Under Section 7 of GPL version 3, you are granted additional
// permissions described in the GCC Runtime Library Exception, version
// 3.1, as published by the Free Software Foundation.

// You should have received a copy of the GNU General Public License and
// a copy of the GCC Runtime Library Exception along with this program;
// see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
// <http://www.gnu.org/licenses/>.

/** @file bits/c++allocator.h
* This is an internal header file, included by other library headers.
* Do not attempt to use it directly. @headername{memory}
*/

#ifndef _GLIBCXX_CXX_ALLOCATOR_H
#define _GLIBCXX_CXX_ALLOCATOR_H 1

#include <ext/new_allocator.h>

#if __cplusplus >= 201103L
namespace std
{
/**
* @brief An alias to the base class for std::allocator.
* @ingroup allocators
*
* Used to set the std::allocator base class to
* __gnu_cxx::new_allocator.
*
* @tparam _Tp Type of allocated object.
*/
template<typename _Tp>
using __allocator_base = __gnu_cxx::new_allocator<_Tp>;
}
#else
// Define new_allocator as the base class to std::allocator.
# define __allocator_base __gnu_cxx::new_allocator
#endif

#endif
======================================================================
also then it asked for gthr-default which was missing copied this over as well
There are 2 folders called bits is separate subfolders....?????

Now it compiles and seems to download as shown below.........
This below is from arduino IDE during compiling blink sketch and downloading also what was sent to the monitor terminal.

Build options changed, rebuilding all
Archiving built core (caching) in: C:\DOCUME~1\yyy\LOCALS~1\Temp\arduino_cache_830\core\core_esp32_DFRobot_FireBeetle-ESP32_firebeetle32_FlashFreq_80,UploadSpeed_115200_50f9c3e3b4c682c6bee32022f0470778.a
Sketch uses 105648 bytes (5%) of program storage space. Maximum is 2097152 bytes.
Global variables use 9220 bytes (3%) of dynamic memory, leaving 285692 bytes for local variables. Maximum is 294912 bytes.
esptool.py v2.0-dev
Connecting...
Uploading stub...
Running stub...
Stub running...
Attaching SPI flash...
Configuring flash size...
Compressed 8752 bytes to 5468...

Writing at 0x00001000... (100 %)
Wrote 8752 bytes (5468 compressed) at 0x00001000 in 0.5 seconds (effective 136.0 kbit/s)...
Hash of data verified.
Compressed 3072 bytes to 105...

Writing at 0x00008000... (100 %)
Wrote 3072 bytes (105 compressed) at 0x00008000 in 0.1 seconds (effective 261.4 kbit/s)...
Hash of data verified.
Compressed 8192 bytes to 47...

Writing at 0x0000e000... (100 %)
Wrote 8192 bytes (47 compressed) at 0x0000e000 in 0.1 seconds (effective 704.7 kbit/s)...
Hash of data verified.
Compressed 188368 bytes to 58320...

Writing at 0x00010000... (25 %)
Writing at 0x00014000... (50 %)
Writing at 0x00018000... (75 %)
Writing at 0x0001c000... (100 %)
Wrote 188368 bytes (58320 compressed) at 0x00010000 in 5.3 seconds (effective 282.0 kbit/s)...
Hash of data verified.

Leaving...
Hard resetting...


this below from Monitor com4 screen............after compile

ets Jun 8 2016 00:22:57

rst:0x10 (RTCWDT_RTC_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT)
configsip: 0, SPIWP:0x00
clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
mode:DIO, clock div:1
load:0x3fff0008,len:8
load:0x3fff0010,len:1760
load:0x40078000,len:6668
load:0x40080000,len:252
entry 0x40080034

Before download the blue LED on the board was flashing at approx 1 second flash
On the FireBeetle board now the blue LED has stopped flashing and board appears to be doing nothing.
So dont know if it actually downloaded. The red LED flashes momentarily as power is plugged in.

I am still stuck, Thanks.
userHeadPic kington
2017-08-29 06:37:51 I found a c++allocator.h file on internet and copied it in to the folder where it was missing.
=====================================================================

// Base to std::allocator -*- C++ -*-

// Copyright (C) 2004-2014 Free Software Foundation, Inc.
//
// This file is part of the GNU ISO C++ Library. This library is free
// software; you can redistribute it and/or modify it under the
// terms of the GNU General Public License as published by the
// Free Software Foundation; either version 3, or (at your option)
// any later version.

// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or dfrobot FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.

// Under Section 7 of GPL version 3, you are granted additional
// permissions described in the GCC Runtime Library Exception, version
// 3.1, as published by the Free Software Foundation.

// You should have received a copy of the GNU General Public License and
// a copy of the GCC Runtime Library Exception along with this program;
// see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
// <http://www.gnu.org/licenses/>.

/** @file bits/c++allocator.h
* This is an internal header file, included by other library headers.
* Do not attempt to use it directly. @headername{memory}
*/

#ifndef _GLIBCXX_CXX_ALLOCATOR_H
#define _GLIBCXX_CXX_ALLOCATOR_H 1

#include <ext/new_allocator.h>

#if __cplusplus >= 201103L
namespace std
{
/**
* @brief An alias to the base class for std::allocator.
* @ingroup allocators
*
* Used to set the std::allocator base class to
* __gnu_cxx::new_allocator.
*
* @tparam _Tp Type of allocated object.
*/
template<typename _Tp>
using __allocator_base = __gnu_cxx::new_allocator<_Tp>;
}
#else
// Define new_allocator as the base class to std::allocator.
# define __allocator_base __gnu_cxx::new_allocator
#endif

#endif
======================================================================
also then it asked for gthr-default which was missing copied this over as well
There are 2 folders called bits is separate subfolders....?????

Now it compiles and seems to download as shown below.........
This below is from arduino IDE during compiling blink sketch and downloading also what was sent to the monitor terminal.

Build options changed, rebuilding all
Archiving built core (caching) in: C:\DOCUME~1\yyy\LOCALS~1\Temp\arduino_cache_830\core\core_esp32_DFRobot_FireBeetle-ESP32_firebeetle32_FlashFreq_80,UploadSpeed_115200_50f9c3e3b4c682c6bee32022f0470778.a
Sketch uses 105648 bytes (5%) of program storage space. Maximum is 2097152 bytes.
Global variables use 9220 bytes (3%) of dynamic memory, leaving 285692 bytes for local variables. Maximum is 294912 bytes.
esptool.py v2.0-dev
Connecting...
Uploading stub...
Running stub...
Stub running...
Attaching SPI flash...
Configuring flash size...
Compressed 8752 bytes to 5468...

Writing at 0x00001000... (100 %)
Wrote 8752 bytes (5468 compressed) at 0x00001000 in 0.5 seconds (effective 136.0 kbit/s)...
Hash of data verified.
Compressed 3072 bytes to 105...

Writing at 0x00008000... (100 %)
Wrote 3072 bytes (105 compressed) at 0x00008000 in 0.1 seconds (effective 261.4 kbit/s)...
Hash of data verified.
Compressed 8192 bytes to 47...

Writing at 0x0000e000... (100 %)
Wrote 8192 bytes (47 compressed) at 0x0000e000 in 0.1 seconds (effective 704.7 kbit/s)...
Hash of data verified.
Compressed 188368 bytes to 58320...

Writing at 0x00010000... (25 %)
Writing at 0x00014000... (50 %)
Writing at 0x00018000... (75 %)
Writing at 0x0001c000... (100 %)
Wrote 188368 bytes (58320 compressed) at 0x00010000 in 5.3 seconds (effective 282.0 kbit/s)...
Hash of data verified.

Leaving...
Hard resetting...


this below from Monitor com4 screen............after compile

ets Jun 8 2016 00:22:57

rst:0x10 (RTCWDT_RTC_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT)
configsip: 0, SPIWP:0x00
clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
mode:DIO, clock div:1
load:0x3fff0008,len:8
load:0x3fff0010,len:1760
load:0x40078000,len:6668
load:0x40080000,len:252
entry 0x40080034

Before download the blue LED on the board was flashing at approx 1 second flash
On the FireBeetle board now the blue LED has stopped flashing and board appears to be doing nothing.
So dont know if it actually downloaded. The red LED flashes momentarily as power is plugged in.

I am still stuck, Thanks.
userHeadPic kington
2017-08-29 04:57:42 The last bit of the last post is actually a snipit of the code in allocator.h file at line 46 ......showing the call to c++allocator.h

allocator.h is in the folder OK but c++allocator.h is not in the folder
userHeadPic kington
2017-08-29 04:57:42 The last bit of the last post is actually a snipit of the code in allocator.h file at line 46 ......showing the call to c++allocator.h

allocator.h is in the folder OK but c++allocator.h is not in the folder
userHeadPic kington
2017-08-29 04:52:58 Thanks for your reply..........
I have been using the guidance on this web page. I have unistalled everything and reinstalled using this guidance again.

https://www.dfrobot.com/wiki/index.php/ ... U:_DFR0478

All installed without error. I used the Arduino 1.8.4 zipped download which gives a standalone install and entered the link in preferences for the board manager to install the firebeetle board.....all seemed to work without error.
The board install puts everything in ........ c:\documents and settings\yyy\local settings\application data\arduino15\packages etc etc ..... by default....I did not get option where to install.....but all seems to be there except this file it is looking fo...???

I attempted to verify/compile the sketch for blink and it gives me same errors and tells me C++allocator.h no such file ??
When I manually look in that folder it is not there.....so question what is it supposed to be looking for.
Is the call by wrong name ??????

=========================================================

Arduino: 1.8.4 (Windows XP), Board: "FireBeetle-ESP32, 80MHz, 115200"

In file included from c:\documents and settings\yyy\local settings\application data\arduino15\packages\esp32\tools\xtensa-esp32-elf-gcc\1.22.0-61-gab8375a-5.2.0\xtensa-esp32-elf\include\c++\5.2.0\memory:63:0,

from C:\Documents and Settings\yyy\Local Settings\Application Data\Arduino15\packages\esp32\hardware\DFRobot_FireBeetle-ESP32\0.0.6\cores\esp32\Esp.cpp:25:

c:\documents and settings\yyy\local settings\application data\arduino15\packages\esp32\tools\xtensa-esp32-elf-gcc\1.22.0-61-gab8375a-5.2.0\xtensa-esp32-elf\include\c++\5.2.0\bits\allocator.h:46:75: fatal error: bits/c++allocator.h: No such file or directory

compilation terminated.

exit status 1
Error compiling for board FireBeetle-ESP32.

This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.

====================================================

/*
* Copyright (c) 1996-1997
* Silicon Graphics Computer Systems, Inc.
*
* Permission to use, copy, modify, distribute and sell this software
* and its documentation for any purpose is hereby granted without fee,
* provided that the above copyright notice appear in all copies and
* that both that copyright notice and this permission notice appear
* in supporting documentation. Silicon Graphics makes no
* representations about the suitability of this software for any
* purpose. It is provided "as is" without express or implied warranty.
*/

/** @file bits/allocator.h
* This is an internal header file, included by other library headers.
* Do not attempt to use it directly. @headername{memory}
*/

#ifndef _ALLOCATOR_H
#define _ALLOCATOR_H 1

#include <bits/c++allocator.h> // Define the base class to std::allocator...???? this is line 46 ???? xxxxxxxxxxxxxxxx
#include <bits/memoryfwd.h>
#if __cplusplus >= 201103L
#include <type_traits>
#endif

=============================================================
userHeadPic kington
2017-08-29 04:52:58 Thanks for your reply..........
I have been using the guidance on this web page. I have unistalled everything and reinstalled using this guidance again.

https://www.dfrobot.com/wiki/index.php/ ... U:_DFR0478

All installed without error. I used the Arduino 1.8.4 zipped download which gives a standalone install and entered the link in preferences for the board manager to install the firebeetle board.....all seemed to work without error.
The board install puts everything in ........ c:\documents and settings\yyy\local settings\application data\arduino15\packages etc etc ..... by default....I did not get option where to install.....but all seems to be there except this file it is looking fo...???

I attempted to verify/compile the sketch for blink and it gives me same errors and tells me C++allocator.h no such file ??
When I manually look in that folder it is not there.....so question what is it supposed to be looking for.
Is the call by wrong name ??????

=========================================================

Arduino: 1.8.4 (Windows XP), Board: "FireBeetle-ESP32, 80MHz, 115200"

In file included from c:\documents and settings\yyy\local settings\application data\arduino15\packages\esp32\tools\xtensa-esp32-elf-gcc\1.22.0-61-gab8375a-5.2.0\xtensa-esp32-elf\include\c++\5.2.0\memory:63:0,

from C:\Documents and Settings\yyy\Local Settings\Application Data\Arduino15\packages\esp32\hardware\DFRobot_FireBeetle-ESP32\0.0.6\cores\esp32\Esp.cpp:25:

c:\documents and settings\yyy\local settings\application data\arduino15\packages\esp32\tools\xtensa-esp32-elf-gcc\1.22.0-61-gab8375a-5.2.0\xtensa-esp32-elf\include\c++\5.2.0\bits\allocator.h:46:75: fatal error: bits/c++allocator.h: No such file or directory

compilation terminated.

exit status 1
Error compiling for board FireBeetle-ESP32.

This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.

====================================================

/*
* Copyright (c) 1996-1997
* Silicon Graphics Computer Systems, Inc.
*
* Permission to use, copy, modify, distribute and sell this software
* and its documentation for any purpose is hereby granted without fee,
* provided that the above copyright notice appear in all copies and
* that both that copyright notice and this permission notice appear
* in supporting documentation. Silicon Graphics makes no
* representations about the suitability of this software for any
* purpose. It is provided "as is" without express or implied warranty.
*/

/** @file bits/allocator.h
* This is an internal header file, included by other library headers.
* Do not attempt to use it directly. @headername{memory}
*/

#ifndef _ALLOCATOR_H
#define _ALLOCATOR_H 1

#include <bits/c++allocator.h> // Define the base class to std::allocator...???? this is line 46 ???? xxxxxxxxxxxxxxxx
#include <bits/memoryfwd.h>
#if __cplusplus >= 201103L
#include <type_traits>
#endif

=============================================================
userHeadPic kington
2017-08-28 23:14:59 Many thanks for sharing this very diverse opinion post where each expert has no doubt shared his best knowledge on the topic. Have more success in your journey.
http://firefoxsupport.com/add-user-in-firefox/
userHeadPic muneshjaveri6361
2017-08-28 23:14:59 Many thanks for sharing this very diverse opinion post where each expert has no doubt shared his best knowledge on the topic. Have more success in your journey.
http://firefoxsupport.com/add-user-in-firefox/
userHeadPic muneshjaveri6361
2017-08-28 04:44:15 It seems that you did not include the proper library. Here is some information about how to add a library. https://www.arduino.cc/en/Guide/Libraries userHeadPic R2D2C3PO
2017-08-28 04:44:15 It seems that you did not include the proper library. Here is some information about how to add a library. https://www.arduino.cc/en/Guide/Libraries userHeadPic R2D2C3PO
2017-08-26 16:59:11 I cannot get simple sketch "blink" to verify / compile
This is the errors I get.......
Arduino: 1.8.4 (Windows XP), Board: "FireBeetle-ESP32, 80MHz, 115200"

In file included from c:\documents and settings\yyy\local settings\application data\arduino15\packages\esp32\tools\xtensa-esp32-elf-gcc\1.22.0-61-gab8375a-5.2.0\xtensa-esp32-elf\include\c++\5.2.0\memory:63:0,

from C:\Documents and Settings\yyy\Local Settings\Application Data\Arduino15\packages\esp32\hardware\DFRobot_FireBeetle-ESP32\0.0.3\cores\esp32\Esp.cpp:25:

c:\documents and settings\yyy\local settings\application data\arduino15\packages\esp32\tools\xtensa-esp32-elf-gcc\1.22.0-61-gab8375a-5.2.0\xtensa-esp32-elf\include\c++\5.2.0\bits\allocator.h:46:75: fatal error: bits/c++allocator.h: No such file or directory

compilation terminated.

exit status 1
Error compiling for board FireBeetle-ESP32.

I have followed the procedures in the tutorials and manual and can compile sketches for other boards OK ( not esp32 types)
I have tried various sketches. the output above is for the "blink" . I can see the boards in board manager and can see it in the com port device manager. I am using windows XP.
userHeadPic kington