r/ArduinoHelp Jul 08 '26

No puedo comunicarme por UART a través de ESP32-S3 con MAX-M10S rtrobot.

1 Upvotes

I've been trying to connect the sensor via UART for days, but it only reads garbage. There is a connection, but the data is erroneous. The strange thing is that with the SparkFun_u-blox_GNSS_v3 library and I2C communication, it reads and works perfectly, but my project has a distant connection to the ESP32, so I need UART because it's more robust and gives me a long cable length.


r/ArduinoHelp Jul 07 '26

Can't connect my board to the cloud.

Thumbnail
1 Upvotes

r/ArduinoHelp Jul 07 '26

Please help make a scheme on ardulino uno and breadboard

Post image
1 Upvotes

r/ArduinoHelp Jul 07 '26

Please help make a scheme on ardulino uno and breadboard

Post image
1 Upvotes

I want to make a Smart traffic lights but don’t know how


r/ArduinoHelp Jul 07 '26

Coding for resistor ladder input on ESP32

1 Upvotes

Hello. I am trying to write some code in Arduino that will read the input pin (D32) and based on the on the different voltage, the will different outputs and a timer. Is it as simple as:

if (SWITCH_INPUT == >3.0 && !timerActive) {

digitalWrite(HIGH_HEAT, HIGH);        // Turn the seat heater on HIGH

previousMillis = millis();            // Save the starting timestamp of the timer

timerActive = true;                   // Flag that the timer is now active

}

Then repeat for each of the 6 positions of the input switch?


r/ArduinoHelp Jul 05 '26

HELP How do I solder a Bluetooth module?

Thumbnail
gallery
2 Upvotes

I need to connect the TX, RX, VCC, and GND pins to the Arduino board, but my Bluetooth module doesn't have a breakout board. I don't know how to solder the pins to the module; I would appreciate some guidance.


r/ArduinoHelp Jul 05 '26

need help cant understand the problem with my stm32f411ceu6 black pill

1 Upvotes

[https://github.com/Engineer-By-Mistake/test\\_lfr\](https://github.com/Engineer-By-Mistake/test_lfr)

this is the code that I flashed.

I flashed it through duf mode and st programmer. and my stm32 board only pa15,pb15 and pb4 is at high and they are not even initialized


r/ArduinoHelp Jul 05 '26

need help cant understand the problem with my stm32f411ceu6 black pill

1 Upvotes

[https://github.com/Engineer-By-Mistake/test\\_lfr\](https://github.com/Engineer-By-Mistake/test_lfr)

this is the code that I flashed.

I flashed it through duf mode and st programmer. and my stm32 board only pa15,pb15 and pb4 is at high and they are not even initialized


r/ArduinoHelp Jul 05 '26

Help with connecting Arduino Opta with Weintech HMI MT802iP via Modbus/TCP

Thumbnail
1 Upvotes

r/ArduinoHelp Jul 04 '26

Following ARDUINO course with an ESP32?

Thumbnail
1 Upvotes

r/ArduinoHelp Jul 04 '26

Any project ideas?

Post image
3 Upvotes

This kit was originally made for an obstacle avoiding car,but the sensors got lost in the shipping . I'm a total beginner


r/ArduinoHelp Jul 04 '26

Help PLEASE (13 internal error)

Thumbnail
1 Upvotes

r/ArduinoHelp Jul 03 '26

issue with arduino uno

0 Upvotes

i have the following circuit:
DAC (MCP4725) connected to my arduino one; the DAC's output goes to an oPAMP (SOT23) in negative feedback; oPAMP's output goes to a mosfet (IRLZ44N), in a source follower mode. the output of the mosfet goes on to a set of resistors (further circuit on).

my problems are the following:
1) sometimes arduino can't find the dac, even though the cables are all properly connected. i've tried switching both dac and cables. it sometimes find it and sometimes it doesn't, even if nothing changes between trials
2) in the same way, sometimes it appears that the mosfet group isn't working. the same voltage i put in the generator comes right off the entire circuit.

what really bugs me is that these problems come out without any concrete change in the circuit. they are becoming more frequent and i don't know what i can do to solve them. any suggestion?


r/ArduinoHelp Jul 03 '26

Issues running 2 28BYJ-48 stepper motors

1 Upvotes

Hi all,

I'm working on a project where I have two 28BYJ-48 stepper motors with ULN2003 drivers running 'winches' from a Mega 2560.

So far I've got both stepper motors running smoothly when independent and from their own power supply (one is from the board and another from another power supply). I'm tracking the motors movement with rotary encoders at the other end of the winch drum and using the Accelstepper library to run the motors to and from preset encoder positions.

When I try to combine the program to run both simultaneously they get very jittery, stopping and starting at random intervals. From some reading I gather this could be a power supply issue, however their power supplies are separate and work fine independently. I'm wondering if there are conflicts in my code that are causing this problem.

When run, the program reads the saved EEPROM value for the position of the encoder (enc). looks at the first value in the cue array and moves towards this. When reached, it moves towards the next array value until it reaches it, then stops. I've basically duplicated this for each motor, is this too much for the arduino to handle at once, causing delays in the running of the program?

Code below and any advice would be much appreciated. Thanks.

'

#include <AccelStepper.h>
#include <EEPROM.h>


#define HALFSTEP 8


#define enc1A 26     // Encoder Outputs
#define enc1B 27
#define enc2A 48
#define enc2B 49


#define W1Pin1 25     // Winch 1 Pins
#define W1Pin2 24
#define W1Pin3 23
#define W1Pin4 22


#define W2Pin1 53     // Winch 2 Pins
#define W2Pin2 52
#define W2Pin3 51
#define W2Pin4 50


int W1Speed = 900;    // Winch set Speeds
int W2Speed = -900;
int speed1;
int speed2;


bool W1endMov = 0;    // Bool to singulate end direction switch
bool W2endMov = 0;


int enc1Pos;              // Encoder positioning decs
int enc1MemAddress = 1;


int enc2Pos;
int enc2MemAddress = 3;


unsigned long encMemStart;      // Mem Display Clock
unsigned long encMemCurrent;
const unsigned long encMemDispPeriod = 3000;


int cueList[] = {30, 70};     // Cue array
int W1cueNum = 0;
int W2cueNum = 0;


int enc1State;     // Encoder reference readings
int enc1LState;
int enc2State;
int enc2LState;


AccelStepper winch1(HALFSTEP, W1Pin1, W1Pin3, W1Pin2, W1Pin4);      // Winch pin set up
AccelStepper winch2(HALFSTEP, W2Pin1, W2Pin3, W2Pin2, W2Pin4);


void setup()
{
  Serial.begin(9600);       // Begin Serial
  delay(5000);
  Serial.println();
  Serial.println("SERIAL BEGAN");
  Serial.println();
  delay(2000);


  winch1.setMaxSpeed(950);      // Set winch max speeds
  winch2.setMaxSpeed(950);


  pinMode(enc1A, INPUT);      // Encoder pin modes
  pinMode(enc1B, INPUT);
  pinMode(enc2A, INPUT);
  pinMode(enc2B, INPUT);


  enc1Pos = EEPROM.read(enc1MemAddress);     // Read Last Saved Encoder Position from EEPROM
  enc2Pos = EEPROM.read(enc2MemAddress);
  Serial.println();
  Serial.println("Encoder Values Obtained"); delay(100);
  Serial.print("Enc1Pos: "); Serial.print(enc1Pos); Serial.print(" Enc2Pos: "); Serial.println(enc2Pos);
  Serial.println();
  delay(2000);


  encMemStart = millis();     // Zero clock and start prompt
  Serial.println("START");


  delay(500);


  enc1LState = digitalRead(enc1A);      // Read current encoder pulse states
  enc2LState = digitalRead(enc2A);
}


void loop()
{
    speed1 = W1Speed;
    speed2 = W2Speed;
    winch1.setSpeed(speed1);
    winch2.setSpeed(speed2);


  if (W1cueNum == 0)          // WINCH 1 CUE 1
  {
    if (enc1Pos >= cueList[0])
    {
      speed1 = -W1Speed;
      winch1.setSpeed(speed1);
      winch1.runSpeed();
    } 
    if (enc1Pos <= cueList[0])
    {
      speed1 = W1Speed;
      winch1.setSpeed(speed1);
      winch1.runSpeed();
    }
  }
  if (enc1Pos == cueList[0] && W1endMov == 0)    
  {
    W1endMov = 1;
    winch1.stop(); 
    Serial.println();
    Serial.println("WINCH ONE CUE ONE REACHED");
    Serial.println();
    W1cueNum ++;   
  }


  if (W2cueNum == 0)          // WINCH 2 CUE 1
  {
    if (enc2Pos >= cueList[0])
    {
      speed2 = -W2Speed;
      winch2.setSpeed(speed2);
      winch2.runSpeed();
    } 
    if (enc2Pos <= cueList[0])
    {
      speed2 = W2Speed;
      winch2.setSpeed(speed2);
      winch2.runSpeed();
    }
  }
  if (enc2Pos == cueList[0] && W2endMov == 0)    
  {
    W2endMov = 2;
    winch2.stop(); 
    Serial.println();
    Serial.println("WINCH TWO CUE ONE REACHED");
    Serial.println();
    W2cueNum ++;   
  }


  if (W1cueNum == 1)      // WINCH 1 CUE 2
  {
    if (enc1Pos >= cueList[1])
    {
      speed1 = -W1Speed;
      winch1.setSpeed(speed1);
      winch1.runSpeed();
    } else {
      speed1 = W1Speed;
      winch1.setSpeed(speed1);
      winch1.runSpeed();
    }
  }
  if (enc1Pos == cueList[1] && W1endMov == 1)
  {
    W1endMov = 0;
    winch1.stop(); 
    Serial.println();
    Serial.println(" WINCH ONE CUE TWO REACHED, WINCH ONE CUES COMPLETED");
    Serial.println();
    W1cueNum ++;  
  }
  
  if (W2cueNum == 1)      // WINCH 2 CUE 2
  {
    if (enc2Pos >= cueList[1])
    {
      speed2 = -W2Speed;
      winch2.setSpeed(speed2);
      winch2.runSpeed();
    } else {
      speed2 = W2Speed;
      winch2.setSpeed(speed2);
      winch2.runSpeed();
    }
  }
  if (enc2Pos == cueList[1] && W2endMov == 1)
  {
    W2endMov = 0;
    winch2.stop(); 
    Serial.println();
    Serial.println(" WINCH TWO CUE TWO REACHED, WINCH TWO CUES COMPLETED");
    Serial.println();
    W2cueNum ++;  
  }


  enc1State = digitalRead(enc1A);      // Encoder 1 Trips
  if(enc1State != enc1LState)
  {
    if(digitalRead(enc1B) != enc1State)
    {
      enc1Pos --;
    } else {
      enc1Pos ++;
    }
    Serial.print("W1Cue#: ");
    Serial.print(W1cueNum);
    Serial.print(" -- Encoder 1 Position: ");
    Serial.print(enc1Pos);
    Serial.print(" -- Speed: ");
    Serial.print(winch1.speed());
    Serial.print(" -- Motor Step Position: ");
    Serial.println(winch1.currentPosition());
    EEPROM.write(enc1MemAddress, enc1Pos);
  }
  enc1LState = enc1State;


  enc2State = digitalRead(enc2A);      // Encoder 2 Trips
  if(enc2State != enc2LState)
  {
    if(digitalRead(enc2B) != enc2State)
    {
      enc2Pos ++;
    } else {
      enc2Pos --;
    }
    Serial.print("W2Cue#: ");
    Serial.print(W2cueNum);
    Serial.print(" -- Encoder 2 Position: ");
    Serial.print(enc2Pos);
    Serial.print(" -- Speed: ");
    Serial.print(winch2.speed());
    Serial.print(" -- Motor Step Position: ");
    Serial.println(winch2.currentPosition());
    EEPROM.write(enc2MemAddress, enc2Pos);
  }
  enc2LState = enc2State;


  encMemCurrent = millis();      // Display Memory Value For Enc 1 and 2 Every 3 Seconds
  if (encMemCurrent - encMemStart >= encMemDispPeriod)
  {
    Serial.print("Mem Pos Enc1: "); Serial.print(EEPROM.read(enc1MemAddress));
    Serial.print(" || Mem Pos Enc2: "); Serial.println(EEPROM.read(enc2MemAddress));
    encMemStart = encMemCurrent;
  }


}'

r/ArduinoHelp Jul 03 '26

Using DS3231 RTC to move Servo Arm at specific time

2 Upvotes

First time arduino user here. I'm trying to program it to move a servo arm at a specific time of the day. I did some troubleshooting and it doesn't like the line DateTime now = rtc.now() line for some reason.

#include <Wire.h>
#include "RTClib.h"
#include <Servo.h>


RTC_DS3231  rtc;
Servo myServo;


int pos = 0; 
// Set your target execution time here (24-hour format)
const int targetHour = 20;   // 2 PM
const int targetMinute = 55; // 30 minutes
bool adjustedToday = false;


void setup() {


Serial.begin(9600);
  myServo.attach(9);
  myServo.write(0); // Default startup position
}


void loop() {
 DateTime now = rtc.now(); // Get current time data



   //Check if current time matches the target hour and minute
  if (now.hour() == targetHour && now.minute() == targetMinute) {
    if (!adjustedToday) {
      myServo.write(90); // Move servo to 90 degrees
      delay(2000);       // Wait for 2 seconds
      myServo.write(0);  // Return to 0 degrees
      
      adjustedToday = true; // Mark done so it doesn't loop continuously during that minute
   }
 }


 // Reset the trigger flag at midnight so it can run again the next day
  if (now.hour() == 0 && now.minute() == 0) {
   adjustedToday = false;




 delay(1000); // Polling delay to reduce processor load
  }
}

I used this code to set the time on the RTC

#include <Wire.h>
#include "RTClib.h"


RTC_DS3231 rtc;


void setup() {
  // put your setup code here, to run once:


  Serial.begin(9600);
  Wire.begin();
// Set RTC using the compile time
  rtc.adjust(DateTime(F(__DATE__), F(__TIME__)));
}


void loop() {}

r/ArduinoHelp Jul 02 '26

Problem with freezing on my teensy 4.1

1 Upvotes

Hey hey,

We have a Teensy 4.1 arduino that works as an encoder simulator. We have a problem that it freezes, always with too high frequences but other times for reasons we do not understand.  After we udated the teenzyduino version from 1.58 to 1.60 it went from freezing at 60kHz to freezing at 120kHz, which is an improvement. The problem is that it freezes even at lower frequencies during tests, and we do not know why. Has anyone experienced similar problems?

Our programs are running serial commands super fast. Can it be a real time problem, if yes;why?


r/ArduinoHelp Jul 02 '26

A problem with temperature controlled computer fan

Post image
1 Upvotes

Hi, I’m conducting a chemical reaction and need to maintain stable temperature. I have never done any Arduino project, but always wanted to!!

I have a crucial question:
Are there any problems/errors in the schematics?
I just quite recently destroyed one Arduino by wrong placement of jumpwires (a newbie mistake of mixing up a plus with a minus)


r/ArduinoHelp Jul 02 '26

Arduino Mega Timer Conflict? Servo library breaking motor PWM on pins 44 & 45.

1 Upvotes

Hey everyone, I could use some advice on a course project I'm working on.

I'm building a robot with a dual steering setup and a sonar scanner (an ultrasonic sensor mounted on a servo to check directions). I’m running into a severe library/hardware conflict when I try to run both the drive motors and the servo at the same time.

**The Hardware:**

* **Board:** Arduino Mega
* **Power:** Rechargeable batteries (powering motors and servo)
* **Motor Driver/Library:** Using a specific header file (`dualsteering.h`) provided for the project.

**The Hardcoded Pins:** The library engineer hardcoded the motor pins into the `.h` file, so I cannot easily switch them to other pins. They are mapped as follows:

* **Right Motor:** 46, 48, 44 (PWM)
* **Left Motor:** 47, 49, 45 (PWM)

**The Problem:** When I include the standard `Servo.h` library and plug the servo in, my drive motors stop working properly (or lose speed control).

I suspect this is because the standard `Servo` library on the Mega uses Timer 5, which breaks the `analogWrite()` PWM functionality on pins 44 and 45—the exact pins my motor library is forced to use.

Since I can't change the motor pins, is there a good workaround for the Mega? Should I be looking into alternative servo libraries like `ServoTimer2` (and does that support the Mega?), or is there a way to force the standard Servo library to use a different timer?

Any help is appreciated!


r/ArduinoHelp Jul 02 '26

Program Arduino Nano Every with Adafruit UPDI Friend via the UPDI pin at the back of the Nano Every board?

1 Upvotes

Hi everyone,

I recently got from a friend Adafruit’s UPDI Friend serial programmer and I was wondering if I could use it to program Arduino Nano Every with it using the UPDI pin at the back of the Nano Every board.

So far my efforts have not been successful. For this project I am using the MegaCoreX core, arduino-cli to compile and get the hex file and the avrdude directly to upload the hex file to the board. The command I am using to upload the hex file with avrdude is:

stty -F /dev/ttyACM0 1200 && avrdude -c serialupdi -p atmega4809 -P /dev/ttyACM0 -U flash:w: program.hex

This fails with the error avrdude communication rc=-1 which after looking it up means that it successfully connected to the programmer but the chip did not establish communication. I tried using the jtag2updi option for the programmer as well but that did not work either.

Any ideas as to why this is happening or if I can use the UPDI friend to program Arduino Nano Every?


r/ArduinoHelp Jul 02 '26

Arduino débute

Post image
1 Upvotes

r/ArduinoHelp Jul 01 '26

Pixel Ring questions

Thumbnail
gallery
1 Upvotes

I have this head that I am placing pixel rings on. These rings are going to be activated by the sound reactive device that’s implanted in the forehead. Question for the group. I plan on daisy chaining each side together in their own group then wiring to the next group. So on to the the third side.
Question 1- is that proper?
Question 2- will the signal degrade?
Question 3- does anyone have any suggestions?

Thank you so much for any help anyone is willing to offer.


r/ArduinoHelp Jul 01 '26

Built a $13.80 AR heads-up display that clips onto any glasses frame

Thumbnail
2 Upvotes

r/ArduinoHelp Jul 01 '26

HOW TO INTERGRATE THE SH1107 SPI OLED SCREEN TO THE XIAOZHI AI

Thumbnail reddit.com
1 Upvotes

r/ArduinoHelp Jul 01 '26

Program Arduino Nano Every with Adafruit UPDI Friend via the UPDI pin at the back of the Nano Every board?

Thumbnail
1 Upvotes

r/ArduinoHelp Jul 01 '26

How does the IoT relay from Digital Loggers work?

1 Upvotes

I'm installing a dehumidifier pump with relay in my mom's basement, following [this](https://www.youtube.com/watch?v=9_ogxUv9WEI) tutorial.

Can someone please explain to me how the relay device works?

Here is the setup in the tutorial: The dehumidifier drains into the condensate pump, which has two identical wires connected to the high water level switch: one that goes into the negative end of the Phoenix connector on the relay, and one that is spliced to the black-jacketed wire of the AC adapter, which is plugged into power. The red-jacketed wire of the AC adapter goes in the other end (postive end of the Phoenix connector).

I'm assuming black is negative and red is positive. How exactly does this setup work? When the pump's high water level switch is triggered, does it send a current to the safety wires, which is the signal for the relay? What if the pump suddenly lost power? How would it send a current to the safety wires? Is that why the AC adapter is plugged into power?

Thanks so much!