Welcome to The Bored Robot, your premier destination for hobbyists, students, and enthusiasts eager to explore the world of practical robotics and engineering.
As a passionate advocate for hands-on learning, I've had the privilege of instructing undergraduates in robotics and participating in innovative projects. This channel is a testament to the digital age of education, providing instructional videos and project presentations.
Join me on a journey where we simplify the world of robotics and engineering, making it accessible to everyone. Together, let's unlock the potential of creativity and knowledge.
Don't miss out-subscribe now, and let's embark on an adventure of exploration, creation, and enlightenment together!
Hi, can you please add the detail and specs about material used in description of video. Like Motor (voltage/current) rating, battery (voltage/current) rating, Type of Arduino used etc. Thanks.
This is what I needed to know, thanks a lot. I'm building a solar tracking system but didn't know how to get info about the photoresistors. If you had any code for solar tracking using photoresistors and a linear actuator I'd really appreciate it.
Thank you so much for the content 🙏🏻 I want to ask, can the program be used if using a 3 phase AC motor and using a relay as the contactor? Thank you in advance🙏🏻
As others have said your code explanation is excellent! I am thinking of implementing this to control three ball valves - I just need to know do stepper motors have free movement when unpowered? I ask this as I need to consider how I can provide manual override in the event of power failure or other faults. In your opinion would stepper motors be suitable for my use case? Thanks
Stepper motors can move freely when they are unpowered. They will hold their torque when powered. They are generally used when precision is required. It's hard to say if this is best for your use case without knowing more. If the movement is just and open and close, perhaps a solenoid can be an easier option?
@@TheBoredRobotLLC Thanks, I was hoping that would be the case. It sounds like steppers may be my best option as I need fine control of opening %. The specific kind of valve is a 180 degree throw metering valve (to achieve a more linear relationship with opening % and flow than a regular ball valve).
Is there a way for us to find The script for your arduino program, so we can copy and paste? The library I downloaded only shows "blocking", unlike in the video's "blocking_fixed_position"
@@trilinh9169 I don't exactly know exactly what you're asking here. If the equation you're trying to follow is y=sin(t), where t is some value for time, then y is the value that will be your desired set point in the PID controller.
The code for those who want to try it out : import serial import matplotlib.pyplot as plt from matplotlib.animation import FuncAnimation import csv # Constants SERIAL_PORT = 'COM4' BAUD_RATE = 115200 # Initialize serial connection ser = serial.Serial(SERIAL_PORT, BAUD_RATE) # Initialize empty list to store data x_vals = [] sensorValue_data = [] # Create a function to raed and process data from Arduino def read_and_process_data(): line = ser.readline().decode('utf-8').strip() sensorValues = line.split(',') x_vals.append(float(sensorValues[0])) sensorValue_data.append(int(sensorValues[1])) # Print the received values print(f'Time: {sensorValues[0]}, Sensor 1: {sensorValues[1]}') # Creat a function to update the plot def update_plot(frame): read_and_process_data() plt.cla() plt.plot(x_vals, sensorValue_data, label='Sensor') plt.xlabel('Time') plt.ylabel('Sensor value') plt.legend() # Creat a function to save data to a CSV file when the plot window is closed def on_close(event): with open('arduino_data.csv', 'w', newline='') as csvfile: writer = csv.writer(csvfile) writer.writerow(['Time', 'Sensor']) for x, s1 in zip(x_vals, sensorValue_data): writer.writerow([x, s1]) # Register the callback function for when the plot window is closed fig, ax = plt.subplots() fig.canvas.mpl_connect('close_event', on_close) ani = FuncAnimation(fig, update_plot, interval=10) plt.show()
Thank you! Phenomenal video! I love the style I love the explanations, to the point and easy to follow!! You may was to consider adding to the end of the ser.close() in the in_close() function. My system doesn't automatically close serial communication and this may save some headaches for other viewers as well!
Glad it was helpful and thank you for the suggestion!
Месяц назад
since arduino is running before the python script activates the time stamps do not start at 0. is there a way to make the timestamp start at zero once the python code starts?
How fast can the GUI keep up with the data? I tried using pyqtgraph, using one thread to parse the serial data, and another thread for the gui updating. However, my sensor transmits at 115kbps continuously, and the GUI starts to lag behind after just a few seconds! I imagine this is such a common application that surely someone has figured it out. Haven't yet tried VizhPort ... but on the off chance that python isn't the best suited, I was thinking fl_charts and flutter!
Woooow, this is the best out there on stepper control using Accel. How can i connect with you for further talks on some projects we can collaborate on. LinkedIn, Email, ????
I've never used that piece of hardware before. Just a quick google search shows that it uses a different language, so I do not believe the code will work.
Question: this is a 1.5A stepper motor and from what I have read so far you need to double it for microstepping, then there are 3 motors so I get a total amperage of 9amps for the system and you said you are keeping the amperage at 1 amp because you are using a breadboard. How are you getting away with only 1 amp?
I have the motor controllers set to a current that just gets the motors moving. Also, there isn't any load on the motor shafts, so the motors won't draw that much current. The setup was just for the sake of this demonstration.
Hi, Is it possible to have the graph scaled to 600 points rather than the 1 point on the axis. So the incoming data is seen to the left of the graph(like the older IDE version seen in video ru-vid.com/video/%D0%B2%D0%B8%D0%B4%D0%B5%D0%BE-PPYMEBa0Vys.htmlsi=__NaLmAU9nlpRXpA&t=1673). I don't want the automatic update of the X-axis. Thanks
I am trying to control two stepper motors using arduino uno and tb6600 motor drivers and control them using Radio controller . However when i run my code only one stepper motor work while the other doesn't receiver input signals from transmitter
@@TheBoredRobotLLC but why does that matter? Isnt the point of using pull up resistor is so that ur button is not in floating state? So the value of resistor doesn't matter anyway as long as it is high enough to be stable
I have a question, I'm using a drv8825-ish in 1\32 micro step, and the motor moves terribly slow. What can I do to make it go faster? My ultimate goal is just a constant rotation speed which varies per motor so that I can use it in my drawing machine
It's going slow probably because you're doing 1/32 steps. Changing to full step or even half step will make it faster, but you may give up precision. It depends on your application.
Excellent video - Thanks! Consider using unsigned math on micros() it simplifies the code (no if() needed). Consider a small state machine in the inyerrupts. On a rising edge save time and on falling edge compute delta and set a new system state. Thid avoids some complications and can help clarify the interface.
Thanks for the advice! I also found another approach and I did that on another video as well. ru-vid.com/video/%D0%B2%D0%B8%D0%B4%D0%B5%D0%BE-MsUL-RY8ZrY.htmlsi=HysbnLop4zBKpxot
I have a video on this. You should be able to do the same with the motor controller that you mentioned. ru-vid.com/video/%D0%B2%D0%B8%D0%B4%D0%B5%D0%BE-QRCvC5xhJCw.htmlsi=tg4ZDeatLPXbjkhq
Please could you release code for this that uses Rc PWM for the control input? My personal use requirement is 2 Rc channel input for 2 stepper controls so this would work great for me if I could use Rc input to control it. Steve.