Welcome to our guide on building a hardware-software Geiger counter emulator of GGreg20_V3 module based on ESP8266 This emulator can be useful for testing and tuning Geiger counters or for educational purposes. Let’s get started!
Updated: When writing this article, we decided to make a separate commercial product – the Geiger counter emulator GCemu20_V1.
Part 1: Introduction and Overview
It is known that the Espressif ESP8266 module has a very high quality random number generator. We could not find any official details about the actual implementation of this generator, so we propose to read the material on this subject, published by a radio amateur and saved on the Internet:
https://web.archive.org/web/20170321162556/http://esp8266-re.foogod.com/wiki/Random_Number_Generator
Warning. Two different concepts with the same name are used in the text. Historically, there is a NodeMCU hardware module on the market as well as NodeMCU software firmware.
The NodeMCU firmware is a compilable, open-source microprogram that can be written to hardware modules with Espressif’s ESP8266 controller. One of the many products based on the ESP8266 controller, is the NodeMCU hardware module.
Thus the NodeMCU firmware can be written to the NodeMCU hardware module. Later in this article we will try, if possible, to clarify what is meant by the name NodeMCU: module or firmware.
What is a Geiger counter emulator for
Before proceeding to create a Geiger counter emulator, it is necessary to consider what for and who may need such a hardware-software device.
The main idea of any emulator in the field of DIY electronics is to temporarily, at certain stages, use a virtual substitute component instead of a real module in the process of IoT device development or experimenting / learning to reproduce the operation and characteristics of a real device with high accuracy. The emulator should simplify and speed up development, as well as add convenience in the initial stages of a planned project or performing unit tests.
Below we present some theses explaining our motives for developing the GGreg20_V3 Geiger counter module emulator.
1.No high voltage
The GGreg20_V3 emulator, unlike the real module, has no high voltage on the board, so it is very convenient to use when developing on the table without fear of accidental electrocution.
At the same time, in terms of the electrical interface of the outgoing pulses, the emulator is a completely similar radiation sensor module, generating random pulses of the same shape and duration as the genuine GGreg20_V3.
2. Simplified learning process
The Geiger counter emulator is suitable for educational institutions. The instructor can gradually deepen practical lessons with students.
First, all classes can be conducted using safe and cheap Geiger counter emulators, and then with real modules with Geiger tubes and high voltage on the tube side. Just like in the Army: familiarization and training is done first with blank cartridges, and only then with live ones.
The emulator fully reproduces the results of the real GGreg20_V3 module, so there is no problem of insufficient number of real modules in the classroom: each student can work with his module independently and complete the learning process without dividing into groups or queues, as it usually happens when resources of training devices and stands in the lab are limited.
3. Lower cost
The emulator has a lower cost than the real GGreg20_V3 module, so it is convenient to use it primarily for debugging and harmonizing the circuit or software of the system being designed or studied.
Debugging a test bench or a project with such an emulator can be performed without the need for specially qualified personnel.
If the emulators are used by students, then the teacher will not need to control the work with the devices, as would be necessary to do with the real Geiger counter module.
Low-cost emulators can be purchased in large quantities and given to students for the duration of their studies, not just for the time they work in the school’s laboratory.
4. No real source of radiation is needed
When we work with a real GGreg20_V3, we need a true source of radiation to reproduce the various situations that need to be considered in the software of the measurement system that is being designed or tested. In order to buy a test radiation source, the radio amateur must first solve a number of problems:
- to determine by physical and chemical parameters which source is needed;
- to find a supplier and buy a test source;
- some countries require customs notification and an import permit;
- the test source can only be of a certain power;
- you must properly store and dispose of the radioactive source;
- the price of the radiation source and its storage system exceeds many times the price of the Geiger counter.
With the emulator, none of these problems will occur. T he device can simulate 5 different modes of ionizing radiation power. The Geiger counter emulator generates output pulses similar to those of the real GGreg20_V3 module in the range from 0 to 1.5 µSv/h (taking the SBM-20 tube as a similar reference). At the output are generated chaotic (using a true random number generator ESP8266) pulses of the same amplitude with a total pulse period of 10 microseconds each.
5. Emulator resource cannot be depleted
SBM-20 tube, installed in GGreg20_V3, has a relatively large, but still limited resource of particles, which it can detect during its lifetime.
The resource of the SBM-20 tube declared in the documentation is at least 2*1010 pulses.
Note 1. With a background radiation of 0.15 μSv/h with a coefficient of 0.0057, the SBM-20 tube detects about 27 pulses per minute.
Thus, under normal conditions, the resource of the tube will be enough for 2*1010 / (27 * 60 * 24) = 20 000 000 000 / (26 * 60 * 24) = 514403 days. And it would seem that this is quite a sufficient potential life of one tube.
A completely different picture is observed when it comes to operating a tube with a test source of radiation.
Here’s an example:
On its website, Images Scientific Instruments provides a list of the radiation limits allowed for import for test sources:
https://www.imagesco.com/geiger/radioactive-sources-int.html
Let’s take two sources from the list at the link:
- Co-60 1.00 uCi, 37000 Bq;
- Cs-137 0.25 uCi, 9250 Bq;
If we assume that under the influence of such a test source, half of the particles from radioactive decays enter the Geiger tube SBM-20 then the lifetime of such a tube would be:
- 20 000 000 000 / (37000 / 2 * 60 * 60 * 24) = 12 days (for Co-60);
- 20 000 000 000 / (9250 / 2 * 60 * 60 * 24) = 50 days (for Cs-137).
As you can see, if we want to experiment (or test our devices that include a Geiger counter) on a real tube, then we deplete its available resource with a true source of radiation rather quickly.
There is no such problem with the emulator. Using the emulator first instead of the tube is economically feasible.
6. Debugging data in the UART
The emulator of GGreg20_V3 module outputs operational data (pulses, time, counts, cycles, etc.) to the UART console port during operation, which, if necessary, can be recorded and processed by the student, developer or radio amateur for training or comparison with the measurements of his tested or developed system.
Genuine GGreg20_V3 counter modules and similar modules of other manufacturers do not and cannot have such a built-in feature.
Note 2. To connect to the UART console, the ESP12.OLED module , on which the emulator is based, has separately led UART interface lines (2.54 mm pitch holes for soldering) on the PCB. To connect the emulator to the computer the user additionally needs to have his own USB-UART converter. Further in the text the connection diagram will be given.
The article will be continued in the following publications:
Geiger counter emulator of GGreg20_V3 module by means of ESP8266 Part 2 Building the Emulator
Geiger counter emulator of GGreg20_V3 module by means of ESP8266 Part 3: Testing and Conclusion