Arduino Library for Dabble app, which includes virtual shields for robot control, sensors, camera, IoT and much more. Compatible with Bluetooth modules like HC-05, HC-06, HM-10, and ESP32 (BLE or Bluetooth 2.0 or 4.0)
Error Message:
C:\Users\harun\OneDrive\Belgeler\Arduino\libraries\DabbleESP32\src\LedControlModule.cpp: In member function 'virtual void LedControlModule::processData()':
C:\Users\harun\OneDrive\Belgeler\Arduino\libraries\DabbleESP32\src\LedControlModule.cpp:36:33: error: 'ledcAttachPin' was not declared in this scope; did you mean 'ledcAttach'?
36
ledcAttachPin(pin,currentChannel);
^~~~~
ledcAttach
C:\Users\harun\OneDrive\Belgeler\Arduino\libraries\DabbleESP32\src\LedControlModule.cpp:37:33: error: 'ledcSetup' was not declared in this scope
37
ledcSetup(currentChannel,100,8);
^~~~~
C:\Users\harun\OneDrive\Belgeler\Arduino\libraries\DabbleESP32\src\esp32BLEUtilities.cpp: In member function 'virtual void BleCallbacks::onWrite(BLECharacteristic*)':
C:\Users\harun\OneDrive\Belgeler\Arduino\libraries\DabbleESP32\src\esp32BLEUtilities.cpp:29:57: error: conversion from 'String' to non-scalar type 'std::string' {aka 'std::__cxx11::basic_string'} requested
29
~~~~~~~^~
C:\Users\harun\OneDrive\Belgeler\Arduino\libraries\DabbleESP32\src\esp32BLEUtilities.cpp: In member function 'void Esp32ble::begin(std::string)':
C:\Users\harun\OneDrive\Belgeler\Arduino\libraries\DabbleESP32\src\esp32BLEUtilities.cpp:55:19: error: cannot convert 'std::string' {aka 'std::__cxx11::basic_string'} to 'String'
55
BLEDevice::init(a);
^
std::string {aka std::__cxx11::basic_string}
In file included from C:\Users\harun\OneDrive\Belgeler\Arduino\libraries\DabbleESP32\src\esp32BLEUtilities.h:5,
from C:\Users\harun\OneDrive\Belgeler\Arduino\libraries\DabbleESP32\src\esp32BLEUtilities.cpp:2:
C:\Users\harun\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.3\libraries\BLE\src/BLEDevice.h:41:27: note: initializing argument 1 of 'static void BLEDevice::init(String)'
41 | static void init(String deviceName); // Initialize the local BLE environment.
| ~^~~~
C:\Users\harun\OneDrive\Belgeler\Arduino\libraries\DabbleESP32\src\esp32BLEUtilities.cpp: In member function 'void Esp32ble::write(std::string)':
C:\Users\harun\OneDrive\Belgeler\Arduino\libraries\DabbleESP32\src\esp32BLEUtilities.cpp:111:38: error: no matching function for call to 'BLECharacteristic::setValue(std::string&)'
111 | bleTxCharacteristic->setValue(x);
| ~~~~~~~^
In file included from C:\Users\harun\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.3\libraries\BLE\src/BLEServer.h:23,
from C:\Users\harun\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.3\libraries\BLE\src/BLEDevice.h:21:
C:\Users\harun\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.3\libraries\BLE\src/BLECharacteristic.h:77:8: note: candidate: 'void BLECharacteristic::setValue(uint8_t, size_t)'
77 | void setValue(uint8_t data, size_t size);
| ^~~~
C:\Users\harun\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.3\libraries\BLE\src/BLECharacteristic.h:77:8: note: candidate expects 2 arguments, 1 provided
C:\Users\harun\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.3\libraries\BLE\src/BLECharacteristic.h:78:8: note: candidate: 'void BLECharacteristic::setValue(String)'
78 | void setValue(String value);
| ^~~~
C:\Users\harun\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.3\libraries\BLE\src/BLECharacteristic.h:78:24: note: no known conversion for argument 1 from 'std::string' {aka 'std::cxx11::basic_string'} to 'String'
78 | void setValue(String value);
| ~^~~
C:\Users\harun\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.3\libraries\BLE\src/BLECharacteristic.h:79:8: note: candidate: 'void BLECharacteristic::setValue(uint16_t&)'
79 | void setValue(uint16_t &data16);
| ^~~~
C:\Users\harun\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.3\libraries\BLE\src/BLECharacteristic.h:79:27: note: no known conversion for argument 1 from 'std::string' {aka 'std::__cxx11::basic_string'} to 'uint16_t&' {aka 'short unsigned int&'}
79 | void setValue(uint16_t &data16);
| ~~^~
C:\Users\harun\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.3\libraries\BLE\src/BLECharacteristic.h:80:8: note: candidate: 'void BLECharacteristic::setValue(uint32_t&)'
80 | void setValue(uint32_t &data32);
| ^~~~
C:\Users\harun\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.3\libraries\BLE\src/BLECharacteristic.h:80:27: note: no known conversion for argument 1 from 'std::string' {aka 'std::cxx11::basic_string'} to 'uint32_t&' {aka 'long unsigned int&'}
80 | void setValue(uint32_t &data32);
| ~~^~
C:\Users\harun\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.3\libraries\BLE\src/BLECharacteristic.h:81:8: note: candidate: 'void BLECharacteristic::setValue(int&)'
81 | void setValue(int &data32);
| ^~~~
C:\Users\harun\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.3\libraries\BLE\src/BLECharacteristic.h:81:22: note: no known conversion for argument 1 from 'std::string' {aka 'std::cxx11::basic_string'} to 'int&'
81 | void setValue(int &data32);
| ~^~
C:\Users\harun\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.3\libraries\BLE\src/BLECharacteristic.h:82:8: note: candidate: 'void BLECharacteristic::setValue(float&)'
82 | void setValue(float &data32);
| ^~~~
C:\Users\harun\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.3\libraries\BLE\src/BLECharacteristic.h:82:24: note: no known conversion for argument 1 from 'std::string' {aka 'std::__cxx11::basic_string'} to 'float&'
82 | void setValue(float &data32);
| ~^~~~
C:\Users\harun\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.3\libraries\BLE\src/BLECharacteristic.h:83:8: note: candidate: 'void BLECharacteristic::setValue(double&)'
83 | void setValue(double &data64);
| ^~~~
C:\Users\harun\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.3\libraries\BLE\src/BLECharacteristic.h:83:25: note: no known conversion for argument 1 from 'std::string' {aka 'std::cxx11::basic_string'} to 'double&'
83 | void setValue(double &data64);
| ~~^~~~
I try to compile the example code. But it's not working. What is the problem?
Code:
define CUSTOM_SETTINGS
define INCLUDE_LEDCONTROL_MODULE
include
unsigned long lasttime=0; void setup() { Serial.begin(115200);
Dabble.begin("MyEsp32");
}
void loop() { Dabble.processInput();
Serial.print("Led:"); Serial.print(LedControl.getpinNumber()); Serial.print('\t'); Serial.print("State:");
Serial.print(LedControl.getpinState()); Serial.print('\t'); Serial.print("Brightness:"); Serial.println(LedControl.readBrightness()); }
~~~~~~~~ C:\Users\harun\OneDrive\Belgeler\Arduino\libraries\DabbleESP32\src\esp32BLEUtilities.cpp: In member function 'virtual void BleCallbacks::onWrite(BLECharacteristic*)': C:\Users\harun\OneDrive\Belgeler\Arduino\libraries\DabbleESP32\src\esp32BLEUtilities.cpp:29:57: error: conversion from 'String' to non-scalar type 'std::string' {aka 'std::__cxx11::basic_string~~~~~~~^~ C:\Users\harun\OneDrive\Belgeler\Arduino\libraries\DabbleESP32\src\esp32BLEUtilities.cpp: In member function 'void Esp32ble::begin(std::string)': C:\Users\harun\OneDrive\Belgeler\Arduino\libraries\DabbleESP32\src\esp32BLEUtilities.cpp:55:19: error: cannot convert 'std::string' {aka 'std::__cxx11::basic_stringIn file included from C:\Users\harun\OneDrive\Belgeler\Arduino\libraries\DabbleESP32\src\esp32BLEUtilities.h:5, from C:\Users\harun\OneDrive\Belgeler\Arduino\libraries\DabbleESP32\src\esp32BLEUtilities.cpp:2: C:\Users\harun\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.3\libraries\BLE\src/BLEDevice.h:41:27: note: initializing argument 1 of 'static void BLEDevice::init(String)' 41 | static void init(String deviceName); // Initialize the local BLE environment. |'} to 'String'
78 | void setValue(String value);
| '} to 'uint16_t&' {aka 'short unsigned int&'}
79 | void setValue(uint16_t &data16);
| cxx11::basic_string'} to 'uint32_t&' {aka 'long unsigned int&'}
80 | void setValue(uint32_t &data32);
| '} to 'int&'
81 | void setValue(int &data32);
| '} to 'float&'
82 | void setValue(float &data32);
| cxx11::basic_string'} to 'double&'
83 | void setValue(double &data64);
|
~^~~~ C:\Users\harun\OneDrive\Belgeler\Arduino\libraries\DabbleESP32\src\esp32BLEUtilities.cpp: In member function 'void Esp32ble::write(std::string)': C:\Users\harun\OneDrive\Belgeler\Arduino\libraries\DabbleESP32\src\esp32BLEUtilities.cpp:111:38: error: no matching function for call to 'BLECharacteristic::setValue(std::string&)' 111 | bleTxCharacteristic->setValue(x); |~~~~~~~^In file included from C:\Users\harun\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.3\libraries\BLE\src/BLEServer.h:23, from C:\Users\harun\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.3\libraries\BLE\src/BLEDevice.h:21: C:\Users\harun\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.3\libraries\BLE\src/BLECharacteristic.h:77:8: note: candidate: 'void BLECharacteristic::setValue(uint8_t, size_t)' 77 | void setValue(uint8_t data, size_t size); | ^~~~ C:\Users\harun\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.3\libraries\BLE\src/BLECharacteristic.h:77:8: note: candidate expects 2 arguments, 1 provided C:\Users\harun\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.3\libraries\BLE\src/BLECharacteristic.h:78:8: note: candidate: 'void BLECharacteristic::setValue(String)' 78 | void setValue(String value); | ^~~~ C:\Users\harun\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.3\libraries\BLE\src/BLECharacteristic.h:78:24: note: no known conversion for argument 1 from 'std::string' {aka 'std::cxx11::basic_string~^~~ C:\Users\harun\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.3\libraries\BLE\src/BLECharacteristic.h:79:8: note: candidate: 'void BLECharacteristic::setValue(uint16_t&)' 79 | void setValue(uint16_t &data16); | ^~~~ C:\Users\harun\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.3\libraries\BLE\src/BLECharacteristic.h:79:27: note: no known conversion for argument 1 from 'std::string' {aka 'std::__cxx11::basic_string~~^~C:\Users\harun\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.3\libraries\BLE\src/BLECharacteristic.h:80:8: note: candidate: 'void BLECharacteristic::setValue(uint32_t&)' 80 | void setValue(uint32_t &data32); | ^~~~ C:\Users\harun\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.3\libraries\BLE\src/BLECharacteristic.h:80:27: note: no known conversion for argument 1 from 'std::string' {aka 'std::~~^~C:\Users\harun\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.3\libraries\BLE\src/BLECharacteristic.h:81:8: note: candidate: 'void BLECharacteristic::setValue(int&)' 81 | void setValue(int &data32); | ^~~~ C:\Users\harun\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.3\libraries\BLE\src/BLECharacteristic.h:81:22: note: no known conversion for argument 1 from 'std::string' {aka 'std::cxx11::basic_string~^~C:\Users\harun\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.3\libraries\BLE\src/BLECharacteristic.h:82:8: note: candidate: 'void BLECharacteristic::setValue(float&)' 82 | void setValue(float &data32); | ^~~~ C:\Users\harun\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.3\libraries\BLE\src/BLECharacteristic.h:82:24: note: no known conversion for argument 1 from 'std::string' {aka 'std::__cxx11::basic_string~^~~~ C:\Users\harun\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.3\libraries\BLE\src/BLECharacteristic.h:83:8: note: candidate: 'void BLECharacteristic::setValue(double&)' 83 | void setValue(double &data64); | ^~~~ C:\Users\harun\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.3\libraries\BLE\src/BLECharacteristic.h:83:25: note: no known conversion for argument 1 from 'std::string' {aka 'std::~~^~~~exit status 1
Compilation error: exit status 1