The process of designing and writing source code as part of a program (or sketch) for Arduino. Do not use for uploading to an Arduino board.

learn more… | top users | synonyms (1)

0
votes
2answers
25 views

Call class B from Class A

I have two classes in my sketch that are independent of each other (a serial output and an LCD display) A simplified structure of my code is as follows: class A { public: int x; void afoo() ...
-1
votes
1answer
16 views

sumo robot programming problem

i am building a sumo roboT with arduino nano and the problem is the ultrasonic sensor is not funtioning while the line sensor keep tracking on the white path when it supposes to search for robot and ...
0
votes
0answers
10 views

Interfacing Arduino with Simulink and Proteus Simutaneously [on hold]

Ok for my project, we have to apply FEC coding for IR transmission. However, the problem is that for any kind of FEC I will need to apply it before modulation, which means i have to interface it with ...
0
votes
4answers
53 views

Arduino language

I'm learning with my school Arduino and how to use it etc. I know Swift and a little bit of HTML and I would like to learn Arduino language, because I think it's easy! What are the best resources ...
0
votes
2answers
39 views

Millisecond timestamp (13 digits) in Arduino

How can I store a 13 digits int in Arduino? For example, current timestamp is: 1500666822235 An uint32_t can only hold 10 digits max. 64 bits integer does not seem to be supported on RFduino.
-2
votes
1answer
65 views

How to print every byte as it arrives in HEX- Arduino UNO and ZE03-CO sensor [on hold]

My question is: Is this the right way to read the bytes from the CO-sensor and do the calculation to get the output in PPM? #include <SoftwareSerial.h> #define RxPin 10 #define TxPin 11 ...
-1
votes
3answers
74 views

What not to do to an Arduino

I may have been working with my Arduino UNO board improperly, because now it fails to upload sketches (says some programmer is not responding) and when I press the cute little restart button, the ...
0
votes
0answers
11 views

Wiegand 26 arduino implementation

I have to connect two rfid readers into arduino. Both readers communicate by wiegand 26 protocol. At the begining i used this library: https://github.com/ugge75/Wiegand-Protocol-Library-for-Arduino-...
1
vote
2answers
31 views

Updating Array Values Incrementally Overwrites The Existing Values, Why?

I have a global array. I'd like to update the array while the program running. But, I've found that my program below doesn't work as I expected. Please checkout the program source: #define ...
0
votes
1answer
15 views

MIDIUSB - Why is the command put twice?

Consider this function: void noteOn(uint8_t pitch) { midiEventPacket_t noteOn = {0x09, 0x90 | 9, pitch, 127}; MidiUSB.sendMIDI(noteOn); } midiEventPacket_t is defined as: typedef struct { ...
0
votes
2answers
41 views

15x15x15 LED cube with thermal sensors

I'm trying to wrap my head around a public art project that I've recently received funding for, and I'm hoping that someone here can help me with a bit of guidance. The concept I'm working on is a ...
0
votes
2answers
19 views

SdFat Library what is dir_t*?

I'm using the SDFat library and the FatFile type has the functions: bool FatFile::dirEntry(dir_t* dir) Return a file's directory entry. Parameters [out] dir Location for ...
-1
votes
0answers
22 views

How can i send the data into arduino using visual studio C# GUI button [closed]

Hallo everyone, I am working on a project. I have used a GUI for motor control. I have used a button in GUI. In order to control the speed of the motor through my gui, i have to use a ...
0
votes
0answers
9 views

TimeAlarm Functions Not Being Called

I am using an Adafruit Flora board. In the following code, it seems as if the twoSecondTimer and fiveSecondTimer are not being called because their print statements are not showing up in the serial ...
0
votes
1answer
41 views

Send signal to vibrate a Restaurant buzzer via web based app to a PC [closed]

I'm new to Arduino, I want to create a restaurant buzzer using Arduino and it should turn on/off via web based interface. It will be locally connected only. Is it possible to send a signal with the ...
0
votes
2answers
44 views

Hiding WLAN password when pushing to GitHub

I have started to use GitHub to store Arduino code. However some of my code uses the SSID and password for my WLAN which I don’t want published. A common way of handling this in non-embedded ...
-3
votes
3answers
44 views

what are data types in c [closed]

data types are many and are used for declaring variables of different types. the type of variable tells us how much space it occupies. this is all good but I didn't exactly understand what are they.
0
votes
0answers
26 views

Pressure Sensor-MPX10DP with amplifier and Arduino UNO - output to kPa

I'm working with an Arduino UNO. I'm trying to use this Sensor to obtain the pressure in kPa. I'm using a tl084cn to amplifier the signal. But I don't know what values I'm getting and what to do with ...
1
vote
3answers
77 views

Constructing my own serial command syntax to control arduino

I know this is a basic question, but as a hardware electronics guy and not a programmer I cannot seem to fathom how to do this - so any examples of code would be greatly appreciated: I want the ...
1
vote
2answers
53 views

Convert Bitstring to Textstring

I have an Arduino Uno which is going to receive a long binary string. I know that this string will correspond to English when decoded. How can I convert the incoming binary string to text, so that I ...
2
votes
2answers
53 views

Sending Analog Input Data from Serial Port to Google Sheets

So I'm trying to make use of my Arduino Uno while I purchase the components for my next project. I've made use of the Digital Hourglass project from the Starter Kit to make sure I get up and move ...
3
votes
1answer
35 views

Can I run arduino on Windows Embedded Compact 2013?

I'm actually working on a robotic project for which I'm planning to use arduino to drive the wheels.For this, I want to send signals from my Onboard embedded computer (which has Windows Embedded ...
0
votes
1answer
36 views

arduino labview serial communication [closed]

I have a problem of synchronization between data sent from LabView interface to Arduino. This is my code. I am using a SHT31 sensor to send temperature and humidity from Arduino to LabView after ...
0
votes
1answer
28 views

Echo from device not matching input

I'm writing a char array to a device with an arduino mega that should be giving me an echo back, instead, I'm getting an array back with different chars that correspond to my sent function, but not in ...
0
votes
1answer
107 views

Difference between Arduino and elegoo? [closed]

I know that Arduino and Elegoo use chips from the same manufacturarers, but still I was wondering if there's any difference between them in terms of software or similar. In school a professor wants to ...
0
votes
1answer
18 views

Incorrect data being received on RX of NRF24L01P

I am running a setup of two NRF24L01P's on homemade code where the TX sends an analog signal fed through a standard pot, and the RX simply prints out the signal. But the RX seems to be getting ...
1
vote
2answers
34 views

delay() runs super fast unless I remove a while loop that never runs

I'm working on a small game on arduino but I'm facing some really odd behavior. When I run this code all of my leds flash on and off in less than a second even though delay(10000); should stop them ...
0
votes
1answer
40 views

Certain String Characters To Int

I have a char* array which looks like this "T 20" and I'd like to extract the "20" and convert it in to an integer. I was thinking of using atoi() but it seems that function will operate on the entire ...
1
vote
4answers
97 views

Running a function in the background continuously

I have a keypad which is connected to arduino (with one analog pin).In the arduino code, I have created a circular queue which stores the inputs by pressing on keypad. Now when a key is pressed on ...
0
votes
1answer
19 views

How to get the server response when I post to a web api

I have an arduino which is using a TCPClient to post JSON messages to a web api. First, I have pasted the code below to see if people have general comments about the method I am using to do so. I am ...
0
votes
1answer
22 views

Sending JSON message to web api via post. Why does HTTP 1.0 versus 1.1 make a difference?

I am sending a message to a web api call every xx seconds. I could not get it to work at all until I changed the header from HTTP 1.1 which is what I was using to HTTP 1.0. Then, it started working. ...
0
votes
1answer
38 views

Can't get constant reading with load cells

I'm really a newcomer to arduino and I'm trying to build a scale with four SEN-10245 load cells and a HX711. My issue is that I can't get constant readings in the serial monitor and I'm not sure if my ...
0
votes
1answer
58 views

Global variables with C++ in multiple files

I'm not a C++ programmer (but I have used regular C code for implementing low-level machine language equivalent SW for some time), and after trying to modify an existing cC+ program to do what I need (...
0
votes
1answer
62 views

Measuring distance based on time

I have written a arduino sketch which is used to measure the distance travelled. Since distance = speed * time , I have initiated speed = 6. I have initiated time = millis() variable and it calculates ...
0
votes
1answer
23 views

Wierd Issue with PWM pin

I'm trying to run two of my motors through PWM. Here's my code - #include <Servo.h> int Lm = 11; int Rm = 10; int incomingByte = 0; int pos = 0; Servo myservo; void setup() { pinMode(Rm, ...
0
votes
0answers
37 views

RadioHead Library custom configuration for RFM96 LoRa

I have a pair of Adafruit RFM96W LoRa Transceiver Breakouts and want to use them with the RadioHead library. My pair of radios works if I use the example sketches from the adafruit tutorial, but I ...
1
vote
0answers
54 views

ESP8266 library / function for IR remote control

I am using IRremoteESP8266 for reverse engineering Hitachi AX-M76E mini stereos IR controller. I want to read the signal that the remote sends and send the same hexas to the stereos with IR led. ...
0
votes
3answers
64 views

Write your own program to control Arduino Uno

Is it possible to write a program to control the Arduino Uno, without using the Arduino IDE?
2
votes
1answer
67 views

Diffrence between running once and infinite

const int ledPin = 12; void setup(){ pinMode(ledPin, OUTPUT); Serial.begin(9600); } void loop(){ if (Serial.available()) { light(Serial.read() – '0'); } delay(500); } ...
0
votes
0answers
8 views

Mac Air 2015, Uploading to Arduino causes computer to crash

When I try to upload code to my cloned Arduino my computer crashes it was working before but seems to crash every time I try and upload to the controller. Any suggestions?
0
votes
1answer
14 views

Avoid overflowing of counter

I have a global uint32_t that keep tracks of used Bytes: uint32_t usedBytes; int bytesWritten; byteWritten = myFile.print(data, FILE_WRITE); if (byteWritten > 0) { usedBytes += bytesWritten; } ...
0
votes
1answer
47 views

HMC5883L not working in continuous mode!

I'm just starting with the HMC5883L, I'm writing my code with C and also my own I2C library. I noticed that the values on the Arduino IDE's serial monitor are constant. Then I developed a function ...
0
votes
2answers
41 views

Reducing noise and finding sampling rate

I have Arduino Due R3 (84MHz) and I am trying to find the mean of value from AnalogRead. I have to set the sampling rate of 8000 samples/second with 4 channels. I tried using for loop for this purpose....
0
votes
1answer
15 views

Arduino Esplora

So I'm trying to turn my Arduino Esplora into a controller, and my first step is to understand how the controller works. I've copied and pasted this code into the Arduino 1.8.2 IDE. Esplora.writeRGB(...
1
vote
1answer
45 views

Recursive list of files on SD card with indexing

I'm trying to create a way to make a recursive list of the long name of files from an SD card with an index so that I call the file I'd like. Right now, I'm having trouble getting the files to list (!...
1
vote
2answers
49 views

Need help with calculator logic

I am trying to build a calculator with an Arduino, an LCD display, and a keypad. Getting inputs from the keypad is not the issue. Before I can add, subtract, multiply, or divide any two numbers, I ...
3
votes
1answer
99 views

How does Arduino IDE 'Get Board Info'?

I want my C# application to automatically select the correct COM port by way of a string equality check against a 'GetInfo'-type request to the Arduino board. I know the Arduino IDE can get info ...
0
votes
0answers
33 views

I want to preserve existing arduino sketch before I try a new one [duplicate]

I'm a complete newbie to Arduino. And to 3D printing. I have a PRUSA I3 clone that has been assembled, but not calibrated or tested. I've determined that I need to change the value of some constants ...
0
votes
1answer
32 views

Cannot obtain reading from Meter (MODBUS)

I have a system in which I am taking readings from a Meter and processing it through an arduino nano. My code looks as follows : #include <SoftwareSerial.h> #define SerialControl 7 #define ...
0
votes
1answer
57 views

Arduino Compiling Error

I recently format my Windows 8 and installed Windows 8.1 . In Windows 8, I was using Arduino IDE and there was no error in compiling.But then I installed Windows 8.1 and re-installed Arduino IDE.I ...