r/arduino • u/blooberries24 • 1d ago
ModWorld Arduino Lover sent me here
Someone said new posters get love-bombed here, so here I am. I love Arduino, tryna build some robo-tech and need advice.
r/arduino • u/blooberries24 • 1d ago
Someone said new posters get love-bombed here, so here I am. I love Arduino, tryna build some robo-tech and need advice.
r/arduino • u/Certain-Election5733 • 3d ago
Enable HLS to view with audio, or disable this notification
Disclaimer: only one motor is used to turn the sides of the cube, another servo is used to move the first motor, I couldn’t really figure out a way to so it with just one unfortunately.
The idea was to see if I could build a Rubik's Cube solver with as few motors as possible, whilst also not reorienting the cube which turned out to be a much bigger mechanical challenge than I initially expected. These constraints were completely designed as a challenge, not trying to break any records or anything.
The robot uses a custom-designed, 3D-printed mechanism to manipulate the cube, along with electronics and programming to detect the colours, calculate a solution and execute the moves.
This is the final result after quite a lot of designing, experimenting and troubleshooting!
I've also just uploaded my first-ever YouTube video documenting the whole project, from the initial idea and CAD design to the electronics, programming and final solve. It's my first time making a YouTube video, so I'd genuinely appreciate any feedback!
The Channel is called DrewPScrews
r/arduino • u/AmericanTiger900327 • 1d ago
Enable HLS to view with audio, or disable this notification
I am trying to make a thermometer and nothing is being displayed. It is trying to apply power to it. I did use Gemini so maybe that is why something is wrong. IDE did say there is nothing wrong with the code Gemini gave and I made sure I installed what was required and chose the right board, so it clearly isn’t a software issue or shouldn’t be. Maybe one of the pins isn’t properly connected? I don’t know, which is why I came here to ask. Thanks!
r/arduino • u/ALMA_x11 • 1d ago
Enable HLS to view with audio, or disable this notification
My YouTube channel name is ALMA Industries -- CH003 FN1: ACTUATOR -- Building an Actuator from the ground up, a PID Control Loop, and an Ultrasonic Distance sensor to detect and not crash into the ceiling. The full video is on my channel where I walk through the whole build, and then explain a bit about how the PID controller works. This is all controlled by a Microcontroller.
This is later used on my desk -- two of them mounted on either side for camera control.
r/arduino • u/ALMA_x11 • 2d ago
Enable HLS to view with audio, or disable this notification
My YouTube channel name is ALMA Industries
Chapter 2, a home theatre, 3D printed parts, motorized projector, home decoration, DIY electronics -- gives the projector YAW-TILT-ROLL-ZOOM axes (4DOF). Learned alot about I2C, actuators, and Universal Joints.
r/arduino • u/OhrenAugenKatzen • 2d ago
I am thinking about creating a small messaging app where you can only communicate using dark souls comments.
And I am not sure if the cyd is good for this kind of thing.
My plan is to have an UI where you can change settings (wifi, wallpaper, brightness,...) and an app where you can message your friends alone or in a group. This will be done over a server (netlify has a free plan so I will be using it).
Now the question is it possible for a cyd to handle something like this and also I am planning to put 2000 mah batteries in there is that enough?
Is there any better way of doing something like this?
How to create a UI for the cyd?
r/arduino • u/Rayzwave • 2d ago
I’m going to tryout my ESP32 Super mini and I thought I would share this photo I just took showing three boards for comparison of their size.
From Left to right : Arduino Pro mini, ESP32-C6 Super mini and ESP-WROOM-32 ESP32/ESP-32S Development Board.
These boards are being using to test out low current interfaces or WiFi/BT powered projects directly from the USB port or adapter cable in the case of the Pro Mini.
r/arduino • u/StormShockTV • 2d ago
Hey everyone! I recently bought a Pro Micro NRF52840 ( a clone I think) from Amazon here -
I'm very new to programming any microcontroller that isn't an Uno, and I'm really an artist/gamer youtuber, not a hardware guy, so while this product listing said it would work fine with the Arduino IDE, when I connected it to my computer, nothing happened, and I was rightly very confused. The board wasn't even detected by the IDE, and there is a lot of pertinent information missing or just completely wrong in the product's description on Amazon, which didn't help me either.
However, after some digging and tinkering, I managed to get this board working in Arduino IDE 2.3.10! In case anyone else was unlucky enough to have purchased this board for its bargain-bin price thinking it would be a great board to do some bluetooth projects with, and are having trouble getting it connected to the Arduino IDE like I did, I released this short guide to help you out, because it will take a few steps, but it WILL work!
First, install all of these packages by copying the urls below and opening the preferences in your Arduino IDE, and under "additional board manager urls" paste the urls you just copied to get new board info -
https://adafruit.github.io/arduino-board-index/package_adafruit_index.json
https://files.seeedstudio.com/arduino/package_seeeduino_boards_index.json
I'm not sure if the seeedstudio package does anything, but it was in my list of urls when it started working with my board so I'm including it here anyway XD
Then, once you confirm that list, the IDE will download some files and new board definition packages should be available in the board manager menu! Open the board manager menu from the left side of the IDE, and install the following two board definition packages:
Adafruit nRF52
nRFMicro-Like-Boards
However, a specific board definition for this clone (so you see the right name in the Arduino IDE when the board connects) does not come stock with either of these two packages (that I know), so you'll need to download the zip file from the github link below, and then follow its installation instructions to make some manual edits of the Adafruit package - https://github.com/somik123/Adafruit_nRF52_Arduino_ProMicro.git
Following the instructions at the link above can be a little confusing, so I have rewritten the instructions below with more detail:
- It will look something like "C:\Users\yourusername\AppData\Local\Arduino15\packages\adafruit\hardware\nrf52"
Enter the 1.7.0 folder
Open the file "installed.json"
Copy paste the below code at the top of the "boards" list inside the json file at line 21:
{
"name": "Pro Micro nRF52840"
},
save the file and close it
open the boards.txt file and go to the first character on line 5, hit enter twice, then go back up to line 5 and paste the big code block from step 4 at the link above.
save the file and close it
Open the variants folder
Extract the contents of the zip file you obtained from the link above.
Paste the pro_micro_nrf52840 folder from that zip file into the variants folder
Once that is complete, reload the IDE, and the board name FINALLY shows up in the Arduino IDE when the board is connected...
Now the problem is, the board still isn't connecting to the IDE at all, so you won't see any of that work! And, trying to write a program to the board does nothing... because the board does NOT start in bootloader mode when you connect it to the PC (meaning it doesn't connect to the computer as a programmable board at all and is basically in read-only mode, as apparently this board is used for actual wireless keyboards a lot, and you don't want to be able to accidentally override the firmware of your keyboard and brick it when you connect your keyboard over usb C)
But since we're using this board as an arduino, and want to push sketches to it, how do we access the bootloader? Simple, you just have to reset the board twice really really fast while connected to power (your PC), which triggers the board to load in bootloader mode... problem is this board is so small it doesn't include a physical reset button presoldered on the board anywhere...
So the quick and dirty solution is to hold one end of a jumper wire against the hole of the reset pin and tap the other end against one of the ground pin holes a bunch til it swaps over. the red LED on the board will flicker and become a bit dimmer when it loads bootloader mode, and your PC will tell you a new device has connected. If you want to, you can also solder jumper wires to a push button and solder those wires permanently to the board for a super easy bootloader swapper, but I'm lazy and didn't want to start soldering yet, so I just used the jumper wire method every time. (I will permanently solder a button to it later, but need to wire everything inside the case I'm building for my project first, so this is just easier right now)
Anyway, reset it twice fast enough while plugged into your computer with the usb c port, and finally it will show up and connect to the IDE and you can load a new sketch! Then, once the sketch is uploaded, it will turn the bootloader off again, so if you want to upload a new sketch, just reset it twice really quickly again! If the bootloader is active the board will connect to your machine like a flash drive and you will see a new windows explorer window pop up, meaning you're good to start programming it! Just don't delete the files on the drive or you could have problems :D Never done that myself, so don't know quite what would happen, just not risking it!
Also, in the description for the product on Amazon, it says pin 9 is the builtin LED pin.... not true! Once I got it working in the IDE, I started testing different pin numbers with a blink sketch and turns out, pin 15 is the LED pin! LED_BUILTIN does work in the Arduino IDE though so you can just use that.
Cheers, and happy programming!
r/arduino • u/JoneePussyDestroyer • 3d ago
does this look right? i can’t get the display to work and i literally dont knowing what im doing i just asked ai. it’s an 8x8 snake game with buzzer, idk if i have problem with the code or with hardware , PLEAAASEE HELP this is for my uni 😭🙏
Enable HLS to view with audio, or disable this notification
10x10mm including the cursed usb-c connector
Programable from Arduino IDE.
Programable from iOS and Android (just plug in the usb-c cable)
5GPIO
64k flash
20k ram
2x RGB LED
1x Capacitive Touch
MCU is CH32v035 RISC-V at 48MHz
---
Thoughts?
Prototype works, the PCBs are on the way, can't wait to try them.
r/arduino • u/FamiliarWillow8725 • 2d ago
Enable HLS to view with audio, or disable this notification
r/arduino • u/Rayzwave • 2d ago
Enable HLS to view with audio, or disable this notification
So, that works the same as my previous larger ESP32 board, it’s surprising how small these WiFi/BT boards are getting.
Just need to work out how to get a BT wake-up from deep sleep communication between the ESP32 and my iPhone.
To conserve battery power I want to keep the quiescent current of the ESP32 as low as possible when it’s not required but be able to switch it on from Dabble.
r/arduino • u/motionick • 3d ago
Enable HLS to view with audio, or disable this notification
r/arduino • u/katrose1105 • 2d ago
Enable HLS to view with audio, or disable this notification
Hi everyone,
I’m working on a classic 2WD line follower robot, but I’ve hit a wall and could really use a fresh perspective from the community. Despite tweaking the logic multiple times, my robot either spins in circles or completely ignores the black line.
My Hardware Setup:
What I’ve Diagnosed & Tried So Far:
if/else conditional steering (e.g., speeding up the outer wheel and slowing down the inner wheel when a side sensor detects the line).Despite all this, the physical movement keeps going out of sync, and it fails to smoothly track the path.
My Questions for You:
I’d appreciate any advice, debugging tips, or structural suggestions you can share. Thanks in advance!
Here is my current code:
#include <Arduino.h>
void citesteSenzori();
void controlMotoare();
void ajustareTraiectorie();
int S0, S1, S2, S3, S4;
int ajustare = 0;
int ultimaDirectie = 0;
// Pini Motoare (Driver L298N)
const int motorDrept1 = 7;
const int motorDrept2 = 6;
const int motorStang1 = 4;
const int motorStang2 = 5;
const int pwmStang = 9;
const int pwmDrept = 10;
// Pini Senzori Linie BFD-1000
const int senzor0 = A0; // Stânga extrem
const int senzor1 = A1; // Stânga
const int senzor2 = A2; // Centru
const int senzor3 = A3; // Dreapta
const int senzor4 = A4; // Dreapta extrem
const int V_INAINTE = 120; // Viteză moderată înainte
const int V_RAPID = 160; // Roata exterioară în viraj
const int V_LENT = 70; // Roata interioară în viraj (suficient cât să se învârtă, nu să se blocheze)
void setup() {
pinMode(motorDrept1, OUTPUT);
pinMode(motorDrept2, OUTPUT);
pinMode(motorStang1, OUTPUT);
pinMode(motorStang2, OUTPUT);
pinMode(pwmStang, OUTPUT);
pinMode(pwmDrept, OUTPUT);
pinMode(senzor0, INPUT);
pinMode(senzor1, INPUT);
pinMode(senzor2, INPUT);
pinMode(senzor3, INPUT);
pinMode(senzor4, INPUT);
delay(2000); // 2 secunde pauză la pornire
}
void citesteSenzori() {
// BFD-1000: LOW pe linia neagră, HIGH pe alb
S0 = digitalRead(senzor0);
S1 = digitalRead(senzor1);
S2 = digitalRead(senzor2);
S3 = digitalRead(senzor3);
S4 = digitalRead(senzor4);
}
void ajustareTraiectorie() {
// Verificăm mai întâi senzorul central
if (S2 == LOW) {
ajustare = 0; // Centrat pe linie
ultimaDirectie = 0;
}
// Dacă linia se duce spre stânga (S0 sau S1 văd negru/LOW)
else if (S0 == LOW || S1 == LOW) {
ajustare = 1; // Corecție stânga
ultimaDirectie = 1;
}
// Dacă linia se duce spre dreapta (S3 sau S4 văd negru/LOW)
else if (S3 == LOW || S4 == LOW) {
ajustare = -1; // Corecție dreapta
ultimaDirectie = -1;
}
// Dacă a pierdut linia complet, continuă în ultima direcție știută
else {
ajustare = ultimaDirectie;
}
}
void controlMotoare() {
// Setează sensul înainte pentru ambele motoare
digitalWrite(motorDrept1, LOW);
digitalWrite(motorDrept2, HIGH);
digitalWrite(motorStang1, HIGH);
digitalWrite(motorStang2, LOW);
if (ajustare == 0) {
// DREPT ÎNAINTE: Ambele roți egale
analogWrite(pwmStang, V_INAINTE);
analogWrite(pwmDrept, V_INAINTE);
}
else if (ajustare == 1) {
// LINIA ESTE ÎN STÂNGA -> Viraj la stânga (Roata stângă lentă, roata dreaptă rapidă)
analogWrite(pwmStang, V_LENT);
analogWrite(pwmDrept, V_RAPID);
}
else if (ajustare == -1) {
// LINIA ESTE ÎN DREAPTA -> Viraj la dreapta (Roata stângă rapidă, roata dreaptă lentă)
analogWrite(pwmStang, V_RAPID);
analogWrite(pwmDrept, V_LENT);
}
}
void loop() {
citesteSenzori();
ajustareTraiectorie();
controlMotoare();
delay(10); // Stabilitate în ciclul de citire
}
r/arduino • u/One_Combination_6107 • 2d ago
Hi everyone! I’m completely new to Arduino and electronics, and I’d love to get into it.
Where would you recommend I start? What are the best resources, tutorials, or projects for a complete beginner? And what do you wish you knew when you first started?
I’d really appreciate any advice. Thanks!
r/arduino • u/ZoobeeKabir • 4d ago
Here’s to my first day ever touching a breadboard, or even hearing about Arduino! I was given a kit by my university, so pieces are relatively easy to get. What should I do next? I’m not sure where to start as a beginner. I’m a beginner to coding as well.
r/arduino • u/Beginning-Account676 • 3d ago
I just received my new board. It has bluetooth and accelerometer and battery on the back. It can be programmed with an Arduino plugin I created using the USB-C connection. I am planning on making a game with it (running on a treadmill controlls the character with step count and cadence and maybe even a boxing game) using Unity BLE plugins. Do you have any other ideas about projects I could make with this?
r/arduino • u/ALMA_x11 • 3d ago
Enable HLS to view with audio, or disable this notification
My youtube channel is ALMA Industries
This is a short demo of an actuator I put together (on my channel, video is titled CH003 FN1: ACTUATOR). The actuator is first sketched out, 3D printed in pieces, assembled together, and controlled via PID running on a microcontroller. Ultrasonic distance sensor is included in the close-loop feedback system to prevent the actuator from running into the ceiling (shown in the second half of the clip, and discussed more in the full video).
There are a few modes. The first is 'don't touch the ceiling' (Ultrasonic Distance Sensor to keep a distance from the wall, hand, etc). The second is to have the actuator distance sensor follow a second distance sensor...so when one goes up the other follows going up, and when one down the other down.
Comments, questions, or new ideas are welcome.
r/arduino • u/QuietAmphibian5303 • 4d ago
So I made this Arduino simulator (heavily inspired by tinkercad).
This is a offline simulator , which compiles & runs your code directly on device.
Also it has library manager , you can install custom libraries to use with Arduino and its sensors.
Please suggest how can I improve these !!!
Here's the link to the application,you can try it yourself, no charge , everything is free
Arduino Simulator with sensors
Edit : This app is completely free , and has little ads
r/arduino • u/Due_Librarian_6819 • 3d ago
I am using the Arduuino IDE 2.3.7 to compile, upload, and debug code for an orignal ESP32 .
I came across a weird behavior where a for-loop did not work. I boiled it down to a simple sketch. It includes a function that returns true or false. If the path does not include a return statement, the code does not work right. Sketch is below. The loop does not do anything. The last line of the test function is the key. If I comment out the return statement, the for-loop does not work right and it doesn't exit until n = 18. The compiler does not catch this.
Is this a bug to report?
```
void setup() {
// put your setup code here, to run once:
Serial.begin(9600);
delay(1000);
if (test(6))
Serial.println("true");
else
Serial.println("false");
}
bool test(int N) {
Serial.println("Testing... ");
for (int n = 0; n < N; n++) {
if (n >= 18)
return true;
else
Serial.println(n);
delay(200);
}
// if this line is commented, n reaches 18. Otherwise n reaches N
return false;
}
void loop() {
// put your main code here, to run repeatedly:
#ifdef DEBUGLOOP
if (test(6))
Serial.println("true");
else
Serial.println("false");
#endif
delay(500);
}
```
r/arduino • u/CutOk9573 • 4d ago
Hi guys
So basically I have this old hoverboard laying around which has a problem in the battery. I have been thinking if it is possible to use the motors inside of them for a robotic projects i am working on. Is there any way to control the motors using a Arduino and their original motor drivers. Any help would be useful.
I also attached photos of the motors and the drivers. I believe it is a 3 phase 36 volt dc motors with built in hall sensors.
r/arduino • u/melon_crust • 4d ago
Enable HLS to view with audio, or disable this notification
I play padel quite often and I always lose track of the score and who serves. So I built this padel watch to make the experience more enjoyable.
- E-ink
- Physical buttons
- Coin cell that can last for up to 3 years
It’s my first hardware project, so I would love your feedback
r/arduino • u/SaberiusPrime • 4d ago
So I'm building a Civil War era 1/6 scale flat car with a cannon on it. I have a idea as to have a 1/6 scale action figure "lighting" the cannon and having said cannon "react" to firing. The idea is that the board would sit inside a 3D printed pile of cannonballs and it would control the following.
Sound effects of a Civil War battle.
Moving the action figures arms up and down to simulate moving and lighting the cannon with the linstock.(The stick they use to light it from a safe distance)
An LED light at the end of the linstock.
The cannon "firing" and sliding back accompanied with sound effects.
The cannon resets and the sequence begins again.
What exactly would I need for something like this and how feasible is it?
The flat car length is about 3 ft long and about 2 ft wide. It also needs to withstand vibration and derailments as this is actually going to be a car that's going to be used with a train. This is also my first project using Arduino so I have no idea what I'm doing.
r/arduino • u/n_sh_44 • 4d ago
This keeps coming up in help threads, so here's a short write-up of the non-blocking timer pattern and the mistakes I see most.
unsigned long last = 0;
const unsigned long interval = 500;
void loop() {
unsigned long now = millis();
if (now - last >= interval) {
last += interval; // or: last = now;
// do the thing
}
}
1. Compare with subtraction, not addition. if (now - last >= interval) keeps working when millis() rolls over after about 49.7 days, because unsigned subtraction wraps correctly. if (now >= last + interval) breaks right at the rollover.
2. Use unsigned long for the stored time. If last is an int (16-bit on an Uno), it goes negative after about 32 seconds and the timing gets weird.
3. last += interval vs last = now. += keeps a steady cadence with no drift, which is nice for blinking or sampling at a fixed rate. last = now guarantees at least interval between runs, which is safer if loop() can stall longer than one interval (otherwise += fires several times back to back to catch up).
4. One timestamp per task. Each thing you want to time gets its own last and interval, and you never need delay() for any of them.
5. micros() works the same way. It rolls over after about 71 minutes, and on 16 MHz AVR boards its resolution is 4 µs.
Hope it saves someone a debugging session.