Servo Testing Tool - PCB Design With Fusion 360

by TomGoff in Circuits > Electronics

195 Views, 0 Favorites, 0 Comments

Servo Testing Tool - PCB Design With Fusion 360

Servo Testing PCB with Animatronic Eye
Eye7.jpg

When you reach a certain age you can easily get stuck in you ways and not learn to use new tools. In this project I wanted to build a tool as well as learn how to use a new tool.

The tool I will be building is a servo testing PCB. This simple circuit allows you to connect up the servo you've had in your parts bin for years and simply check whether it still works before you proceed with your project. It means you can be certain the servo works before you blame any dodgy code or wiring.

The tool I wanted to learn was Fusion 360 Circuits Design. When I was training as an engineer I had the luck to initially train using manual drafting tools and then we transitioned to AutoCAD release 12. Throughout my engineering career I have had to learn new design tools such as 3D AutoCAD in early 2000's, then Autodesk Inventor for design and FEA (Finite Element Analysis) and over the last 10 years more electronics design tools. It's easy to get stuck in a rut and not try new tools so I wanted to learn a new design tool to push me out of my comfort zone and also so that I can have an informed decision on the tool.

I used an animatronic eye to test the Servo Testing tool because by simply adding an eye (preferably googly or animatronic) you make the project 10 times better!

Supplies

comps.jpg

Here's a list of the tolls and Components you will need. The Bill of Materials (BOM) for the PCB was easy as Fusion 360 automatically develops a BOM as you design the PCB.


Tools

  • Fusion 360 Software
  • Soldering Iron
  • Cutters
  • Screwdrivers
  • Small Pliers (for bending wire)

PCB

  • Capacitor C1               - 0.33uF Electrolytic
  • Capacitor C2               - 0.1uF Ceramic
  • Capacitor C3               - 0.1uF Ceramic
  • Capacitor C4               - 0.33uF Electrolytic
  • Capacitor C6               - 0.1uF Ceramic                                                                                                       
  • Diode D1                       - GEN PURP 200V 1A Rectifier    
  • Diode D1                       - GEN PURP 200V 1A Rectifier                                                                                
  • LED1                             - 1206 SMA LED BLUE
  • IC1 555                          - LM555_SOIC 
  • IC2 Voltage Regulator - LD1117 SOT223
  • J1, J2                - Terminal Block 0.2"(5.08mm) Trough Hole
  • PIN HEADER1 & 2      - Generic Male Pin Header 3-way 0.1" (2.54mm)
  • Resistor R1                   - 1k ohm 1206 SMD
  • Resistor R2                   - 1k ohm 1206 SMD
  • Resistor R3                   - 3k ohm 1206 SMD
  • Resistor R4                   - 100k ohm 1206 SMD
  • SW1                  - Through Hole Slide Switch (I used a terminal with a wire link)

Consumables

  • Solder
  • Flux


Animatronic Eye

  • Hobby Servo's x 4
  • 3D Print Files
  • 2mm Screws
  • 0.8mm Wire x 200mm
  • 3D Printer and Filament

PCB Design With Fusion 360 Electronics Design

Fusion 360 - PCB Design

As I discussed in the introduction I designed the PCB with Fusion 360 Electronics Design Software. I have done an instruction video showing the PCB design together with a tutorial showing you how to design your own PCB with Fusion 360.

Electronics Simulation With Tinker Cad

555 Servo Tester Simulation using Tinkercad

As with many of my projects I used Tinker Cad to simulate and test the circuit before I bought and assembled any hardware. The Video attached shows the circuit in operation together with it interacting with a Servo Motor.

For those interested, the circuit generates a PWM signal that Controls the Servo Motor. A PWM signal is a series of electrical pulses with a specific frequency and duty cycle. For most hobby servos, the frequency is typically around 50 Hz, which means one cycle is 20 milliseconds long (period = 1/Frequency = 1/50 = 0.02s).The width of each pulse, called the pulse width, within this 20 ms period determines the position of the servo, for the servo's I used this is:

  • Minimum Pulse Width (0.7ms in my case but typically 1ms) moved the servo to one extreme, 0 degrees.
  • Maximum Pulse Width (2.2ms in my case but 2ms typically) moved the servo to the other extreme (about 120 degrees in this case but this value varies depending on the servo).
  • Intermediate Pulse Widths positions the servo at angles between the two extremes. For example, a 1.5 ms pulse centres the servo at 60 degrees.

To calculate the size of the capacitors and resistors in the circuit you use the following calculations to work out the length of the high period of the PWM signal.

T = 0.69 x R x C (R = Resistance, C = Capacitance)

So for the off period the time is fixed so:

T = 0.69 x 100 x 10^3 x 0.22 x10^-6 = 0.015s = 15ms (milliseconds)

The on period depends on the position of the potentiometer.

With 10k ohm Potentiometer at Minimum:

T = 0.69 x (1000 + 3000) x 0.22 x10^-6 = 0.00076s = 0.76ms

With 10k ohm Potentiometer at Minimum:

T = 0.69 x (1000 + 3000 + 10,000) x 0.22 x10^-6 = 0.002s = 2.1ms

With 10k ohm Potentiometer at Mid Point:

T = 0.69 x (1000 + 3000 + 5,000) x 0.22 x10^-6 = 0.0014s = 1.4ms

Using the above you can calculate that the PWM signal has a frequency of between 58 and 63 Hz (Frequency = 1/Period). This is a little high for hobby servos but it works.

Soldering the PCB

thumbnail_IMG_5981.jpg
Solder1.jpg
Solder2.jpg
Solder3.jpg
Solder4.jpg
Solder5.jpg

I designed the PCB to mostly use Surface Mount components. I did this because I feel that over the next few years surface mount components will mostly be used in electronics, even hobby electronics. Surface mount components are generally preferred over through-hole components because they allow for smaller, more compact designs, higher component density, and automated assembly. Automated assembly might not seem important for hobby electronics but can be useful if you making many PCBs and is a serviced that can be added when you are having your PCB manufactured.

I purposefully used larger 1206 components to make it easier for hand soldering, here's how I hand solder SMD components:

  1. Clean the solder pads for the component with a flux pen, or similar.
  2. Apply some Solder to one of the pads.
  3. Place the component next to the pad and hold with tweezers.
  4. Heat the solder you have already applied and push the component connection into the solder with the tweezers.
  5. Apply solder to the unsoldered pads.

You can use this method for all of the components, you just need to be careful with the smaller components such as the 555 IC. You should inspect the connections after completion to ensure there is no bridging between connections. You can remove bridging with solder wick.

Assembling the Animatronic Eye

Eye1.jpg
Eye2.jpg
Eye3.jpg
Eye4.jpg
Eye5.jpg
Eye6.jpg
Eye8.jpg
Eye9.jpg
Eye10.jpg
Eye11.jpg

I decided to use an animatronic eye for to demonstrate the servo testing tool because the are fun and I've always wanted to build one.

I didn't design this eye myself as the aim of the project was to build a PCB to test Servo's but I needed something to test it out on. I purchased the plans on Etsy and then 3D printed them at my Hackspace (Norwich Hackspace, UK) using our new Bambu 3D printer. It was all held together by 2mm screws and I assembled the Eye as follows:

  1. Mount the two feet to the frame.
  2. Mount the Pivot to the frame.
  3. Mount the four Servos to the frame.
  4. Mount the eye holder to the pivot.
  5. Bend the linkage wires to shape with the wire jig.
  6. Mount the Servo horns.
  7. Connect the two eye holder linkages.
  8. Fit the eye ball to the eye ball holder.
  9. Fit the two eye lids.
  10. Connect the two eye lid linkages.
  11. Connect the Servo's to the Servo Test PCB.

Note: On most hobby servo's the Red wire is 5 Volts, The Brown Wire is Ground (0 Volts) and the yellow wire is the controls signal (the PWM signal).

You are now ready to try your servo controlled animatronic eye out. Be careful at first as you might need to adjust the angle of the servo horn to the correct middle position.

Final Comments

The electronics in this project was pretty straight forward but I achieved my goal of building a new tool for testing Servo's and learning to use a new tool with Fusion 360 Circuit Design. It also encompassed Surface Mount Soldering and learning about the operation of Servo Motors.

My experience with Fusion 360 Circuit Design was positive and I found it very easy to learn. I can see the huge advantage it offers when integrating mechanical and electronics designs and also when designing custom electronics components in 3D that you immediately include in your design.