Stack Exchange Network

Stack Exchange network consists of 175 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 [programming]

The process of designing and writing source code as part of a program (or sketch) for Arduino. For questions about uploading code to an Arduino board, use the [uploading] tag instead.

3
votes
0answers
393 views

Do software SPI read from a register using shiftin()

How to read from a register using software SPI, presumably shiftin()? It works using the builtin SPI library + hardware SPI. I seem to be able to write but not read using manual shiftin()/shiftout()...
2
votes
0answers
364 views

How do I install a library in Arduino Yun cross compile environment?

A few days ago, I've asked this question. Thanks to the replies I've received, I've set up a cross compile environment for Yun by following this guide. I've created a virtual machine with virtualbox ...
2
votes
0answers
334 views

USB Keyboard in Retro Emulators

I have created a retro keyobard using a ZX spectrum and a PRO MICRO based on the info here: http://blog.tynemouthsoftware.co.uk/2013/04/arduino-leonardo-based-zx81-usb-keyboard.html When plugged into ...
1
vote
0answers
23 views

Troubleshooting Program using sensors and actuators

I am doing a project on waste management. I have to separate waste majorly as metal, plastic and other materials. For that using Arduino Mega 2560. I have connected Inductive proximity sensor @ A0 (...
1
vote
0answers
50 views

Ideal voltage level for attachInterrupt()

Well I am working on old textile machines, it is taking motor RPM with ISR. I want to read this RPM and publish on web. but the output voltage of this old system is 0 and 22 Volt. (0 Volt when the ...
1
vote
0answers
45 views

Arduino Communication with Xbee

I'm trying to establish a wireless connection between two Arduino's(M0) using xbee s2c, one Arduino as the sender and other as the receiver. But I am not able to receive the message what the Arduino ...
1
vote
0answers
32 views

Zero-ing Compass | Following Magnet Strip Robot

So my problem is purely programming, I understand the problem but can't figure out what to do, Is there a library? should I create my own code for Zero-ing my compass so I don't have value from earth ...
1
vote
0answers
110 views

Installing Optiboot loader for pro mini 3.3V 8MHz

I have tried to install a better bootloader in some chinese Arduino pro mini boards. I have tried the OptiLoader application via an ArduinoAsISP. I failed in some way. The boards got unstable, I can ...
1
vote
0answers
59 views

ALLBOT knee joints not moving

I am trying to write a simple script for an ALLBOT, but am encountering a very peculiar issue. With the following code, I can align all the servos: #include <Servo.h> #include "constants.h" // ...
1
vote
0answers
129 views

Counting peaks multiple times and opening a valve

I am opening a valve to let fluid flow. The pressure being measured here is with how much pressure the fluid is being pulled into a system. I am trying to measure the average value of only first 10 ...
1
vote
0answers
1k 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. ...
1
vote
0answers
194 views

How to pass input from a Midi controller to a function?

I am trying to pass the input[], data1(pitch) from a Midi controller to the waitForButton function. When a key is pressed it sends data1(pitch) into the array input[], and when the key is up the array ...
1
vote
0answers
63 views

Changing function to work with Midi controller instead of buttons

I am trying to change up this function to work with a midi controller instead of buttons most of the code for the function i will be using as is. it just the parts of the code the deal with button ...
1
vote
0answers
33 views

Not hearing PlayBack from code that records and plays back MIDI

I have altered some code that i found online that records and playback midi data from a midi controller. from my testing i am pretty sure that notes are being recorded from my midi controller, i have ...
1
vote
0answers
308 views

How to play Midi from the Sparkfun Mp3 Player Shield?

in the video: https://www.youtube.com/watch?v=zc1zbwheyE0 I suspect they may be using the midi playback functionality of the chip (VS1053b) on the Mp3 shield. how do you playback Midi from the mp3 ...
1
vote
0answers
408 views

Arduino Serial Communication Issue

I state that I have already written a similar question on StackOverflow thinking that the problem is with my computer software. Anyway, after some shell debugs, I notice that the real issue is on the ...
1
vote
0answers
59 views

Issue regarding executing sketch code when not connected to USB

`I have an Arduino Uno A000066 Board R3 that has an Arduino A000079 Motor Shield Rev3 attached to it. Also I have connected two DC Servo Motors to the Motor Shield and wrote the following sequence: ...
1
vote
0answers
232 views

Problem with my Arduino project

I am making a smart bin which automatically sense (with the help of IR sensor ) and dispose the trash by moving with help of DC geared motor 12V 60 RPM and it also detects for obstacles with the help ...
1
vote
0answers
197 views

OV7670 non FIFO with AL440?

I am trying to build a low-cost Arduino-based camera image to SD card prototype and would like to know if it is feasible to connect a non-FIFO OV7670 camera to an AL440B video buffer to avoid the ...
1
vote
0answers
192 views

Connection between Matlab and Arduino

I'm trying to connect Maltab and Arduino by this code: arduino=serial('COM7','BaudRate',9600); fopen(arduino); But I get this message: Open failed: Port: COM7 is not available. No ports are ...
1
vote
0answers
418 views

Arduino programming attiny13a

Hello I want to program an Attiny13a with Arduino code. I always have this error when I add repository "no file board.txt" in path. How to successfully configure IDE to able burn on it? I use : Link ...
1
vote
0answers
255 views

How to generate Analog Signal (Voice) to the microphone

I have question about microphone and generating sound signal. I have microphone in my intercom at home. It is simple analog microphone, not digital. What I want is to connect arduino analog ...
1
vote
0answers
1k views

Pelco D Library for Arduino

Does anyone know of any Pelco D libraries available for Arduino? I already have a PTZ joystick controlling 3 PTZ cameras, but I would like to add an Arduino 'intelligent' controller capable of ...
1
vote
0answers
87 views

27 Servo Project, Uno with Adafruit's 16-Channel Drivers

I'm working on a project where I need to be able to control 27+ servos. The problem is that I am unsure how to control them from a computer. I'd love to build a simple program with a user interface ...
1
vote
0answers
547 views

7 Key Educational Piano with Capacitive Sensor

I am working on a project for grade 10 computer science. I am supposed to make a piano that has 7 keys using a capacitive sensor, and the piano is supposed to teach you songs like Twinkle Twinkle ...
1
vote
0answers
499 views

Checking string condition?

I'm looking for my Arduino board to jump to a function based on an if condition, where a string (content) is checked to see if it matches the word FALLEN. However, the if condition never occurs ...
1
vote
0answers
4k views

Aduino Due Can messages

I am trying to read/send CanBus messages using a Arduino Due. As of now I have used https://github.com/collin80/due_can library to setup my Can Bus interface. I am using Vector Software CanAylzer ...
1
vote
0answers
933 views

MODbus response for configure data

I am not able to receive data. I am able to send data from master but am not getting any response. This program uploaded successfully. I have below setup to monitor data from Modbus. I have included ...
0
votes
0answers
7 views

How can you combine arduino scales with a touch screen display?

I'm working on a project where ideally I could display the input from three different scales onto an TFT LCD screen. I've found some good information on programming a scale and displaying readings ...
0
votes
0answers
25 views

Fastest way to convert binary string to a number?

I am using a Teensy 3.2 board as control logic for an ADC that I am building for teaching purposes. Currently, I am employing an attachInterrupt() to detect the rising edge of an external clock pulse ...
0
votes
0answers
17 views

empty message receive

#include <GSMSim.h> #include <SoftwareSerial.h> #define RX 7 #define TX 8 #define RESET 13 #define BAUD 9600 GSMSim gsm(RX, TX, RESET); const int doorSensor= 2; int doorSensorState= 0; ...
0
votes
0answers
46 views

Cannot write pin LOW

All the other examples I've seen have had coding errors where they set a pin LOW in a loop with no delay so that it goes high again right away - but this problem is different, and probably something ...
0
votes
0answers
26 views

Can I use an ST-Link to program an STM32F4 through the Arduino IDE?

I have a bunch of boards with STM32F's on them, and they only have JTAG headers. Is there some way to program and/or debug the boards
0
votes
0answers
27 views

How to use parameteric function arguments

I have a function defined as follows: void turn_leds_on(int col_indx, int bright_1 = BRIGHTNESS, int del_1 = 5, bool dir_1 = true ) This function is called using MQTT from user to define led's ...
0
votes
0answers
169 views

Can I use ESP8266 and OV7670 to video stream on a web?

OV7670 image sensor, small volume, low operating voltage, providing all functions of a single chip of VGA camera and image processor. so I am using and ESP8266 to connect to internet and stream the ...
0
votes
0answers
32 views

Serial communication problem NodeMCU

this is my first post here. Before I ask you my problem, I'm sorry if I'm wrong to write but my English is bad. So, my problem is this: I'm developing a "client-server" system with serial ...
0
votes
0answers
50 views

invalid pure specifier (only '= 0' is allowed) before 'int'

#include <PixySPI_SS.h> #include <Pixy.h> #include <Adafruit_MotorShield.h> #define X_CENTER ((PIXY_MAX_X-PIXY_MIN_X)/2) #define Y_CENTER ((PIXY_MAX_Y-PIXY_MIN_Y)...
0
votes
0answers
26 views

how do i fill an array from a grayscale sensor (SKU:SEN0147)?

I'm designing a safe lock of 4 digits, but the password is in terms of colors, I have 3 colors. we are obliged to use a grayscale sensor (SKU: SEN0147). The assignment is as follows: Write a program ...
0
votes
0answers
199 views

ESP8266 to send data to thingspeak while doing unblocked read on Serial.readString()

I have a requirement to get RFID data on Arduido UNO and send it to ESP8266 to be sent to ThingSpeak via the Wifi module. However, ESP8266 is also programmed to send Temperature and humidity data to ...
0
votes
0answers
142 views

nRF24L01 communication with Arduino as transmitter and Raspberry Pi as receiver

here are the codes and i don't know why it does not communicate. The arduino should send some example data and the raspberry pi should simply receive the data. Transmitter code (Arduino) #include "...
0
votes
0answers
29 views

Fujitsu FMC-16LX(MB90F387) Pulse Sensor BPM formula displaying only 96BPM

#include "_ffmc16.h" #include "extern.h" #include "monitor.h" void initLCD(); void delay(); void instCtrl4(unsigned char data); void display(unsigned char temp); void display1(unsigned char pulse, ...
0
votes
0answers
36 views

Installing ESP 32 in Arduino IDE

What to do if in Arduino IDE boards manager, installation is stuck at "Downloading tools (3/3). Downloaded 38,190kb of 125,719kb." when installing ESP32 on Arduino IDE? I have not connected the ESP32 ...
0
votes
0answers
38 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
0answers
311 views

How to make use of HeatIndex and DewPoint. with BME280 library?

Modified library example using HeatIndex and DewPoint calculations; from the BME280 Library by Tyler Glenn. /* BME280 I2C Test.ino This code shows how to record data from the BME280 ...
0
votes
0answers
52 views

Where to find MegaDueShield.h?

Hackster has a project that uses this as an include. I can't find it anywhere.
0
votes
0answers
129 views

Using 4 identical sensors on the I2C bus

I am using 4 Pololu VL6180X ToF sensors on the Arduino UNO for a school project but just can't seem to get it working correctly. I understand that I need to hold them in reset and change the I2C ...
0
votes
0answers
271 views

Import complex sketches into Atmel Studio 7

my Arduino software has grown too much so I had the idea of moving to AS7. My sketch is made of 2 .INO + 1 .h files and uses a 3rd party library. Everything compiles fine in the Arduino IDE. When ...
0
votes
0answers
255 views

concurrent display of BMP file and text on Arduino TFT LCD screen

I am using an Arduino TFT LCD screen (1.7'') on Arduino Due for displaying .bmp file of 80X60 pixels. Is it possible to display a .bmp image on the lcd screen and also display text/draw an object such ...
0
votes
0answers
58 views

Create PWM pulses by comparing the cosine wave with AnalogRead potenciometer

I need generate 4 pulses, for the digital outputs, for example 8,9 and 10,11, at this moment I am using an Arduino Mega. The pulses have these characteristics: 1) 8 and 9 are the same pulses, but I ...
0
votes
0answers
57 views

How to save an incoming MESSAGE of SIM900D MODEM?

I can receive a message but I cannot save it in a variable and find strings in it. The question: is it possible to save the text message in a variable? This is my code. #include <SoftwareSerial.h&...