PIC16F877 timer0 code and Proteus simulation

This PIC16F877 microcontroller tutorial answers the question, " How to use timer0 of PIC16F877 and how to handle its interrupts? " Using PIC16 simulator (Proteus) you can verify this PIC timer0 code and change it according to your needs. This code is written in C language using MPLAB with HI-TECH C compiler. You can download this code from the 'Downloads' section at the bottom of this page. It is assumed th ...

Read more

New Earth Time (NET) digital clock in recycled retro-modern case using PIC16F627A

Ever get confused by GMT, or just wish you had a cooler way to keep track of time?  Build a New Earth Time clock!  Using a PIC microcontroller, some code, and a couple discrete parts, you too can have a unique timekeeping device to keep on your desk. New Earth Time (NET) is an idea for a global time standard.  Like Greenwich Mean Time (GMT), it is the same "New Earth Time" everywhere on the globe at any ins ...

Read more

00 to 99 minute timer using PIC16F628A microcontroller

Last week I was browsing my old backup hard drive and I found a source code for a very simple PIC based digital timer that I made a couple of years ago. The actual hardware of the project isn’t with me anymore. I might have lost it when I moved from my old apartment into my new home. However, I thought this might be a good practice project for beginners and so I am sharing it here. I am not going to build i ...

Read more

2 Digit Counter using PIC12F629 Microcontroller

This article describes a 2-Digit Counter using a Microchip PIC12F629. It shows what can be done with an 8-pin chip having just 5 output lines and one input line. The chip drives two7-segment displays and this would normally require 7 lines to drive the segments plus another one or two lines to select the displays. We have shown how a single line can be used to drive two different segments by using the tri-s ...

Read more

Digital Clock using PIC Microcontroller and DS1307 RTC

A Digital Clock can be made easily by using PIC Microcontroller, DS1307 and a 16×2 LCD. I have already posted about Interfacing DS1307 RTC with PIC Microcontroller. The DS1307 RTC can work either in 24-hour mode or 12-hour mode with AM/PM indicator. It automatically adjusts for months fewer than 31 days including leap year compensation up to year 2100.  DS1307 comes with built-in power sensing circuit which ...

Read more

Mars Clock using PIC16F877A microcontroller

What do you do if you have a spare LCD module with backlight, a weird 16 button keyboard, and a PIC16F877A microcontroller gathering dust? A monster Martian Clock immediately springs to mind. You are probably thinking "There are hundreds of PIC clocks on the Net - do we need yet another one?!" Well, this one is a bit different: It has 16 timers that can be independently paused and restarted, and can run for ...

Read more

Interfacing Real Time Clock (RTC) DS1307 with PIC Microcontroller

DS1307 is a low power serial real time clock with full binary coded decimal (BCD) clock/calendar plus 56 bytes of NV SRAM (Non Volatile Static Random Access Memory). Data and Address are transferred serially through a bidirectional I2C bus. The RTC provides year, month, date, hour, minute and second information. The end date of months is automatically adjusted for months fewer than 31 days including leap ye ...

Read more

Programmable relay switch using PIC MCU (revised version)

Programmable relays are key elements in numerous automation applications such as automatic street light control, watering and pump control, HVAC, home automation, power plants automation in industries, etc. This article describes a DIY programmable relay switch using PIC16F1847 (PIC16F628A can also be used) microcontroller. It is a revised version of my previous PIC-based relay timer project with added feat ...

Read more

Understanding Timers in PIC Microcontroller with LED Blinking Sequence

This will be the fifth tutorial in our PIC Tutorial Series, which will help you to learn and use Timers in PIC16F877A. In our previous tutorials, we had started with Introduction to PIC and MPLABX IDE, then we wrote our first PIC program to blink the LED using PIC and then made a LED Blinking Sequence by using delay function in PIC Microcontroller. Now let us use the same LED Blinking sequence which we have ...

Read more

DIY Digital Clock with Temperature Display using PIC Controller

One of the most enjoyable part of being an electronics person is creating your own gadgets and using them in daily life. In this article, we are building one of those with the help of SoloPCB design tools, a digital desk clock with temperature display feature. The brain of the circuit is a Microchip PIC18F252 microcontroller. It acquires precise time information from DS1307 real time clock via I2C interface ...

Read more
Scroll to top