Thursday, April 30, 2020

Arduino Powered Colloidal Silver Maker

I have used a colloidal silver maker for years, but it was not mine, and the owner asked for it back.  Then I looked for my home made silver maker but could not find it.  Then I got an idea, make a colloidal silver maker powered by an Arduino so it could control the voltage, current, reverse the polarity, graph the results and time the operation.

This is my latest schematic.

There are now some filter capacitors in the circuit to attempt to get more stable numbers on the LCD display.  I have changed the resistors in the divider to 300K (Two 150K in series) and 100K to further reduce the current reading when no water is present.  Also note that the stirrer motor is now on D3 for PWM ability.  Eventually you might be able to adjust the stirrer voltage with a few key presses.  I have also made a small circuit board with the voltage and current monitoring resistors on it.  Its visible in some of the latest pictures.

This is the schematic showing the LCD wiring.  This is identical to the LCD shield wiring.



This is what the LCD screen looks like in an earlier version.  I could use a bigger screen!  The LCD is saying the voltage is .51 volts and .25 volts across a 1K ohm resistor for a current of .25ma, it never reaches 1 ma during over 4 hours of operation.  Every 30 minutes the Arduino reverses the polarity and the LCD will then show around 17.7 volts.  The bottom line has the run time.

This is what the LCD looks like after over 30 minutes of operation, when the polarity is reversed.  The voltage and current bounce around a lot, likely because of the noise from the air pump motor.

Here is a picture of the colloidal silver maker, but it was running off USB power and the CS container was only half full.  This time the L293 board is visible on the right side of the picture.

This picture shows the Colloidal Silver Generator actually running.  The Air pump stirrer has been added with 20 ohms in series to reduce the motor noise.  Also the motor ground must be separate from the other grounds because of all the electrical noise that the motor makes.
Arduino Colloidal Silver Maker
Here is another picture.  The resistor divider and L293 motor controller are now located on the top of the colloidal silver maker.  Eight wires then run down to the Arduino.  There are two ground wires, one ground wire for the motor controller and one ground wire for the voltage divider.

After the second test run with the current staying under .5 ma, and 1 ma being the ideal current, I am thinking that it needs to to be modified from 12 volts to 20 volt operation.  Most Colloidal silver makers use 24 to 28 volts. The L293 can operate up to 30 volts, but the Arduino voltage regulator has a maximum of 20 volts, and the air pump stirrer has a maximum of 12 volts. The air pump runs best at around 9 volts.  So either a redesign will be needed to have some voltage regulators added, or I can try to use a 20 volt power source like that of an old laptop ac adapter.

I tested this design for a few minutes with a 19 volt laptop AC adapter.  Only 17.7 volts made it to the colloidal silver maker.  The Arduino voltage regulator got very warm but survived.  I disconnected the air pump for this test because it is rated for 12 volts maximum and runs best at 7-9 volts.  I have since added a PWM output from the Arduino for the air pump of 1/2 of the power source or 10 volts for 20 volt operation.

The Arduino's PWM ability is used to regulate the current to the Colloidal Silver maker to just under 1 ma. The over current shutdown is set to 2.0 ma.

There is a video of it running at this link: https://youtu.be/3ap4-GnGx_8

Here is the code so far:

/*****************************
Arduino Colloidal Silver Maker
By Bob Davis
April 2020

Use a 16x2 LCD display shield or equivalent
Shows the voltage, current, and run time.

The circuit:
 * LCD RS - D9
 * LCD Enable - D8
 * LCD D4 - D4
 * LCD D5 - D5
 * LCD D6 - D6
 * LCD D7 - D7
 * LCD R/W and VSS pin to ground
 * LCD VCC and LED pin to 5V
 * 10K variable resistor:
 * ends to +5V and ground
 * wiper to LCD VO pin (pin 3)
 * Uses L293 motor controller on D10 adn D11 for PWM ability
 * Uses L293 on D3 for stirrer motor.

*********************/

// include the library code:
#include <LiquidCrystal.h>

// initialize the library with the numbers of the

interface pins
LiquidCrystal lcd(9, 8, 4, 5, 6, 7);

// Pins for Colloidal silver maker
int CS1=10;
int CS2=11;
// Pins for stirrer
int Stir=3;
int Shutdown=0;
// Variables for time
int hours;
int minutes;
int seconds;
long hour = 3600000; // 3600000 milliseconds in an hour
long minute = 60000; // 60000 milliseconds in a minute
long second = 1000; // 1000 milliseconds in a second
float AN1=0.0; // Analog inut 1
float AN2=0.0;
float temp1=0.0;
float temp2=0.0;
float CUR=0.0;  // Current in ma
int CurSet=255; // Current Setting

void setup() {
  // set up the LCD's number of columns and rows:
  lcd.begin(16, 2);
  pinMode (CS1, OUTPUT);
  pinMode (CS2, OUTPUT);
  pinMode (Stir, OUTPUT);
}

void loop() {
  // Reverse current every 30 minutes
  if (Shutdown==0){
    analogWrite(Stir, 128); // 1/2 supply voltage
    if (minutes<30){
      analogWrite(CS1, 0);
      analogWrite(CS2, CurSet);
    }
    else{
      analogWrite(CS2, 0);
      analogWrite(CS1, CurSet);
    }
  }
  else{
    analogWrite(CS1, 0);
    analogWrite(CS2, 0); 
    analogWrite(Stir, 0); 
    }
  temp1=analogRead(A1);
  AN1=((temp1*5.0)/1024.0)*4.0;
  temp2=analogRead(A2);
  AN2=((temp2*5.0)/1024.0)*4.0;
  CUR=abs(AN1-AN2);
  if (CUR > 1.0) {CurSet--;} // Reduce PWM
  lcd.clear();
  lcd.setCursor(0,0);
  lcd.print("V:");
  lcd.print(AN1);
  lcd.setCursor(8,0);
  lcd.print("V:");
  lcd.print(AN2);
  lcd.setCursor(10,1);
  lcd.print("C:");
  lcd.print(CUR);
  // print the number of seconds since reset:
  long timeNow = millis();
  hours = (timeNow) / hour;             
  minutes = ((timeNow) % hour) / minute ;
  seconds = (((timeNow) % hour) % minute) / second;
  lcd.setCursor(0, 1);
  lcd.print("T:");
  lcd.print(hours);
  lcd.print(":");
  lcd.print(minutes);
  lcd.print(":");
  lcd.print(seconds);

  if (hours>3){ // Time under 4 hours
    Shutdown=1;
    }
  if (CUR>2.0){ // Current under 1ma
    Shutdown=1;
    }

  delay(300);
}