Servo Motor control using Dual Axis Joystick Module tutorial - Arduino Nano - Code included
HTML-код
- Опубликовано: 21 сен 2024
- Analog servo motors are inexpensive little powerhouses that can be perfect when you're designing something that needs to move. They pack a lot of torque for their size and their shaft position can be pretty accurately controlled.
The Dual Axis Joystick Module presents three outputs, two of which are analog and one digital. The two outputs are the analog voltage on two potentiometers representing voltage dividers; thus the inclination can be measured on each axis, Ox and Oy. Digital output is pressing a button.
Parts used:
- 1x Breadboard
- 1x Arduino Nano
- 5x Jumper Wires (female-male)
- 4x Jumper Wires (male-male)
- 1x MG995 Servo motor
- 1x Power supply with batteries (for the servo motor)
Follow me :
Facebook: / lot10games
Instagram: / 1indie_game_dev
Just a question about connections: Why am I not seeing the battery (+) that supposed to connect to Nano, just (-) is connect and why is micro usb connected to computer that is powered up? Which way is the battery (+) is to connect to Nano? Your projects is confusing me and it makes no sense to me. Thank you.
If you want to power the servo from the batteries and the Nano from PC ( like I did in this example), you have to connect the ground together, but no need to connect the + to nano board. But if you want to power up the Nano board and the servo from the batteries, all you have to do is to make one more connection from + batteries to Nano VIN pin. But be careful, batteries should be between 7-12v in order to use the VIN pin from the Nano. My batteries draw more than 12V so I used a buck converter, and I could power up the Nano board from the batteries
Operating voltage of mg995 servo motor
4.8 ~ 6 V DC Volts
Operating Speed (4.8v): 0.200 sec/60° degrees at no load
Operating Speed (6v): 0.160 sec/60° degrees at no load
Which batteries are you using?
18650 3.7V batteries from a laptop
where is the code pls post
Can you pls add the code
The download link is in description