Skip to main content
Share Your Experience: Take the 2024 Developer Survey

Questions tagged [input]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
0 votes
1 answer
77 views

Interfacing 8 ohm speaker ouput with ESP32

I'm trying to use an ISD1820 recording module with the ESP32, except I want to store the recordings and send them over Wifi rather than playing them back. The ISD1820 has an output for an 8-ohm ...
user89016's user avatar
1 vote
1 answer
120 views

how to change output PWM based on analog input

I want to give different PWM (D11) signals based on how much voltage is input (A7). How can I change PWM for different analog values? #include <LiquidCrystal.h> #include <ezButton.h&...
hfsrg's user avatar
  • 39
2 votes
0 answers
65 views

How to show repeated result on LCD while button is pressing

my results are here. 0 press--"a" 1st press--"b" 2nd press--"c" 3rd press-- still showing "c" When button pressed 3rd time, It must be repeated to show "a&...
hfsrg's user avatar
  • 39
0 votes
1 answer
522 views

How to use reset pin as I/O pin with ATtiny44

I am using the Arduino IDE as an ISP programmer to program my ATtiny44 IC. Unfortunately, I ran out of pins, so I want to use the reset pin as I/O. I read several articles online that says it is ...
electro_nooobbbb's user avatar
2 votes
2 answers
82 views

Looking for a very simple board

I’ve worked with esp8266/esp32 boards in the past and they were great. But now I have a very simple project where both of these are way too powerful. I want to read one analog input over USB per COM. ...
boop's user avatar
  • 191
1 vote
1 answer
135 views

Input on the Nano RP2040 does not float

I am using the Nano RP2040 with MicroPython and run the following code: import machine import time p0 = machine.Pin(0, machine.Pin.IN) while True: print(p0.value()) time.sleep(0.3) The Nano ...
Panhaboth K's user avatar
3 votes
1 answer
593 views

Input Oscillating Wildly

I'm trying to read an input from a switch but instead of getting 0 and 1 for closed/open, I'm getting 0 and a rapid series of 1s and 0s. Originally I tried (and failed) to simply read a rotary encoder ...
WillM's user avatar
  • 39
0 votes
3 answers
613 views

Using 1 ms delay() in a for loop to check inputs.. Bad?

So first off, I know millis() exists. Just asking out of curiosity. Say you have a button you wanna check for during a delay.. Maybe a 10 second delay. So you make a for loop that checks for input and ...
BobaJFET's user avatar
  • 135
2 votes
2 answers
58 views

How do I fix my code so that it reads text from the serial monitor?

I have created a code that should print out "Enter true to deactivate alarm" in the serial monitor, then store the user's answer and print "alarm off" if they enter true and "...
Jillian's user avatar
  • 21
-1 votes
1 answer
103 views

Serial.parseInt works for first menu but now in a sub menu

I am trying to use the Serial object to print some lines giving the users some options to select by entering an int. It works at this main menu. But when the user selects 1 I use Serial again to print ...
androidAwesome's user avatar
0 votes
1 answer
130 views

Drum game controller - Problem with Piezo inputs [closed]

I currently try to build some Drums for the game Clone Hero. The problem that I have is that I can't use both of my Piezo inputs that I have hooked up at the same time. I have a Arduino Pro Micro and ...
DuddiSuppe's user avatar
1 vote
2 answers
572 views

how to config the Arduino ADC'S input on A0 instead of use default?

I am try to build this AC-DC meter, the code original used default A3 as input, how can change the input on A0? the link: https://simple-circuit.com/arduino-autoranging-ac-dc-voltmeter-with-trms/ ...
oldbin's user avatar
  • 11
1 vote
0 answers
96 views

Serial communication problems

When I run this script serial communication just stops after a random period of time. There is no error it just stops outputting data and does not respond to inputs in IDE. Does anyone know a fix for ...
kiranmclernon's user avatar
1 vote
1 answer
1k views

Writing multiple inputs to serial port using a while loop

I am trying to get the serial monitor to prompt me to input two settings - the PWM level and the Resonance level. I am being prompted to input the PWM level, but before I can input the Resonance level ...
PrematureCorn's user avatar
0 votes
1 answer
395 views

What is happening when digitalWrite(pinname, LOW) is invoked after pinMode(pinname, INPUT_PULLUP)?

I read the Arduino official docs on digitalWrite and am confused about what is happening from an electrical perspective when digitalWrite is invoked on INPUT_PULLUP pins. Say my code says this: ...
rfii's user avatar
  • 170
2 votes
1 answer
75 views

Arduino changing output based on wire voltage

I’m new to arduino and I want to build myself smart switch that can be turned of both manualy and via wifi, is there any way to change position of relay based on if another wire is live or not? Im ...
krystof18's user avatar
  • 315
4 votes
4 answers
3k views

Why am I receiving random input values in my Arduino?

I want to use a switch for my Arduino using digitalRead(), but I keep receiving random inputs. Whenever I connect energy to that pin, it always returns HIGH, but otherwise it goes completely random. I ...
john papp's user avatar
3 votes
2 answers
354 views

Is it bad practice to multitask without timing constraints

Going through resources such as several things at the same time and with some greatly appreciated assistance on here I'm finally getting a grasp on how to multitask a microcontroller. Most examples ...
Zhelyazko Grudov's user avatar
1 vote
1 answer
47 views

Unable to make a really basic sketch work

I've been learning how to encapsulate my code within functions, and one of the examples I worked on is a simple INPUT_PULLUP button. When I upload the sketch from the arduino website everything works, ...
Zhelyazko Grudov's user avatar
1 vote
3 answers
100 views

Memory for inputs?

When a button is pressed, the Arduino might be busy with something (like drawing the screen). When the Arduino has finally time to check the button input, the uses might have release it already. Is ...
SaschaDeWaal's user avatar
1 vote
1 answer
293 views

Arduino analog input to iphone notification

I need some help :) Is it even doable? Is there anyone who wants to help me program it? My wish: I want to receive a iphone notification when 1 arduino analog input drop from 5 to 0 volt. Then (...
Joepl10's user avatar
  • 11
1 vote
2 answers
94 views

arduino mega buzzer output

I have project by Arduino mega which have 22 inputs and 22 outputs and buzzer reset and output reset pushbuttons , it have two status if the input is high(not continuous ) the output will on and the ...
eng.hamza's user avatar
0 votes
2 answers
184 views

Turn on relay for amount of time by continuous input

I have a project having two input status first the input is not continuous the output buzzer relay will be on for 10 seconds and then turned off or it can be off directly by push button the second ...
eng.hamza's user avatar
1 vote
0 answers
74 views

Changing the servo motor operating direction using arduino

I want to turn the servo motor 90 degrees with the first double high inputs, then I want to turn the motor 180 degrees with double high inputs, but the motor turns 180 degrees with one high input. ...
Sabri73's user avatar
  • 51
2 votes
2 answers
4k views

Measure the time between 2 inputs

I am making a small project, and for that, I need to measure the time between 2 inputs. basically, a program to measure the time elapsed from when digital pin 2 is high to when it again becomes high.
Chinar's user avatar
  • 21
2 votes
2 answers
92 views

Rasberry Pi Controlling Arduino - Reads "Ghost" Input - Doesn't Complete Logic Loop

I am using an Arduino Atmega2560 clone, I have used it many times before with satisfactory results - although I haven't used it with my Rpi before. My Raspberry Pi is model 4 (B I think?). #define ...
GeorgeWTrump's user avatar
0 votes
1 answer
197 views

Attiny85 Clone Cannot set P1 to input [closed]

Everything i read about the chinese Digispark attiny85 clones says you can use p0-5 as digitlal I\O (p5 as after fuse reset) Simple test code for a button will not let me use P1 as an input tied to a ...
Glen020's user avatar
2 votes
1 answer
173 views

Analog input voltage rises when motor is working

I'm making automatic water plant system. I'm using: Arduino Uno 3.3-6V water pump -https://www.amazon.com/Vipe-Micro-Submersible-Motor-Water/dp/B01N0X3CW4 Capacitive soil moisture sensor - https://www....
marejosef's user avatar
2 votes
2 answers
312 views

Plotting data from Arduino and using the serial monitor in parallel

I'm very new to the Arduino world so bare with me. I would like to plot live data that I receive from my arduino. I use the Serial Monitor to read user input, show text, etc. The only way I found to ...
Luca Rüffert's user avatar
2 votes
2 answers
2k views

Unable to use analog pins as digital inputs

I want to use the analog pin A7 as a digital input pin. As stated in the Arduino docs the analog pins can be configured in the same way like any other digital pin. However, when trying to configure an ...
albert's user avatar
  • 205
2 votes
1 answer
58 views

Input state is stuck HIGH when function called using input also uses same input to call another function

I'm writing a choose-your-own-adventure style project for a class project. My Arduino Uno is set up with a 16-digit LCD display and two pushbuttons with pulldown resistors. I'm wanting each function ...
Snyper's user avatar
  • 41
0 votes
1 answer
54 views

Streaming integer data from Arduino to Java, integer greater than 0xFF

I need to send how many milliseconds elapsed since the beginning of the time the arduino runs to java using Serial.write(). However, the largest integer that I can throw in there is 255, naturally ...
John Rawls's user avatar
-1 votes
2 answers
48 views

Certain componenet does not seen to respond when given voltage

I am using a part off an electronics set I got a long time ago. It is off a electronic set called snap circuits rover deluxe Its a disc launcher and I have wired it to how it seems to want to be ...
DigitalRookie4's user avatar
5 votes
2 answers
969 views

Multiple Push buttons to one input

So I am trying to use one input to control an LCD display. The goal being that once one of the buttons is pressed it delivers a message. I have watched quite a few tutorials and can get the program to ...
David Wisniewski's user avatar
3 votes
3 answers
5k views

How to wire a three-pin on-off-on switch for reading input?

I would like to read the output of an on-off-on switch with my Leonardo board, but I have very little knowledge of electronics and don't know how to wire it up. This is the switch in question: E-...
Boonswaddle's user avatar
-1 votes
1 answer
36 views

Longruner Nano ATMega 328P input stays HIGH for 1s longer than the reality

I have a Longruner Nano ATMega 328P (copy of arduino nano, main difference being the USB connector, CH340 instead of the usual FT232, from what I could find using google searches). I wrote a super ...
Supamiu's user avatar
  • 101
1 vote
1 answer
59 views

Is it possible to exit a loop on the change of an input state?

I would like to exit a particular loop if the state of an input changes from LOW to HIGH. This is the current loop: void brakeFade() { pixels.clear(); pixels.setBrightness(255); pixels.fill(16711680, ...
JabawokJayUK's user avatar
0 votes
1 answer
484 views

Using the LED pin for input

I have an Arduino-like device with few GPIO pins (DigiSpark clone). It is based on an 8-pin AtTiny85 IC so there are Power, Ground and six other pins, two of those six are being used for USB keyboard ...
RedGrittyBrick's user avatar
1 vote
2 answers
37 views

Generate 5VDC signal when external sensor input changes from high to low

I am new to arduino. I have a project in which I need an arduino to generate a +5VDC signal in response to a change of status, (high/5VDC To low/ground) from an external source. The external ...
Randy Anglin's user avatar
1 vote
1 answer
690 views

USB control panel with endless turn knobs

I understand that some arduinos are capable of presenting themselves as a USB HID device to a PC. I would like to use one to build a custom input controller that lets me read maybe 8 or so turn knobs ...
Bram's user avatar
  • 199
0 votes
1 answer
332 views

How to code an arduino to execute a particular code using a slide switch

I’m pretty new to arduino. I need help concerning a project I’m making. I’m using a SPDT slide switch to switch between what code(method) should be executed.i.e when I shift the switch to the left, ...
Brandy's user avatar
  • 33
-1 votes
1 answer
74 views

Ultrasonic Sensor as Unlock Sensor

Is it possible to use ultrasonic sensors maybe HC SR04 type as unlock sensors? I'm figuring out if it can replace matrix keypad? For example 6 HC SR04 are used to be an input sensor waiting for a ...
Billy's user avatar
  • 1
1 vote
1 answer
37 views

What is the name of a peripheral which reads servo output data physically?

I know the title is phrased terribly, but I'm not sure how to phrase it since I'm not sure of the name. I have a servo, that I cannot connect to, except for the output spine/shaft (physically). I ...
trueCamelType's user avatar
-1 votes
2 answers
127 views

Can't get actual output when, both input logic is high

I want When, light=0, ir=0 then output will pin 8 high & pin 12 low. light=0, ir=1 then output will pin 8 high & pin 12 high. light=1, ir=0 then output will pin 8 low & pin 12 low. light=...
Shahin Kadir's user avatar
-3 votes
4 answers
253 views

How should I connect 5 buttons to arduino so that I can use the least number of inputs all the buttons are connected to ground

The problem here is that I want to connect 5 input buttons to an Arduino but I do not want to utilize 5 input pins of Arduino, is there any matrix like connection using which I can reduce the number ...
Shakti Phartiyal's user avatar
0 votes
2 answers
1k views

How to read input pin on MCP23017?

I'm working to develop a simple code for MCP23017 that I want to use to run LCD128x64. I was succeeded to set IODIRB as output and blink LED as a test. Now I want to read the pin state, but I couldn'...
R1S8K's user avatar
  • 283
1 vote
0 answers
570 views

Not Able to get INPUT_PULLUP pinmodes to work on multiple pins

I am working with an Arduino nano, and ic2 128x32 OLED display and a 1x4 membrane keypad. Problem is that only one of the 4 pins are detecting the button press. it's not the Arduino, I already was ...
Avi Baruch's user avatar
0 votes
1 answer
52 views

Arduino Due Digital Inputs without Response

On two of my Arduino Due, when connecting the pin 3.3V to any digital inputs (37,36,35,34), no serial message nor LED_BUILTIN is thrown as output, only the Test message. Digital Pins are set as ...
Brethlosze's user avatar
0 votes
2 answers
216 views

Handling arduino output current

I need to power an actuator that requires 12 volts and consumes between 5 and 10 amperes depending on the weight it is charging. Therefore I bought a power supply of 12 volts and 10 amperes. My ...
punk code's user avatar
1 vote
1 answer
3k views

Can I use the PWM pins as regular digital input/output pins?

In regards to the arduino which has pwm pins, can I use these pins as normal input/output digital pins or not? Thanks in advance.
Terry1612's user avatar