Flying Lego Quadcopter

by NeilP43 in Living > LEGO & K'NEX

23647 Views, 113 Favorites, 0 Comments

Flying Lego Quadcopter

IMG_6706-edit.jpg
The Flying Lego Quadcopter - first flight and how it works
RQMK6128.JPG

I love LEGO.

I love flying machines

LEGO + making it actually fly? Everything is awesome, two of my favourite hobbies combined :)

My first instructable will take the Lego 60193 Arctic Air Transport Helicopter (quadcopter!) and add the necessary electronics to make it fly for real as a Radio Controlled model. The target audience for this instructable is someone that may already have some RC flying experience, but if you don't I'll give pointers to where you can find out more information and with some practice on a smaller/cheaper toy quadcopter first you could certainly build up to this!

The challenging part with this build is keeping as much of the original LEGO model look as possible, while squeezing in all the electronics. To make fly of course we need to add motors, propellors, electronic speed controllers (ESC) and an electronic flight controller to manage the stability of the model and convert the commands from the RC transmitter into appropriate propeller speeds to control the model.

The electronics have been chosen to fit within the available space, and the LEGO modifications have been kept to a minimum to attach the motors.

Let's get going!


[I've been inspired by others that have done something like this before, but all the written instructions, photos and video are 100% my own work]

Supplies

Build the Lego Kit & Plan the Electronics

IMG_E1426.JPG
IMG_2336.JPG
IMG_2338.JPG

Building the LEGO kit is the first and quickest part of this build! I built the full model first, along with the ice block for the saber tooth tiger and the little quad bike that comes with it. Just follow the LEGO instructions (in case you're interested, they're available online: http://lego.brickinstructions.com/en/lego_instruct... )

After letting my kids play with the LEGO model a while I took some of it apart to see how the electronics would fit and also the arrangement of the props and motors.

With the winch gear and other unnecessary blocks removed from inside it's relatively open inside which is great for placing the battery (0.95Ah 3 cell LiP), and the 20x20mm stack with flight controller and 4-in-1 electronic speed controller.

With any flying model it's important to get the center of gravity right to make flying and trimming the model easier. For a quadcopter this means the main weight of the aircraft should ideally be centered between the props. With the battery sitting just behind the pilot and flight controller at the back this is pretty much perfectly balanced already.

Drill the Lego to Allow Bolting on the Motors

IMG_2053.JPG
IMG_2072.JPG
IMG_2077.JPG
IMG_2083.JPG
IMG_2075.JPG
IMG_6689.JPG
IMG_6688.JPG
IMG_2074.JPG
IMG_6691.JPG

Here's where it gets interesting. The placement of the fixing holes of a standard 1806 brushless motor is almost exactly the same as the studs on a standard LEGO 2x2 plate. Each 'engine' mount on the quadcopter has a studded dark stone gray plate 2x2 (LEGO 3022), and on top a medium gray stone gray tile 2x2 with vertical pin (LEGO 2460) which would normally hold on the LEGO propellor hubs.

To fit the brushless motors I drilled the LEGO using the following steps:

  1. Found a good pillar drill to make accurate drilling easier, in this case I borrowed my dad's workshop which had neat little pillar drill and vice combination
  2. Removed the arm from the model complete with 'engine' mount
  3. Removed the medium gray tile with vertical pin
  4. Measured the required hole distance with calipers and found it to be a fraction larger than the centers of the lego studs
  5. Drilled holes in the 2x2 plate first and checked the bolts fitted
  6. Checked the brushless motors fit ok, actually only needing 2 bolts
  7. Then put the plate onto the arm and drilled all the way through
  8. Drilled 2 corners of the medium gray tile with vertical pin

  9. Drilled out the vertical pin with a larger drill to provide an indent so that the bottom pin & circlip of the brushless motor can turn freely

  10. Front: Bolted on the motors with long bolts such that they go all the way through the arms of the quadcopter (1x M2x12 + 1x M2x16 for the two front motors)

  11. Rear: Bolted on the motors with long bolts such that they go all the way through the raised-up lego motor mounting (2x M2x16 per rear motor) I didn't have bolts long enough to reach all the way through the frame

Choose Your Motor Arm Placement - Short and Wide or Long and Narrow

IMG_2344.JPG
IMG_2341.JPG
IMG_2340.JPG

By re-arranging the 'arms' of the quadcopter it's possible to change the layout slightly to favour either a wider or narrower placement of the motors, and the amount of propeller overlap.

Short and wide (first picture, default)

The default LEGO build (first image) has the props & motors placed wide (horizontally) with quite a lot of overlap, and relatively close together relative to the length of the body.

Long and narrow (second picture, recommended)

By swapping the arms around from left and right sides it's possible to change the layout to a narrower configuration (horizontally) and and more spaced out, and with less overlap, down the length of the body. I prefer this configuration because:

  1. I expect it will have better stability as the model is relatively heavy down the length of the body vs the horizontal
  2. There's less overlap for the props which means less likely there's an issue with the clashing into each other

Ultimatley the choice is yours and the good thing about lego it's easy to adjust and chance this now (but a little harder after all the wiring and soldering)

Wire Up the Electronics

motor-direction.png
IMG_2311.JPG
HGLRC-XJB-Wiring.jpg
IMG_2555.JPG
IMG_2562.JPG

Now that the motors are physically fitted it's time to do the wiring.

Motors

  • The wires included on the rear motors were long enough to solder to the electronic speed controller (ESC) directly. It's important that the ESC is orientated the correct way around make make easy connections to the correct motor. I found that with the ESC solder tabs to the sides it's a nice tight fit into the body of the lego chassis
  • The default for Betaflight (flight controller firmware) is to have motor 1 in the bottom right corner, turning in a clockwise direction (make sure you have the same on each diagonal), I prefer to use the 'REVERSED' setup where the front motors spin outwards so that any grass cutting is thrown outwards and not onto the camera/front of the model
  • The front motor wires were not long enough so I extended with a short length of black wire and heat shrink connection to make it tidy
  • Each brushless motor has 3 wires, it doesn't matter which order these are connected in as the motor direction can be corrected later in the programming stage with BLheli configurator

Battery connector & smoothing capacitor

  • Solder the appropriate power connector to the flight controller to match the battery, e.g. a JST RCY.
  • Solder on the smoothing capacitor, if included, to reduce electrical noise (optional)

Receiver

  • Connect up as appropriate, usually an SBUS connection and may additionally support telemetry. Refer to the instructions for your flight controller and receiver combination.

Other

  • 5v Beeper - optional, useful for error beeps and low battery alarm
  • In the future there's also an option to include a small first-person-view (FPV) camera and video transmitter (VTX). The HGLRC flight controller stack includes a VTX option ;)

Once you've completed soldering, double and triple check your connections, check for and remove any short circuits (multi-meter resistance check across battery terminals) before you connect the battery and/or use a smoke stopper.

On power up you should see the lights of the flight controller turn on and some beeps from the ESCs.

Configure the Flight Controller and Spin the Motors

IMG_2565.JPG
bf-firmware.PNG
bf-1-connected.PNG
bf-2-ports.PNG
bf-3-config1.PNG
bf-3-config2.PNG
bf-3-config3.PNG
bf-5-pids.PNG
bf-4-power.PNG
bf-6-receiver.PNG
Taranis-default.PNG
Taranis-mixes.PNG
bf-7-modes.PNG
bf-8-motors.PNG
blheli-configurator.PNG
LegoQuad.bmp

Now that everything is wired up it's time to configure the flight controller. This means downloading the software (well firmware) that performs the task of decoding the control signals from the RC transmitter, and processing sensor input (accelerator, gyros), and providing the control signals for the ESCs to turn the motors at the right speeds to make the quadcopter go exactly where you want it to, while keeping it straight and level in the hover.

The major steps are outlined below, but the instructions for the HGLRC flight controller have a lot more detail, and there's also lots of great YouTube videos on how to setup a quadcopter, try 'Painless360', 'Joshua Bardwell' or 'Flitetest' to name a few.

Major steps shown in screen shots (remember to hover over [boxes] in screenshots):

  1. Remove propellers for safety!! Battery not required for first few steps, just USB power.
  2. Download the betaflight configurator https://betaflight.com/
  3. Connect micro USB cable to the flight controller (check the manual if any special drivers are required)
    • Note it may be easier to do this without the flight controller screwed down into the chassis
  4. Download and flash the appropriate firmware for the flight controller, the HGLRC F428 this uses 'OMNIBBUSF4'
  5. Hit the 'connect' button and go through the flight controller manual for setup e.g. for mine
    1. Setup - calibrate the accelerators with the model (& flight controller) level
    2. Ports - UART1 - Serial RX for the RC receiver SBUS connection, save and reboot
    3. Configuration parts 1 to 3
      • QUAD X config - note - I use reversed motors so that any grass cutting on landing gets thrown to the sides not the front window

      • Adjust board and sensor alignment if you've rotated the flight controller (i.e.the ^ arrow on the board is not pointing forwards)

      • Receiver - SBUS serial receiver or to match your RX

      • save & reboot

  6. PID tuning (this is the control loop for stability) - I've used defaults for a 250 size quadcopter
  7. Power and battery
    1. Connect the flight battery for this one, you'll hear the ESCs beep
    2. Start with the instructions but adjust / calibrate to get the right voltage reading to enable low voltage alarms
  8. Receiver - Make sure your channel mapping and direction of controls is correct, when everything is setup the model quad picture in the bottom right should move in all the right directions with when you move the sticks on your RC controller
    • I've also included screen shots of my FrSky Taranis setup & a custom BMP icon for the transmitter screen
  9. Modes - adjust to your preference but I use 3 switches:
    1. ARM on/off
    2. HORIZON for self levelling / ACRO for traditional FPV flight
    3. BEEPER - helpful if you lose the model in long grass or a bush
  10. Motors tab - use this to test each motor individually (with props off), and importantly note the rotation direction of each,
    • correct any rotation direction with BLHELI configurator (battery connected, ESCs powered), no need to re-solder and change the motor connections
    • I've left other BLHELI options at defaults

After all these steps you should be able to disconnect the USB, & battery, then check everything works (without props) by:

  • Turn on TX
  • Connect the flight battery and leave the quad still and level on the ground
  • Turn on ARM switch and motors should spin at a low speed
  • Test the throttle increases RPM
  • In horizon mode, try tilting the quadcopter and check that the motors react appropriately, e.g. tilt it forward and the front motors will speed up.
  • dis-ARM and power down, it's soon time to fly!

Re-inforce the Frame and Glue the Lego!?

IMG_6693.JPG
IMG_6695.JPG
IMG_6698.JPG
IMG_6700.JPG
IMG_6701.JPG

Rear motors:

Glue? Lego? Kragle?

Frowned upon by most lego builders, I've tried to avoid glue at all cost. The only place it really needs it is the rear motor blocks onto the arms (first photo above). Everything else is using the magic of lego.

The rear Motors are nicely bolted onto these 'motor blocks' but this bit of lego needs to be fixed down to the Arm and not fly off. I used a little hot glue on the middle of the plate where this fixes down. Hopefully this is not permanent and will pull apart if I need to make repairs.

Reinforced mid-frame:

I used a few extra lego pieces from other models to add a little extra rigidity to the central frame to better cope with the forces. The layout of the arms is unchanged.

Flight controller / ESC bolted:

The flight controller is already a tight fit, but drilling one hole and take a single bolt through to the tail section will make sure it doesn't move with vibration. Alternatively double sided foam/tape inside might work.

Go Fly!

The Flying Lego Quadcopter - first flight and how it works
video-screenshot-e.jpg
IMG_6710.JPG
IMG_6709.JPG
IMG_6711.JPG
IMG_6708.JPG

All that's left to do is take it outside, find some open space and fly(*)! Ask a friend to video it, and hope the lego doesn't fall apart!

The video linked is the very first flight, and as I can see from my smiling face, it worked great! It certainly took a little longer to put together than expected but the result is something special. I can image making some fun rescue mission animations and action movies with my kids, their lego and this flying quadcopter.


I hope you've enjoyed my first instructable inspired by the 'make it fly' competition, please comment and ask any questions!


* Note - if you've never flown before, it's probably worth practising first on something smaller, cheaper and more robust like an Eachine E010. Also please check your local laws for Drone Safe Code or similar, in the UK https://dronesafe.uk/drone-code/ in the USA https://www.faa.gov/uas/getting_started/ . In most places this means flying in open spaces where you have permission to fly, and you're away from any people, buildings and vehicles not under your control.