[01.14.2015] I designed a very simple $2 circuit board to breakout a “TRRS” (Tip-Ring-Ring-Shield ) 3.5mm headphone jack that you see all over the place these days. I’m wanting to drive multiple channels of an oscilloscope and the 3 RCA to 3.5mm TRRS cables seem to be in use everywhere and would be useful for low bandwidth ( ~50MHz ) applications for capturing digital state transitions ( not so much signal integrity ). The TRRS jacks exist in smart phones to support earbud head sets with microphones and also in video devices ( video iPod, camcorder, etc ) to deliver Left and Right audio plus a Composite video on 3 conductors plus a return instead of the normal “TRS” Tip-Rings-Shield 2 conductor stereo connector. Digging into to their pinout I was astonished to find out that mechanically all the TRRS plugs and receptacles seem compatible, but electrically EVERYBODY wires them up differently. The return signal actually isn’t the “S” ( shield ) for most manufacturers ( although it is for some ). The “S” is return for 3.5mm mono, 3.5mm stereo, but not necessarily 3.5mm TRRS 3 conductor. Some devices go in the TRRS order of “Audio-Audio-Ground-Video”, some “Audio-Video-Ground-Audio”, some “Audio-Audio-Video-Ground”. I looked up various TRRS to RCA cables on Amazon and about 1/2 the reviews said things like “piece of junk – didn’t work” or “audio on only one channel, no video” or “didn’t work until I plugged the red into video and yellow into audio jack”. What a disaster. How much does this cost Amazon in returns? Bad design decisions like these are made by electrical engineers and it really makes the industry look bad. I ended up going with the “Camcorder” ~standard~ as at least multiple manufactures agreed to it for video cameras ( but of course I won’t be able to use an Apple video cable ). I found a good writeup up on this whole TRRS mess here . To think electrical engineers helped get men on the moon in 1969.
[ 01.12.2015 ] Assembled my new USB 2.0 12Mbps UART board today. Thought I would take the opportunity to blog about the entire process from start to finish – board design, procurement, surface mount assembly and final test.
[ 12.23.2014 ] Started new ExpressPCB 2-layer design for a small 1″x0.5″ board to replace a standard 1Mbps FTDI Cable but run 12x faster using a USB 2.0 chip from FTDI – the FT232H. All of my previous FTDI board designs have used the FT232R as it is a smaller chip that includes an oscillator and all the USB passives on chip. The FT232R interfaces to USB at a conservative 12 Mbps versus SERDES 480 Mbps for the FT232H. The FT232H requires a lot more support circuitry ( 12 MHz precision oscillator, protection diodes and is in a bigger package ). Expecting a 2-layer PCB to work at 480 Mbps was a huge $3 gamble I was willing to take.
[ 12.26.2014 ] Finished the design ( working on it part time – had other things going on the last few days ). Typical design flow is schematic design and then have a computer autoroute. My flow is quite different in that I manually place components where I think they can be routed using only two layers and also assembled by hand in as small area as possible. Using ExpressPCB version 7.0.2 (only), layout is done manually using a vector drawing program. Red signifies copper on the top, green copper on the bottom, yellow silkscreen on top for labeling. Designing a PCB like this is very much a challenging puzzle. After I finish the design, I import the ExpressPCB file into CopperConnection and export a single *.ZIP containing layer Gerbers and Excellon drill files in OSH-Park selected format. This process takes about 10 seconds. I could actually layout my board design in CopperConnection – but I already know ExpressPCB – so why bother learning a new tool? ExpressPCB is a great service for at work when I need a board fast. When I’m not in much of a hurry, OSH-Park is super inexpensive and high quality.
[ 12.26.2014 ] Uploaded Gerber and Excellon *.ZIP file of design to OSH-Park. The website takes a few minutes and presents a rendering of all the different layers ( Copper, Solder Mask, Silkscreen, Drill holes ). Approve and purchase the design 0.61×1.21 inch (15.39×30.66 mm) 2 layer board for $3.65
Here is an example OSH-Park panel that I found on the web that they showed at a Makerfaire in Portland in 2013. Notice how small all the designs are and how much daylight shines through. Their software does a fantastic job of panelizing multiple small gerber designs. Other low cost PCB places like IteadStudio stick with simple fixed rectangles on a 5x5cm grid and charge on those dimensions even if your design is much smaller. I often look at other people’s OSH-Park designs at flickr site to see how far they stretch the 2 layer and 4 layer capabilities.
[ 01.10.2015 ] Bare boards arrive in the mail. They usually have rough snap-off edges which are easily filed down with a metal file.
[ 01.12.2015 ] Surface Mount Assembly begins. My tools are a 10x/30x microscope, a Weller-Ungar 921ZX soldering station with a screwdriver tip, GC Electronics Liquid solder-flux 10-4202, Kester “44 Rosin Core” lead solder 66/44 0.5mm .020″, Chem-Wik 0.075″ solder wick, Isopropyl Alcohol 99.8% IPA, Cotton Swabs, Dental Pick, Tweezer and “Dexter” leather gloves. I also have a 4″ surplus case fan at the back of my microscope to take away the fumes.
I always start by placing the QFP 1st as alignment is crucial with 0.5mm pitch between pins. Once the package is perfectly aligned ( 10x magnification ) I pour solder flux liberally along the perimeter. Flux is amazing stuff, not only does it perform Jedi mind control on molten lead to seek out copper and avoid solder mask – but it is wonderfully sticky stuff and does a fairly decent job of keeping the QFP from drifting out of alignment. That said – I always tack down the corners first with just a bit of solder and then pour the solder on thick – rolling across all the leads. End result – complete ugly mess, shorts everywhere – but the leads are all attached to their pads in perfect alignment.
Pass-2 ( you knew there had to be a pass-2, right ? ) – Solder Cleanup. The wick combined with the flux on the board magically sucks up the excess solder shorting all the leads. This step gets really hot really fast. I protect myself ( finger tips ) with my Dexter gloves ( thin unlined leather ) so I can position the wick and not burn myself. I protect the chip by only wicking about 4 pins at a time then pull back and let the IC cool down for a few seconds before proceeding. Takes patience but perfectly soldering an internally fried chip to a board is a real bummer. I do own a nice hot air reflow station where I can remove bad ICs -but I generally would rather just start a new board assembly from scratch than rework a bad one.
Pass-3 : This pass is optional, but is worth the effort. Apply lots of IPA ( the kind that makes you go blind – not the tasty beer ) and cotton swab scrubbing to remove all the flux.
Pass-4 : With the QFP clean, I crank my microscope up from 10x to 30x and go around to each pin with a dental pick and check for bad solder joints ( loose pins ) or any shorts. I usually don’t find any, but the time to check is before all the other components are soldered to the board as access to the QFP pins becomes difficult if there are other components around.
Once the QFP is on everything else is pretty straight forward. I only use 0603 for Bypass caps ( 0.1uF ) and 0805 10uF Bulk Caps and 0805 resistors. This speeds up assembly as I don’t need to look up each component in the design file, I can tell just by the pad size and what its connected to determine what to place. For example – I never connect a 0805 resistor between power and ground – so it must be a 10uF bulk cap. For the small SMT 0603s and 0805s I drop a bit of solder on 1 of 2 pads, then apply to component with tweezer and resolder the 1st pad to the component, then with the component firmly ( fully planar ) attached to the board, I apply solder and the iron tip to the 2nd pad. After this, the 1st pad usually needs some more solder to make a good looking connection. Thats it – I’m done with assembly!
Before test – I take a moment to reflect and decide what I would do differently to make assembly easier in the future. For this design the microUSB connector was a problem. It is designed for solder paste and oven reflow assembly as the leads are recessed behind the shield housing. I was able to solder them eventually, but a little more space between the connector and QFP would have been better. Mini-USB is MUCH easier to hand solder. Another issue I discovered is the shield extending behind the leads unexpectedly results in the shield resting above my 5V trace on the top side. The solder mask is the only insulation preventing a short from 5V to shield return. Prior to plugging into my computer, I applied my 5V DC supply to 5V PCB rail and the shield and confirmed no short. This is OK for a one-off, but I immediately created a new “fixed” version of this design and moved the 5V trace south about 0.010″ to clear the shield. For $3.50 I will probably fab out this “fixed” version and scrap the remaining 2 unstuffed PCBs of Gen-1 if I decide I need more than 1 unit. The micro USB connector was the only issue, so moving on….
Time for test. Plug and pray a micro USB cable from my computer into the board. And look at that! COM5 ready for use.
1st test is to send 9,600 baud to my scope. Bit length is about 100us, or roughly 10,000 Baud.
2nd test to send 921,600 baud to my scope. Now the bit length is about 1us, or roughly 1Mbaud.
3rd and final test, run my Powershell script that talks directly to FTDI device driver DLL and configure port for 12Mbaud.
Excellent! I’m in business. I now have a USB 2.0 to 12Mbps UART serial interface into my FPGA designs that is electrically and mechanically compatible with my existing FPGA boards ( that are designed for the industry standard FTDI cable ). That ends my Black Mesa activity for tonight. Next tasks are to change my FPGA design for the faster baud rate ( simple divisor setting in Verilog ) and establish Backdoor communications (Register Reads and Writes using BD_SHELL.exe ) and then time SUMP.exe data dumps from FPGA to computer and compare date rates between 1Mbps cable and 12Mbps board. Due to Windows and Powershell limitations – it may or may not be faster. If it is faster ( like 10x faster ) – my next iteration of the design is ready to be assembled. This uses the same chip, but interfaces using 16 wires over a Nano x16 header instead of the FTDI 2 wire 1×6 connector. Spec says transfer rates should be 40 MBytes/Sec ( 320 Mbps ) – which theoretically would be 27x faster than my existing design that is already 12x faster than my existing FTDI cable. That project is for another day however.