Questions tagged [pins]

"Pins" are like gateways between the Arduino code running on the chip and the components attached to Arduino. It can refer either to the physical connectors on the board, or it can refer to the pins defined in the code.

Filter by
Sorted by
Tagged with
1
vote
0answers
32 views

How can I use Arduino Analog Uno pins as Digital pins? [duplicate]

How can I use Arduino Uno Analog Pins as Digital pins, So that I can Attach more components like sensors to the Arduino? My 13 pins are preoccupied and I want more.
1
vote
0answers
32 views

How to make 16 coin vibration motors and 5 servos work at the same time on a Arduino Mega?

I saw in Arduino Mega's datasheet that the sum of currents out of all input/output pins combined should be maximum 200mA. But I want to make 16 vibration motors and 5 servos work together on the same ...
2
votes
4answers
304 views

Why do we use bitwise operators to assign PORTx, DDRx and Pinx?

I have come accross a lot of examples using ways similar to the ones shown below to assign values to the pins. PORTB |= (1<<PORTB2); //set bit 2 PORTB &= ~(1<<PORTB1); //clear bit 1 ...
0
votes
1answer
28 views

Az Delivery ESP32 DevKitC V2 PIN names/number

i wonder where to find out the PIN names for the Az Delivery ESP32 DevKitC V2. There is a pin out graphic, but it does not say how the Pin addresses are: https://cdn.shopify.com/s/files/1/1509/1638/...
1
vote
0answers
16 views

Understanding the pin diagram for MPU6050 IMU

I was reading this tutorial about the MPU6050 IMU and I was unable to understand why the pin configurations vary so much when compared to this schematic for EasyEDA. The tutorial has this pin ...
1
vote
1answer
42 views

Can SoftwareSerial be used in an ESP01

I am using ESP01 as a microcontroller that retrieves information from Firebase and sends them over serial to an Arduino Uno for other uses. I am not using NODEMcu since it has few analog pins and ...
-1
votes
3answers
52 views

ATMega328 functions, but will not output to any pins

Problem: ATMega328 Refuses to digitalWrite() to any pins, I can upload and run sketches using the board UNO from the ide on the 328 and can confirm it is working using the serial monitor (see code). I ...
0
votes
2answers
44 views

What is the proper wiring for relay module?

I want to know the recommended wiring for relay. I am setting it up as NO. Where should I connect the relay, the hot wire or the ground wire? Where should I connect the wire going to bulb, NO or C ...
0
votes
1answer
51 views

Get more PCINT capable pins on Mega 2560

I'm building kinda "ball game" for a total of 6 players based on these per-player specs: 1 stepper motor with 4 pins 2 end stops (start & finish) per motor 1 finish LED 3 holes to score,...
1
vote
0answers
64 views

Wake up from a pin, Sleep when work is done

I have a project which needs to sleep most of the time, and when a button gets pressed, it does its thing which is producing a fading sound wave (using interrupts) until it's time to sleep again. The ...
1
vote
1answer
40 views

pin numbering for non-standard chips

so i replaced the mainboard in (what was) an anet a8 3d printer with a proper RAMPS setup. there was nothing wrong with it, (or at least it wasnt damaged, there are a number of severe design flaws) so ...
1
vote
1answer
26 views

Can you power the ESP8266E-12 with any of the 3.3V pins?

If I want to operate the NodeMCU on the 3.3V input with 2.5V to 3.6V; can I use any of the 3.3V pins to do so?
0
votes
1answer
77 views

WeMos D1 ESP-Wroom-02 Mother Board ESP8266 - where is reset pin for deep-sleep

This item was bought for battery use with deep sleep purposes. For doing so in ESP8266 reset pin must be connected to Gnd pin in order to wake up. This board lacks a reset on- board pin. Since spec ...
0
votes
1answer
38 views

can i convert a pin into ground

i recently started using Arduino uno , but to my despair , the ground pin , without which i cant do any project (or can i ) , so i thought of a possible solution , what if i could program the board to ...
0
votes
1answer
39 views

Can we use UART COMMUNICATION with MCP23017?

I am using MCP23017 as a GPIO expander with Arduino in my project. I have too many serial devices and no pins left on Arduino for UART communication. I am wondering if I can use this MCP23017 GPIO ...
0
votes
1answer
96 views

digital input pins on arduino nano with standard firmata and pyfirmata are always 'None'

I have connected pin D2 on my arduino nano to high, and tried it out with an arduino c program and it works. However, when I load standard firmata onto the the controller from the arduino IDE and try ...
0
votes
1answer
30 views

NodeMCU ESP8266

I am doing a project and using NodeMCU ESP8266. My project includes sensors for UART, I2C and 4 interrupts. I need to read the data from these sensors and get these data via microUSB in real time. ...
1
vote
2answers
88 views

Connecting an arbitrary number of pins to pin holes without soldering?

I want to avoid soldering for health reasons. I have no well-ventilated open area in my apartment. For a board/modules that have no pins but only holes, how can I connect pins to the holes without ...
3
votes
1answer
142 views

Why do ESP boards break out the SPI flash pins?

I have an ESP32 development board and a NodeMCU board here. Both breaking out the pins for the SPI flash of the ESP. These pins are mentioned in standard pinout descriptions as must/should not connect....
2
votes
1answer
75 views

Arduino doesnt seem to be reading my pin states

I seem to have an unbelievable thing. My code was working perfectly on one arduino, when i upload the same sketch to another one, it is behaving strangely, it seems like it is not reading any of my ...
0
votes
1answer
217 views

What are the best GPIO pins to use for my project?

I'm working on a home automation project to control my Sommer Base+ garage door opener through Home Assistant. The project consists of a WeMos D1 Mini with two reed switches (to detect door open/...
0
votes
1answer
70 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 ...
0
votes
4answers
105 views

Is it dangerous to connect two output pins together?

If I have two output pins, one set high and the other set low with digital or analog write like this digitalWrite(PIN1, LOW); digtialWrite(PIN2, HIGH); and then I short them together using a wire, ...
0
votes
1answer
33 views

What does a tilde (~) mean as annotation for a data pin?

When I examine the datasheet for the Arduino Micro (couldn't find the Pro Micro on their site, btw) then I see some data pins annotated with a ~ character, and some are not. For instance, D9 has a ~ ...
0
votes
2answers
222 views

Put Arduino in DFU mode (no RST pin)

The instructions to put the Arduino into DFU say I should shortcut briefly the 2 leftmost ICSP headers next to the USB port. But my board does not have them. Does anybody know what are the right ...
0
votes
1answer
77 views

ESP 8266 reverse digitalWrite behaviour on which pins?

I am using a device with an ESP 8266 microcontroller. I have discovered that setting LED_BUILTIN to HIGH turns the built-in LED off and setting LED_BUILTIN to LOW turns the built-in LED on. This ...
0
votes
0answers
62 views

Arduino GPIO automatically turns high

I've been trying to turn on 21W bulb with Protected MOSFETS. But somehow the bulbs are getting high automatically from arduino. I've tried all the hardware related things like pull down with different ...
0
votes
0answers
36 views

Adafruit 2.8 TFT LCD Touchscreen 4 wire pins - unclear instructions

Warning - Noob question I am trying to follow the instructions provided by the vendor https://learn.adafruit.com/2-8-tft-touch-shield/touchscreen-paint-example to no avail. Specifically: We ...
0
votes
1answer
46 views

Arduino voltage connection pins

On the Arduino power connector jack, which is the positive terminal pin and the negative pin?
0
votes
1answer
32 views

Using PortB as a sink, not working

Out of ideas here, i try using PB0-3 as sinks for a LED matrix and the pins just won't sink. My test code: void setup() { //bitClear(SPCR, 6); pinMode(PD5, OUTPUT); pinMode(PB0, OUTPUT); ...
0
votes
1answer
198 views

Arduino Nano use SPI pins as I/O pins? and still be able to do ISP?

I wonder if can use the Arduino Nano SPI-pins(MOSI,MISO & SCK) as I/O pins in a sketch? and still be able to program over ISP? Of course I will physical disconnect the Arduino from any other ...
0
votes
1answer
87 views

How to use attachInterrupt() in ATtiny85 with Arduino IDE?

It's possible use external interrupts/attachInterrupt() with the ATtiny85 when I program with Arduino IDE? If is possible, how many inputs (for external interrupts) the ATtiny85 have and which are ...
0
votes
0answers
99 views

Help Needed! How do I attach a color sensor to a 2WD robot and use it to control its movement?

I'm relatively new to the world of Arduino, so don't be frustrated if I ask questions that could be silly. This project has a deadline, so any input is appreciated. THE PROJECT: I am planning to ...
0
votes
1answer
29 views

How to set a not plugged in pin to ground or Low

I have digital pin 7 when set to High it does and when set to low it does not. The only way I can get consistent High or Low is to use a 2 position 3 pin switch with my pin 7 in the middle and ground ...
0
votes
0answers
51 views

ESP8266 GPIO limitations with HC-SR04

I want to build a systems that measures if some parking spots are occupied or not. I chose to use an ESP8266 12-E NodeMCU Kit with multiple HC-SR04 ultrasonic sensors. In my project, it is essential ...
5
votes
3answers
9k views

What to do with Arduino floating pins?

I have some unused pins, should I connect them together and to the ground or leave them floating?
0
votes
2answers
48 views

Read amount of I/Os in code

I want to write an Arduino code, that runs on several different Boards. The code can perform digitalRead/Write operations, but the pin number will be set from the user/outside. I want to include a ...
1
vote
1answer
245 views

What is the equivilent of PORTx for Teensy (4.0)?

I've seen people use code like PORTB |= 0x1 << 6 to set the sixth bit of PORTB in arduino. I understand that this is significantly faster than using digitalWrite. How can this be done using a ...
0
votes
0answers
40 views

How to specify pin in Servo library?

Here's what caused the original confusion. As one know, Arduino nano and UNO use analog pin as PWM pins, while Arduino Mega use digital pin output as the PWM pins, which this webpage ignored to ...
0
votes
1answer
112 views

How to connect HC-06 BT module without pins?

So, from one popular Chinese store I ordered a HC-06 module that I received... and due to some mistake from a store, I received a HC-06 without connecting pins. So usually HC-06 looks like this (with ...
0
votes
1answer
149 views

Multiple variant.cpp entries for same physical pin

Some variant.cpp files have more than one entry that points to the same physical pin. For example (from Arduino Zero's file): // 14..19 - Analog pins // -------------------- { PORTA, 2, PIO_ANALOG, ...
1
vote
1answer
22 views

Help, I want to turn relay constantly on until a difference is detected, but triggered only one instead

Help, I want to use arduino to control relay for electricity, i get data from a sensor and when a value is detected it should be constantly on until another detection triggered again, i can get the ...
-1
votes
2answers
157 views

USING HX711 ( WITH LOADCELL) WITH PCF8574 IN NODEMCU

I have used hx711 and loadcell with nodemcu (esp8266) in its D1 and D2 pins ( here I have used Logic level shifter and a 5v supply to power hx711).It worked perfectly fine. Due to the lack of enough ...
0
votes
0answers
74 views

Unable to get input from Wemos D1 PIR sensor

I am using the script below to create a motion sensor using a Wemos D1 and a PIR sensor. I'm using the ESP8266 Community board manager (V2.6.3). THE PROBLEM When I use the Wemos D1 R1 board no ...
0
votes
0answers
44 views

Non-Linear readings on Analog Pin A0 vs. other Pins A1

I discovered a curios behavior of my Nano v3. The analog Pin A0 seems to measure data in a non-linear way while the other pins seem to work normal. Please have a look at the screenshot. This is the ...
0
votes
1answer
186 views

Trying to read different gas levels with MQ2 Gas Sensor

I found a link on how to connect MQ-2 Gas Sensor to Arduino Uno. http://electronicsprojectshub.com/how-to-connect-mq2-gas-sensor-to-arduino/ After I bought all the parts and tried it out, the sensor ...
0
votes
1answer
211 views

Use JYETech 2.4 Inch LCD Display Screen Module with Arduino?

I have this JYETech 2.4 Inch LCD Display Screen Module that I would like to use for a project I have in mind, however, I'm not sure how to wire it up with my Arudino Mega. Here is the datasheet for ...
-2
votes
1answer
45 views

Can you use a 128 pin LCD on an atMega?

I found a couple old calculators and their LCD's have about 130 pins. I was wondering if I can build an LCD driver to reduce the number of I/O pins, because I don't want to use like 14 I/O extenders; ...
-1
votes
1answer
183 views

4:1: error: expected initializer before 'void' [closed]

int button void setup() { pinMode(13, OUTPUT); pinMode(12, OUTPUT); button 4; pinMode(4=INPUT); } void loop() { if(digitalRead(4)== LOW); { digitalWrite (13, HIGH); delay (250); ...
0
votes
1answer
45 views

Understanding analog pins in pinMode

When passing the pin number in pinMode its possible to use A0 - A7, does it apply only to that methode? How can pinMode expect a number (is it int?) type in case of digital pin another (is it then ...

1
2 3 4 5
9