Path: Home => AVR overview => Applications => UV-LED exposure with Timer   Diese Seite in Deutsch: Flag DE Logo
UV-LED exposure

UV-LED exposure unit with timer ATtiny2313

This application describes a UV-LED array to expose fotosensitive PCBs and an ATtiny2313 timer to control the exposure time.

The UV array can have two sizes: with 98 and with 169 UV diodes. The larger version allows the exposure of Euro-sized PCBs (160-by-100 mm), the smaller has problems with those. The UV-LED array has the following properties: The timer device with an ATtiny2313 has the following properties:

0. Content

1 Hardware

1.1 Exposure-Hardware

Scheme Exposure The hardware of the UV-LED exposure consists of 14 resp. 25 constant current sources with an npn transistor BD439, driving seven resp. six UV-LEDs with 19.5 mA each (average). Neither the varying hFE of the transistors nor the number of LEDs per row (six or seven) nor a varying operating voltage has an influence on the constant current sources, as long as the operating voltage is large enough:
Vmin = VLED + VEmitter + VCEsat
= 3.2 * N + 4.3 + 0.2
= 26.9 V (N = 7)
= 23.7 V (N = 6)

The operating voltage does not need to be stabilized and can be as high as 45 V without forced transistor cooling.

The base voltage is either at 5 V to switch the UV LEDs fully on or below 0.7 V for UV LEDs fully off. The current required is between 2 and 3 mA, so can be supplied by any portpin output of an AVR. The base current would be up to 24 mA, if all hFEs of all transistors would be at their minimum guaranteed value of 20 and if 25 rows were driven. At average the hFE in my case was 137 (123 minimum, 150 maximum).

The Zener diode with 4.7 or 5.1 V at the base of the transistors protects the LEDs from extensive currents that would be associated with an overvoltage. With a disconnected timer unit the Zener diode and the 2.7 k resistor provides a 5 V source voltage at the bases of the transistors and, by default, switches the UV-LED diodes on.

UV light Dangure! The light is very intensive. Direct exposure of your eyes can cause serious damages. Via the input clamps named "Base" the driving voltage can be tied to zero volt, and the UV-LEDs are switched off.

Assembling the components and the UV-LEDs on a 10-by-16 cm breadboard is shown in the Layout for the smaller version. The black dots are UV-LEDs, the yellow rectangles are transistors, the lightbrown rectangles resistors, the blue rectangles clamps and the red rectangles are spare place for screws. The layout shows the component side, all components are mounted on top of the board. On the bottom side, the components are soldered and connected using enameled copper wire.

Extension layout The enlarged version adds 71 additional UV LEDs on a 80-by-160 mm PCB. The picture shows the wiring of the columns with seven resp. six LEDs.

Coverage of the LEDs in the enlarged version The picture demonstrates the coverage of a (here as black background plate) Euro PCB. The angle of the UV LEDs is at 30°, the distance of the LEDs from the PCB is at 120 mm, which means a circle of 64 mm diameter.

The picture shows that the coverage on the three PCB edges is not at average. It is therefore recommended to cover the three side walls of the casing with aluminium sheet to enforce UV light mirroring on the edges.

1.2 Power supply

The exposure devive needs 26 V operating voltage. Voltages above that level are consumed by the Collector-Emitter of the transistors and increase their heat power. Up to 45 V can be applied without forced cooling of the transistors.

The smaller version consumes roughly 300 mA, the larger version 470 mA. Power supply for LEDs This shows such a power supply. A fuse of 500 mA limits the wall current, a 30VA toroidal transformer with two secondary coils of 30 V supplies the 30 V, two power diodes and two parallel 2.2 mF electrolytical capaitors form the DC.

Voltage without load This shows the voltage on the capacitors on start-up of the power supply. The classification of the capacitors for 50 V is required as minimum, as the picture shows.

Voltage with 500 mA load At a load of 500 mA the voltage decreases down to 36 V. At 470 mA I measured 37 Volts, which is well in accordance with the simulation. This is by far enough voltage for the LED operation. The voltage swings of 0.69 V (at 50 Hz) are easily suppressed by the constant current regulating transistors.

Mounting the power supply The picture shows the mounting of the toroidal transformer and the small PCB with diodes and capacitors in a wooden box.

1.3 Timer-Hardware

Timer-Scheme The ATtiny2313 is clocked with an external xtal of 2.4576 Mcs/s.
The LCD display is connected via a 14-pole connector to Port B (eight data bits), to the portbits PD0 and PD1 (control bits RS and E) and to the potentiometer (contrast adjustment).
The three keys (white, black and red) are connected to the portbits PD2, PD3 and PD4, the resistors 4k7 and the tantal capacitors 4µF debounce the keys.
On portbit PD6 a two-coloured LED is connected to display the operating status. The board is supplied with 5 V, via the voltage regulator 7805, from the supply voltage of the UV-LED array.
The in-system-programming interface is available via a standard KANDA connector. You can also use a 6-pin connection instead.

Some caution is required if you supply the base voltage without the LED operating voltage in place. In this case the CE does not deliver current and
Ibase max = (5 V - 0.7 V / 440 Ω = 9.8 mA

flow into each transistor base. With 14 rows this is theoretically 137 mA, with 25 even larger. This is more than a portpin of an AVR can deliver and the 5 V operating voltage can break down, by that interrupting LCD operation. The transistors are not at risk.

1.4 Alternative 5V supply

In the schematic of the timer a 7805 regulator is shown. This can only be used if the LEDs are powered by an external power supply with not more than 30 V. If the 30 V power supply is used, which can have up to 50 V (without load), such a regulator would not be usable (due to over-voltage). An alternative supply for the 5 V of the timer can be build as follows.

5V power supply from 30V This has a little bit more components than an integrated regulator but works with the 30-to-50 V power supply.

On the input a green LED (with two resistors) and a Zener diode (also with two resistors) reduce the no-load voltage of the power supply down to transistor-friendly 42 Volts. The Zener diode of 9.1 V is blocked by a 10µF capacitor to suppress noise. The base of the transistor BD439 is at 9.1 Volts, its emitter at 8.45 V. This goes into a small 78L05 integrated regulator. Du to the small input voltage difference, the 5 V supply can deliver up to 100 mA current. The transistor should be cooled with a small 20 K/W heat sink.
To the content list

2 Operation

2.1 Operation of the exposure unit

Exposure Box The UV-LED array should be mounted in a minimum distance of 15 cm to the PCB. A larger distance is of advantage, because it smoothes the exposure at the borders of the PCB.

Exposure Cover Advantageous is mounting the array to the inside cover of a wooden or plastic box, that is high enough. The box then protects the eyes from the intensive UV light. You can purchase such boxes or build your own one.

2.2 Operation of the Timer

After connecting the timer unit to the operating voltage, the LCD displays a message with the function of the device, the software version and the copyright of the software for a few seconds. After that period the device is ready and the LED shows green light.

Key operation Pushing the white key prolongs the exposure time by 10 seconds, the black key diminishes exposure time by 10 seconds. Pushing the black key while holding the red key down stores the exposure time in the internal EEPROM. Pushing the white key while holding the red key down starts the exposure. Pressing the white key again while holding the red key down stops the exposure cycle. During exposure, the LED blinks red.

The necessary exposure time for your PCBs can be determined by tests. In my box with 14.5 cm height the optimal exposure time with a laser-printed thin sheet and a 1 mm plastic panel on top is roughly four minutes.

Box from above That is how the box looks like from above.

That is how the extended LED field looks like.

Extended LED field Extended LEDs on

To the right the LEDs are switched on. The previous LEDs and the extended LEDs obviously have different intensities. But I have not seen any difference in exposures of large PCBs, so the difference is academic.

To the list of content

3 Software

3.1 Software Source

The software for the timer is available in HTML format or as Assembler source code file. The assembled Hex code file and a prepared EEPROM hex file is also available.

3.2 Fuse selection

Warning! New ATtiny2313 by default have their internal RC generator as clock source. After burning the flash and before using the timer, the ATtiny2313 has to be changed to use the external xtal as clock source. This is done by setting the appropriate fuse. Be sure you change the fuse setting with an external xtal connected. Otherwise the fuse setting process fails and error messages result. The easiest way is changing the fuse setting with the ATtiny2313 mounted in the target circuitry.

To the list of content

©2009 by