We launched a new project: TwinTeeh Plus: the PCB mini-factory
DiyouPCB MK-I Features
The printer has been designed to use any photosensitive material to the laser wavelength (405nm) although the tests were performed with negative Dry-film (blue color).
- Print area: 210mm x 170mm
- Laser wavelenght: 405nm
- Auto-focus: through astigmatic method
- Diameter of focused laser beam: approx. 0.1mm
- Print speed: 600mm/min.
- Travel speed: max. 15,000mm/min.
- Dimensions: 385 mm x 345mm x 100mm
- Weight: approx. 2.6Kg
- Power: 110V/230V, 50 - 60 Hz, 2A
- PC Requirements: Microsoft Windows XP/Vista min. 1 GB RAM, min. Graphics 1024 x 768 pixels, USB 2.0 port.
- Electronics: based on Arduino ONE
We used the famous Toshiba PHR-803T Blu-Ray™ pick-up (really it's HD-DVD). We though we could use a Blu-Ray™ pickup laser diode to sensitize Dry-Film: a photoresist material very popular to print PCB's. Dry-film is easy to use (adheres to the copper board through heat) and has a reasonable price ($15-$20 per m2). We have used it extensively with very good results.
The idea of using a Blu-Ray™ laser diode is not very original; we found some experiences of this type on the Internet, all based on removing the diode from the pickup and installing it on a CNC machine or a laser printer.
But we din't want to tier down the PHR-803T because it is a jewel of engineering; we hate to destroy things (although finally we broke some of them to learn how they work). In addition, we wanted something as simple as buying the pickup and connect it to the printer. Fortunally the lack of PHR-803T technical information forced us hacking it. :-) And using reverse enginering we figured out the connector pinout and took advantage of the complete system: auto-focus, lens up and down, laser power, laser oscilator, etc, all through it's own electronics.
We started the project in February 2013 but break on several times thinking that it was not feasible. Finally, in October 2013, we did all tests successfully. In total it have been about 8 months of work.
As we said later we wanted to build the printer without tier down or or re-use other ink printers or CNC machines. For this reason we designed everything from scratch. We thought that our PCB printer had to be low-cost, easy to build and "printable" with a 3D printer. We wanted to use an Arduino ONE for the electronics, although is very limited in terms of CPU speed and memory. We found on the web some experiences of people buiding CNC machines with it and the most important thing: there is open-source CNC firmware available that we could modify and adapt to build our printer. That gave us hope.
The software had to be also very easy to use. The idea was to use Eagle Cadsoft to design the circuits, then generate the files for printing the PCB's and send them to the printer.
We began to refine the tool-chain: Eagle as electronic's CAD, GRBL as firmware and we should also develop the server tool that will allow to send the files to the printer. The easiest way to do it were using g-code file format, but Eagle doesn't generates it so easily so we finally decided on HPGL: a simple and easy option used in many plotters. We had only to implement the basic HPGL commands, not the complete set. This were perfect because the Arduino does not have too much memory.
For the first tests we replaced the Dremmel of our CNC router by a laser diode withdrawed from a Blu-Ray™ Pickup. These laser diodes emit light near the UV band but we had doubts about if it would enough to sensitize the dry-film. We did some testing and it worked. The laser started to "paint" in the film but in a very rude way, probably because it emited too much power or lack of focus.
We saw that it would be more easy to print up than down. The printed had to be something similar to scanners or photocopiers. Just open the door put the copper board on top of the window, close the door and press the print button.
Printing is as simple as opening the door deposit the PCB on the glass and press a button.
The PHR-803T incorporates a UV laser diode on the 405nm wavelenght. The spectrum is more than enough to sensitize the dry-film, but we could'nt find any technical information about it. We sent several e-mails to the manufacturer without success. After searching all the web we decided to open and analyze some of them.
The pickups are cheap, costing approx. 10$ so we bought some of them and tried to find out the pinout through reverse engineering.
Hacking the PHR-803T
The PHR-803T is a masterpiece of engineering manufactured by Toshiba. It's an optical HD-DVD pickup very well known in the market because it's used in the Xbox360. Nowadays, optical storage technology has been largely superseded by other technologies like flash memories. In fact Toshiba has discontinued HD-DVD readers/writers so there are in the market many spare parts at low prices.
The pickup incorporates some interesting stuff:
- Two laser diodes: one of 405nm (HD-DVD) and another of 650/780nm to CD/DVD.
- A focus lens and coil servos for auto-focus, tracking and correction angle.
- A photodiode array which receive the RF signal and help focusing and tracking.
Thanks to the page of Sam (Sam's Laser FAQ ) we learned a lot about how the laser works and got the little information available about the PHR-803T on the Internet. Sam include in his web a very interesting photo of a exploded view that helped us to identify its components.
If we see the picture on Sam's page, the laser operation is relatively simple:
- The laser diode (2) emits UV light that is conducted through a system of mirrors and prisms until the focus lens(12).
- This lens can be moved in several axis using three coils. This allows the pickup to focus the laser on the disk, follow the audio track (tracking) and correct the laser angle.
- Once the laser is reflected on the disc surface, it goes back through the lens (12) and through more prisms and mirrors is redirected toward the photodiode array (4) where we get the RF signal as well as the signals needed to correct the focus and align the laser with the track (tracking).
- To make the auto-focusing, the electronic reader reads the signal from the photodiodes (4) and moves the focus lens(12).
All the information about optical pickups is often classified. It is possible to obtain only superficial information about old models of CD or DVD readers. Thanks to them we began to learn about optical pickups and got very valuable information to deduce how use the PHR-803T. After all, the DVD technology was an improvement on the CD, and the HD-DVD/Blu-Ray an improvement on DVD, so we thought that the techniques used should be similar and the pinouts similar as well.
For our purposes we just needed to turn-on the laser, modulate his power and focus it properly on the PCB. The PHR-803T has a FPC connector of 0.5 pitch with a 45 pinout. Only connect some wires to the connector took us some time. We finally designed a special breakoutboard to easily "snif" the signals.
The testing breakoutboard
The PHR-803T turned-on.
We followed the traces on the flexible PCB to deduced some pins.The more obvious were the traces from the connector to the lens coils. We found also the pins of GND and VCC which are several (2.5V, 5V and 9V).
The ATR0885 IC
Under the microscope we saw that the pickup uses a chip: the ATMEL/ATR0885 and we found on the Internet its Datasheet. It is the HF driver that manages the laser diodes. We got also the datasheet of the 405nm laser diode. We are not sure, but we believe it's the Sharp GH04P21A2GE . Curiously, the laser diode has a tiny QR code, but we couldn't read it.
The laser diode.
In adtition to the microscope, we also used an old oscilloscope. Burning some pickups we conducted some tests and finally we figured out the pins we were interested on: 405nm laser on/off and current control, the VCC pins and four photodiodes signals, called in almost all pickups tech. references A,B,C,D signals. Adding and subtracting these signals the DVD reader conforms the called Focus Error (FE) signal, which tells the reader if the laser is focused. We think that we also know the pins of the RF signal but we have not investigated enough. Anyway we do not need it to build the printer.
The photodiode array under the microscope.
The Pickup Driver circuit
Once we found out the pins, we move on to designing the circuit that would allows to control it, mainly we needed: turn on/off the laser, control the intensity, move the focus lens, read the photodiodes signals and be able to perform auto-focus .
We call it the Pickup Driver.
The pickup driver circuit.
More complex was to obtain the Focus Error signal (FE) since the original DVD readers implement complex electronics that focus the laser on the disk in real time. Play with it was complety out of the scope of our project, so we though we can did something more simple because we didn't need to focus the laser continuously on the PCB. We only needed to focus the laser at the beginning of printing, but of course not directly on the board, because it is not very reflective but we also risk to sensitize the dry-film during the focus process. Finally we decided to use some type of reflective material in one of the printer's corner that would be at the same pickup distance than the PCB and where the laser could focus before printing. We did it with a square of 10mmx10mm of alu. foil and and !it worked!
The first Pickup Driver prototype
Before we begun to design the mechanical parts and decided to buy materials and spent money, we thought could be a good idea to install the pickup in our 3D RepRap printer, replacing the extruder. We put below a PCB covered with dry-film and we conducted some tests. When we developed the film we saw that the idea could be feasible, but there was a lot to improve.
The PHR803-T and the Pickup Driver installed in our 3D printer.
Auto-focus: the astigmatic method
Optical pickups focus on disc using the so called astigmatic method.This method is based on the deformation of the roundness of the laser beam when it is unfocused. The pickup has a series of lenses that lead the reflected ray to a photodiode array which generates four signals (A,B,C,D). Using them it is possible to deduct if the laser is unfocused and move the lens to focus it correctly.
The photodiode array
Once you know the A,B,C,D signal pins, implementing the auto-focus algorithm is easy: just add A+C and subtract B+D from the result. The pickup returns those signals in the form of minimum current variations that depend on the laser light received by each photodiode. The photodiodes are arranged in a square (see following figure). As you can see, it is possible to infer the focus level checking if the result is less than 0 (too close) equal to zero (focused) or greater than zero (too far) and with this information move the lens until the laser is focused.
The astigmatic method
It seems easy so we bought some high-speed op-amp (TLC2274C) to amplify and combine the signals and obtain one that we could interpret in an Arduino analog port.
Tunning the laser
After some testing we began to have an idea of the laser power needed to sensitize the dry-film. It depended on the printing speed and power. Too much power at low speed and the laser overexposed tracks surroundings. Less power or high sped and the laser didn't sensitize enough the photoresist. All these tests we did were focusing manually, by moving the Z-axis of the RepRap 3D printer up and down. Although the Pickup Driver was generating the FE signal, we had not yet developed the Arduino's software that would read the signals from the photodiodes, so we run manually.
Right away we saw an additional difficulty: the laser power needed to sensitize the dry-film generated an excess of light (halo) surrounding the main laser beam and exposing the tracks surroundings. There was no way to fix it. If we reduced laser power the halo disappears but we couldn't sensitize the dry-film. We were close of abandoning the project.
First blurred testing
Solar Film: the solution
We have no idea of optics and we didn't want to modify the pickup, nor of course change their lenses.
Inspired on a sunny day we though we would install sunglasses on the pickup and filter out the excess of light.
We tried with some kind of sunglasses and it works, but how would install them in the pickup and at the correct distance? In addition sunglasses are expensive and this solution broke several of our design rules: low-cost, not tier-down, easy to do, etc. Finally, we found a better solution: solar film.
Solar film is this kind of sun protective film used in home and car windows to filter UV light. It is very cheap and it's sold with different degrees of UV filtering so we tried with one semi-transparent and it worked.
The film is self-adhesive and we simply pasted it on the printer bed glass. It is cheap and meets all the requirements. It also protects our eyes in case of accidental printer door opening while the laser is turned on.
First decent printing
The auto-focus algorithm and the S-Curve
At this stage we could sensitize the dry-film with good quality but still focusing manually so we boarded the development of the auto-focus algorithm.
The Pickup Driver circuit performs the operation ((A+B) - (C+D)), generating a Focus Error signal. Our goal was read that signal, interpret it and move the lens to the appropriate focus point. But… .once more it won't be so simple.
While snifing the FE signal with the oscilloscope we saw a lot of back noise. We try moving a DVD disc in front of the pickup and we appreciated (once in a while) a very fast sinusoid wave. At that moment we did'nt know it was the famous S-curve. For some reason that we unknow, the photodiode array get excited only when there is a variation on the disc distance. In other words: we must move the pickup lens up and down to trigger the wave.
Reading some CD's manuals we understood how it works.
The algorithm is as follows:
- Turn on the laser. (Note that if the laser power exceeds a certain threshold the photodiode got saturate).
- Move the pickup lens bottom and them up to determine the amplitude of the S-curve (and also detect if there is a disc or not).
- If there is no disc, generate an error. (In our case if there is no reflective material or if it is far away from the pickup).
- Immediately move the lens up and down while monitoring the signal.
- If the signal is equal to the amplitude divided by 16 the laser is focused (in our case we have set this threshold at 48 because we don't neeed such precision, in fact focus too much produces a laser beam below 0.1mm wide and this is a problem more than a solution).
To implement this algorithm in the Arduino, we filter the back noise and sample the signal with an analogue port. Then we analyze the signal in real time, while we moved the lens up and down with another thread, until we detect the S-Curve and found the focus point. The method is not 100% reliable and has some margin of error so we run the test a number of times and check the values obtained.
The mechanical parts
We thought that the printer could to be based on a simple cartesian robot with two axis X/Y moving the pickup in a given area. We didn't care about the size of the printing area because we will use stepper motors with enough power. Was the same for us to make it small or large and finally we choose a size of 210mm x 170mm. We have never done PCB's so large but you never know when you need it.
Some printer parts.
The laser beam should be pointing up so we could support the PCB on a glass. The glass should be very thin as the focal distance of the pickup is only 1.6mm.
This glass is installed in a plywood window. Previously was necessary to paste the solar film on the bottom of the glass and installed a few screws in the window to adjust the height of the glass to the pickup. Finally we glued a piece of reflective foil (aluminum) in one of the corners (home position) where the laser will focus before printing. This foil is above the glass so it is at the same distance from the pickup than the PCB.
Bottom View of the printer bed glass with a PCB on and the solar film at bottom. In the top left corner you can see the reflective aluminum foil where laser beam focus.
The first idea was move the pickup on one of the axis (Y) using their own 3mm bronze bushing.
First prototypes used the own 3mm pickup bushes.
But we saw that the shafts flexed too much and decided to replace them with 6mm shafts. We preferred to use bronze bushes instead of ball linear bearings because their greater precision, even though it takes more time to calibrate the distance of the axis to fit well since they have to slide smoothly.
The 6mm bushes
To move the axis we used two NEMA 16 stepper motors, two pulleys of 16 teeth and T2.5 timing belts.
Nema 16 stepper motors.
We also designed two belt tensioners with bronze bushes as idle pulleys. They allows us to adjust the belt tension easily.
The belt tensioners
We use plywood for the printer base and printing bed window and a couple of pieces of threaded rod to create the printer framework. It allows easy width calibration of the X-axis.
The rest of the parts were printed in PLA so DiyouPCB is easy to replicate as a RepRap.
RepRap printing DiyouPCB parts.
When we begun to test the new mechanic we appreciated two problems. The circles were oval (the famous problem of squaring the circle) and some lines appeared as bitten.
Some circle an arc testing.
Circles and pads were not completely round. Appeared deformed and sometimes even square.
Reviewing the software we do not appreciate any major defect so we analyze the mechanical design.
The belts were tight and the motors adjusted to the correct current. The guides apparently swinging well. We were searching what could happend in CNC forums and we found that is a frequent problem generated by belt backlash. It usually happens when the motor change direction. But belts were new and properly tensioned so we could not improve too much. Finally we modified the firmware in order to compensate the backslash. We add a few extra steps to the motors when they change direction. This type of adjustment is usual in CNC software.
The other problem was that at certain speeds the lines appeared as bitten.
Detail of bitten lines
We make several assumptions trying to find out the cause of the bites. Finally determined that were due to motor vibrations and belt resonances. Vibrations originate mainly at Y-motor.
All of the stepper motors generate some kind of vibration. These vibrations are transmitted to the pickup though the belt, making it vibrate and causing the laser beam moving a few microns.
Bizarre vibration damper
After many tests and some bizarre designs (see photo above) we saw that it was almost impossible to entirely eliminate vibrations and the solution was to modify the vibration frequency until they were "invisible". We didn't want to change the dimensions of the printer so we adjust the speed of the motors and we designed a more rigid Y axis cart using shafts of 6mm and larger bushes that will increase the contact surface with the rods. This also increased friction which reduce vibrations. The motors have enough power to move the new cart so it wasn't a problem and definitively solved the "bitten lines" effect.
Final design with 6mm shafts and rigid pickup support
We are still fighting with vibrations. In order to avoid them, we should substitute the stepper motors by servos but servos are expensive and we spent all our budget.
We use three parts for the electronics:
- Arduino ONE
- DiyouPCB Pickup Driver (PD) - responsible for managing the pickup and to adapt the focus signal.
- DiyouPCB Controller Shield (PCS) - an Arduino shield responsible of hosting the motor/lens drivers and connect all the stuff to the Arduino.
The Arduino and the Printer Controller Shield PCB
The Shield prototype with some provisional patches.
We decided to use a ribbon cable to connect the Shield to the Pickup Driver so we could use the same cable to carry all the signals to the printer carriage. For the Y axis we used the own FPC cable of the Pickup. We installed two end-stops switches in the own cart simplifiying in this way the wiring. Finally we had to add an additional shielded wire for the FE signal to prevent back noise produced by PWM.
We adopted the famous A4988 Pololu stepper motor drivers. They are inserted into the Shield very easily.
The entire set is powered by a single external power supply of 12V 2A.
The software tool chain neeed to manage the printer is as follows:
- With Eagle Cadsoft we develop the circuit and generate the HPGL file, one for each PCB side.
- With DiyouPCBRun, a tool we've developed, we sent the files to the printer.
- In the printer side we developed DiyouPCBFirm: the Arduino firmware which parse the HPGL commands and manage the printer.
For the printer firmware we decided to use GRB, a 3-axis CNC firmware for Arduino UNO written by Simen Svale Skogsrud. But the way GRBL managed the acceleration curves were not suitable for printing. It was designed for CNC routers that feed wood or metal very slowly and in our printer we needs just the opposite because the pickup weighs a few grams and we can accelerate it very fast. So, we tried with Marlin, which is a mashup of several 3D printing and CNC firmwares, including GRBL. It support accelerations of up to 3000 mm/s2 and actually worked better.
Marlin was writen by Erik van der Zalmruns for the Arduino Mega but we wanted to use Arduino ONE that is more limited. So we had to prune all the program and incorporate extra code to control the laser,read the focus signal and move the lens up and down. Both, GRBL as Marlin, use g-code as numerical control language so we removed also the g-code parser code and implemented a basic HPGL parse, which is the language we used in the printer.
At the server side we developed DiyouPCBRun with Processing.
DiyouPCBRun is responsible for reading the HPGL files and send it to the printer. The resident firmware in the Arduino receives the HPGL commands through an USB port and draws with the laser beam the circuit while DiyouPCBRun shows you the job evolution.
Printing the Pickup Driver PCB. You can see the evolution of the work in real time. At right, the HPGL commands that are sent to the printer.
The final result
The first circuit that we made with the printer was his own Pickup Driver PCB. We wanted to prove that the printer could print his own electronics. Once again self-replication. :-)
The pickup driver PCB.
The printer is still not perfect. We should further improve the printing quality and solve the problems of the vibrations caused by the stepper motors and the induced by the use of timing belts (backlash and resonances). But is a good prototype to experiment with blue-ray pickups and UV lasers. At this moment, the printer is an experimental model that can be use it to investigate and try to go beyond his limits. If you decide to build take it in consideration.
Distribute and copy DiyouPCB
DiyouPCB is an experimental open-source project for both hardware and software. It can be distributed, copied and manufactured under the terms of the GPL license V3 (GNU General Public License).
We have designed DiyouPCB with much effort in the hope that it will be useful, but WITHOUT ANY KIND OF WARRANTY; tacit or implicit to no particular purpose. The printer is not perfect. It's simply an EXPERIMENTAL PROTOTYPE which will allow you to research about the use of blue-ray pickups to sensitize photoresist materials.
For more information on the terms of the license see http://www.gnu.org/.
We are already working on the next project: DiyouPCB MK-II.