Electronics tutorials including microcontroller, microprocessor, programing and circuits. Intended for beginners, electronics hobbyists, college students, professionals and educational purposes.

Interfacing GLCD with PIC Microcontroller

I have already posted about Interfacing character LCD with PIC Microcontrollers. By using GLCD (Graphical LCD) we can present information in a better and user friendly way by using any patterns or shapes. Graphical LCDs are preferred where both character and graphical representation are required. Compared to Character LCD, GLCD is a bit complex and we need a powerful graphic library. MikroC PRO for PIC Microcontrollers provides powerful built in libraries for that. GLCD  MikroC Pro - Graphic LCD Library MikroC Pro for PIC Microcontrollers...

Interfacing Ultrasonic Distance Sensor : ASCII Output with PIC Microcontroller

In some of our projects, we may want to measure the distance of an object from a point. Ultrasonic Distance Sensors are the best sensor which provides stable, accurate, precise, non-contact distance measurements from 2cm to 4m. Ultrasonic Sensors can be used to measure distance between moving or stationary objects. Being very accurate and stable, these devices find large number of applications in robotics fields. For example it can be used as an excellent replacement for IR sensors in  a Micromouse. In...

Interfacing Relay with PIC Microcontroller

A relay is an electromagnetic switch which is used to switch High Voltage/Current using Low power circuits. Relay isolates low power circuits from high power circuits. It is activated by energizing a coil wounded on a soft iron core. For detailed working of relay please visit this page. A relay should not be directly connected to a microcontroller, it needs a driving circuit. A relay should not be connected directly to a microcontroller due to following reasons.. A microcontroller is not able...

DC Motor Speed Control using PWM with PIC Microcontroller

I already posted about Interfacing DC Motor with PIC Microcontroller. In our robotics applications we may have to control the speed of the DC Motor. In this tutorial we will see how to control the speed of a DC Motor using Pulse Width Modulation (PWM). By using PWM we can easily control the average power delivered to a load and by thus we can easily control the speed of the DC Motor. You may think that a variable resistor in series...

Generating PWM with PIC Microcontroller using CCP Module

PWM is a technique used to generate analog output signal using digital signals. It is commonly used to control average power delivered to a load, motor speed control, generating analog voltage levels and for generating analog waveforms. CCP Modules are available with a number of PIC Microcontrollers. CCP stands for Capture/Compare/PWM. Using PWM module is far more easier and cost effective than using extra chips for PWM generation.  MikroC Pro for PIC Microcontroller provide built-in library for PWM which makes our...

Expanding IO Ports of PIC Microcontroller using MCP23S17

Usually a microcontroller comes with a limited number of IO ports called General Purpose Input Output (GPIO) ports. But some applications require more IO ports than that available on a microcontroller. In these cases we can use IO Port Expanders to increase the IO capability of a microcontroller. MCP23017 and MCP23S17 are two such 16 bit IO expander with Serial Interface  manufactured by Microchip. MCP23017 uses high speed I2C interface while MCP23S17 used high speed SPI interface. MCP23S17 In this tutorial we...

Analog to Digital Conversion in ARDUINO

Analog to digital conversion module of ARDUINO UNO has 6 input ports. The number of the port varies with your ARDUINO model but the coding remains the same. The analog reading in the analog inputs are converted into corresponding 10bit(0-1023). ARDUINO developers have made such an option that you can print anything and see it on the Serial monitor. This example demonstrates analog input usage by reading an analog sensor on analog pin 0 and turning on and off a light...

Building Your Own PCB : Printed Circuit Boards

The electronic product construction technique for many is the printed circuit board, or PCB. There are a number of ways to build a custom printed circuit board. Good quality copper clad should be used for manufacturing of printed circuit board. Materials that you use to make printed circuit boards come in various forms. You can buy either single- or double-sided copper clad. Unless you’re making a double-sided board, stick with single-sided clad. The board that you use to make your PCB...

>