Thursday, May 11, 2023

Modifying Scionix-Holland 38B57/1.5M-E1 Scintillating Detector

 Commercial scintillating detectors are very expensive - hundreds, often thousands of dollars for a good NaI(Tl) detector. They are not always affordable for amateurs, even on the secondhand market but for many applications they are the only solution.

There is a hidden, and often overlooked and underestimated gem though, made by a leading in the scintillator business Dutch company - the Scionix-Holland 38B57. This detector is nearly impossible to beat when it comes to price and it is pretty much "the best bang for the buck", delivering an incredible performance for its very low price on the used parts market. The detector was manufactured as an OEM part about 10-15 years ago and not available for purchase as new but there are plenty salvaged units, offered by various Internet sellers.

The 38B57 is a "classic" NaI(Tl) detector - the crystal is 38mm by 57mm (1.5" x 2.25"), surrounded by reflective powder, coupled with a 38mm Hamamatsu R980 10-stage head-on PMT and mounted in an Aluminum + Stainless Steel tube enclosure.

38B57 is employing an integrated design - the NaI(Tl) crystal is not encapsulated in its own aluminum can, but it is directly interfaced (glued) to the PMT's Head-On photocathode window and then both, PMT's front part and crystal are sealed together in an air-tight aluminum can. Then the assembly is wrapped with the Mu-metal magnetic shielding and together with the VD PCB is housed in a stainless-steel tube with an aluminum end-cap. 

The integrated design keeps the cost down, but it means that this detector is not really serviceable beyond its voltage divider circuit / PCB - crystal and PMT cannot be decoupled from each-other and replaced without the complete destruction of the detector - this is one of the down sides of such design.

38B57 on the other hand, is a really a high-quality, spectroscopy grade detector and the lack of an additional glass window in front of the crystal improves the resolution by reducing photon refraction and/or reflection which would normally occur with the extra glass window of an encapsulated crystal.

These detectors are part of the Exploranium GR-135 RIID device and hundreds such units are being decommissioned all the time by various US Government agencies (Border Patrol, Cost Guard, etc. ) and sold to equipment recyclers / salvagers.

These detectors will often show up on eBay for as little as $80/ a piece (at the time of this writing but prices do change) and sometimes for even less, making "good size NaI(Tl) Scintillator for under $100" possible!

The 38B57 detector located in its black, shock-proof rubber protector, inside an Exploranium GR-135 Radioisotope Identifier unit. The white connectors on top are how the detector is connected to the electronics - the left one is the temperature sensor for compensation and the right one is power to the detector.

Obviously, if the PMT or crystal are broken because the unit was mistreated or dropped, the detector goes in the garbage bin but if they were treated well and in a good, working condition, they can provide excellent post-service life as a Gamma Scintillator (Counting or Gamma Spectroscopy probe) - I routinely measure the FWHM resolution to be better than 7% (@662keV) for the 38B57 detectors. This makes it an excellent choice for those who need a scintillator probe, are just beginning and want to try Gamma Spectroscopy and are on a budget. 

I, actually started my Gamma Spectroscopy experiments years ago with such detector.

Unmodified, freshly decommissioned detectors.
I cut off the connectors in order to remove the detector without damaging the rubber booth protector.

As the detectors are removed from the Exloranium GR-135 units and sold on eBay, they are not directly useable - they have a custom voltage divider circuit with transistors and diodes in the last stages, intended for use with the GR-135 hardware and must be modified with a "standard" voltage-divider circuit to get the best performance for both, linearity and resolution.  Even the original connectors and the way they are powered is specific to the GR-135 unit. People have tried to use them without any modification but the results are not great and linearity is very poor. The simple and easy to do modification brings it to a completely new level and one will be rewarded with a very capable detector.

The modification process consists of removing the original voltage divider, installing a "classic" circuit with appropriate impedance and installing a coaxial connector in the housing.

This modification is not difficult but requires basic electronics and soldering skills and one should be comfortable, working with SMD components in order to perform the procedure.


Funny enough, the most difficult part of the modification process is opening / removing the rear aluminum cap of the detector.

The cap is glued very well, with 2 different types of adhesives (one of them is conductive) and one must use a heat-gun, an utility knife and some patience to take the cap off. 
Fortunately, there are no heat sensitive components in the very back of the housing, but heating must be done quickly before the heat creeps down the housing, towards the NaI(Tl) crystal. Holding the detector with a moist paper towel can provide additional cooling and heatsinking effect to the crystal housing while performing this procedure.

Enemy #3 of these inorganic scintillating crystals are rapid temperature changes which can cause the crystal to crack. (Enemy #1 is moisture and Enemy #2 is mechanical shock)

It requires quite a bit of heat for the adhesive to fail and let the cap go. Inserting the blade of the utility knife between the edge of the tube and the cap allows for the cap to be pried off gently - this action must be carried out repeatedly at different spots around the perimeter of the cap until it comes off.

If the cap doesn't budge initially, just reheat quickly to a higher temperature, while monitoring the temperature of the crystal housing and once the cap is open, slowly cool down the top, heated edge, of the stainless-steel tube.

The aluminum cap can retain heat, so the process is - heat up the cap, then quickly put down the heat-gun and try to pry it off with the utility knife, then repeat as necessary.

Once the utility knife blade widens the gap enough to slip in a flat-head screwdriver between the edge and the rim of the cap, things become easy as twisting the screwdriver applies quite a bit of force to pry the cap open.

Some caps will come off quickly and easily, but others will have excessive amount of glue and can be "tough cookies".

Once the aluminum rear cap is removed, this is how the detector looks on the inside. 

Next step is to remove the silicone sealant, cables and the cable grommet.

DO NOT try to remove the stainless-steel tube from the bottom, aluminum part of the housing in order to gain better access to the PCB - it is not needed, and any such attempts could lead to the destruction of the detector!

All of the work is carried out through the back opening.

I cut the cables for this picture, but actually the wires should be de-soldered and completely removed. The picture shows the original Voltage Divider, with the transistors in the last stages. It is a tapered VD and the total impedance is fairly low - around 12MOhms.

Most components of the original VD must be removed, and some will be replaced with different values. The only components that stay are the 3 capacitors shown on the picture - everything else, marked with "X" in this picture, must be de-soldered.

The best and fastest way to remove these SMD resistors is using 2 soldering irons equipped with fine tips (I use ETP tips for this task with my Weller stations). This method also carries less chance for PCB damage. Each resistor is heated simultaneously on both sides and picked up by the two soldering iron tips as if tweezers are used. It takes me just a few minutes to remove all of the unnecessary components. Solder wick is used to clean the pads and prepare them for the new resistors. The old soldering flux can be cleaned off with alcohol pads or alcohol-soaked Q-tips.

This picture shows how the PCB should look like after de-soldering the original divider. 3 out of the 4 SMD capacitors (10nF/200V) are left in place. The 4th capacitor on the very left is removed and later a resistor will be installed in this position.

Next step is to install the SMD resistors for the new, "standard" voltage divider. I have discussed choosing resistors for PMT VD in other posts but for general purpose (counting with Eberline or Ludlum meters for example) 10 MOhm resistors are normally used. This is a 10-stage PMT with 2R (20M) between K and Dy1 and R(10M) for all other resistor positions (between the rest of the Dynodes).  The footprint on the PCB requires 1206 package resistors. The total impendence of the VD will be 120M, which causes minimal voltage drop even with weak HV power supplies. 
(For Spectroscopy, a lower value for R should be used - 1M or 2M is generally a good choice.)

I use 10 Mohm / 1/4W / 1206/ 0.1% tolerance resistors - Digikey part # 749-MCA1206MD1005BP500CT-ND - Vishay High Stability chip resistors.

Resistance tolerance is not super-critical as there are already differences in the PMT's Dynode stages to begin with, and 1% tolerance should work just as well. 

All resistors should be installed just as shown on the picture.

(tip: buying these resistors in quantity of 100 pcs from Digikey is more cost-effective, especially if more than one detector is modified as each detector takes 12 resistors)

On the picture above:

A. Resistor is installed in the position of the removed capacitor.

B. Resistor is installed on top of the capacitor and in parallel.

C. Two resistors in series are installed between Dy1 and K. Single 2xR resistor (in this case 20M) can also be used but I found to be more convenient if I use 2 resistors as the distance between the pads allows for this and it looks clean.

This is how the PCB should look like after all of the resistors are installed. The yellow wire is connected to the PMT's Anode (P) pad and supplies both, HV Bias to the PMT and return signal - it returns back the positive pulses generated by the PMT to the external circuit.

The grounding lead wire, soldered on one end, to the detector's housing must be connected to the K pad (PMT's Cathode). The stainless-steel part of the housing acts as electrostatic shield for the PMT. 

After the K lead (black wire) is installed, the grounding wire to the housing is connected at the junction of K-2R. 
If the original wire is not long enough to reach the K pad, it can be extended with a piece of bus wire, as shown.

The two pads circled on the picture must be bridged with a short piece of jump wire. 
This is an important step and should not be missed!

This is the schematics of what the modified detector should be.

The aluminum cap is drilled in the center and a female BNC connector is installed - I recommend using a good quality connector with Teflon center conductor, like Amphenol UG-625/U. 
Alternatively, a MHV or even SHV connector can be used but there is not much clearance on the inside.

The drill diameter for the hole in the cap is 3/8" for a round connector and if the connector barrel is D-shaped (to prevent rotation), then 11/32" drill bit is used, and the rest is shaped with a set of small round and small flat files, until the connector can just fit through the hole without being able to rotate. Using connectors with D-shaped barrels is the better choice as it locks the barrel in place and prevents the connector from loosening itself when operated.

The yellow and black wires (silver-plated stranded wire with Teflon insulation) are soldered to the BNC connector. These wires are about 1" long (but could be a bit shorter) and are carefully bent and routed not to touch the board or components when the cap is closed.

The original cable opening is sealed with a piece of self-adhesive copper tape and a length of Kapton tape on top. The housing should be completely light-proof and air-tight. RTV sealant around the BNC connector (on the inside) can be applied before the connector nut is tightened, to seal it as well. 
The aluminum rear cap is glued back with hot-melt glue to the stainless-steel housing.

I also seal the seam between the aluminum part of the housing and the stainless-steel tube with a strip of Kapton tape - just for "good measure".

The modified 38B57 detectors - completed and tested, ready to be installed in Gamma Dogs. After the modification, these detectors can be directly connected to counters such as Eberline ASP-1 or most Ludlum counters. They will certainly outperform Ludlum 44-2 probe for example. 

Here is a Gamma Spectroscopy plot done with one of the modified detectors.
The FWHM resolution for 662keV (1uCi of Cs-137 source disk) is 6.9%. The detector was running on 575V and connected to a Gamma Spectacular GS-USB-PRO. (The second peak from the left is XRF coming off the lead castle - the peak is suppressed due to the graded shielding ).
These detectors output ~110 CPS (6600 CPM) for the Natural radiation background when unshielded.

"Gamma Spectroscopy Only" Use / 12MOhm Total Impedance VD

If the detector is to be used for Gamma Spectroscopy only, with GS-USB-Pro or a Lab Grade PS driver providing "stiff" HV Bias, lower impedance VD will result in better stability, better SNR and even faster response. 
The 12MOhm VD on the other hand pulls more current and it is too low for portable, battery operated, meters - it will cause a significant voltage drop and an increased battery usage.

The original VD can be modified by removing the active components and only some of the resistors while keeping all of the existing 1MOhm resistors - this is really simple and logical, but I decided to provide the pictures anyways in case somebody wants to follow this guide as a step-by-step.

Only the marked with "X" components should be removed, keeping all 1Mohm resistors.

This is how the PCB should look like after de-soldering the unnecessary components.

Additional 5x 1MOhm resistors are needed (I used the ones salvaged from other units) to complete the 12MOhm Voltage Divider. 
The rest of the modification is just as outlined above.

Tuesday, April 4, 2023

Building a Scintillator, using CsI(Na) crystal and Hamamatsu R6231 PMT

 This scintillator build is not much different than the others except for using a CsI(Na) crystal and 2" / 51mm PMT.

 I understand that people use these posts as a guide when building their own scintillators so I decided to document it as it might provide additional information, which I might have missed in previous posts.

Using Gamma Spectacular PCB for R6231. This PCB is designed for both, single wire (HV Bias + Signal) and 2 wire (HV Bias and a separate Signal line) interface. I populated the PCB for the Single wire interface using R value of 5.6M for the voltage divider. Had to improvise a bit with the 2R resistors between K-G and G-D1 as there was only one footprint per resistor but there are no 11.2M resistors.
Total resistance of the VD is 67.2M.

Voltage-Divider impedance is not a super-critical parameter, but it is important to consider based on the application. For example, with battery-powered counters and meters where the HV Bias supply can't take much load, high-impedance is preferred as the lower current will reduce the voltage drop. Some PS will drop the output voltage with impedance as low as 60M. In these cases, a total impedance of 120M will work well. High-impedance divider on the other hand will have lower SNR (Signal-to-Noise Ratio) and linearity could suffer as well - for Gamma Spectroscopy with benchtop / lab-grade power supplies, VD impedance of 12M will work great.
For this detector I went "in the middle of the road" with VD around 70M.

Machined PMT rear cap, completed PCB and the PMT ready for the final assembly.

The PMT is a 2" Hamamatsu R6231 - the little brother of R6233. The only difference between the two is really the size - all other specs are the same.
R6233 is one of the best all-around PMTs - I've built more than a dozen detectors with it and absolutely love it - the R6231 should be just as good!

VD PCB installed on the back of the PMT with the two silver-plated, Teflon insulated lead wires. 

Installing the MIL-grade BNC connector (Amphenol UG-625 B/U). 
There is a wire fed thru a small hole in the cap for grounding the electrostatic shield. Heat shrink tubing is added for extra insulation of the Anode lead and both wires are coiled into "springs" and away from each-other before closing the PMT cap so they don't press on the board and stay away from the components.

The photocathode window was thoroughly cleaned with Acetone and any dust particles were removed using micro-fiber cloth and sticky tape until the glass is absolutely spotless. 

The crystal is a "Soviet Era" 40mm x 40mm CsI(Na). Datecode is June, 1991.

CsI is a higher density (4.51g/cm3) scintillation material which makes it more efficient at detecting gamma (better stopping power and higher Z). 
Its light output is 85% when referenced to NaI(Tl) but one big advantage of CsI(Na) when compared to CsI(Tl) is that the emission peak matches perfectly the response of Bialkali PMT photocathode at 420nm wavelength. 
CsI(Tl) on the other hand is better suited for use with SiPM as its peak is at 550nm and cutoff at 320nm.
CsI(Na) is also much faster scintillator with decay time of 630ns compared to CsI(Tl) at 3.5us which allows for higher rate detection. Not as fast as the NaI(Tl) with 250ns decay.

Comparison of the emission peak wavelength and temperature response of both types CsI materials. 
The light yield is slightly lower with 41 photons/keV Gamma for CsI(Na) compared to 54 photons per keV Gamma for CsI(Tl) but greater than NaI(Tl) with 38 photons/keV Gamma.

My crystal is absolutely pristine - no significant blemishes, no yellowing, no cloudiness.
It is crystal-clear (no pun intended). The glass of the optical interface window was cleaned in the same manner as the PMT's photocathode.

Due to the small difference in diameters between the crystal canister (45mm) and the PMT (51mm), I added a short sleeve from EVA foam around the window area, which will center the crystal during assembly, preventing it from sliding off-center to the PMT. The size difference is very small (~5mm) and there was no need to 3D print a centering collar.

A drop of high-viscosity (100K cSt) silicone fluid is added as optical interface between the two glass surfaces to minimize reflections and refractions by eliminating the air gap between the two glass windows. The silicone oil's refractive index is around 1.41 which is close to the 1.46 refractive index of the borosilicate glass of the PMT.

PMT and crystal are put together and the silicone fluid interface is distributed evenly between the two glass surfaces with repeated, overlapping, wide, circular motion until it becomes a very thin and even layer. The extremely high viscosity of this layer and surface tension prevents it from "running" and it will stay permanently in place.

Strips of vertical electrical tape are used to pull together both, PMT and Crystal with some tension. The tape is stretched during application, and it exerts constant pressure between the two parts ensuring a firm contact. With this small diameter PMT 4 long strips (which loop under the crystal) are sufficient.
Both, crystal and PMT are then wrapped multiple times, around, with special focus on the interface zone so it becomes one tight package.

After completely wrapping the assembly with multiple layers of electrical tape, I added a sleeve of EVA (Ethylene-Vinyl Acetate) foam to serve as mechanical shock protection and thermal insulation for the assembly. EVA foam is a very dense closed-cell foam and does great job for both applications.
The front face of the crystal is also protected by a disk of EVA foam, glued to the crystal's foam sleeve. 
Needless to say, the assembly is 100% light-proof.

The magnetic / electrostatic shield is added as a two turns sleeve of special Mu-Metal sheet, spot-soldered closed, and the grounding wire is then soldered to the sleeve. The sleeve overlaps the photocathode area and into the crystal canister by about 5-7 mm.

Second EVA foam sleeve for even more shock protection of the glass-envelope PMT goes on top of the magnetic shield.

After completing the entire assembly, the final protective layer of heat-shrink tubing is applied. 

This is probably the most critical and dangerous part of the assembly process as overheating the crystal can easily cause it to crack. Crystal temperature should not be increased too rapidly. Heat was applied in short burst (with cooling time between them), which allowed the heat-shrink to heat up rapidly but not to transfer a lot of heat at once, and not for a long time, to the crystal.

Heat-shrinking is not "a must" but provides a nice finish, serves as an additional protective, abrasion / scratch resistant layer and keeps both components - crystal and PMT firmly together.

Just as expected, the resolution is not bad at all! 

Running the detector on 600V, for Cs-137 at 662keV resolution is 6.2% FWHM. Theremino's algorithm for automatic estimation of the FWHM resolution seems to be a bit on the conservative side so a more realistic value would be actually around 6.0%, which is even better - not too shabby for a 30-year-old, Soviet Era crystal.

Tuesday, March 7, 2023

Complete DIY XRF Setup

My DIY XRF setup is finally complete - it is comprised of an Amptek X-123 detector using the proprietary Amptek 25 mm2 / 500 μm Si-PIN X-Ray detector element (model FSJ32MD-G3SP), Amptek Pre-Amplifier and DP5 DPP /MCA.

Details about the detector are in THIS post.

On the exciter side, in the past, I have used X-Rays from an Am-241 source (59.54keV). Unfortunately, there is no exempt quantity or a way to obtain high activity, pure Am-241. The ones used in modern household smoke detectors are only 0.9 uCi (unless obtained from the old Pyrotronics industrial smoke detectors with up to 80uCi) but still have the Am-241 mixed and pressed into Gold and Silver foil which has parasitic emissions of the said metals in addition to the Am-241 decay product - usually a fairly strong Np La line emission (from Np-237 decay product). The Neptunium La-line is observed even with recently created Am-241) La at 13.95keV.

I decided to switch over to an X-Xay Tube where the emission can be controlled, the spectrum is uniform with the exception of the XRF emissions from the target material but this is normally a single metal.

 I am using Moxtek Magnum series transmission X-Ray tube with Tungsten target - 10W total electrical power (-50kV / 200 uA) controlled by an X-ray source controller of my own design.

The X-Ray tube is placed inside a Lead shield. The aluminum box on the right-top in this picture is the detector enclosure, housing the detector element, preamp, power supply and the Amptek DP5 Digital Pulse Processor.

This is my test setup while doing XRF on a piece of copper foil for initial Energy Calibration.

The aluminum box in the center of the picture is the X-Ray tube's high-voltage power supply module. It is a high-frequency switching supply with a very easy to work interface - 3 output channels (2 analog and 1 digital) and 3 input channels (2 analog and 1 digital) + 12V main power. The supply is very efficient and the current draw is around 1.5A at maximum power.

The X-Ray source aperture and detector at almost 90 degrees so the X-Rays are skimming the surface of the specimen.

This is the first XRF of Copper foil with the new source - the Ka line is at 8.05keV and to the right the Kb-line is at 8.90keV. 
I still need to adjust the detector Peaking Time and Flat Top Time as well as the Slow and Fast detector thresholds - currently I have over 99% of Dead time due to the current settings intended for low X-Ray flux source.

My X-Ray Source Controller works flawlessly, and I am really happy with the end-result.

Saturday, February 25, 2023

X-Ray Source Controller for MOXTEK and AMPTEK Mini X-Ray tubes

 I needed controller for the Magnum series 50kV / 10W MOXTEK X-Ray source. As it turns out the controller, once sold by MOXTEK is no long available (discontinued) and the Moxtek salesperson told me - "We expect customers to develop their own controllers". This is not a big deal - their controller has very basic functionality anyways, so I went ahead and developed my own design to control the tube.

One of my design goals is to have a stand-alone unit - no computer required. I don't want to fumble with numerous applications while doing XRF and prefer to have a piece of hardware with actual buttons I can press when it comes to X-Ray tube control.

I was pleasantly surprised to find out that the AMPTEK Mini-X2 tube uses the same electrical interface as MOXTEK so my controller will work for AMPTEK Mini-X2 just as well.

My design is based on the nRF52840 System-on-a-Chip (SoC) using Cortex M4F processor and employs 6 control channels as required by the Tube's interface  - 4 Analog and 2 digital channels. Of these 6, there are 2 Analog outputs (12-bit DACs), used for setting up tube's HV and Emission Current parameters, 1 digital output (5V TTL signal) to turn the source ON / OFF. There are also 2 Analog inputs (12-bit ADCs) to monitor the Tube's working parameters as they are returned by the Moxtek HV PS module and a digital input (5V TTL signal) to report when the beam is on and stable (Filament fully heated). 

I had to employ Level shifters as the nRF52840 is a 3.3V chip and the MOXTEK module has 5V TTL levels for the digital signals. Furthermore, the set ranges on the Analog output channels are 0-to-4V so I had to use the 4.096V internal DAC reference voltage which means the DAC must be powered with 5V Vdd.

For the Analog inputs, I used voltage dividers to bring down the Monitor channel voltages in the range of 0-to-3VDC and used the built-in ADC reference of 0.6V with gain of x5.

There is also 5th Analog Input channel, internal to the controller, with its own voltage divider, used to monitor the Low-Voltage Main Input Power and to inhibit controller operation if the input power is not nominal.

OSH Park delivered again beautiful, high-quality PCBs. The ordering process is very simple and a pure joy - I almost feel sorry I don't have more PCB projects to order. The PCB design was done with Eagle but I am not big fan of what Autodesk is doing with Eagle and very likely to switch over to KiCad in the near future.

The assembled and ready X-Ray Source controller - XTC-2000 (a.k.a. "X-Ray Tube Commander 2000" :-) 
(Chat GPT suggestion :-)

Using a rotary encoder with a pushbutton makes the UI really quick and intuitive. The button (knob-press) is used to enter adjustment mode and the user can dial the whole number and the tenths after the decimal point for each parameter separately. After entering Set mode, the encoder push-button scrolls through different cursor positions. 
The encoder is equipped with its own microcontroller (Atmel SAM D09) which takes care of all of the quadrature input stuff - counts, phase-detection, timing, etc. and just reports the actual tick count over I2C bus to the MCU. This makes it really fast and easy to use and I can reset the tick counter with a command if needed.

The complete and working controller during bench-testing and DAC/ADC non-linearity compensation and alignment. The white (unpopulated in this picture) 4-pin JST connector near the encoder is AUX I2C expansion connector, used for the remote temperature sensor.

Currently, the code is fairly small (~1500 lines only) yet it is pretty complete and mature and the core functionality is all done and bug-free thus "Version 1.0".

In the unlikely event of some commercial interest I might write a menu system for setting up various internal parameters and calibration values, but even at this stage, XTC-2000 has more features, better functionality and better ergonomics than both, the discontinued Moxtek controller and the entirely software-controlled Amptek controller. 

As part of the safety and tube health features, I added temperature sensing and monitoring using MCP9809 chip.

While designing the PCB, I foresaw that having an extra I2C bus connector for future expansion might come handy so I added one to the board layout.
The sensor I am using is MCP9808 - a very accurate and precise chip with I2C interface. Resolution is actually much better than 0.25°C but for my purpose 1° Celsius is completely sufficient.
The controller constantly monitors the temperature of the tube and it will shut it off if temperature exceeds +60°C and until cools down below +55°C. The sensor presence is auto-detected on startup - if the cable is not plugged in, the controller will work normally, without any limitations.
The critical part here is the connection cable between the controller and the MCP9808 breakout board - the cable must be fully shielded due to the proximity to the tube's HV cables and must be of very low capacitance as the I2C bus does not allow for high capacitance on the signal lines or the useable bus speed will begin to drop.  At 70cm cable length the sensor works just fine. The cable I used was foil-shielded 4-conductor USB cable.

The last thing currently pending on my development list is a suitable enclosure.

Thursday, January 19, 2023

XRF Exciter source using a Moxtek Miniature X-Ray Tube

 I am working on a new XRF Exciter source, employing a pretty cool miniature, ceramic, 10W X-Ray tube with Tungsten target by Moxtek (MAGNUM series). This source will deliver an immensely higher X-Ray flux compared to the Am-241 source I've been using, thus cutting down on the integration time during XRF analysis and bringing out peaks hiding in the noise.

The Moxtek X-Ray tube comes with a High-Voltage Power Supply module which allows for control of both, the tube voltage (-10kV to -50kV range) and the tube's emission current (0 to 200 uA). The maximum electrical power is 10W into the tube - here are the specs.

The brass housing of the X-Ray tube with the beryllium window aperture and the two high-voltage supply cables. The tube is in a Grounded Anode configuration and the two cables deliver both, High-Voltage to the Cathode and power to the filament. The brass housing is massive enough to dissipate plenty of heat. In its final configuration, the tube will mounted inside of 1+" thick lead shielding as some X-rays are generated in all directions besides the collimated main beam. These X-Rays are much attenuated but still a radiation hazard so proper shielding is mandatory.

My test setup. The HV PS has a very neat and straight-forward interface for controlling the tube's operational parameters of the tube. It is also very efficient when it comes to power - it requires 9V to 12V DC and about 1A of current. The efficiency is a little over 80% - around 12W input power which is fantastic.

While I am designing and prototyping the X-Ray tube controller (more on this later), just for a quick testing I was driving the tube with my 3-channel power supply in a rather "manual fashion" - Ch.1 is the main power, Ch.2 controls the HV - 0.8V to 4V are scaled to -10kV to -50kV range and Ch.3 sets the beam's current - 0 to 4V are scaled to 0-200uA range.

The tube's module returns monitor signals - voltages with the same exact scaling factors as the control voltages in order to monitor the actual HV and Current. A TTL level signal controls the beam ON/OFF and there is a FILAMENT READY return signal from the HV PS when the filament is heated, and the beam is ON and stable.

One important requirement is that the beam should not be turned ON sooner than 2 seconds after it has been turned OFF to prevent damage to the tube's filament. For the same reason the tube should not be turned ON for a minimum of 1 second and no less than that - all these will be part of my design goals for the controller.

Prototyping the X-Ray tube controller - using nRF52840 MCU with ARM Cortex M4F, 24LC32 EEPROM for storing configurations, 12-bit MCP4728 Quad DAC for Tube control, large SHARP Memory display (400x240), bi-directional level shifter, Non-Latching Relay, MCP 9808 temperature sensor and a nifty I2C Rotary Encoder breakout.
There are various other components - voltage dividers, voltage regulator, power conditioning, buzzer, pull-up and pull-down resistors, etc. located on the controller board - I designed the board with some thru-hole components so I can easily continue the development once I have the boards in hand and swap components as needed.

Controller's User Interface
On top is the Status display, temperature reading (when sensor is plugged in) and the current timer display. Second section, below, is the Mode selector and Timer Selector display - it also shows the Last Run Log and calculated X-Ray tube power. Third section is the X-Ray tube's Parameter (S) Set configuration where the user can dial in voltage in -5kV to 50kV range (0.1kV steps) and Tube's current 5uA to 200uA (0.1uA steps). Bottom band is the (M) monitor display showing the return signals from the tube's power supply - digitized with 12-bit ADCs. 
All set parameters are persistent - stored in EEPROM and automatically loaded on startup. There are also two user-configurable Presets with Tube parameters for quick switching between different set of values for different experiments. I might increase the number of presets to 3 eventually.

There are 3 operational modes - MOMENTARY when beam is ON while the OPERATE button is pressed and turned off when released. The second mode is TOGGLE - pressing the OPERATE button turns ON the beam and starts a count up timer. Second press of the OPERATE button turns OFF the beam. Sequential ON/OFF will integrate the beam time in the "Last Run time" until a RESET action. The third mode is COUNTDOWN timer - user can dial desired beam time and OPERATE button STARTS/PAUSES the countdown. The X-Ray beam is turned OFF when the timer expires but it can be PAUSED, STOPED or canceled at any time. The user can also use the rotary encoder to add or remove time from the timer while the beam is ON.

I have added many safety features!
 When the beam is turned OFF there is a 2 seconds blackout period while the filament is cooling. During this time the beam cannot be re-engaged. It is not possible also to run the tube for less than 1 second - if any such attempt is made, the controller will automatically "pad" the time for a total of 1 second. There is an INTERLOCK detection feature which inhibits any operation unless the interlock switch of door/ enclosure is closed or overridden with a key. In COUNTDOWN and TOGGLE mode, pressing on the TIMER RESET/MODE button or the Rotary Encoder button acts as an EMERGENCY SHUT-OFF. In TOGGLE mode there is also Timeout feature which will turn off the tube after a period of time if left unattended. The controller also constantly monitors the Low Voltage supply and disables the tube if under-voltage condition occurs. Tube temperature is monitored with an external sensor attached to the tube housing and the tube is turned OFF if temperature reaches 60C.
Control voltages for the HV and the Emission Current are always kept at 0VDC when the tube is OFF to prevent the tube from firing up due to a transient on the TTL "tube enable" signal during controller power-up and shut-down. These control voltages go up to the programmed levels just before the X-ray tube is turned ON and are dropped again to 0VDC shortly after the tube is turned OFF.
Another safety feature is a "parameter watchdog" - 2 seconds after the x-ray tube is on the beam is stable the controller will be actively monitoring for a difference between the set control voltages and the return monitor voltages - if a specified tolerance is exceeded, the controller will turn OFF the tube.

There is a relay with NO/NC contacts used for control of external equipment - X-Ray ON indicator, shutter, acquisition system, etc
The nRF52840 BLE will allow me to implement a Bluetooth connection to another host device (Smart phone for example) and control everything remotely. 

Overall, I am quite happy with the results. This is the PCB design for the controller board. Critical modules are socketed and can be replaced easily. There is a terminal block and a DB-9 connector directly compatible with the Moxtek DB-9 on the Magnum series tubes and auxiliary 2-pin power connector used for tubes with higher than 4W power.

For testing, I looped the DAC outputs used to Set the x-ray tube control parameters (the "S" display line on the display) to the ADC inputs for monitoring the tube's return (the bottom, "M" display line) and whatever is programmed as SET tracks perfectly on the MONITOR. The ADCs exhibit a small non-linearity up to about 2.4V (they run with 3.00V reference) - I plotted voltage set vs. voltage read and created a curve to correct it, which improved the accuracy quite a bit.

The internal ADCs of nRF52840 are configured for 12-bit resolution and using the built-in 3.0V (0.6V x5 Gain) voltage reference. The ADC noise is very typical for these chips - around ~3mV swing as seen on the plot. I might employ a ring-buffer and toss out the Min and Max values over a couple of seconds samples while averaging the rest in an attempt to get a more stable readout if I get bored - now the least significant digit exhibits some ADC noise from time to time - it is fairly stable due to the over-sampling conversation I am doing so no real motivation to address this more or less non-issue.