Using PicBasic with the PIC16F84 PIC Microcontroller
Description: This project uses only a few of the instructions that come with PicBasic, but serves to show how easy PicBasic really is. It also shows how PicBasic strongly resembles programming the BASIC Stamp. Here we are using the serin command, and a couple if then statements to design a simple serially controlled I/O-expander that can be used to increase the I/O capabilities of other PIC microcontrollers or the BASIC Stamp. One feature that PicBasic offers with the serin command is the ability to use a qualifier.
The project described focuses on utilizing the PicBasic programming language to create a serially controlled I/O expander. The I/O expander serves to enhance the input/output capabilities of microcontrollers, specifically those from the PIC family or the BASIC Stamp. The serin command is employed to facilitate serial communication, allowing for the reception of data from a controlling device.
The circuit typically consists of a PIC microcontroller configured to operate in conjunction with additional I/O pins. The I/O expander can be implemented using a shift register or a dedicated I/O expander IC, which receives serial data and translates it into multiple parallel outputs. This is particularly useful in applications where the number of available I/O pins on the primary microcontroller is limited.
In the implementation, the serin command is utilized to read incoming data. The qualifier feature of the serin command allows for more robust data handling by enabling specific conditions to be set for the incoming serial data. This can include checking for specific start bits or ensuring that data is received in the expected format, thereby enhancing reliability.
The overall design includes pull-up resistors on the input lines to ensure stable logic levels, and decoupling capacitors are placed close to the power pins of the microcontroller to filter out noise. The schematic will typically showcase connections between the microcontroller's serial output pin and the data input of the I/O expander, along with connections for power and ground.
This project exemplifies the ease of programming with PicBasic while demonstrating practical applications for expanding I/O capabilities in embedded systems. The simplicity of using if-then statements in conjunction with the serin command allows for straightforward control logic, making it accessible for both novice and experienced developers.This project uses only a few of the instructions that come with PicBasic, but serves to show how easy PicBasic really is. It also shows how PicBasic strongly resembles programming the BASIC Stamp. Here we are using the serin command, and a couple if then statements to design a simple serially controlled I/O-expander that can be used to increase the I/O capabilities of other PIC microcontrollers or the BASIC Stamp.
One feature that PicBasic offers with the serin command is the ability to use a qualifier.
The idea behind this project is to provide some means of loading a program into a PIC that will then be able to program other PICs in a more conventional way. How do you program a PIC to be a...
How can graphical LCDs be controlled using a microcontroller? Is there any datasheet available?
Graphical LCDs (Liquid Crystal Displays) are widely used in various electronic applications for displaying complex graphics and text. To control these displays with a microcontroller, several steps...
Standard serial interfacing of a microcontroller (TTL) with a PC or any RS232C standard device requires a TTL to RS232 level converter. A MAX232 is used for this purpose. It provides a 2-channel RS232C port and requires external 10µF capacitors.
The...
A light computer has been developed that simulates the scanning effect seen in the KITT car from the TV series Knight Rider. The design utilizes a microcontroller, specifically the PIC16F84A, instead of the commonly used CD4017 counter IC. This choice...
This is the lowest cost dialing alarm on the market and shows what can be done with an 8-pin microcontroller. The complete circuit is shown below. You cannot see all the features of this project by looking at the circuit...
A small biped walker constructed from 2mm plywood, powered by two RC servos. It utilizes the widely available and programmable flash microcontroller PIC16F84. This simple circuit is designed to program the PIC16F84 and similar flash memory components. The project includes...
A method for measuring static electricity for a science project was sought. An old copy of "Getting Started in Electronics" by Forrest M. Mims III was referenced for guidance.
To create a static electricity measurement circuit, a simple design can be...
A soft power switch for a microcontroller is designed such that a momentary switch can activate the circuit, including the microcontroller. When the switch is pressed a second time, the microcontroller is capable of shutting itself down after executing necessary...
The F84 MRTC was my second design of a miniature real-time controller. This version uses PIC16F84 running with a low power X-tal 32,768Hz. The scheduler for 6-channel output was saved in EEPROM. No terminal for serial downloading of the scheduler....
We use cookies to enhance your experience, analyze traffic, and (if you allow) serve personalized ads.
By clicking Accept All, you agree to our use of cookies.
Learn more