Questions tagged [library]

A library is a file that can be included into the code to add new instructions by combining many existing instructions and creating one easy to use instruction to call.

Filter by
Sorted by
Tagged with
0
votes
0answers
15 views

Using SMS to send commands to the Arduino. Having problems in data parsing

I'm still inexperienced in programming and i apologize in advance if my mistakes are stupidly obvious. This sketch I'm working on is a basic GSM project using SIM900a Mini and an Arduino UNO that ...
0
votes
2answers
41 views

displaying a 3 digit clock time on a 4 digit 7 segment display

I purchased one of these 4 digit 7 segment displays using a TM1637. I installed the TM1637 display library from the libraries manager and included it: (#include <TM1637Display.h>). I am ...
0
votes
1answer
22 views

ESP8266 compilation error: “previous declaration of 'HTTPMethod HTTP_HEAD'”

I have an ESP8266 program that used to work but is now failing to compile with this error: C:\...\Arduino\libraries\WiFiManager/WiFiManager.h:25:24: note: in expansion of macro 'PROGMEM' const ...
0
votes
1answer
112 views

Unresolved reference to public function from library

I have three libraries that I've written and I'm trying to use. They're stored as follows Documents ├── Some/Path/To/Folder │ └── firmware.ino └── Arduino └── libraries ├── error ...
0
votes
1answer
468 views

Wiring ESP8266 and PN532

I'm trying the Android Hce example in this PN532 library. I can't find how to set SDA and SCL address in the code, so I tried connecting them in CLK and SD0 pins. The serial monitor gives me "Didn't ...
0
votes
1answer
35 views

Error compiling for Arduino Nano 33 BLE with LiquidCrystal library

I recently started coding in the Arduino IDE for the Arduino Nano 33 BLE I bought. When I choose the Nano 33 BLE as my board, I get the following Error: Arduino: 1.8.11 (Windows 10), Board: "Arduino ...
1
vote
2answers
2k views

Are there any good and maintained libraries for using DS2482 I2C to 1-Wire bridge?

The DS2482-100 and DS2482-800 are I2C to 1-Wire bridges which are useful for driving complex 1-Wire networks. These are natively supported by a number of packages in Linux so you can interface easily ...
0
votes
1answer
65 views

Trying to read different gas levels with MQ2 Gas Sensor

I found a link on how to connect MQ-2 Gas Sensor to Arduino Uno. http://electronicsprojectshub.com/how-to-connect-mq2-gas-sensor-to-arduino/ After I bought all the parts and tried it out, the sensor ...
0
votes
1answer
2k views

Using Capacitive Sensing Library with a 74HC4067 multiplexer

I'm trying to use the Capacitive Sensing Library by Paul Badger in conjunction with one or more 74HC4067 multiplexers to achieve a lot of capacitive touch inputs. I came across this youtube video ...
0
votes
1answer
149 views

Passing reference to hardware between methods in custom class

I'm a C++ / Arduino newbie, trying to build a custom library for the first time. I created a unit called CDSensors.cpp, which has two methods, SetupSensor and ReadSensors. The sensor is a SparkFun ...
0
votes
1answer
56 views

How to control segments with SevSeg library

The SevSeg library by Dean Reading seems to have a keyword to control individual segments on SSD's. I am using four common cathode, single digit displays. Does anyone know how to program individual ...
0
votes
1answer
35 views

IDE finds multiple libraries

I don't understand Arudino IDE. Ever. This is a part of the compilation output: Alternatives for ArduinoJson.h: [ArduinoJson@6.14.0] ResolveLibrary(ArduinoJson.h) -> candidates: [ArduinoJson@6....
0
votes
1answer
23 views

How to declare a pointer for arduino neopixels library so I can set it up in the setup function with dynamic variables?

I am using NeoPixel strips, and I want to be able to declare a pointer to them, but not initialize them until the setup function (because they will initialize with certain variables only made ...
1
vote
2answers
4k views

Accel Stepper help, stepper not going backwards

So my question is that I am trying to use a arduino library called Accel Stepper to control a stepper motor, I made code that makes the stepper motor move one rev clockwise and then one rev counter ...
5
votes
1answer
412 views

Recommended way to fork a library

I want to extend a library, available on github to add some features I need. Of course I will made available the new source code as well. Because it's the first time I do this, I'm not sure how to do. ...
0
votes
0answers
193 views

Using the Broadcom AFBR-S50 with Arduino

I'm trying to interface with a Broadcom AFBR-S50MV85G ToF sensor over SPI using an Arduino, which is complicated by the fact that the provided library and reference application is written for Cortex ...
0
votes
1answer
29 views

How should I customize UIPEthernet constants?

I am using UIPEthernet to get an Arduino Nano to drive an ENC28J60 Ethernet Shield for a UDP-based application. I'm customizing a number of its #define parameters to change default settings to save ...
0
votes
2answers
48 views

How do I segment Arduino program when line count is so large that code maintenance is difficult?

I'm looking for the Arduino/C++ equivalent of COBOL's 'copy' statement. I'm working on a program that is approaching 600 lines of code in the TopLevel.cpp source file. This is hard to manage ...
0
votes
1answer
45 views

Adafruit ImageReader Library 2.3.5 added several library dependencies

Why has Adafruit ImageReader Library v2.3.5 recently added six dependencies on other libraries for hardware I'm not using? I used the v2.3.2 of the Adafruit ImageReader Library successfully two ...
0
votes
2answers
36 views

TimerOne Hanging

For the following program. Compiles and runs. I start the Serial Monitor (shown following code) and it asks me to input the Blink Rate. This runs in setup. Then it enters the loop and prints to the ...
-1
votes
1answer
102 views

How to Use Function Code 6 Modbus RTU library

I'm trying to communicate with a temperature controller using Modbus RTU. I used this Arduino library. I was able to read PV(current temperature value) using below code. It uses Function code 4. I ...
0
votes
1answer
135 views

Trying to instantiate a DS3231 real time clock within a library

I'm trying to write a library encapsulating things that I do with a DS3231 real time clock. I have managed to compile a sketch using the library, but it apparently blows up when attempting to call ...
4
votes
4answers
1k views

Binary message formatter

I am currently developing an IoT device with arduino and i want to minimise the data payload. First i used json which is not very efficent in fixed messages (the format will always be the same). Then ...
1
vote
1answer
763 views

Library compilation error

Need help for this Tutorial. I tried to compile the code, but I'm getting compiling error. I tried to ask on that forum too but got no answer, the error is: In file included from C:\Program Files (...
0
votes
0answers
35 views

Mqtt setCallback with arduino mega in custom library

in pubsubclient library in method Set callback, calback is defined as MQTT_CALLBACK_SIGNATURE I found in code #if defined(ESP8266) || defined(ESP32) #include <functional> #define ...
0
votes
0answers
21 views

to define a object in your own arduino library which is already defined in inbuilt library

I am creating my own GPS library using NeoGPS library. So for fixing the GPS NeoGPS library defines gps_fix as: gps_fix fix; Now i want to define the same thing in my library. How to define the ...
1
vote
1answer
294 views

FFT library for Arduino 101?

I am currently trying to get a real-time FFT working for a project on an Arduino 101 which uses the Intel Curie chip. All the FFT libraries (if any) seem to be for the Arduino Uno and architecture ...
-1
votes
1answer
659 views

Error when HX711_Arduino_Library installed

First I'm getting this error #include no such directory. Then HX711_Arduino_Library installed. Now getting following errors: Arduino: 1.8.9 (Windows 7), Board: "NodeMCU 1.0 (ESP-12E Module), 80 MHz, ...
0
votes
1answer
1k views

Arduino force feedback vibration gamepad

I'm projecting a gamepad with Arduino Micro. I'm using the Arduino Joystick Library. I'm building this gamepad for racing games so I need to catch signal like hit_the_wall, hit_another_car. I wonder ...
1
vote
1answer
544 views

Looking for light-weight Arduino OLED library that supports text and bitmaps

I'm trying to incorporate a screen into my Arduino code which is quite large already. The Adafruit SSD1306 library is overly large and has a lot of unnecessary things in it. I've found the ...
0
votes
1answer
226 views

How to scale a bitmap (uint8_t array) in Arduino?

So I have a project where I send text to an Arduino, which is then printed out as a QR code on a thermal printer that can take a bitmap image with a given width and height. Is there a way I can "...
0
votes
2answers
38 views

Unable to declare variable in a library that doesn't have a class: multiple definition of the variable

I have created a library Lib that doesn't have a class. I want this library to have a variable that can be accessed from outside. The way I would go about this is to just declare them in the header ...
0
votes
0answers
78 views

MQ7.h: No such file or directory

Using ESP32 I'm making air pollution quality meter. For that I need MQ7.h library which is of version 1.0.4 MQUnified sensor library, which supports all sensors. I am using MQ7 carbon monoxide sensor....
0
votes
1answer
43 views

Error: function was not declared in this scope when using a library without classes

I have created a library of functions that doesn't have and mustn't have a class. In order to have functions inside the library that can only be called from the library itself, you just write them ...
0
votes
2answers
32 views

Including keypad library removes sound from my piezo element

I am using the keypad library to include keypad and input numbers. when a specific number is entered a sound must be made. However when I input using the serial monitor , sound is working. But when I ...
0
votes
1answer
76 views

How to use existing (non-arduino-specific) library with subfolders in Arduino IDE?

I have a generic c++ library that i'd like to use in an arduino project without making changes to the library code. The library contains subfolders and files in the library include other files of the ...
0
votes
0answers
40 views

Arduino Lib doesn't recognize String type

I use the following code snippet in a library I wrote: int MyClass::Send(MyMessage* message) { String rev = func(); // Do Work } And in a different library I wrote: String func(){ ...
0
votes
1answer
1k views

undefined reference to `PPMintIn::PPMintIn(int)'

I am making a new library that will utilize PinChangeInt's library. My intention is to further simplify repetitive code by creating a library. (This is to allow for multiple PPM channels without ...
0
votes
0answers
61 views

Having problems compiling this code for NRF24l01 on stm8s103f3p6

It said it has mutiple libraries were found for "nRF24L01.h" but i check the Ardurino libraries I can only found one. And it work fine if I compile it to Arduino uno. //Include Libraries #include <...
0
votes
1answer
21 views

Protecting variables and functions within a library that has no class

If you want to have functions within a library that only the library itself should be able to use or variables that shouldn't be accessed from outside, you usually make them private by writing this in ...
1
vote
3answers
7k views

Global variables use to much space in the dynamic memory

I use two simple libraries (see 1, 2) I found online for my code on the Arduino Uno, unfortunately I also use ROS and all those libraries take away to much space, when I compile my code I get this ...
0
votes
1answer
220 views

Installing Jan Breuers SCPI Parser

I am trying to install/include Jan Breuer's SCPI parser. I was not able to find any documentation to accomplish this. I copied the contents on of the GIT zip file to my Libraries directory, but when I ...
0
votes
1answer
61 views

Bypass a function error

I have a long code written in Arduino101 that works fine. I use a prepared function (connected to a library) in my code that I have not written it. My input to this function is an array. In 99.9999..% ...
0
votes
2answers
314 views

ESP12E Soft WDT reset stack trace leads to libraries

Im using ESP12E DevKit v2 (esp8266 wifi module) board for controlling relays and displaying DHT22 temp,humidity on web server. It runs smoothly when the web client is closed but when i leave the ...
0
votes
1answer
406 views

DFPlayer for Writing to SD Card

Can you use the DFPlayer to write to the SD card? Link for DFPlayer: https://www.dfrobot.com/wiki/index.php/DFPlayer_Mini_SKU:DFR0299 Here's the goal of my project. I have a button that, when pressed,...
0
votes
1answer
24 views

Initalizing library object in own library

EDIT: @Juraj fixed the Issue, changes at the end of the post I am developing an application to program OneWire ID Chips. I am using the OneWire library (https://github.com/PaulStoffregen/OneWire) and ...
0
votes
1answer
76 views

millis() function works with inline code and gives output but when creating own library it doesn't works

I am creating library for GPS to use in my project. I am using Adafruit GPS and its library to create my own library in which I am using millis() function to display the GPS Location after 1 minute (...
4
votes
2answers
131 views

How to document a custom library in Arduino

I have created my own library and it is working flawlessly. Now I want to add some documentation to it that the Arduino IDE can understand. For the functions from the Arduino IDE itself like delay(ms)...
0
votes
1answer
38 views

Creating an array with the length coming from a library

When creating an array like in the sketch #include <Lib.h> int myArray[Lib::len]; void setup() {} void loop() {} the variable len must be an integer constant that is known at compile time. ...
0
votes
1answer
226 views

Error: invalid application of 'sizeof' to incomplete type 'int []' when trying to compute the size of an array in a library

I have created a library that contains an array. This is the .h file: class Lib { public: static int arr[]; }; And this is the .cpp file: #include "Lib.h" int Lib::arr[] = {0, 1, 2, 3}; ...

1 2 3 4 5 9