In this post we’ll study how to control a relay using Arduino on Tinkercad using NPN Transistor Control.
As we know Arduino have only limited output voltage and current from its pins.
So when we want to control a motor or a bulb we need to first control a relay to control that bulb or motor.
But also the relay coil draws relativily high current from that Arduino can supply.
That’s why we use the NPN transistor as a switch.
Here is the complete circuit that controls the transistor from Arduino to control the relay which supplies voltage to the bulb.
Code
Here is the simulation video on Tinkercad
https://www.tinkercad.com/things/bRRLalBRMhR-arduino-relay-button-npn-control
as we see in this video see we control relay from Arduino to power some high power stuff like a bulb from higher voltage from Arduino.
as we know Arduino cannot control high power devices it only supplies 5 volts with limited current, so we use relays in between to control motors and bulbs with a high voltage.
this relay cannot be directly controlled from Arduino because it throws current from its coil, now we know it only supplies 5 voltage with limited current, so we use that transistor NPN as a switch, this is the emitter base and collector we use it as a switch between the Arduino and the relay base
It is directly controlled by the Arduino output pin so it rings he 5 voltage to the relay terminal to control it’s open and close, let’s see how this circuit work this is the code here we can see that it has the code to control the pin button number 8 to take the action from the pin button.
as we have seen in the previous posts this relay the output pin number 2 it starts with the state relay low and a state button, this uses the bounce to to filter the input from the button and it makes some delay in between>
so let’s start the emulation and see how it’s working, let’s press Start simulation and find that there are three volts coming to the Bulb and controlled by the relay which is controlled by that transistor controlled by the Arduino>
let’s press the button then bulb lights on we can see high current and then pours off let’s see it again it’s powered up then it’s powered down t’s powered up then powered down .
Recent posts
- My Six Years Old Son Wanted to Build His own Flying CarBuilding My Son’s Dream: A Flying Car with Tinkercad and Arduino Ever since my 6-year-old son could talk, he’s been fascinated by the idea of flying cars. He would sketch designs, build models with his toys, and talk about how one day he would soar above the ground in a car with wings. His dream… Read more: My Six Years Old Son Wanted to Build His own Flying Car
- How I made My Kids #Arduino #Flying Car #Tinkercad Dream #Aviation #AeroArduinoIntroduction: Welcome to a new project from AeroArduino, where we turn dreams into reality! In this exciting project, we’re bringing to life a childhood dream of creating an Arduino flying car using TinkerCAD. If you haven’t subscribed yet, be sure to hit that subscribe button to stay updated with our latest projects. Circuit Connection: Let’s… Read more: How I made My Kids #Arduino #Flying Car #Tinkercad Dream #Aviation #AeroArduino
- Easy #Tinkercad #Arduino distance measurement using ultrasonic sensor #AeroArduino
- Building a Smart Ultrasonic Car With Code Blocks on TinkercadToday, I want to share an exciting project that brings together ultrasonic sensors, motors, and a sprinkle of programming magic to create a Smart Ultrasonic Car. Imagine a little robotic vehicle that can sense its surroundings and make decisions on the fly – that’s exactly what we’re diving into! The Heart of the Project: Ultrasonic… Read more: Building a Smart Ultrasonic Car With Code Blocks on Tinkercad
- Super Simulation for Accelerometer with Arduino in TinkercadIntroduction The world of electronics education often relies on simulation software to bridge theoretical knowledge and practical application. TinkerCAD stands as a prominent platform for simulating electronic components, aiding enthusiasts and learners in experimenting virtually. In this tutorial, we’ll explore how to overcome the absence of an accelerometer component in TinkerCAD by using a creative… Read more: Super Simulation for Accelerometer with Arduino in Tinkercad
- Monitoring Soil Moisture with Arduino and LCD: A Step-by-Step GuideHow to Build Step-by-Step Arduino Soil Moisture Sensor With Tinkercad Simulation – DIY Guide on AeroArduino
- Revolutionizing Aircraft Ground Handling: The Advantages of Remotely Controlled TugsIntroduction: The aviation industry has witnessed minimal innovation in aircraft tugs, resulting in outdated and inefficient ground handling operations. However, the advent of remotely controlled aircraft tugs has the potential to transform ground handling practices. These advanced tugs offer numerous advantages over traditional counterparts, including increased efficiency, improved safety, and reduced environmental impact. In this… Read more: Revolutionizing Aircraft Ground Handling: The Advantages of Remotely Controlled Tugs
- The Mighty Antonov AN-22: Revolutionizing Cargo Transportation in the SkiesIntroduction: In the realm of aviation, where technological advancements continually push boundaries, the Antonov AN-22 shines as a true marvel. With its massive size and unparalleled cargo-carrying capabilities, this iconic propeller aircraft has carved its name in the annals of aviation history. Join us as we delve into the world of the Antonov AN-22 and… Read more: The Mighty Antonov AN-22: Revolutionizing Cargo Transportation in the Skies