Monday, October 24, 2016

1st version
                          
SCHEMATIC
Here are the parts used in both version :
10uf electrolytic capacitors, 22pf ceramic capacitors
10K and 220Ohms resistors
16MHz crystal, tact switch and 3mm LED

2nd version
                            
PARTS USED
1.

                                                  18650 x2 Battery Holder

2.

                                           ATMEGA328 with Arduino Bootloader

3.

                                        DC Connector Adapter Plugs 2.1×5.5mm

4.

                                            Jumper Wires male to male – 65pcs

5.

                                       Standalone Arduino ATMEGA328P-PU Kit

6.

                             Step Down Switching power DC-DC converter module

7.
                                                                             UNO R3

In first version of the making of standalone arduino we are using the popular LM7805 to regulate the power down to 5V.

The LM7805 is not the most efficient (approx. 55%), but if your project is connected to the grid, than this doesn’t really matter.

Now in the second version we are using a more efficient (up to 96%) miniature switching power supply.

If using batteries this would save power and make your project last longer.

Also it requires less connections since all the component are included on the switching board, unlike the LM7805 that requires capacitors and jumpers.

We are using 2x 18650 Protected batteries of 3.7V and 4500mAh each.

Connected in series they will provide between 7.4 – 8.4V and have a capacity of 4500mAh.

Using Protected 18650 batteries is important to make sure that they don’t get over-discharged.
Continue reading

                                         
                                                    SCHEMATIC DESIGN
PARTS USED
1.
                                                                 65 mm WHEEL
2.

                                       DC Motor with double shaft Gearbox 1:120

3.

                                        DC Motor with double shaft Gearbox 1:48

4.

                                   Infrared Speed sensor module with encoder Disc

5.

                                           Jumper Wires male to female 20pcs

6.

                                              Jumper Wires male to male – 65pcs

7.

                                  L9110 Motor Driver H-Bridge board Dual Channel

8.
                                                                             UNO R3
CODE
#include <TimerOne.h>
unsigned int counter=0;
int b1a = 6;  // L9110 B-1A
int b1b = 9;  // L9110 B-1B
void docount()  // counts from the speed sensor
{
  counter++;  // increase +1 the counter value
}
void timerIsr()
{
  Timer1.detachInterrupt();  //stop the timer
  Serial.print("Motor Speed: ");
  int rotation = (counter / 20);  // divide by number of holes in Disc
  Serial.print(rotation,DEC);  
  Serial.println(" Rotation per seconds");
  counter=0;  //  reset counter to zero
  Timer1.attachInterrupt( timerIsr );  //enable the timer
}
void setup()
{
  Serial.begin(9600);
  
pinMode(b1a, OUTPUT);
pinMode(b1b, OUTPUT);
  
  Timer1.initialize(1000000); // set timer for 1sec
  attachInterrupt(0, docount, RISING);  // increase counter when speed sensor pin goes High
  Timer1.attachInterrupt( timerIsr ); // enable the timer
}
void loop()
{
  int potvalue = analogRead(1);  // Potentiometer connected to Pin A1
  int motorspeed = map(potvalue, 0, 680, 255, 0);
  analogWrite(b1a, motorspeed);  // set speed of motor (0-255)
  digitalWrite(b1b, 1);  // set rotation of motor to Clockwise
}
IMPORTANT FILES TO DOWNLOAD
Continue reading

                                         
Parts Used
1.

                                   DHT11 sensor – Temperature and Humidity module

2.

                                           Jumper Wires male to male – 65pcs

3. 
                                                                         UNO R3


CODE
#include <DHT.h>
#define dht_apin A0 // Analog Pin sensor is connected to
dht DHT;
void setup(){
  Serial.begin(9600);
  delay(500);//Delay to let system boot
  Serial.println("DHT11 Humidity & temperature Sensor\n\n");
  delay(1000);//Wait before accessing Sensor
}//end "setup()"
void loop(){
  //Start of Program
    DHT.read11(dht_apin);
    
    Serial.print("Current humidity = ");
    Serial.print(DHT.humidity);
    Serial.print("%  ");
    Serial.print("temperature = ");
    Serial.print(DHT.temperature);
    Serial.println("C  ");
    
    delay(5000);//Wait 5 seconds before accessing sensor again.
  //Fastest should be once every two seconds.
}// end loop()


IMPORTANT FILES TO DOWNLOAD
DHT11_SKETCH
DHT11_LIBRARY

Continue reading