Author Archives: LHelge

Quadrocopter update

I used to have a tuning rig for my quadrocopter but I forgot it at my parents place before I stopped working on it for more than a year and now the rig is gone. Now that I want to continue working on the quad I had to build a new tuning rig.

Quadrocopter tuning rig

I made a new tuning rig for the quadrocopter.

Close up on tuning rig.

A close-up on one of the arms holding the quadrocopter. A small piece of aluminum tube with an inner diameter of 8 mm is striped to the MDF. Inside a M8 threaded rod is inserted into the square bar of the quadrocopter and is secured with a M8 nut and washer.

It is a little larger and better looking than the last one and there is less friction when rotating the quad. This hopefully leads to a better tuned software. I managed to tune the angular rate mode this weekend, I think it will be flyable right now but I haven’t tested it yet due to bad weather. I’ll upload a video as soon as I have tried it outdoors.

This is what I have left to do with controller software:

  • Filter yaw gyro signal, it’s to noisy right now to use as a feedback signal for yaw control
  • Activate and tune feedback control for yaw
  • Tune pitch/roll control in angle mode
  • Activate battery voltage measurement, blink LEDs with different speed depending on battery voltage. (and install LEDs on the quad)
I also started to work on a v. 2.0 of the controller with a faster processor, more sensors, more outputs and more inputs.

Upgrading Turnigy 9x with er9x firmware

A couple of weeks ago I ordered a Turnigy 9x RC radio transmitter. This is a cheap but capable transmitter sold by HobbyKing. I’m very impressed by the quality of the hardware and the thing have more buttons, switches and channels than I’ll ever use, but I’m not really satisfied with the firmware.

Luckily there are a lot of custom firmwares for this radio and from what I’ve read, the one named er9x is currently the preferred one. Guides on how this update is done can be found on many places (for example here), this is how I did it:

I used a USBasp AVR programmer, these can be bought off eBay for a couple of dollars. Since i generally prefer PIC processors, this was nothing I had so I ordered one. But I guess you could use any programmer supported by AVRDUDE.

When you have your programmer, there is a software called eepe that is a specially made AVRDUDE frontend for programming er9x firmware. I downloaded and installed that program.

Then you need to connect your programmer to the processor, this is the hardest part, but not really that hard. First unscrew the six screws on the back of the radio. Then disconnect the cable hold the two halves of the radio together.

Disconnect

Disconnect this cable

after that you need to locate the connection points where the programmer should be connected. These are all around the processor in the lower part of the radio. NOTE: I have the v2 version of this radio, the connection points differ on the older v1 of this radio!

Connection points

These are the six connection points that needs to be connected to the programmer. Note that I have the v2 version of this radio, these could differ on older versions.

To connect the USBasp programmer I made a custom cable like this

Programming cable

The programming cable made from a 10 pole flat cable and a 2×5 connector.

AVR connector

These are the different signals in the 2×5 AVR programming connector, with the connector in the same orientation as on the image above.

Note that the leads 3, 6, 8 & 10 are cut off and not used.

I soldered the cable to the connection points and followed the instructions for eepe. When I was done, I left the soldered cable inside the radio if I want to flash it again someday.

 

The RepRap is printing!

The RepRap build is moving along I haven’t installed the heated bed yet since I need a 24 V power supply, capable of delivering 10 A, first. I found a small pack of four 200 x 200 mm mirrors at IKEA named Sörli that will be perfect for a heated build surface. But for now I will print on a cold printbed. I measured the build volume without risk of hitting anything, it’s around 180x180x100 mm, so the mirrors will be perfect!

For the first real print after installing the hotend I put kapton tape directly on the aluminum sheet. The print wouldn’t stick at all, the printer just smeared a large blob of heated plastic around. I’ve read that blue painters tape is the preferred surface when printing PLA without heated bed so I bought two different brands of tape, Tesa and Kip at the local Hornbach store.

Blue painters tape

Blue painters tape from Kip and Tesa

So far I have only used the KIP-tape and I would say it works great. I’ll come back with a comparison when I’ve tried them both. Most people recommend Scotch blue 2090 but I haven’t found a supplier for that brand here.

I ordered a 0.35 mm J-Head MK V-B hotend from www.hotends.com. Most of it was already assembled, I just needed to insert the resistor and thermistor and put some kapton tape on it, then I could mount it to the extruder. I’ve also ordered some thermal grease that I will put on the resistor and thermistor when it arrives, but for now, the printer works fine without it.

J-head MK V-B

J-head MK V-B mounted on Wades geared extruder

Here are some pictures on my first print, maybe you could guess what it is?

First print

First print, here I used honeycomb infill, which probably results in the strongest parts, but to achieve any print speed, you need something more sturdy than a Prusa Mendel because of all the small print head accelerations needed to create a honeycomb pattern. The printer was shaking like crazy!

Finished print

Finished and assembled print, the outer part is mounted with two ball bearings and can be moved by a servo.

Finised print 2

The same part from above. Servo cable neatly hidden in the aluminum tube.

When generating the g-code for the printer you can choose how much infill you like to have. This particular print have the outer 3 layers solid and the inside have a 40% rectilinear infill which saves plastic filament, print time and weight but the parts are still very strong. This infill pattern is not as demanding on the printer as the honeycomb.

Infill

This image shows how the parts look on the inside, the top print was aborted half way through.

I will soon write another post about the thing I am printing together with the STL-files and a complete BoM.

The RepRap is alive!

I have previously written about my RepRap build, now its starting to come together. The last part I need before i can make my first print is the hotend that I’ve ordered from www.hotends.com

I use a RAMPS 1.4 board that, I ordered from 3D Gadgets, to control the stepper motors. RAMPS is an Arduino based RepRap controller that you can flash with several different firmwares. My first try was Marlin which seems to work fine. Since I dont have any hotend and temperature sensor I had to make some firmware hacks to get the thing moving. But I did!

And some picture of how it looks right now.

Picture of my RepRap

My RepRap including motors and RAMPS controller. It’s just put together to see if it works.

The steppers are pretty small but I got them very cheap. Let’s hope the have enough power not to loose steps while printing. A worst case solution could be to crank up the current and put heatsinks on them, or just buy bigger ones.

RAMPS 1.4

The RAMPS (RepRap Arduino Mega Pololu Shield) 1.4 controller loaded with Marlin firmware.

RAMPS 1.4 have 5 Pololu stepper drivers to be able to control X, Y, Z, E0 & E1.I only use one extruder and the Z axis have two motors connected in paralell on one of the driver. Maybe I’ll change the firmware so I can use one driver for each motor instead, but I don’t think that is necessary right now since the load on the Z-axis is very low.

Z-Motor

One of the stepper motors controlling the Z-axis

Y-Motor

The motor controlling the Y-axis

X-carriage

The carriage and extruder moving in the X-axis

X-Endstop

Each axis have a mechanical microswitch for endstop.

Right now I only have 3 endstops which is enough for the controller to find the home position (coordinate 0, 0, 0). It’s probably safer to have 6 endstops, one for each end of each axis, maybe I’ll add 3 more in the future.

Extruder

The extruder which push the plastic filament through the hotend

Extruder-top

Top view of the extruder, you could see the hobbed bolt inside which grips the filament

I use Wade’s Geared Extruder I hope my small stepper motors are strong enough for this extruder.

Filament

A 1 kg roll of white 3 mm PLA filament

I will start out with PLA plastic for my first prints, from what I’ve read I think ABS is more likely to warp because of uneven cooling. I think PLA will work great until I have my heatbed working.

Updates on the RepRap build

Last week I received 5 NEMA 17 stepper motors for my Prusa Mendel RepRap. They are pretty small and I’m a bit worried that they will be to weak for some parts of the printer (mainly the extruder) but I have to wait and see.

I also ordered a complete RAMPS kit and 1 kg of plastic filament from 3D Gadgets. The shipment from china with FedEx was super fast but since I work office-hours it seems impossible for FedEx to deliver it to me.

I hope I’ll find a solution to get my package and will post some pictures on both RAMPS and the steppers when it arrives.

I also discovered that I could run the whole RepRap on 24 V using RAMPS or that I could divide it so the steppers and extruder run on 12 V using the 5 A fuse on the board and the heatbed running on 24 V using the 11 A fuse allowing me to push 264 W of power into the heatbed. Should be enough.

To buy before first print:

  • Extruder
  • Power supply
  • Endstops
  • Piece of glass to use as print surface.

Prusa Mendel printbed

I put together a heated printbed for my Reprap using three parallel 10 Ω 100 W power resistors. The resistors are screwed onto a 220 mm x 200 mm x 5 mm aluminum sheet. This will make the whole printbed a 3.3 Ω 300 W heating element.

Printbed power resistors

Three 100 W power resistors connected in parallel will act as a heating element.

On top of the sheet I will place a 220 mm x 220 mm sheet of glass to use as a print surface.

Top of printbed plate

Top of printbed plate

When printing the printbed should be between 60° C and 110° C depending on which plastic is used.

Since the main voltage used on the reprap is 12 V, maximum power that can be achieved is

  \frac{U^2}{R} = \frac{12^2}{3.3} = 44 W

My guess is that it will take at least two eternities before it gets hot enough, but for a start I’ll use the printbed temperature logic built into the RAMPS controller card.

Later on I think I’ll build my own temperature controller with either a step-up or a separate power source with a higher voltage to get more power out of the printbed.

Not much happening right now

It’s been a while since I had any updates here. I’ve had a lot to do and, no energy to work on any of the projects here for a while. I think that the first project I’ll resume when the summer is over is my Prusa Mendel RepRap.

RepRap Prusa Mendel

Current build status of the printer

Whit this done I could start making parts for really cool multicopters.

Quadrocopter revisited

I started talking about multirotors with a colleague a couple of days ago and I suddenly got the motivation back to finish my quadrocopter that I started to build over a year ago. I wanted to build my own quadrocopter controller based on my kalman filter for angle estimation. But I never really got the control parameters tuned good enough for stable flight.

I don’t think I’ve posted any pictures on the quadrocopter in my previous posts so I’ll post some here.

Assembled quadrocopter before painting

Assembled quadrocopter before painting

Earplugs used to isolate controller board from vibrations

Earplugs used to isolate controller board from vibrations

and some videos to show how far I got with the controller tuning.

The first thing I did when starting to work on the controller again was to rewrite the controller part of the code from scratch. This time I think I’ll implement two different control modes, one that I call stable and one that I call acrobatic. Actually I’m more interested in the stable mode since I want to use the quad as a camera platform but it’ll be nice to have an acrobatic mode as well. This is two rough sketches on how I plan to implement them.

Stable quadrocopter controller

Stable quadrocopter controller

Acrobatic quadrocopter controller

Acrobatic quadrocopter controller

In the stable controller the angle of the platform is controlled by the radio, while the acrobatic takes the angular rate as an input. If you tilt the stable platform 15° and then release the controller it will return to horizontal level while the acrobatic will continue to lean 15° until you pull the lever in the opposite direction and tilt the platform back.

As I wrote in my post about the Kalman filter it is actually two identical filters for pitch and roll working completely individually. This works great for angles up to somewhere around 45° but the filter will go crazy if you start doing loops  and rolls. That’s why the Kalman filter is removed in the acrobatic mode leaving a controller that works directly on the gyro signals.

Right now the code is ready and parameters for the new PID controllers needs to be found. Last time I did this I built a rig but I left that at my parents house a while ago.

Quadrocopter test rig

Quadrocopter test rig, the quad rotates freely around one axis.

I dare not to test the new parameters without having the quadrocopter securely fastened to something heavy. On full throttle the motors produce around 1,2-1,4 kW of power which can do some real damage. I realized that the hard way…

My hand before the doctor stitched it together .

A 3cm long cut in my hand (actually 4 or 5 cuts from the rotating propeller) before the doctor stitched it together.  It was all the way through the skin, I was lucky that no tendons were harmed.

I plan to visit my parents in a couple of weeks, I’ll post an update once i fetched the test rig.

Propeller driven Lego car.

Lego Technic is perfect for creating quick prototypes of pretty much anything, combine this with RC stuff and you can create really fun stuff. One simple example is the robot i describe in this post:
Sunday afternoon robot

My old Lego is usually stuffed away in a box in the basement, but when we have kids visiting we usually bring it up to the apartment. I suspect I’m the one enjoying it most and this time I built a RC lego car

Lego Propcar 1

From the side

Lego Propcar 2

The motor and propeller us used as a pusher

Lego Propcar 3

The battery, ESC and receiver is secured with a rubber band

Lego Propcar 4

I use a HXT900 servo to steer

After a few testruns I added a propeller protection bar to minimize the risk of running into something with the propeller.

Lego Propcar 5

Propeller protection

Runs great, I’ll probably update this post with a video when I’ve recorded one.

Battery bag for my E-Bike

Last weekend we borrowed a sewing machine to make new curtains for the apartment. When I was sewing the curtains I realized that It wouldn’t be very difficult to make a custom battery bag for my e-bike. I would like a bag that I could mount in the frame triangle and have room for 4 Turnigy 6S 5Ah batteries. Doing some measurements, calculations and drawing I came up with this design

Battery bag drawing

An outline of the battery bag, the red triangle is the frame, the blue rectangles are batteries and the gray rectangle is the controller mounted on the frame.

I went to the fabric store and found a black nylon fabric that had a PVC layer on one side. This should be fairly water resistant and I plan to spray it with some textile waterproofing spray as well. I was recommended to use a thread for furniture which is much stronger than ordinary thread as well. A couple of hours thinking, cutting, and sewing later:

Battery bag

I use some Depron in the bottom, and some foam in the two corners to protect the batteries and fill out the bag.

Zipper

The zipper has a bit of fabric folding over it for water protection

Hole for cable

The hole for the cable is also waterproof since the side of the bag overlaps ~10 cm where the cable comes out.

Cable

I'm using the cable I made for the E-Puch. This cable is for two turnigy batteries in series and two in paralell with a 60A fuse. The LEGO part is just for size reference.

Packed

Everything fits nicely inside the bag

The bag fits perfect on the bike!

Battery bag on bike

Battery bag on bike

Battery bag in frame

Battery bag in frame

Pleas write a comment if you think I should make some kind of drawing and description on how to make a bag like this.