PIC microcontroller pages


     It is, however, most vital for designers of embedded control products to select the most suitable controller and companion devices. Embedded control products are found in all market segments: consumer, commercial, PC peripherals, telecommunications (including personal telecom products), automotive and industrial. Most embedded control products must meet special requirements: cost effectiveness, low-power, small-footprint and a high level of system integration. Typically, most embedded control systems are designed around a MCU which integrates on-chip program memory, data memory (RAM) and various peripheral functions, such as timers and serial communication. In addition, these systems usually require complementary Serial EEPROM, display drivers, keypads or small displays. Microchip has established itself as a leading supplier of field-programmable embedded control solutions. The combination of high-performance MCUs from the PIC12CXXX, PIC16C5X, PIC16CXXX, PIC17CXXX and PIC18CXXX families, along with non-volatile memory products, provide the basis for this leadership. Microchip is committed to continuous innovation and improvement in design, manufacturing and technical support to provide the best possible embedded control solutions to you.

PICmicro MCU Overview and Roadmap
Microchip PICmicro MCUs combine high-performance, low-cost, and small package size, offering the best price/performance ratio in the industry. More than 120 million of these devices ship each year to cost-sensitive consumer products, computer peripherals, office automation, automotive control systems, security and telecommunication applications.
Microchip offers four families of 8-bit MCUs to best fit your needs: PIC16C5X 12-bit program word, PIC16CXXX 14-bit program word, PIC17CXXX 16-bit program word, PIC18CXXX enhanced 16-bit program word and PIC12CXXX 8-pin 12-bit/14-bit program word MCU families. All families offer OTP, low-voltage and low-power options, with a variety of package options. Selected members are available in ROM, EEPROM or reprogrammable Flash versions. The widely-accepted PIC16C5X, PIC16CXXX and PIC17CXXX MCU families employ a modified RISC architecture. Today, the industry’s first 8-pin MCU family – the PIC12CXXX, joins these families. The PIC12CXXX family combines the 8-bit high-speed RISC architecture of the PICmicro MCUs with the smallest footprint MCU. Microchip pioneered the use of RISC architecture to obtain high speed and instruction efficiency.

PIC12CXXX: 8-Pin, 8-Bit Family
The PIC12CXXX family packs Microchip’s powerful RISC-based PICmicro architecture into 8-pin DIP and SOIC packages. These PIC12CXXX products are available with either a 12-bit or 14-bit wide instruction set, a low operating voltage of 2.5V, small package footprints, interrupt handling and a deeper hardware stack. All of these features provide an intelligence level not previously available in applications because of cost or size considerations. PIC16C5X: 12-Bit Architecture Family
The PIC16C5X is the well-established base-line family that offers the most cost-effective solution. These PIC16C5X products have a 12-bit wide instruction set and are currently offered in 18-, 20- and 28-pin packages. In the SOIC and SSOP packaging options, these are among the smallest footprint MCUs. Low-voltage operation, down to 2.0V for OTPs, makes this family ideal for battery operated applications. Additionally, support is available for PIC16HV5XX that can operate directly from a battery at wide voltage ranges up to 15 volts. PIC16CXXX: 14-Bit Architecture Family
With the introduction of new PIC16CXXX family members, Microchip now provides the industry’s highest performance Analog-to-Digital Converter capability at 12-bits for an 8-bit MCU. The PIC16CXXX family offers a wide-range of options, from 18-pin to 68-pin packages as well as low to high levels of peripheral integration. This family has a 14-bit wide instruction set, interrupt handling capability and a deep, 8-level hardware stack. The PIC16CXXX family provides the performance and versatility to meet the more demanding requirements of today’s cost-sensitive marketplace for mid-range 8-bit applications. PIC17CXXX: 16-Bit Architecture Family
The PIC17CXXX family offers the world’s fastest execution performance of any 8-bit MCU family in the industry. The PIC17CXXX family extends the PICmicro MCU’s high-performance RISC architecture with a 16-bit instruction word, enhanced instruction set and powerful vectored interrupt handling capabilities. A powerful array of precise on-chip peripheral features provides the performance for the most demanding 8-bit applications. PIC18CXXX: 16-Bit Architecture Family
The PIC18CXX2 is a family of high performance, CMOS, fully static, 16-bit MCUs with integrated analog-to-digital (A/D) converter. All PIC18CXX2 MCUs employ an advanced RISC architecture. The PIC18CXXX has enhanced core features, 32 level-deep stack, and multiple internal and external interrupts sources. The separate instruction and data busses of the Harvard architecture allow a 16-bit wide instruction word with the separate 8-bit wide data. The two-stage instruction pipeline allows all instructions to execute in a single cycle, except for program branches, which require two cycles. A total of 68 instructions (reduced instruction set) are available. Additionally, a large register set gives some of the architectural innovations used to achieve a very high performance of 10MIPs for an 8-bit MCU. The PIC18CXXX family has special features to reduce external components, thus reducing cost, enhancing system reliability and reducing power consumption. These include programmable Low Voltage Detect (LVD) and Brown-Out Detect (BOR).
Microchip has innovative programming options for the embedded systems designer. These programming options address procurement issues by reducing and limiting work-in-process liability and facilitating finished goods code revisions. Microchip's worldwide distributors stock reprogrammable inventory, allowing customers to respond to immediate sales opportunities or accommodate engineering changes off the shelf. One-Time Programmable (OTP) PICmicro OTP MCUs are manufactured in high volumes without customer specific software and can be shipped immediately for custom programming. This is useful for customers who need rapid time to market and flexibility for frequent software updates. FLASH (electrically reprogrammable). PICmicro FLASH MCUs allow erase and reprogramming of the MCU program memory. Reprogrammability offers a highly flexible solution to today's ever-changing market demands – and can substantially reduce time to market. Users can program their systems very late in the manufacturing process or update systems in the field. This allows easy code revisions, system parameterization or customer-specific options with no scrappage. Reprogrammability also reduces the design verification cycle. In-Circuit Serial Programming (ICSP). Microchip's PICmicro MCUs feature ICSP capability. ICSP allows the MCU to be programmed after being placed in a circuit board, offering tremendous flexibility, reduced development time, increased manufacturing efficiency and improved time to market. This popular technology also enables reduced cost of field upgrades, system calibration during manufacturing, the addition of unique identification codes to the system and system calibration. Requiring only two I/O pins for most devices, Microchip offers the most non-intrusive programming in the industry. Self Programming. Microchip's PIC16F87X family features self programming capability. Self programming enables remote upgrades to the FLASH program memory and the end equipment through a variety of medium ranging from Internet and Modem to RF and Infrared. To setup for self programming, the designer programs a simple boot loader algorithm in a code protected area of the FLASH program memory. Through the selected medium, a secure command allows entry into the PIC16F87X MCU through the USART, I2C or SPI serial communication ports. The boot loader is then enabled to reprogram the PIC16F87X FLASH program memory with data received over the desired medium. And, of course, self programming is accomplished without the need for external components and without limitations on the PIC16F87X’s operating speed or voltage. Just think of the advantages that Microchip's self programming capability will provide your business. Quick-Turn Programming (QTP) Microchip offers a QTP programming service for factory production orders. This service is for users who choose not to program a medium to high quantity of units themselves and whose code patterns have stabilized. Serialized Quick-Turn Programming (SQTPSM) SQTP is a unique, flexible programming option that allows Microchip to program serialized, random or pseudo-random numbers into each device. Serial programming allows each device to have a unique number which can serve as an entry-code, password or ID number. Masked ROM Microchip offers Masked ROM versions of many of its most popular PICmicro MCUs, giving customers the lowest cost option for high volume products with stable firmware.


PIC16C84, PIC16F84
  •  Variables from 1 to 15 bits, packed in memory to save space
  •  Use of program EEPROM for long term storage of variables
  •  Arrays from 1 to 16 elements in RAM, or 1 to 1024 elements in EEPROM
  •  Handles strings as constants or constant arrays
  •  15 bit arithmetic capability, integers range from -16384 to +16383
  •  Full range of arithmetic functions including logical and bit operations
  •  Structured BASIC language including WHILE/WEND, FOR/NEXT, subroutines and user defined functions
  •  Supports use of interrupts
  •  Standard RS232 serial interface for programming and communications
  •  2kx8 or 8kx8 EEPROM
  •  9 lines of usable I/O
  •  24 bytes internal PIC RAM available for user variables and stack

The PIC16C84 is a relatively recent addition to Microchip Technology Incorporated's range of microcontrollers (for which they coined the name Peripheral Interface Controllers or PICs). The 16C84 is particularly interesting because its program memory is implemented in EEPROM technology. This gives the 16C84 a marked advantage over EPROM microcontrollers (even other PICs) during the prototyping stages of a project simply because it can be reprogrammed instantly (or nearly so - it takes about 20 seconds).
Microchip's PIC16C84 is a general-purpose, low-cost, 18pin, 8bit microcontroller with the capability of in-system software downloads to its on-chip EEPROM memory. For the shoe-string-budget developer, this makes for dramatically improved ease of use over the more conventional UVEPROM based microcontrollers where you're constantly wasting time pulling out the chip, erasing it, reprogramming it, and plugging it back in again. With the PIC16C84, you won't need that expensive programmer or pin adapter and you can have your code edited, re-assembled, downloaded and running again, all within a few seconds. What's more, MicroChip have made their excellent, PC hosted, MPASM assembler and all the hardware and software manuals (in PDF) you'll ever need available free over the internet. What you will need to do is build a very simple, low cost parallel port programming adapter to connect your PC to your target board, enabling the PC to re-program your PIC16C84 in-system. Microchip even publish a design for such an adapter in their AN589 application note, my contribution is to improve their hardware design, and produce a DOS based program to drive it. These tools, PROG84 hardware and PP84 software, are made freely available to the internet community via this page. There are several other sources for such stuff already on the web and there are a few pointers provided below, however I designed these tools specifically for:
  • DOS or DOS-box-under-windows operation
  • Minimum wear on EEprom cells
  • Fast turn-around time
  • Command-line driven, no on-line interaction
  • Compatibility with MPASM __CONFIG, __IDLOCS and DE statements
  • Reliable timing on all PCs from 286s to MegaMHz Pentiums

PP84 softwareThe operating software, PP84.EXE, runs on your PC under DOS (or in a dos box under windows). It reads an 8-bit (INHX8M) HEX file produced by MPASM and, via the PC's parallel port and programming adapter, re-programs all the PIC memory locations that need changing. A bulk erase is not performed unless the PIC to be programmed is code-protected. A memory location that already contains the correct data word is not programmed, empty memory locations are not programmed either. The short set-up and hold timing delays called for in the programming spec are timed using an oscillator built into the programming adapter, longer delays are timed by the PC with a software delay mechanism, calibrated at start-up against the real-time clock. In this way excessive over timing on delay loops due to a requirement to cope with a range of PC performances can be avoided. These measures all result in a fast time-to-program, secure timing margins and reduced wear on EEPROM cells. PP84 takes device config, ID information and EE data memory initialisation bytes directly from the HEX file in accordance with MPASM's specifications. In this way, all such control information can be contained, and documented, within the assembler source file and there are no interactive decisions to be made during the programming process. PP84 software will NOT work with AN589 hardware PROG84 hardwarePROG84 is the parallel port adapter hardware, it's a modification and extension to MicroChip's AN589 reference design. It is 100% compatible (and other software which works with AN589 hardware will work with PROG84 hardware) but includes a 555 oscillator, running at about 250KHz, which provides a system tick to the PP84 software from which it derives the short duration timing delays called for in Microchip's programming spec. It also includes its own 12V voltage regulator making it independent of the external power supply's regulation and a couple of status LEDs give visual confirmation of activity. Note that the BAT85 diode is a Schottky type and is used only to square up the waveform from the 555, use a 1N4148 if you can't source a BAT85. Also note that it sometimes _may_ be possible for the 12v Vpp voltage, applied to the CLR pin during programming, to source enough current into the 5v Vcc power supply rail (via the CLR pull-up resistor) to pull this rail above 5.5v and thus prevent the PIC from programming properly. This can be cured by including a series diode with the CLR pull-up resistor to prevent current flowing into the Vcc rail, see the sample target schematic below. IMPORTANT - The 1nF (or 1000pF) capacitor Cx between pins 5 and 12 of the PIC chip is essential and should be placed as close as possible to the chip it filters impulse noise from the clock line. Third party PCB artwork is available for the adapter, see below. I take no credit for these designs but also I take no blame. The adapter should also work with the 'F84 device although, due to one or two subtle differences, you may find that the code-protection feature does not work. However, a third party version of the sotware is now available specifically for the F84, see below. PP84 software detects the presence of PROG84 hardware by looking for the square wave clock signal from the 555 timer. It makes no attempt to measure the frequency of the clock, as this is not critical, but does measure the clock's mark-to-space ratio and tests for it being roughly 50:50. So if you have problems with PP84 not finding your PROG84 hardware you should first look to the 'squareness' of your clock waveform - it can often help to just lower the frequency a bit, to say 100KHz.If you have an IBM PC with a parallel printer port, then you can program PIC16C84 microcontrollers by building this simple circuit. 

The 16C84 can be programmed in a serial mode which requires very few connections between the chip and programmer. This is the approach adopted for this project (despite being connected to the PC via a parallel port, the PIC is actually programmed in serial mode).  Together with this text you should have received the file pp.asc, which is the schematic for the programmer. Although this circuit will do the job, you might like to modify it in various ways. For example:
I find it useful to use LEDs to show when VDD and Vpp are applied to the 16C84; the two unused sections of the 4066 can be used to isolate RB6 and RB7; the 4066 can be replaced by two transistors and a few resistors. Provided your circuit is compatible with the one shown in pp.asc, then the software provided should still work. The schematic specifies 13.8V for the programming voltage - I use a CB power supply - however, 12V should be fine, and in many PCs this  can be obtained from a spare floppy-disk power lead. The hardware can be attached to any available parallel port provided it is at one
of the standard port addresses.
For the serial port you can use the following circuit:

 

 

Download here the pcb, the pcb silk and the programmer software (PIP02).

 

 

What you need from MicroChip

Third party contributions Temperature Measurement Reference Material What else is out there

Google


[ About me | Acronyms  | CW | Data Sheets | Docs | Download | E-mail | HOME | Ham projects | Hobby circuits | Photo galery | PIC | QTH photos |
Sign in my guestbook | View my guestbook ]


© 2001 - YO5OFH, Csaba Gajdos