Deathblades: The Double DECer board

Once upon a rainy day in Boston, Charles sat in his free scrounged office chair, slumped over the armrests. He was focused intently upon his 17″ LCD monitor, its glow filling the darkened, humid room. The ambiance was only disturbed by the sound of raindrops upon the dusty window, whose blinds were drawn such that he did not have to think about the fact that it was raining outside and he really, really hates rain and doing anything or going anywhere in the rain so he didn’t go MITERS to keep adding sensors onto the motors and…

Alright, that story went nowhere.

I did take today to think a little more about controlling the Deathblades. At this point, I knew that

  • I was going to use the Maxon DEC modules
  • XBEE radio units would handle communication between the input device and the skates.
  • … There will be a handheld control input device. With, like, an XBEE in it.

However, all these thoughts a controller do not make. Taking advantage of the rainy day, I took my Course VI skills out on a second test drive and began laying out the internal control circuitry for the skate motors. The DECs, as bare boards, aren’t really conducive to hacking together. I would need a solution which supplies them with power and auxiliary components, and as long as I have those on a board, I might as well put in communications as well.

Now, if you had asked me even a few months ago, I’d have just whipped together something out of protoboard. But in the interest of legitimacy and experience, I’m going to have a real PCB made.

I started by drawing out the schematic of the board. Core components such as the XBEE and DEC modules were added and “wired” first, then support circuitry added as needed. I had to make several custom devices for this board, one of which was the DEC module itself.

The XBee will used in just about the simplest fashion it can be – a direct, no-microcontroller, digital and analog I/O bridge. One of its analog (PWM, actually) pins will drive the speed input pin on the DECs, and a digital I/O will toggle the Enable pins so the motors can coast – otherwise, there’s a dynamic braking effect. Because the XBees run only on 3.3 volts (Digi should fix that, really), I added a 5v to 3.3v LDO regulator, which draws power from the Hall sensor output (VCC_HALL). The DECs are rated for “35mA” output each, so I’ll see how conservative that really is.

While making this schematic, I had the chilling realization that the XBee’s 3.3 volts maximum output will never drive the DEcs to full throttle.

Uh oh. So I had to somehow level shift 0-3.3v to 0-5v. My first instinct was a noninverting rail-to-rail op-amp set to 1.5x gain (which is about the ratio between the two voltages), but that was just… so analog. The next option is a bidirectional level shifter like this Sparkfun unit, which is available for an almost trivial price. Problem is, that meant making yet another custom component. I was getting tired of having to whip up my own parts at that point, even if all it amounted to was copying and pasting footprints and symbols.

… so I took the discrete path out and spec’d some SOT-23 signal MOSFETs and 1206 SMT resistors. This will officially mark my foray into surface mount parts, something which I PROMISED PROMISED PROMISED to never EVER EVER do. But TO-92 cases just looked bad on a board, so there. There are two stages of the inverter such that the PWM signal remains rectified.

After the level shifting, the signal goes through a low-pass RC filter with a break frequency of around 160Hz before splitting to the two DEC modules.

What happens after  you make a schematic? You hit the “Board” button and Eagle piles everything onto a blank PCB representation. You then unchain your inner OCD and watch the board come together.

Well, here’s most things. I discovered that even the DEC modules will have a hard time fitting inside the ‘blades. Two reasons contribute to this:

  • Eagle’s free version limits you to 100mm long boards. The DECs had trouble fitting in crosswise because the boards are 1.75″ wide, but the internal skate cavity is only 1.6″.
  • Within 100mm, I couldn’t fit the DECs “longwise” and still make room for the XBee.

So for now, I’m going to hedge my bets on the fact that the 2.6Ah lithium polymer pack is true to its stated dimensions. If they are, then the DEC boards will be elevated above the level of the aluminum side plates, which means the boards can be 1.6″ wide with no trouble. The layout above reflects that.

Most of the way completed. The tricky part of this circuit was, oddly enough, routing the power connections. Otherwise, it still has modest componentry and convenient routing characteristics, unlike some weird shit like this.

Now the board has been routed to my satisfaction. The top layer text says “DOUBLE DEC’ER BOARD” and the bottom one “ETOTHEIPIPLUSONE.NET”, and both are in copper.

I couldn’t decide on a more productive use of the “overhang” space under the left DEC – but maybe later.

With luck, I should get these boards in the same timeframe that the USPS and China Post figure out what to do with my battery packs.

3 thoughts on “Deathblades: The Double DECer board”

  1. I have that library installed. Unfortunately, it only seems to contain component level footprints, not any of their breakout boards or similar. I guess I could always just design in some headers to take their place, but I prefer the actual part to lessen the possibility of confusion…

  2. Don’t forget to put 0.1 uF ceramic caps across the power connections of *everything*.

    Putting caps on the output of the voltage regulator is essential. Putting them elsewhere is purely good electronics hygene (it’s hard to have too much power suppy capacitance).

    In this situation, the LM1117 actually calls for a 10 uF tantalum cap close to it’s ouput terminals. You may get away with using just whaever internal capacitance the XBee has, but it’s a really bad idea. Also, the reg may decide to oscillate randomly, or all the time.

    Check the datasheets for all the components, and look for power supply bypassing info. The VReg has some specific ESR requirements (section 1.3 of the datasheet).

Comments are closed.