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.
527
questions
0
votes
0
answers
61
views
How to efficiently manage external libraries?
I know that it is possible to download a library on github manually, or automatically with a similar script to this one using arduino-cli:
ARDUINO_LIBRARIES=("Keypad")
GITHUB_LIBRARIES=(&...
0
votes
1
answer
41
views
Problem installing RPLidar library
I'm trying to add the RPLidar library. I've already checked this solution, but it's not working for me, I get this error :
Error: 13 INTERNAL: Library install failed: extracting archive: Not a ...
1
vote
1
answer
48
views
Why 0 devices, but not 1?
I have found a sketch in Wokwi where a MAX7219 LED matrix is used. The sketch subject is to display 0 using <LedControl.h>. I don't understand why it's nessesary to send 0 unlike 1 in fourth ...
2
votes
1
answer
90
views
How to change the direction of a stepper motor using the AccelStepper library?
I'm using a Nema 17 stepper motor (200 steps) and a DRV8825 motor driver. This is the configuration I am using:
I am using a 9 V power supply. The dirPin is connected to pin 3 on the Arduino board, ...
3
votes
2
answers
2k
views
is #ifdef __SD_H__ considered a bad practice?
Say I'm working on a library^1 to which I want to add support for SD.h^2 but knowing for a fact that many microcotrollers don't support SD.h (therefore they result in compilation errors [eg. Attiny85])...
1
vote
0
answers
48
views
MKR GPS shield inconsistent GPS connection/data printing...library issue?
I have been using a MKR WiFi 1010 board with GPS shield for a very long time (year+) and have not been able to solve my problems with the GPS data dropping out.
The setup for my field application is a ...
2
votes
1
answer
897
views
Impossible to install the esp_camera library
I cannot install the esp_camera library. When I try to add the .zip, I get "does not contain a valid library.
Everything about this ESP-32 Cam seems to rely on that library, and I can't find a ...
1
vote
1
answer
109
views
Get 3-inch e-Paper working on a Nano
Please help!
I purchased a 3-inch e-Paper Display from Waveshare, which appeared to suit my project well. The exemplary little code to show an image was easy to set up and to demonstrate functionality:...
1
vote
0
answers
444
views
Keyestudio KS5009 ESP32WROOM32 Smart Home
I'm encountering persistent errors with the sample code provided for my smart home kit project. Despite conducting extensive research and troubleshooting efforts, I haven't been able to find a ...
2
votes
1
answer
305
views
Uploading a Library to the library manager from a Github branch
I am trying to upload a library to the Arduino Library Manager. I know the GitHub - arduino/library-registry: Arduino Library Manager list repository, and I have already read the instructions, but I ...
-2
votes
3
answers
128
views
Using Soft UART - how include library
I want to use the soft serial communication example.
But when I compile it, it sais:
/home/xxx/Arduino/SoftwareSerialExample/aa/aa.ino:28:28: schwerwiegender Fehler: SoftwareSerial.h: Datei oder ...
2
votes
0
answers
148
views
Ability to connect 2 or more w5500 Modules and deal with them as objects
I wish to create a rudimentary ethernet in/out - switch/hub where I can (sort of) daisy chain my boards. (I don't wish to use a ethernet switch/router/hub)
One port would be acting as server
The ...
0
votes
0
answers
30
views
What library does the Beetle BLE utilize for BLE commands?
I am trying to pair two gloves containing beetle BLE's on each, one set to a peripheral role and one to central to control leds for kids' party jewelry.
The Arduino.BLE library does not work with this ...
4
votes
2
answers
474
views
Trying to resolve invalid conversion from 'byte' {aka 'unsigned char'} to
I'm trying to use an existing Arduino library on the Raspberry Pi Pico. The library is here:
https://github.com/j-bellavance/EdgeDebounce/tree/master
It's based on some interesting insight at Jack ...
0
votes
2
answers
47
views
Why does analogRead(A0) deliver different Values when called in a library file vs calling it in the sketch directly
I wanted to write a library representing a sensor to later on have an array of sensors.
I generated a file MoistureSensor.h:
#ifndef MoistureSensor_h
#define MoistureSensor_h
#include <Arduino.h&...
4
votes
1
answer
110
views
How do you take the simplest continuous reading from a Garmin Lidar Lite V4 using I2C on a Particle Boron v4.1.0?
Hey there Stack community.
I'm working with the Particle Boron v4.1.0.
I'm connecting a Garmin Lidar Lite V4 on I2C.
I'm using the LIDARLite_v4LED.h header file found in the library given for this ...
2
votes
2
answers
206
views
With reference to Arduino Keyboard library, it does not have a keymap for UK keyboard, has anyone created a KeyboardLayout_en_UK.cpp file for this?
With reference to the Arduino Keyboard library, it does not have a keymap for the UK keyboard. I have tried to find a keyboard map that shows the hex value for the UK keyboard but I didn't have any ...
1
vote
1
answer
370
views
How to drive two Stepper motors and use an Ultrasonic sensor together?
I am working on an autonomous robot using two 4-pin stepper motors, HC-SR04 ultrasonic sensor, 2 L298N motor drivers (one for each motor), and an Arduino Uno. My problem is that when I use the stepper ...
2
votes
1
answer
41
views
Having issues understanding what "#define GET_STATUS" does
I am trying to use a Waveshare 4.2inch e-paper display with an Adafruit Feather Adalogger M0, but am having issues with two separate instances of #define GET_STATUS being defined differently in ...
1
vote
0
answers
174
views
Using library functions in timer ISR ESP32
I'm trying to use a library function in my ISR function that uses the internal timer to trigger every 1 ms. The chip that I'm using is an ESP32-C3-MINI. Here is my current code:
main.cpp
#include <...
-1
votes
3
answers
99
views
What is the best way to create a library from existing functions?
I was tasked to take functions that work, and create a library with these functions.
Take a look at the following function that existed inside a program:
char* Num_to_HEX_char_array(int32_t value)
{
...
-1
votes
1
answer
50
views
Unable to get my created library to work - while it compiles
I am experimenting with creating my own Arduino libraries. Unfortunately, while the program compiles, the end result does not work.
For purposes of experimentation, I have broken down the library in ...
2
votes
1
answer
714
views
ESPAsyncWebServer code not compiling
Error messages
Arduino: 1.8.14 Hourly Build 2020/12/15 11:33 (Windows 10), Board: "Generic ESP8266 Module, 80 MHz, Flash, Disabled (new aborts on oom), Disabled, All SSL ciphers (most ...
1
vote
1
answer
247
views
1MHZ Attiny85 RF with MANCHESTER library
I'm trying to set up a transmitter made by the following components :
Attiny85 (I need 1MHZ speed)
Cheap 433mhz transmitter (FS1000A)
The library I am using is the Manchester library GitHub.
The ...
0
votes
1
answer
1k
views
Just installed Arduino 2.0.3 - what is windows path to associated libraries?
Just installed Arduino 2.0.3 and I attempted to build a sketch which includes a library that I manually installed in version 1.8.19 and it can't be found:
In my program I have
#include <DS3231.h>...
1
vote
0
answers
57
views
Adding RTC Library for Arduino Project in Visual Studio
I am working in an Arduino project in visual studio. I need to get and set time to a RTC clock. That's why I am adding a ds3231 header file in my project from GitHub. When I want to build "it's ...
0
votes
1
answer
93
views
Making library for arduino
I'm learning library making on arduino , I want to make a library that works with arrays a user sets, e.g:
User sets array of int,
when a certain function is been called the library will check if ...
-1
votes
1
answer
875
views
I need help with creating a menu using u8g2 library
I want to make a project with a (Nokia 5110) display using u8g2 library.
Here I have the code for my program:
#include <Arduino.h>
#include <U8g2lib.h>
#include <TM1637Display.h>
#...
0
votes
1
answer
40
views
Confusion regarding PID library?
PID library is available(built in) in standard installation of arduino IDE or do we have to download it additionaly after installing our IDE?
How can i check which of libraries are available in my ...
1
vote
0
answers
430
views
Is there a FreeRTOS library for an Arduino Nano 33 BLE?
I can't seem to find any library online so I can start developing FreeRTOS tasks for the Arduino Nano 33 BLE in the Arduino IDE. Is FreeRTOS incompatible with this Arduino?
0
votes
1
answer
159
views
Best way to "hack" a library without forking it
I'm using Visual Studio Code and PlatformIO.
I added some libraries to my project using platformio.ini:
lib_deps =
olikraus/U8g2@^2.34.4
crankyoldgit/IRremoteESP8266@^2.8.4
plerup/...
5
votes
1
answer
893
views
Library not found when using the arduino-cli command (although working with the Arduino IDE)
I have a sketch which I can upload without problem with the Arduino IDE. I installed the arduino-cli Version: 0.28.0 Commit: 06fb1909 Date: 2022-10-18T15:53:04Z. I want to compile and upload a code ...
1
vote
3
answers
382
views
Is there a way to strip a library from all unused parts and defines, automatically?
Say you want to investigate part of the code you use from a rather large library, but it's buried between all kinds of #defines and classes etc, that you're never gonna use in your code.
Is there a ...
0
votes
1
answer
114
views
#define from main (.ino) not considered by comiler in own libaries
I have got the problem, that my #define from main (.ino) is not considered by the comiler in my own libaries. This #define MQTT_MODULE is only considered in the main (.ino) programm, but not in ...
-4
votes
1
answer
97
views
Can I run Arduino code on a 6502?
I've been doing projects with the arduino boards for a long time and accordingly also with the libs from adafruit etc. But that was too boring for me and I wanted to get more into the matter, so I ...
2
votes
1
answer
70
views
How to configure 16x2 character LCD to work with 8bit?
I have the LiquidCrystal library installed but all the examples are for 4bit connection, I want to drive the LCD with 8bit.
In LiquidCrystal.cpp file it says;
When the display powers up, it is ...
-1
votes
1
answer
75
views
Library fails to compile
I want to try out this library:
https://github.com/connornishijima/arduino-volume3
I downloaded the zip file from github, renamed it, and included it as a library in the IDE.
So run one of the ...
1
vote
1
answer
134
views
Fluctuation in 4 half bridge load cell via combinator
I'm currently using a Sparkfun 4 Half-Bridge load sensor (50 Kg) with combinator and amplifier both are from the Sparkfun. Link:https://www.sparkfun.com/products/10245 (For Load Sensors)https://www....
0
votes
1
answer
40
views
TVout characters don't line up
I am messing around with the Arduino TVout library and I have created some multi-character tiles (I don't know what else to call them). Just to start out, I created a simple X that spans across 4 ...
1
vote
0
answers
951
views
PlatformIO - Creating a library including a 3rd party library
I'm using PlatformIO, and I'm trying to create a library who uses another library in it.
(1) For that I created an empty library called ABCD.h stored in a newrep github repository.
(2) 3rd party ...
0
votes
1
answer
414
views
Create a library when using PlatformIO
(1) I'm trying to work with libraries in PlatformIO format", for , of a library, located in Arduino's libraries, where code is llocated under \src directry.
(2) Any other library, not it "...
1
vote
1
answer
1k
views
Arduino create Json Array with double values and 2 decimal point
How i can create a Json Array with double values and 2 decimal point using the ArduinoJson Library?
https://arduinojson.org/v6/how-to/configure-the-serialization-of-floats/
In the folowing small ...
1
vote
1
answer
62
views
Please help me navigate the stepper motor object definition in the documentation
I am trying to use the stepper library and the stepper object is documented like this
This function creates a new instance of the Stepper class that represents a particular stepper motor attached to ...
-1
votes
1
answer
146
views
How to use two timers 1 and 4 simultaneously in Arduino Mega 2560
I activated timer 1 and its interrupt on the 2560 board and it works properly. Now I want to run Timer 4 as well. I installed the Timer 4 library, but when I compile the program, I get the following ...
1
vote
0
answers
902
views
AccelStepper motor current position
When using the AccelStepper library to control the motor, I need the current position of the motor at any given time when in motion. However, the functions in this library blocks so currentPosition() ...
0
votes
2
answers
157
views
Odd behavior of defines - is this Arduino specific and how does it work?
A question I have long had regards an interaction between #define statements and a library header include. I've seen several Arduino libraries use this rather convenient configuration system where you ...
1
vote
2
answers
2k
views
Undefined reference to function in custom library
Hello I am making a private Arduino library but am having trouble understanding how it is linked. Why does this h file work, but when I move the definition of board_led to a matching c file, it throws ...
1
vote
1
answer
56
views
Is it possible to use mathematical sets and their operations in arduino?
In python there is the object set that resembles a mathematical set, namely, you can remove elements from it, add elements to it, you can calculate the intersection/union between two sets, etc.
Is ...
1
vote
1
answer
898
views
Arduino HX711 load cell lots of drift
I am trying to make this 50kg load cell work with this HX711 chip. I currently have the following connections :
Load cell red -> E+
Load cell black -> E-
Load cell white -> A-
Load cell ...
1
vote
0
answers
57
views
Problem adding library in the Arduino IDE
Currently, I'm trying to build image processing on ESP32 using OpenCV GitHub - joachimBurket/esp32-opencv: Shrinked OpenCV for ESP32. Then I want to put this library into Arduino IDE.
But, I'm having ...