// EDUCATION & TECHNOLOGY

Wednesday, 12 December 2018

winter training in dehradun

With a new innovative approach, Ensino presents an exciting opportunity this winter for all the students to savor the delights of Placements, Industrial Exposure and Quality Training. This winter, gather your energy and vitality to undergo valuable and rigorous winter training in over 50+ technologies from Ensino.

It’s high time for candidates to decide aptly for short revision sessions, being placement drives knocking each campus. Ensino’s winter Training Programs caters the dual need of revisions for placements and major projects as well. The recent hiring trends of companies’ reveals that self-made major project, Industrial training and clarity of concepts are preferred the most. In this winter session, students can experience the entirely new and innovative teaching methodologies with certifications from MICROSOFT, ORACLE, AUTODESK, PANASONIC and NUVOTON so that they can develop the “Spark to shine in the Technical World”.

The chilly and snowy winter is an excellent time for the students to brush up their skills and gain Industrial Exposure. So the advice for the student is “Don’t wait for the SUMMER TRAINING in dehradun, seize the moment that is in front, and join our valuable winter Training course that comes with assured Placement assistance.

Winter is high time for candidates for short revision sessions, innovative projects and preparation for the interviews and placement drives. So think and decide about your future.  Come and join Ensino, and get access to its enhanced power packed courses in 50+ high end technologies that is surely going to exceed your expectations. Hence enroll for the winter training in dehradun and be prepared for the exciting journey with us.

Friday, 9 June 2017

Important factors involved in a Hotel Management Course

A Hotel management course is usually looked at as a stepping stone towards a bright career in the hospitality and hotel industry. Good courses in Hotel Management equip you to face real world challenges and train you in sharpening the skills that you already possess whilst imparting you with new skills. In the life of a fresher student, choosing the right course from the right college is an important decision and thus, the right amount of thought should go into it. There are several factors on which an aspirant can base his/her decision of choosing a course in the field of Hotel management. Some of the factors to be considered could be:
1.     Exposure:
While the basics taught in most of the Hotel management schools is pretty much the same, the exposure provided always differs. The right amount of exposure to how the real industry works, also called ‘on-field training’ is an essential part of your learning experience. An aspirant must go through the curriculum of a course and assess the amount of exposure they can get from that course. For example, If you are interested in being a part of a culinary arts program, look at whether you’ll be exposed to the workings of a professional kitchen or a professional Chef as a part of your training.

2.     Faculty:
Hotel Management is a detailed course which demands a certain level of expertise from the faculty who train students every year in the field. One of the key aspects to look into is whether the faculty has the experience and knowledge to provide you with a broad perspective in the field. Today, Institutes providing hotel management courses make sure that they get industry insiders to be part of the faculty team in order to give the students, a taste of their professionalism and experience.

3.     Placements:
Placements are the end results of all the hard work that you put into studying and training during the course of your studying. When you get into the hotel industry, work experience is a major factor in deciding how your journey in the industry will be. The more work experience you can gather, the more knowledge you’re able to accumulate. Hotel management is a practical field and it is important to apply on field, all the theory that you’ve learnt in hotel management school.

Before you apply for a hotel management course, it is important to assess yourself and understand your strengths and weaknesses. Certain skills are mandatory for a hospitality management graduate to have in order to make mark in the field. Some of the necessary skills that an aspirant must possess are:

1.     Practical and Soft-spoken:
In an industry like this one, there is a lot of communication that takes place mainly, between the employee and customer. In such a situation, there is no space for rude behavior or misunderstanding. It is very important to keep your cool, be practical, and speak in a composed manner.

2.     Efficient and effective:
The hospitality industry works on teamwork, wherein all the employees work towards one specific goal. In such a case, even one person’s mistake can affect the entire functioning of the procedure. A hotel management employee should be very aware of his abilities and must always be efficient in his work and effective in his communication.

3.     Presentation skills:
To be presentable in your appearance in terms of your dressing sense, personal hygiene, and a good command over the language is vital for you to have a good first impression on the customer. Hospitality depends heavily on first impressions, as a customer who has had a bad first impression during his/her first visit to a hotel, would probably never return for the same service.

4.     Confidence and Attitude:
A person with the right kind of confidence and attitude will be able to excel in an industry like hospitality. In this industry, you might come across various kinds of customers and it could be a challenge to deal with some of them. This field has its share of challenges, and to get through them, a person will need to build the right kind of attitude. Being warm and pleasant yet assertive is the key to good communication and retention of customers.

If you feel like you have all these skills and could conquer the hospitality world, go out there and acquire the skills necessary for a successful career in Hotel Management.

Author Bio
SImran is a passionate hotel management graduate who is seeking a successful career in the Hospitality industry. She possesses a flair for writing, particularly about her experiences in the hotel industry, and a passion for sports. She wishes to connect with people through her effective writing skills and useful content 



Saturday, 17 December 2016

Why Facebook Likes Are Important | buy facebook likes

Growing up, my parents told me is wasn’t important to be popular. Shows what they know! Having a well-liked Facebook page is a great way to gain major brand exposure, cultivate relationships, and communicate with a targeted audience.
Raise Your Visibility
What exactly happens when someone “likes” your business’s Facebook page?
Let’s look at an example. I personally am a big fan of kettle corn from a company called Popcorn, Indiana. If I “like” their page, here’s what shows up on my personal profile’s wall and in my news feed:
It won’t be long before one of my friends sees this, and decides to click on “Popcorn, Indiana” to check out their page (such as my boyfriend, who loves their white cheddar popcorn).
Build Relationships
But the relationship doesn’t end there (between me and Popcorn, Indiana, that is, not me and my boyfriend). Every time Popcorn, Indiana posts a status update on their page’s wall, that update will appear in my news feed for me to see.
buy facebook likes
https://lc-s.co/pmOQc

Wednesday, 12 August 2015

Effect of Modi's foregien visits


Prime minister Mr. Narendra Modi has visited many countries since he took oath almost a year ago. Many of us criticizing him for his so many foregien trips including opponent parties. But believe me friends his foregien trips are quite beneficial for the country. Opponents are just misleading by saying his foregien trips are worthless. I will give you some statics given by a leading newspaper and you will be amazed.
Read carefully-

India received $19.78 billion foreign direct
investment (FDI) from 12 countries visited by Prime Minister
Narendra Modi in financial year 2014-15, Parliament was
informed today.
During the period, Indian companies invested $3.42 billion in
these countries which include Bhutan, Brazil, Nepal, Japan,
the US, Myanmar, Australia, Fiji, Seychelles, Mauritius, Sri
Lanka and Singapore.
The total outflow and inflow of foreign investment in general
for 2014-15 fiscal was $6.42 billion and $75.71 billion,
respectively, Commerce and Industry Minister Nirmala
Sitharaman said in a written reply to Rajya Sabha.
In 2014-15, FDI in India increased by 27 per cent to $30.93
billion."

So you can analyze now that his foreign trips are worthwhile and can boost our economy fastly.

Tuesday, 11 August 2015

Know Google's new CEO- An Indian



As Google's third CEO, Pichai is taking over a
company in flux. In a massive corporate
restructuring, Google has become a subsidiary of
Alphabet, a new company run by Google co-
founders Larry Page and Sergey Brin.
Pichai, 43, was born in Tamil Nadu, India. After
graduating college in India for metallurgical
engineering, he came to the United States to study
at Stanford University -- the alma mater of the
Google founders and so many other early Googlers.
Pichai got his start at Google in 2004, building the
now defunct Google toolbar. The toolbar allowed
Internet Explorer and Firefox customers to make
Google their default search engine .
In the next few years, he took over Chrome,
Google's Web browser. When he introduced Chrome
to the world in 2008, the world reacted with
puzzlement: How could it compete with Internet
Explorer and Firefox?
Yet Chrome eventually became the world's most
used Web browser. Chrome even became a
successful operating system for Chromebook
laptops, used mostly by schools.
Pichai eventually became vice president, then senior
vice president in 2013 when he added Android to his
growing portfolio.
Last year, he became Google's product chief,
overseeing virtually all Google software products
not named YouTube. He runs Google+, Google
Wallet, Android Pay and Google's Apps services for
businesses.


Pichai also runs the Google I/O developers
conference, where he serves as the public face of
Google for eager customers waiting to know what
the next versions of Android and Chrome will do. He
also shows off the company's biggest new products
and services, including kicking off this year's
massive Google Photos announcement.
Subdued and generally quiet, Pichai is admired at
Google not just for his obvious engineering talents
but also his general likability.
"Sundar has been saying the things I would have
said (and sometimes better!) for quite some time
now, and I've been tremendously enjoying our work
together," said Page in a blog post announcing the
move.
As CEO of Google, he gets one more feather in his
cap and adds a few more products to his now giant
kingdom -- search, ads, maps, apps, Android,
Chrome and YouTube will now all be under his
purview.

Saturday, 1 August 2015

swami vivekananda thoughts

Swami Vivakanada's top 10 quotations that inspires you the most



1)Take up one idea. Make that one idea
your life - think of it, dream of it, live on
that idea. Let the brain, muscles, nerves,
every part of your body, be full of that
idea, and just leave every other idea
alone. This is the way to success.
2)We are what our thoughts have made us;
so take care about what you think.
Words are secondary. Thoughts live; they
travel far.
3)You have to grow from the inside out.
None can teach you, none can make you
spiritual. There is no other teacher but
your own soul.
4)The moment I have realized God sitting
in the temple of every human body, the
moment I stand in reverence before
every human being and see God in him -
that moment I am free from bondage,
everything that binds vanishes, and I am
free.



5)Arise! Awake! and stop not until the goal
is reached.
6)You cannot believe in God until you
believe in yourself.
7)Our duty is to encourage every one in his
struggle to live up to his own highest
idea, and strive at the same time to make
the ideal as near as possible to the
Truth.
8)The more we come out and do good to
others, the more our hearts will be
purified, and God will be in them.
9)The whole secret of existence is to have
no fear. Never fear what will become of
you, depend on no one. Only the moment
you reject all help are you freed.
10)Condemn none: if you can stretch out a
helping hand, do so. If you cannot, fold
your hands, bless your brothers, and let
them go their own way.

Saturday, 11 July 2015

what is good education

when we heard the word education, a picture series runs on our mind in which we see schools, teachers, students or if if we are already done with our schooling then we thought of our school days. These whole things which I have described was part of our education. Education in all sections of this world defines by all these parameters schools+ teachers+ students.



 Apart from these many other things may be there but these three things most important and must be their to get education. Some of you may think why I have described schools as essential part of education as to get education students means you and teachers means anyone who teaches you is sufficient. I have described schools as important part of proper education because we must have a class room so our infant from his/her very beginning in schools can learn how to interact with others means he learns how to be social in schools, but without schools knowledge he can gain but not education as being social is part of good education.



 So now you can imagine that a good education just not to get knowledge of particular subject but good education teaches us to be practical, be social, be friendly to everyone and so on. Only this good education can make you excel in your life, getting only knowledge is not sufficient to live in this world.

Its not the responsibility of only schools or government to make you infant social its parents who teaches him or her to be practical to be social to be gentle to everyone. If someone is good in his academics but not gentle not social he will find hard to live on this earth because we human beings are somehow social animals.



So when you think good education think other parameter also apart from knowledge is to make your child social, gentle and practical.

By-
Pankaj Pathak

Friday, 10 July 2015

Reservation in Education

Reservation in our education system , is considered to be a backbone to certain communities. These communities are Schedule Casts, Schedule tribe and OBC ( creamy and Non creamy). So why government is given these communities such special reservation in education as compared to general person.



it all start with untouchablity, means in past schedule casts were treated to be untouchable. They didn't have rights in society same as upper caste peoples. They worked for upper caste people, in overall they were badly treated at that time. Due to which trend started that a person who is of lower caste can't eat, live or even get education with upper caste people. As time passed they lower caste people were so harreshed that they were mentally and socially get neglected.
After Independence, because we live in Democratic country where everyone has right to live equally, it was realized that these lower castes peoples whose percentage was very less in all sectors as compared to upper caste peoples should be increased, so only we can talk about equality. The overall thought according to me was right because as a human being if you think whatever lower caste people faced during post independence was inhuman act. In starting Parliament implemented this for 10 years but after every 10 years it was increased and even now we have reservation in education system.
according to my view what I observed regarding reservation is that at starting the reservation rule was absolutely right because at that time lower caste people percentage in all sectors were so less. Still lots of areas are such where untouchability exists for which I totally support reservation. But what I observed regarding reservation system is that a person who needs it more is not getting this. Let me give you an simple example, a person from lower caste who don't have anything in his childhood achieved great success in his life with getting reservation in every field. According to me it is right if he gets reservation. But now think that his son or daughter giving any exam getting reservation is right or wrong. It is wrong because his son or daughter have everything now just because they are from lower caste they are getting reservation is wrong. Now a days what I observed is that maximum number of peoples whom are getting reservation don't require it. But some of areas in India have peoples , must have reservation which I support.
one thing I want to add here is that now reservation should not be given in name of caste. Because according to me lots of people just to get reservation in India make their false certificates though they have enough money but getting all facilities just because they are lower caste in papers. This I observed in my college time.



Another thing which I want to add in not to give reservation in name of caste is that, think of a poor student. His father don't have enough money so he can get proper education. Just because he is from general category he can't get any such reservation. It seems totally wrong. Though the concept of reservation was right but now I think amendments should be done. Reservation earlier during just after independence can be understood based on caste, but now after 6 decades still giving reservation just in name of caste didn't seem proper, reservation I totally support but it should be given due to financial conditions of one. Poor must get reservation because poor is poor we can't decide him in terms of his caste as upper caste poor or lower caste poor or Hindu poor or Muslim poor.
give your views also.

By-
Pankaj Pathak

Thursday, 9 July 2015

Education system in India

India is a country of around 1.25 billion peoples of which 65% population is young, means india is young nation. To progress we must focus on youths because they will decide future of the nation. Education is primary and most important criterion for better india as if everyone in younger generation will get proper education than only India will prospected.



In this direction from very first election till now government of India has done some great work. Presently around 990 billion rupee budjet is alloted for this. HRD ministry is responsible for higher education system as of primary education state government along with center is responsible.
At present 75% ( round figure) of population in India is educated. Let us now analyze thing rather than going to facts. I will took point by point analysis  but all regarding Government schools and colleges.

1) the very first thing to boost primary education government of India has already started Mid Day Meal scheme, so our children will get better health also.

2) books, dresses etc are free up to 8th standard.

3) the fee in government schools are so less and we compare this with private schools it is about 1/50 or more also. So government is taking less but giving more.

4) still we people don't choose government schools for our child. We are ready to pay 50 times fee even teacher who is teaching in private schools not even qualified any of the exam whereas all government teachers are well qualified.

 5) even what I observed that a government teacher prefer private schools for his infant. It simply shows that they don't have believe in their own system.

6) in reality government schools have very less number of students present there in most of the places.

7) let us now think of higher education. For graduation many options are present in India like engineering, doctor, law, science etc.



8) but what I observed is that Indian education system works only for a good degree.

9) when I say that "works only for good degree" it means we do graduation to get only degree not some knowledge or for skill development in us.

10) for this government is not responsible because they already have provide us all facilities but it is us that we want degree only not proper knowledge.

 11) like for example South Korea and India started building their education system in same year. We focused on Degree based preparation and they focused on skill development. you can analyze where they have reached in technology.

 I am not criticizing totally the education pattern but somehow to become world power we can't work with such education system. We must change it. When I say we it means Government+ we people of this great country.

By-
Pankaj Pathak

Wednesday, 8 July 2015

INNER PEACE




When we heard this " inner peace", some positiveness comes automatically. In this busy and hectic life most of us are not happy; but we all wanted to be happy. So the question arises in our mind automatically; how to be happy. Is there any tool or machinary or government sceheme. The answer is NO. But let me tell you a screat, there is always a person who can make you happy and that special person ( or say great person) is YOU
.
you are the one who is key to make yourself happy. We all know happiness is the key of peaceful life and vice versa peaceful life leads to happy life.
when I say peace it means inner peace.



I met lots of people, they are earning enough money, they wanted something in past which they have acheived already but they are not happy with their life, still searching for inner peace.
during my undergraduate program I met a gentleman Aveshy Witkow, he was from Is real. He told me that he came India to get inner peace because He is not happy with his life. While returning I asked about what he got and he said he still not happy.
The question arises why he was not?

I think the answer is inner peace to get happy life cannot be achieved by travelling far. The place you have to visit, is your own hearth. Ask yourself what you want? If you do what your hearth says then you must be happy because now you are listening to yourself not others.

-By
Pankaj Pathak

Tuesday, 7 July 2015

Effect of technology on education


In the words of "Nelson Mandela"- " education is the most powerful weapon which you can use

to change the world".



thinking of this deeply, when we thought changing the world by education, what does it mean?

Simply it means, education teach people to think critically, positively. So the world can change.

technology from some past decades is also changing; so is it right to say technology is changing

the world? Yes of course. Technology has changed the way we live, travel, and affect all of us

somehow. If this technology is changing the world and change in world can be done by

education we can think of that technology has changed the education.

 But as it said every coin has 2 sides, effect of technology on education also have 2 sides.

thinking of negative side, think of calculators. Though it makes calculation easy and fast, but

making our capability of thinking is decreasing. Games are also considered to be part of good

education, but when we say games it does it mean graphical games. No, it means physical

activities so we can be fit to be learn everything. Video games are attracting new generation

though they are colorful, interesting but they make us physically imperfect.



as it said noting has only bad in it. Technology has changed our education system a lot. Distance

learning, e- education, smart classes, computers are those examples where we see positive

impact of technology on education. And there is many more latest technologies in education

system now a days. Technology has made our education very fast and advanced, so thanks to

technology.


-by
Pankaj Pathak
(pankaj.pathak175@gmail.com)

Monday, 6 July 2015

[How to] Block Facebook Game Requests

Not everyone likes getting constant game requests from friends. This is a simple most effective way to completely block Facebook game requests.
This tutorial is to be followed using and android or iPhone.
1. Open the Facebook app and tap on More on the bottom right, then scroll down and tap on Account Settings.
Block-Facebook-Game-Requests-2
2. Scroll down and tap on Apps.
Block-Facebook-Game-Requests-1
3. Now tap on Platform.
Block-Facebook-Game-Requests
4. Finally under “Game invites and App Notifications” select NO or OFF. From now on you will never get any game invites.
Block-Facebook-Game-Requests-3

Saturday, 4 July 2015

Line Follower Robot using Arduino

This line follower robot is basically designed to follow a black line on a white surface. Any way the same project can be used to follow the opposite configuration with appropriate changes in the software. The entire hardware of this simple line follower robot using arduino can be divided into three parts. The sensor, arduino board and the motor driver circuit. Lets have a look at the sensor first.

Sensor.

The sensor consists of two LED/LDR pairs with appropriate current limiting resistors. The resistance of an LDR is inversely proportional to the intensity of the light falling on it.  The circuit diagram of the sensor is shown in the figure below.
arduino line followerResistors R1 and R2 limits the current through the LEDs. Resistors R6, R8, R3,and R5 forms individual voltage divider networks in conjunction with the corresponding LDRs. When the sensor is correctly aligned, both LED/LDR pairs will over the white surface. In this condition sufficient amount of light gets reflected back to the LDRs and so their resistance will be low. So the voltage dropped across the LDR will be low. When the robot is drifted to  one side , the sensor in the opposite side falls over the black line and the intensity of light reflected back to the corresponding LDR  will be low. As a result the resistance of the LDR shoots up and the voltage dropped across it will be high. The voltages dropped across the right and left LDRs (nodes marked R and L in the above circuit)  are given as input to the analog input pins A4 and A3 of the Arduino board. Right and left sensor outputs observed while testing the above circuit is shown in the table below.
line follower robot using arduino

Arduino uno board.

The arduino board has to be programmed to keep the robot in correct path. This is done by reading the left and right sensor outputs and switching the left and right motors appropriately. Output of the right sensor is connected to the analog input A4 of the arduino and output of the left sensor is connected to the analog input A3 of the arduino. The voltage range that can be applied to a particular analog input of the arduino is 0 to 5V. This range can be converted into a digital value between 0 and 1023 using  analogRead () command.  For example if 3V is applied to A3,  the following code will return 3/(5/1023) which is equal to 613 in the variable leftValue.
int leftInput = A3;
int leftValue=0;
void loop ()
{
leftValue = analogRead (leftInput);
{
From the above table you can see that the voltage across a particular LDR will be 4.4V when it on white and 4.84V when it is on black. The digital equivalent of 4.4V will be 900 and that of 4.84V will be 990 as per the above scheme.  The median of these two values is 945 and it is set as the reference point for the program to check the orientation of the sensor module.
The program identifies the position of the sensor module by comparing the sensor readings with the reference point that is 945. If the reading of a particular sensor is greater than 945 the program can assume that the particular sensor is above black. If the reading of a particular sensor is less than 945 then it is assumed that the particular sensor is above white. If both sensor readings are less than 945 then it means both sensors are on white. If both sensor readings are above 945 it is assumed that both sensors are above black (the same thing happens if we lift the robot off the track). Based on the above four conditions, the program appropriately switches the left and right motors to keep the robot following the black line.

Motor driver.

The motor driver circuit is based on two NPN transistors Q1 and Q2. Each transistors are wired as a switch with a resistor at its base for limiting the base current. The motors are connected to the emitter terminal of the corresponding transistors. A 0.1uF capacitor is connected across each motor  for by-passing the voltage spikes. Back emf  and arcing of brushes are the main reason behind the voltage spikes. If these voltage spikes are not by-passed it may affect the Arduino side.   Circuit diagram of the motor driver is shown in the figure below.
arduino line follower motor driver

Circuit diagram.

Full circuit diagram of the line follower robot  is shown in the figure below.
line-follower

Program.

int leftInput=A3;
int rightInput=A4;
int leftMotor=13;
int rightMotor=12;
int leftValue = 0;
int rightValue = 0;
void setup()
{
  pinMode (leftMotor, OUTPUT);
  pinMode (rightMotor, OUTPUT);
}
void loop()
{
  leftValue = analogRead (leftInput);
  rightValue= analogRead (rightInput);

 if
   ( leftValue < 945 && rightValue < 945)
   {
     digitalWrite (leftMotor, HIGH);
     digitalWrite (rightMotor, HIGH);
   }
   else
   {

     if
     ( leftValue > 945 && rightValue < 945)
    {
      digitalWrite (leftMotor, LOW);
      digitalWrite (rightMotor, HIGH);
    }
 else {
   if (leftValue < 945 && rightValue > 945)
   {
   digitalWrite (rightMotor, LOW);
   digitalWrite (leftMotor, HIGH);
   }
   else
   {
     if (leftValue > 945 && rightValue > 945)
     {digitalWrite (rightMotor, LOW);
       digitalWrite (leftMotor, LOW);
     }}
      }
    }}

Setting up the circuit.

  • First of all remember that each LED and LDR has its own characteristics.
  • Carefully measure the voltage across each LDRs in both scenarios (on white surface and black).
  • A lot of parameters like individual LDR/LED characteristics, ambient light, clearance between sensor and surface etc may affect the result.
  • Get in to your own reference point for the program. In my case it was 945 but you may get a different value.
  • Use a separate power supply unit for powering the motors. Anything above 100mA will be hard for the USB port.
  • The motors used here are 9V/30RPM DC bow motors. If such a configuration is not available, choose the closest one.
  • While soldering up the sensor module, the gap between the two LED/LDR pairs must be selected according to the width of the black line. In my case it was 2cm.
  • Clearance of the sensor from the ground was around 1cm in my case.
  • The sensor LEDs used were 4mm bright green LEDs.
  • The sensor LDRs used were general purpose LDRs.

Simple LED Projects using Arduino

This article is another step forward in learning more about Arduino. We have demonstrated 5 simple led based projects using arduino, which will help you to learn its basic concepts.
1. Blinking Two LED’s using Arduino
As a beginner, if you have tried the “Hello World” program to blink an LED using Arduino; you can try to blink Two LED’s as next project. There are 14 I/O (input/output) pins in your Arduino uno board. These pins are numbered from 0 to 13. They can be configured as either input or output in the sketch you create for arduino. If you have learned the “Hello World” program carefully, you now know that input/output configuration of pins has to be done inside the setup() function. So here is the circuit diagram to blink 2 led’s using arduino.
Blink_2_LED_with_Arduino

Sketch to Blink Two LED’s using Arduino
const int LED1 = 12;
const int LED2 = 13;

void setup()
{
  pinMode(LED1,OUTPUT);
  pinMode(LED2,OUTPUT);
}

void loop()
{
  digitalWrite(LED1,HIGH);
  delay(1000);
  digitalWrite(LED1,LOW);
  digitalWrite(LED2,HIGH);
  delay(1000);
  digitalWrite(LED2,LOW);
}

The only difference in this sketch is use of 2 pins in output mode. I have used pin number 12 and 13as output. I have configured them as output inside the setup() function. Inside the loop(), I have written commands to blink LED’s alternatively. When LED1 is ON, LED2 will be OFF. After 1 second LED1 will turn OFF and at the same time LED2 will turn ON. Wait another 1 second and you will see LED2 turning OFF and LED1 turning ON. This cycle repeats.
I have added a photograph of the practical setup I made below.
Blink_2_LEd_with_Arduino
You can watch video of the same circuit below.
2.Control LED with Push Button
If you observe carefully, so far we were just playing with some outputs. We made one LED blink and then we stepped ahead to make two LED’s blink. In both cases we wrote software commands to make our arduino blink led’s automatically at an interval of 1 second. What if we want to control led’s ON and OFF time based on a user input?  This means, I want to give an input manually and based on my input LED should turn ON and OFF. We can use a push button switch to give user input to arduino. In fact, we can use any type of a simple switch like Push to On or Push to Off or a mini push button switch. In this example I am using a “normally open” mini push button switch. A normally open push button switch will be in its open state by default. This switch will close for the time we keep its actuator pressed. If you want to know more about working of different push button switches, you can read our detailed article on push button switches.
http://i2.wp.com/techfeasta.com/wp-content/uploads/2015/04/Control_LED_with_Push_Button.png?resize=693%2C366

I have added the circuit diagram to control LED with arduino using a push button switch.  To connect push button to arduino, we need one of the digital I/O pins configured as a digital input. In this example, I have set pin number 7 as a digital input. So we should connect the push button switch to pin 7 of arduino as shown in circuit. A reference voltage should be connected to one end of switch and the other end of switch should be connected to ground. To avoid a short circuit between pin number 7 and ground, you should connect a resistor (preferable a 10K ohm) in between. The reference voltage is used to detect ON state or closed state of the push button. Arduino board has a readily available +5 voltsreference on power pins cluster. When the push button is pressed, the reference voltage line will get connected to pin number 7.  This voltage will drop across the 10K ohmresistor. So when push button is pressed, a +5 volts is available at pin 7 and this will be considered as state HIGH. On the other hand, when the push button is released (residing in its normally open state), there is no reference voltage line connected at pin 7. On this state, the voltage across 10K resistor is 0 volts (ground potential). This same potential is at pin 7 as well and will be considered as state LOW. This is how ardunio distinguishes between closed (ON) and open (OFF) states of push button switch.
Lets get into the program side of controlling LED using push button switch. In this program, the highlight is instruction to read push button state. APL (Arduino programming language) has an instruction named digitalRead() – which reads a digital input given at the configured input pin. In our program, this instruction reads the status at pin 7 and returns a value according to what it has read. In our example this instruction reads voltage level at pin number 7; returns HIGH if its +5 volts and returns LOW if its 0 volts. Since it returns a value, we have to assign this instruction to a variable while we write the program. We have used the variable val to store the value returned by the instruction digitalRead(). The push button switch is connected to pin 7 and we have assigned this pin 7 to a variable named SW inside our sketch. Inside the setup()function, we have configured this pin 7 (the SW variable) as input using pinMode() instruction. So here is the program.
const int LED = 13;
const int SW = 7;

 int val=0;

void setup()
{
  pinMode(LED,OUTPUT);
  pinMode(SW, INPUT);
  }

 void loop()
 {
   val=digitalRead(SW);
if(val==HIGH)
{
digitalWrite(LED,HIGH);
}
else
{
  digitalWrite(LED,LOW);
 }
 }

3.Toggle LED using Push button
Lets get into next project which is even more interesting. Here we are going to toggle an LED using a push button switch. Toggle means to change state. Our objective here is turn LED ON with first push button press and turn LED OFF with next push button press. This cycle of ON and OFF should continue with each push button press.  The same circuit diagram given above is enough to do this project as we are not manipulating any hardware connection. We just need to change our software (sketch) to change the behavior of this circuit.
Here is the sketch to toggle an LED using push button switch.
const int LED=13;
const int SW=7;
boolean state = true; //declare variable state as boolean
int val=0;

void setup()
{
  pinMode(LED,OUTPUT);
  pinMode(SW,INPUT);
  }
void loop()
{
  val=digitalRead(SW);
  delay(120); // Software debouncing using 120ms delay

if(val==HIGH)

{state=!state; // Compliment variable state using ! operator
  digitalWrite(LED,state);
}
}

I used a “normally open” mini push button switch to implement the circuit. This means a push button press always gives us a “HIGH” state. In other words, we have to sense the closed state of push button switch to turn LED ON and OFF. Turning LED ON and turning LED OFF  both depends on a single event – the press on actuator of push button switch (its closed state – when the voltage at switch = HIGH). We can do this program in many ways. An efficient program always will have less lines of code. In this program, I used boolean instructions and a complement operator. In the program a variable namedstate is declared as boolean and I initialized it as true.  A boolean instruction has only two possible values, either true orfalse. The next highlight of the program is to use of complement operator ( ! ). This is the same negation operator we see in 8051 and other micro controllers. For example, we have an instruction called CPL in 8051 instruction set. This instruction compliments the values in accumulator (0’s with 1 and 1’s with 0’s). In digital electronics, a NOT gate performs the same task.
So here is the working of program. We initialized variable state as true.  Other lines of code are the same we used in previous programs. You already know what is written inside setup(). Lets come toloop(). We sense input of switch withdigitalRead(SW) and store it in an integer variable val. Now we check for the push button press by continuously checking if the variable val has ever registered aHIGH. If it ever registers a high, we compliment the status of state variable and save it to the same variable. Now if the state variable was TRUE before, it has been complimented to FALSE. We write the status of state variable to LED. Based on the value of state variable LED will turn ON and OFF. LED will turn ON if state variable holds a TRUE and LED will turn OFF if state variable holds a FALSE. This process of reading the push button switch and complimenting the state variable continuous.
Note:- In our program, the first push button press actually turns the LED OFF. It will turn ON only with second push button press. From then it will alternate between ON and OFF with each push button press. If you want it to turn ON with first push button press, you just need to make a change in the boolean declaration statement. Declare the variable as FALSE initially.
Note2:- You might have noted a delay(120); instruction just below the val=digitalRead(SW);instruction. It is calledsoftware debouncing technique. This a practical aspect of the circuit. If you are to write the program based on theory, you don’t need a delay instruction here. But there is a practical problem. You may upload the code with out this delay instruction and see the behavior of circuit. Some push button press will actually toggle and some other will not yield an expected result. This behavior is due to 2 reasons. 1) The push button is a mechanical switch. One push button press will yield a series of high pulses (bcz of the vibration created when 2 mechanical parts get in contact) in practice. 2) Arduino is a really fast prototyping platform. In fact its not arduino, its the micro controller used in the board that’s really fast. In an arduino uno, Atmega328 is used which is of 20 MIPS execution capability. This means the controller can execute 20 million instructions per second. It is very very fast than we can imagine. So arduino will sense all these series of high pulses created by one push button press. But we dont need arduino to sense all these pulses. We just need 1 HIGH pulse per push button press. This is a problem created by the bouncing switch and we eliminate this problem through a debouncing technique. There are 2 types of debouncing techniques. Here we apply software debouncing. You may read more about debouncing techniques in our article.

4. Toggle 2 LED using Pushbutton

Our next project is to toggle 2 LED’s using a single push button switch. Here we need one more LED and little tweak in the software. I have added the circuit diagram and program below.  I respect your intelligence. You don’t need an explanation for this circuit and program after learning this much.
Toggle_2_LED_using_Push_Button

I have added the sketch below. Read the sketch carefully. We just need to add a few lines to above program. Its really that simple.
const int LED1=13;
const int LED2=12;
const int SW=7;
boolean state = true; // declare variable state as boolean
int val=0;

void setup()
{
  pinMode(LED1,OUTPUT);
  pinMode(LED2,OUTPUT);
  pinMode(SW,INPUT);
 }
void loop()
{
  val=digitalRead(SW);
  delay(100); // Software debouncing

if(val==HIGH)

{state=!state; // Complimenting the status of LED
  digitalWrite(LED1,state);
  digitalWrite(LED2,!state);
}
}
I have added a video of the practically implemented circuit. You can watch it below.
Note 3:- I already wrote that there are different ways to create a program. This same program for toggling LED can be written without using a boolean variable. If we dont use a boolean variable, we can not make use of the compliment operator. This simply means we have to handle the task of switching LED states inside our code. I have added a sketch to toggle an LED without using boolean variable. If you take a closer look, you can see this program is very big and uses more variables and instructions than our previous program (with boolean variable). But both sketches leads the same desired output. So which program is more efficient ? The one with less lines of code!
const int LED1 = 13; 
const int LED2 = 12;
const int SW = 7;
 int flag;
 int val=0;
 int state=1;

void setup() 
{
  pinMode(LED1,OUTPUT); 
  pinMode(LED2,OUTPUT);
  pinMode(SW, INPUT); 
  }

 void loop() 
 {
 val=digitalRead(SW);
 delay(100);
 if(val==HIGH&&state==1)
 {
   digitalWrite(LED1,HIGH);
   digitalWrite(LED2,LOW);
   flag=0;
 }
 if(val==LOW&&flag==0)
 {
 digitalWrite(LED1,HIGH);
   digitalWrite(LED2,LOW);
   state=0;
 }
 if(val==HIGH&&state==0) 
 {
   digitalWrite(LED1,LOW);
   digitalWrite(LED2,HIGH);
   flag=1;
 }
 if(val==LOW&&flag==1)
 {
     digitalWrite(LED1,LOW);
   digitalWrite(LED2,HIGH);
   state=1;
 }
 }

Fan Speed Controlled by Temperature and Arduino

I made this project because I wanted a way to automatically control the speed of a DC fan according to the temperature read by a LM35 sensor. I had a few problems with the PWM part mainly because the fan made a disturbing noise so I had to add a simple RC filter at the output of the PWM pin on the Arduino board.
arduino-temperature-fan-speed-control-550x494

Arduino Sketch
  1. #include <LiquidCrystal.h>
  2. LiquidCrystal lcd(7,6,5,4,3,2);
  3. int tempPin = A1; // the output pin of LM35
  4. int fan = 11; // the pin where fan is
  5. int led = 8; // led pin
  6. int temp;
  7. int tempMin = 30; // the temperature to start the fan
  8. int tempMax = 70; // the maximum temperature when fan is at 100%
  9. int fanSpeed;
  10. int fanLCD;
  11.  
  12. void setup() {
  13. pinMode(fan, OUTPUT);
  14. pinMode(led, OUTPUT);
  15. pinMode(tempPin, INPUT);
  16. lcd.begin(16,2);
  17. }
  18.  
  19. void loop() {
  20. temp = readTemp(); // get the temperature
  21. if(temp < tempMin) { // if temp is lower than minimum temp
  22. fanSpeed = 0; // fan is not spinning
  23. digitalWrite(fan, LOW);
  24. }
  25. if((temp >= tempMin) && (temp <= tempMax)) { // if temperature is higher than minimum temp
  26. fanSpeed = map(temp, tempMin, tempMax, 32, 255); // the actual speed of fan
  27. fanLCD = map(temp, tempMin, tempMax, 0, 100); // speed of fan to display on LCD
  28. analogWrite(fan, fanSpeed); // spin the fan at the fanSpeed speed
  29. }
  30. if(temp > tempMax) { // if temp is higher than tempMax
  31. digitalWrite(led, HIGH); // turn on led
  32. } else { // else turn of led
  33. digitalWrite(led, LOW);
  34. }
  35. lcd.print(“TEMP: “);
  36. lcd.print(temp); // display the temperature
  37. lcd.print(“C “);
  38. lcd.setCursor(0,1); // move cursor to next line
  39. lcd.print(“FANS: “);
  40. lcd.print(fanLCD); // display the fan speed
  41. lcd.print(“%”);
  42. delay(200);
  43. lcd.clear();
  44. }
  45.  
  46. int readTemp() { // get the temperature and convert it to celsius
  47. temp = analogRead(tempPin);
  48. return temp * 0.48828125;
  49. }
test setup
I used an LCD shield to display the current temperature and speed of the fan, but you can use the circuit without the LCD display. You also need to select the transistor by the type of fan that you use. In my case I used the well-known BD139 transistor and a 9V battery to provide power to the fan and transistor. The LM35 temperature sensor and red led are powered with 5V from the Arduino board.
How does the circuit works?
As you can see in the sketch on the first line I included the LiquidCrystal library (header) that includes useful functions to use when an LCD is connected to the Arduino board. Then I set the pins for the sensor, led and fan.
The most important part is to set the variables tempMin and tempMax with your desired values. tempMin is the temperature at which the fan starts to spin andtempMax is the temperature when the red led lights warning you that the maximum temp was reached. For example if you set tempMin at 30 and tempMax at 35 then the fan will start spinning at 30°C and reach its maximum speed at 35°C.
We store the temperature value in the temp variable and then use some if() functions to check if temp is lower than tempMin and if so let the fan OFF (LOW). The next if() is to check if temperature is higher than the minTemp and lower than the tempMax and if so then use the map() function to re-map the temp value from one value to another. In our case fanSpeed will have a value of 32 at tempMin and 255 at tempMax. These values are used to control the speed of the fan using PWM and the analogWrite().
The fanLCD re-maps the temp to allow the display of fanSpeed in a 0 to 100% range so you can say that the speed of the fan is directly dependent of the LM35′s temperature. When the temperature reaches the value set in tempMax the fan will be at its maximum spinning velocity and the LCD will display FANS: 100% even though the temperature might increase above tempMax.
The rest of the explanation can be read in the comments area of the Arduino sketch.