Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

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.

0
votes
2answers
22 views

Error compiling a sketch to class/library conversion

I'm trying to take a sketch and turn it into a class for a library I'm making, but I'm getting compile issues. This is not a duplicate as suggested. as i explain in the comment and my answer. Thank ...
0
votes
0answers
33 views

How do I fix the error - Error: too many initializers for int[0]

I'm trying to write a simple Library for a robot that I'm making and I'm getting errors I don't know how to diagnose - basically i made a battery monitor for the robot and added some status leds - but ...
0
votes
1answer
28 views

'inet_addr_to_ipaddr' was not declared in this scope

I am using ESP32 Ping from this page: https://github.com/pbecchi/ESP32_ping It works fine on ESP32, no compiler error. Because something wrong on my PC, I did fresh install Windows 10 and Arduino ...
-2
votes
0answers
22 views

where can I get “soc/soc.h” [on hold]

I am trying to follow the instructions for a project given here. What do these parts of the code mean, and how can I obtain the files? #include "esp_err.h" #include "esp_wifi_types.h" #include "...
0
votes
1answer
21 views

Calling external function from a class function

I'll try to explain my need: I have a generic library I created, called myIOT.h. This class have a pre-configured MQTT and wifi setup. Inside this library there is a mqtt_callback function, for all ...
0
votes
1answer
19 views

How do you remove dependencies from a library?

I'm writing a library for a project i created, but it depends on the Neopixel library from adafruit. I want to remove this dependency and have my library be a stand-alone library. Is there a way to ...
0
votes
0answers
27 views

Passing functions while creating a library [duplicate]

I'm trying to create a library to bind a major part of common code ( starting Wifi, initiate MQTT, OTA and more ). while using same code in a non library sketch, which works as expected, I find a ...
0
votes
0answers
14 views

Parsing multiple jsonObjects with Arduinojson and return a list of values

I am building a table tennis score board which parses json objects with ID and names of players to let the players pick their name inside a menu and later on submit the scores to my server. But I am ...
0
votes
1answer
30 views

New code results in audio noise

I am working on a circuit that can record audio to an SD when a switch is HIGH and stop recording when the switch is LOW. I am using the TMRpcm library. I previously had an issue solved on these two ...
0
votes
0answers
18 views

error while uploading a code

Arduino: 1.8.5 (Windows 10), Board: "Arduino/Genuino Uno" avrdude: can't open input file C:\Users\PETER_~1\AppData\Local\Temp\arduino_build_223764/nyu_probe_activity1_code.ino.hex: No such file or ...
0
votes
1answer
19 views

Trying to save .wav files with new name every loop

I have built a set up with an Arduino UNO hooked up to a switch, so that whenever the switch goes from HIGH to LOW it saves audio to an SD card. I am using the TMRpcm Library. The problem is the ...
0
votes
3answers
76 views

Creating a library for arduino

I found a really nice 24 bit I2C adc which was fairly cheap as well (ADS1219) but as far as I could tell there are no libraries for it so I decided to make my own. I have managed to write functions ...
-1
votes
0answers
25 views

No hex file generated from the Arduino IDE to use in proteus after adding esp8266 library

after adding the esp8266 and the firebase Libraries to the Arduino IDE, I am not getting the .hex file anymore. I already saw in some topics that this is normal and that it will only generate .bin ...
1
vote
3answers
44 views

Guideline in library creation

According to this example, creation of an Arduino library is quite understandable. But a few things I would like ask (mostly regarding to what to be defined where) when a library is not that simple: ...
0
votes
0answers
27 views

WiFiEsp library TIMEOUT if do something after client in loop

i don't manage to find out a solution with my code using ESP8266 (esp-01) and WiFiEsp.h library. I can receive datas easily but when i add some code after client.stop(), the library stops run the code ...
-1
votes
0answers
25 views

How do I make changes in the existing library of Arduino?

I have to interface 16x2 LCD and that too with the help of Shift register 74hc164 IC. So I want to change on my LiquidCrystal library. How can I make changes in it. It is showing error: LiquidCrystal ...
0
votes
2answers
43 views

ESP8266 library: 2 requests received instead of 1

I have a strange issue with my sketch using WiFiEsp.h library from https://github.com/bportaluri/WiFiEsp When i send 1 request to my ESP8266 from my browser as http://192.168.0.25 , it seems that my ...
0
votes
1answer
26 views

NRF51822 ± Arduino Uno / ATmegaXXX?

Hello I want to make a simple home automation project and I'd like to use an arduino uno for prototyping and later a atmega for deployment. I need some sort of a mesh communication method. I was ...
0
votes
1answer
36 views

Using timer classes within classes

I am trying to develop a class for a pump that works on a stepper motor, it should be simple but its not working the way I thought it would. Once I move the timer object into the class the code wont ...
0
votes
2answers
65 views

My Ultrasonic sensor is only showing 4cm range?

I am using an ultrasonic sensor SR04 with Arduino Uno and a sample program which I got from the library. However, my output reading is only 4 cm even when there is no object in front of it. I even ...
0
votes
3answers
39 views

Iteed SD card breakout info for Arduino

I got an SD card breakout from an online shop, its the iteed kind without the level shifter, it has the 3.3 / 5 V switch. I cannot find any libraries or write example for it. Has anyone dealt with it ...
1
vote
1answer
170 views

Standard Practice for including custom library in examples folder

I have created my custom library with examples folder in them. The main header file is ABC_Node.h. I am referring the structure of Adafruit libraries for Arduino and in some repos under the examples ...
0
votes
1answer
47 views

Arduino IDE does not display examples folder from my custom library

I have created a custom library for local usage. I call is ABC_node for ESP32 and the structure is as follows: . |-- examples | |-- bnoCalibStorage | | `-- bnoCalibStorage.ino | |-- ...
0
votes
1answer
40 views

Apply patch to library for custom changes in Arduino IDE

I wish to obtain unix epoch timestamps in millisecond precision. I am using an ESP32 along with DS3231 RTC breakout board from adafruit. Apparently the Repository is not maintained often but I see a ...
0
votes
1answer
44 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 ...
0
votes
1answer
28 views

How to Create a reference to an External Print object

Right now I have an object: class Dog { public: Dog(uint8_t I2c, Stream& feedback); void Speak(); private: uint8_t _I2c; Stream& _output; }; Dog::Dog(uint8_t I2c, Stream&...
2
votes
1answer
41 views

Specific values not showing when using a numeric keypad

I have attached a 3x4 keypad to my Arduino Leonardo as an input method. Whenever I press the buttons, the majority of the keys work but specific ones don't. Here's my code, I've set it up to beep a ...
0
votes
0answers
48 views

Arduino and rf24 library

I recently bought two "SparkFun Transceiver Breakout - nRF24L01+ (RP-SMA)" and the antenna. I used the hookup guide from SparkFun to hook one breakout board to my Arduino running the "Getting Started" ...
1
vote
2answers
60 views

Why is there no embedded c code in arduino libraries?

When I took a look at how the arduino libraries were coded I expected to see register names like I/O registers(PINx,DDRx,PORTx) and other such registers with values assigned to them but instead I saw ...
1
vote
1answer
77 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 ...
2
votes
2answers
178 views

How to determine the source of constants in libraries?

Preamble: I am trying to figure out how to program and use the timers in the Feather M0 using the Arduino IDE. I have seen a number of examples published, but I'm not one to just blindly copy some ...
1
vote
2answers
402 views

How to write a library that support both HW and SW Serial communication and allow user to chose which one to use?

I'm working on a library for Arduino/ESP8266/Teensy that use serial to send AT commands. I want to make it as customizable as possible, so I avoided to hardcode the serial and I ask for a reference in ...
0
votes
2answers
172 views

How would I include Arduino libraries using AVR-gcc without the IDE?

I am writing my own code for the Arduino Uno. I compile my code with AVR-gcc, and then upload it with AVRdude. I am not using the Arduino software, but I do have it installed and working on my PC. I ...
0
votes
0answers
88 views

Arduino hangs when sending data using UDP

I am trying to use the W5500 ethernet chip with the Arduino to send some stuff over UDP, but my program hangs when I call Udp.endPacket(). The library in question is here: https://github.com/sstaub/...
0
votes
0answers
253 views

Rc-Switch Receiver Code not receiving anything

Hi so I'm Having Problems on my receiver code which uses the RC-switch.h library, The transmitter code is OK and it prints the corresponding values on the serial monitor but the receiver code doesn't ...
0
votes
0answers
29 views

Virtual Wire transmitter code

I'm Having problems on my virtual wire transmitter code. when i press one button the backward button is continuously being pressed even when im not pressing it. Here is the code // TRANSMITTER CODE #...
0
votes
0answers
82 views

Servo.h and ServoTimer2.h difference

So i'm trying to code a servo motor to turn left when a button is pressed and turn right if another button is pressed i already have a code for it on the servo.h library but it has a problem with the ...
1
vote
1answer
540 views

How to install your own library with Arduino IDE 1.8.5?

I'm struggling a bit with Arduino language + its IDE not being 100% real C++. I wrote my own I2C library for a sensor but can't get the IDE's compiler to recognise it. I'm using Ubuntu 18.04. I get ...
1
vote
2answers
66 views

Attach Interrupt with Library

I am trying to make a library for Arduino, which requires an interruption, but the problem is that when I try the attachInterrupt function inside my library, there's a problem about attachInterrupt is ...
0
votes
1answer
47 views

MAX6675 gives a climbing reading

I am using a MAX6675 board and a k-type thermal couple to measure temp. The problem is even when running the example the temp value keeps climbing. MAX6675 test 27.25 C = 27.25 F = 130.10 109.00 C = ...
1
vote
2answers
205 views

Where should a modified “pins_arduino.h” be stored for Arduino IDE compile?

Our PCB uses an ATmega2560 chip and uses most of the pins, including some that are not defined in the standard pins_arduino.h module, since that module only provides for the pins that are brought out ...
0
votes
0answers
29 views

Cannot load anything from library

So I installed libraries through the Arduino interface (Sketh->Include Library->Manage Library). Then I check: C:\Users\username\OneDrive\Documents\Arduino\Libraries, and I confirm the new libraries ...
1
vote
1answer
79 views

How to avoid calling multiple times Wire.begin() in libraries?

it's all in the title ; I'm developping a library and use *TwoWire pointers in this library ; but I am using an external library that calls Wire.begin(). I've seen something about TWCR register in ...
0
votes
1answer
607 views

Specified folder/zip file does not contain a valid library

I am trying to use this library. But when I try to import the .zip file (of the directory) downloaded from GitHub, Arduino IDE says "Specified folder/zip file does not contain a valid library"
-1
votes
1answer
159 views

Multiple #ifndef vs. single one #endif

My question is connected with the issue as linked: Is there any good working MODBUS TCP master library available for Arduino? An example of Modbus TCP master library as suggested in the post above. A ...
0
votes
1answer
99 views

LiquidCrystal library and timers don't seem to be compatible

If I set timer2 to Compare Match mode, my LCD display stops working. If I use Overflow Interrupt it works fine. Here's my test code. I have a loop() function which does its thing, and a timer ...
0
votes
0answers
34 views

StepperLab3 library and Liquidcrystal

I want to control a stepper while displaying user menus on a freetronics style 16x2 LCD. I'm using liquidcrystal for my menus and in order to get non-blocking control of the stepper I've imported the ...
0
votes
1answer
32 views

CMDmessenger library

I am trying to use the CMDmessanger library on my Arduino uno, and am facing an issue. My issue starts right from the ArduinoController.ino example. When i send the frequency command 3,1; The led ...
2
votes
1answer
734 views

How to transmit string data using the rc-switch library?

I am using the rc-switch library for sending and receiving data. In rcswitch library, there is no method to send string data. I am using below method to send the string message in char buffer. ...
1
vote
1answer
238 views

Error: “undefined reference to …” when calling non-void class' functions from within class

I haven't used an Arduino for anything as complicated as this project before (single sketch projects so far), and am struggling getting my code to compile now that I'm creating my own libraries for ...