Output Devices

Output devices are essential components in various systems and technologies, converting electronic signals into tangible actions or displays. They play a crucial role in transforming digital information into physical outcomes that users can perceive and interact with. Here's a brief overview of output devices along with examples

DC Motor:
DC (Direct Current) motors are commonly used output devices that convert electrical energy into mechanical motion. They find applications in robotics, industrial automation, automotive systems, and consumer electronics.

Servo Motor:
Servo motors are specialized output devices widely used for precise control of angular or linear position, velocity, and acceleration. They incorporate feedback mechanisms such as encoders or potentiometers to achieve accurate motion control.

LED Display:
Light Emitting Diode (LED) displays are output devices used to visually convey information through the emission of light. LED displays offer advantages such as high brightness, low power consumption, and long lifespan.

Stepper Motor:
A stepper motor is a type of electromechanical device widely used for precision motion control in v arious applications such as 3D printers, CNC machines, robotics, and automated systems. Unlike conventional motors that rotate continuously when power is applied, stepper motors move in discrete steps, allowing precise positioning and control.

Group Assignment

The Kannai team as usual was divided into two and i worked with Ahmad Tijjani Ishaq The task is to measure the power consumption of an output device. Our documentation can be found on Our group assignment page

We measured power consumption of three different dc motors (12v, 9v, and 5v ), using a multimeter and also power supply. We measured power for stall possition too.

Individual Assignment

All source files can be found Here at the side bar.

Assignment for the week is to add an output device to a microcontroller board you’ve designed, and program it to do something

I designed and Produced my final Project electronic board and more about it can be found on my week 8 Assignment page. On my board, there are pins for output devices such as:

  • Solonoid
  • LED
  • And more spaces are also provided. I focused on The solonoid aspect for my assignment and i also played with :
    • DC motor (control with relay and arduino uno board)
    • Servo motor with arduino uno board

Solonoid Lock

A solenoid lock is a type of electromechanical locking mechanism that utilizes a solenoid—a coil of wire wound around a ferromagnetic core—to control the locking and unlocking of a door or access point. Solenoid locks are commonly used in applications where remote or electronic control of access is required, such as in security systems, electronic safes, vending machines, and industrial equipment. This makes it suitable for my final project.


Working Principle

  • A solenoid lock consists of a solenoid coil, a plunger or bolt mechanism, and a housing that holds these components.
  • When an electric current is applied to the solenoid coil, it generates a magnetic field that magnetizes the ferromagnetic core.
  • This magnetic field attracts or repels the plunger or bolt, depending on the design of the lock.
  • In the locked state, the plunger or bolt is extended or engaged, preventing the door or access point from opening.
  • When the electric current to the solenoid coil is interrupted or reversed, the magnetic field weakens or changes polarity, causing the plunger or bolt to retract or disengage, allowing the door to open.

Based on the working principle, a simple High and Low code can extend or contract the solonoid plunger But one problem arises. I am using a 12v solonoid device and the output signals of my pico is 3.3v.
To solve this i had to make a seperate power system of 12v on my board and also provide a switching mechanism. There are many ways to perform switching operation for example we can use a relay or a transistor. I chose a transistor for that purpose.

Switching System
I designed my switching system with a mosfet transistor as follows:

  • I used a 3s battery to provide the required 12v for the solonoid
  • I connected the gate of the mosfet to the signal pin of my pico
  • I connected the source to ground
  • then i connected the drain to one of the pin of my solonoid
  • The other pin of the solonoid was connected to the 12v + of my battery
  • Once there is signal at the gate, the mosfet switches on the solonoid
  • The diagram is as shown below

I used a basic blink code to test the working of my solonoid


I completed my activity and decided to work with DC motor and servo motor using arduino board as follows.

DC Motor

A DC motor operates based on the principles of electromagnetism and the Lorentz force law.

  1. Basic Components: A DC motor consists of two main parts: the stator (stationary part) and the rotor (rotating part).
  2. Magnetic Field: When a current passes through the coils of the electromagnets in the stator, a magnetic field is generated. This magnetic field interacts with the magnetic field produced by the rotor.
  3. Lorentz Force: According to the Lorentz force law, when a current-carrying conductor (in this case, the rotor) is placed in a magnetic field, a force is exerted on it.
  4. Rotor Movement: As the rotor experiences a force due to the interaction between the magnetic fields, it starts to rotate.
  5. Commutation: The direction of the current flowing through the rotor coils needs to be reversed periodically to keep the rotor turning in the same direction. This is achieved through a commutator.
  6. Speed Control: The speed of a DC motor can be controlled by varying the voltage applied to it.
  7. Torque Production: The torque produced by a DC motor is proportional to the strength of the magnetic field, the current flowing through the rotor coils, and the length of the conductor within the magnetic field.

Overall, the working principle of a DC motor relies on the interaction between magnetic fields and current-carrying conductors, resulting in rotational motion that can be controlled and utilized for various applications.

Wiring
The wiring is simple as the DC motor has just two pins. One is sonnected to the signal pin and the other to ground, once the signal pin is set to high it turns on the DC motor. However, The voltage level at the pins of arduino uno is 5v which is not enough for my 12v DC motor hence i resort to using relay for switching purpose.

Relay

A relay is an electromechanical switch used to control the flow of electricity in a circuit. It consists of a coil, an armature, and one or more sets of contacts. Relays are commonly used in various applications where it's necessary to control high voltage or high current devices using a low voltage control signal.

Working Principle
When a current flows through the coil of the relay, it generates a magnetic field which causes the armature to move. The movement of the armature either makes or breaks the connection between the contacts, thus opening or closing the circuit connected to the relay.

Relays are often used as switches in circuits where the control signal needs to be electrically isolated from the load circuit. This isolation helps in protecting the control circuit from voltage spikes or other disturbances present in the load circuit.

Types of Relays

There are several types of relays, including:

  • Electromechanical Relays: These are the traditional relays that use an electromagnet to mechanically operate the contacts.
  • Solid-State Relays (SSRs): SSRs use semiconductor devices like transistors and thyristors to perform switching operations without any moving parts. They offer faster switching speeds, longer lifespan, and are often used in applications where silent operation and high switching frequency are required.
  • Reed Relays: Reed relays use a hermetically sealed reed switch enclosed in a glass tube. They are compact, have low contact resistance, and are often used in high-frequency applications.
  • Time Delay Relays: These relays are designed to operate with a delay after the control signal is applied. They are commonly used in applications where timing functions are required.

Overall, relays play a crucial role in controlling electrical circuits in various applications, providing isolation, protection, and switching capabilities. I used the 12v electromechanical relay for the switching purpose.

As seen in the above pictures, I used key yes studio relay and i connected my motor as follows:

  • I connected the IN to the signal pin
  • I connected the GND to gnd of arduino
  • I connected the VCC to 5v arduino
  • I connected the NO to one pin of the DC motor
  • I connected the COM to the possitive voltage of my 12v battery
  • I connected the negative of my battery to the other pin of my DC motor
  • Below is a similar circuit using 9v battery

  • I also used a similar code as i did with the solonoid and thats the end of my DC motor documentation.

  • Servo motor

    A servo motor is a rotary actuator that allows for precise control of angular position. It is widely used in various applications such as robotics, automation, remote-controlled vehicles, and precision engineering where accurate and smooth motion control is required.

    Working Principle

    Servo motors operate based on a closed-loop control system. The basic components of a servo motor system include the motor, a position feedback sensor (such as a potentiometer or an encoder), and a control circuit.

    Here's how a servo motor works:

    1. Reference Signal: The desired position or angle is set by providing a reference signal to the servo motor control circuit. This signal typically comes from a microcontroller or a dedicated servo controller.
    2. Comparison: The control circuit compares the reference signal with the feedback signal received from the position sensor. The feedback signal indicates the current position of the motor shaft.
    3. Error Signal: Any difference between the reference signal and the feedback signal generates an error signal, which is used to determine the direction and magnitude of the required correction.
    4. Motor Control: The control circuit then adjusts the power supplied to the motor based on the error signal, driving the motor shaft to the desired position.

    This closed-loop control mechanism ensures that the servo motor accurately follows the desired position or angle, even in the presence of external disturbances or variations in load.

    Types of Servo Motors

    There are various types of servo motors, including:

    • DC Servo Motors: These motors use a DC motor as the actuator and are suitable for applications requiring moderate to high torque and speed.
    • AC Servo Motors: AC servo motors use an AC induction motor or a synchronous motor combined with a feedback control system. They offer high torque, high precision, and are often used in industrial automation and CNC machinery.
    • Brushless Servo Motors: These motors use brushless DC motors with feedback control. They offer high efficiency, low maintenance, and are commonly used in applications requiring high precision and reliability.

    Overall, servo motors provide precise motion control and are essential components in various electromechanical systems and applications. I used the tower pro servo motor with arduino uno

    Wiring
    The servo motor as seen in picture above has 3 pins, Then red is connected to 5v of arduino, the brown is connected to ground and the yellow/orange is connected to the signal pin.
    I uploaded two codes, the first is the sweep code from the servo library example and the second code is a custome sketch to move the servo to different angles as shown below.


    All source files can be found Here at the side bar.


    Contact Me

    Phone: Email: Address: Repository:
    +2348132166281 mjidda@nitda.gov.ng No.3 Alimoh Abu street, wuye districs.Abuja Nigeria. Gitlab Repo