Battery Doctor

The Battery Doctor uses the following modules:

  1. Battery

  2. AD converter

  3. Potentiometer

  4. Empty

It supports regular batteries but also SmartBatteries containing a I2C interface. Charged batteries can be de-charged using a constant current set by the potentiometer. The AD converter measures current and voltage to determine the battery's capacity. The AD converter uses I2C bus to communicate with an attached computer.

To not risk to damage the battery due to exhaustive discharge the following method can be used. The fully charged battery is discharged with a constant current. The inflection point is detected (2nd derivative of the voltage time curve crosses zero). A common rule says when this point is reached the battery has half capacity.

Figure 2. Battery Doctor


Geiger Counter

One issue (next to the impact of atomic power plants) is the natural radioactivity of radon coming from the earth and maybe getting collected in the cellar. Limit are set at 400Bq/m3

Becquerel Bq is an SI unit it is a radioactive decay per second usually it is used for gas with a volume Bq/m3

Old units:

1 Curie = 3.7e10 Bq

1 Sv (sivert = si unit) = 1J/kg=1m2/s2

1 rem = 0,01 Sv = 10 mSv

The Geiger Counter uses the following modules:

  1. Geiger counter

  2. AVR CPU

  3. I2C to USB converter

  4. Empty

Figure 3. Geiger counter


The assembly is powered from an USB port. The USB to I2C converter board is just used for this purpose to feed the 5V from the USB to the other board. The geiger counter module has a high voltage step up converter that transforms the 5V from USB up to around 500V. The PWM for that is produced by the AVR microcontroller. Two neon lights show the presence of the high voltage. The high voltage is feed through high ohmic resistors to the external geiger tube from Philips (or Valvo) model 18505. The high impedance prevents that somebody gets electrocuted, however the tube is well isolated. Pulses are converted to 5V level signals to be feed to the AVR module. Additionally the geiger module has a small loudspeaker at the back to make the clicks.

The AVR microcontroller counts the clicks ans sends them via RS232 to a PC. Luckily I did not found radioactive objects around my place.

Figure 4. Radioactivity

geiger graphics

Geiger counter module

Two little neon tubes show if the capacitors hold a high voltage

Figure 5. geiger counter high voltage module

geiger schematics

Figure 6. The geiger module

geiger module

The resistors form a voltage divider that gets the right voltage for the valve. A high voltage capacitor (2kV) stabilizes the voltage.

Figure 7. geiger counter valve

philips 18506

Power meter

The assembly uses the following modules:

  1. power supply

  2. mains power

  3. arduino uno

Since it uses 230Vac voltages the modules are isolated.

Figure 8. Power meter front

mains power front side

Figure 9. Power meter back

mains power back side

The mains power module uses two hall sensors to convert the 230Vac voltage and current to isolated low and safe voltage signals: An analog multiplier chip is used to create the power signal from the current and voltage signal. All 3 signals voltage, current and power are feed to the front panel where their shapes can be observed using an oscilloscope. The a filtered power signal is internally available and is feed to the AD converter of the arduino module. This way no high speed conversion and calculation is required.

The arduino module (containing an arduino uno), converts this signal every second and puts the AD converters value to the serial port where a PC can be attached to do a nice graph with it.

Figure 10. Power curve

mains power

The curve shows the power of my PC while editing this text. The high got produced by turning on the printer and the low peak by turning off the monitor.

Infrared interface

There are a lot of different infrared transceivers making use of an old PIC micro-controller that is programmed in assembly around. Those transceivers are used in LIRC they are no more good documented and have especially when it comes to sending weak behavior. Since those PIC assembly language implementation did not fit my needs I ended up with my own design Elecbox was a good platform to test them out using different modules:

  1. I2C to USB converter just to get 5V power from USB

  2. UIRT module or AVR module

  3. Infrared board

Figure 11. girt


IR module

The receiver chip TSOP4838 does all the work and demodulates the received signal. A jumper allows to modulate an IR signal using a 555 timer chip or pass the signal directly to the IR diodes. Since IR is not visible two LED's are added to show received and transmitted signals.

Figure 12. Schematics IR module

ir schematics

Figure 13. IR module

ir module


There are many IR transceivers available for as UIR, UIRT, UIRT2 and IRMAN that are based on a PIC16F84A microcontroller. The UIRT module allows to implement them on the Elecbox using the IR module and a module to get the power. It also holds the necessary hardware to support programming the PIC microcontroller via RS232 interface.

Figure 14. Schematics UIRT

uirt schematics

Linurs Servernest startpage