Arduino Wireless Laser Turret
by Eagle199393 in Circuits > Arduino
30647 Views, 171 Favorites, 0 Comments
Arduino Wireless Laser Turret
![P1050697.JPG](/proxy/?url=https://content.instructables.com/FGA/ZJPR/HS18EBDH/FGAZJPRHS18EBDH.jpg&filename=P1050697.JPG)
Very easy to build arduino wireless laser turret, also very cheap components you can buy on ebay for example.
To make this project I used 2.4GHz RF transceiver modules that is built in the nRF24L01+ IC.
nRF24L01+ are extremely cheap and cost a few dollars for one piece.
List of components you need to buil this awesome project:
Arduino UNO (only as programmer)
Arduino Pro MINI ---------------2pcs
Breadboard 830 Tie-points
Breadboard 170 Tie-points
Laser module
Servo 9g -------2pcs
nRF24L01+ module ------ 2pcs
Joystick module
Cellphone Li-ion battery 3.7V -----2pcs
male-to-male cables, male-to-female cables,female-to-female cables
cable tie
fix wire
![P1050683.JPG](/proxy/?url=https://content.instructables.com/F3F/OYLK/HS18EM0T/F3FOYLKHS18EM0T.jpg&filename=P1050683.JPG)
![P1050671.JPG](/proxy/?url=https://content.instructables.com/FDA/FVUD/HS18EK0Z/FDAFVUDHS18EK0Z.jpg&filename=P1050671.JPG)
![P1050675.JPG](/proxy/?url=https://content.instructables.com/FO8/QGUZ/HS18EK3Z/FO8QGUZHS18EK3Z.jpg&filename=P1050675.JPG)
How to upload sketches on Arduino Pro MINI.
- Remove Atmega328 from Arduino UNO
- Using male-to-female cables connect Pro MINI to UNO RX-RX; TX-TX; RST-RST; GND-GND; VCC-+5V
- Change in Tools-Board-Arduino Pro or Pro MINI
- Upload sketch
Receiver Sketch
#include <Servo.h> #include <SPI.h> #include "RF24.h" Servo servo1; Servo servo2; RF24 radio(9,10); const uint64_t pipe = 0xE8E8F0F0E1LL; int msg[1]; int data; int pos; void setup() { servo1.attach(3); servo2.attach(7); radio.begin(); radio.openReadingPipe(1,pipe); radio.startListening(); } void loop() { if (radio.available())radio.read(msg, 1); if (msg[0] <128 && msg[0] >-1)data = msg[0], pos = map(data, 0, 127, 7, 177),servo1.write(pos); if (msg[0] >127 && msg[0] <255)data = msg[0], pos = map(data, 128, 254, 9, 177),servo2.write(pos); }
Transmitter Sketch
#include <SPI.h> #include "RF24.h" RF24 radio(9,10); const uint64_t pipe = 0xE8E8F0F0E1LL; int msg[1]; int potpin_1 = A0; int val_1; int potpin_2 = A1; int val_2; void setup(void){ radio.begin(); radio.openWritingPipe(pipe); } void loop() { val_1 = analogRead(potpin_1),val_1 = map(val_1, 0, 1023, 0, 127),msg[0] = val_1,radio.write(msg, 1); val_2 = analogRead(potpin_2),val_2 = map(val_2, 0, 1023, 128, 255),msg[0] = val_2,radio.write(msg, 1); }
![P1050685.JPG](/proxy/?url=https://content.instructables.com/F49/XK4X/HS18EN69/F49XK4XHS18EN69.jpg&filename=P1050685.JPG)
![P1050691.JPG](/proxy/?url=https://content.instructables.com/F1T/K69Z/HS18EN6C/F1TK69ZHS18EN6C.jpg&filename=P1050691.JPG)
![P1050694.JPG](/proxy/?url=https://content.instructables.com/FAD/00QH/HS18EN6E/FAD00QHHS18EN6E.jpg&filename=P1050694.JPG)
![P1050693.JPG](/proxy/?url=https://content.instructables.com/FYG/XQMU/HS18EN6S/FYGXQMUHS18EN6S.jpg&filename=P1050693.JPG)
Fix laser module and servo components by wire like it shown on pictures.
Transmitter Scheme.
![P1050718.JPG](/proxy/?url=https://content.instructables.com/F3S/ZAYH/HS18ECBB/F3SZAYHHS18ECBB.jpg&filename=P1050718.JPG)
![P1050721.JPG](/proxy/?url=https://content.instructables.com/FES/JPZZ/HS18ENAV/FESJPZZHS18ENAV.jpg&filename=P1050721.JPG)
![P1050719.JPG](/proxy/?url=https://content.instructables.com/FI9/7YBQ/HS18ENBA/FI97YBQHS18ENBA.jpg&filename=P1050719.JPG)
Transmitter scheme.
Recivier Scheme
![P1050723.JPG](/proxy/?url=https://content.instructables.com/FGU/FXIL/HS18ENAX/FGUFXILHS18ENAX.jpg&filename=P1050723.JPG)
![P1050706.JPG](/proxy/?url=https://content.instructables.com/FDF/O73C/HS18ENBC/FDFO73CHS18ENBC.jpg&filename=P1050706.JPG)
![P1050702.JPG](/proxy/?url=https://content.instructables.com/FWV/JA42/HS18ENBG/FWVJA42HS18ENBG.jpg&filename=P1050702.JPG)
![P1050705.JPG](/proxy/?url=https://content.instructables.com/FPN/Y0K7/HS18ENBI/FPNY0K7HS18ENBI.jpg&filename=P1050705.JPG)
![P1050709.JPG](/proxy/?url=https://content.instructables.com/F1C/0LY1/HS18ENBK/F1C0LY1HS18ENBK.jpg&filename=P1050709.JPG)
Receiver scheme
Final Result
![P1050712.JPG](/proxy/?url=https://content.instructables.com/FKF/03YE/HS18ENBF/FKF03YEHS18ENBF.jpg&filename=P1050712.JPG)
![Arduino nRF24L01+ Laser turret](/proxy/?url=https://content.instructables.com/FPH/HCMB/HS18ENK1/FPHHCMBHS18ENK1.jpg&filename=Arduino nRF24L01+ Laser turret)
http://youtu.be/Nt5nIwc3mYA
https://github.com/maniacbug/RF24 -------- RF24 library