Best Microcontroller Projects


The easiest way to learn PIC Interrupts with Full C Examples Included
For both 16F and 18F series devices...

PIC Interrupt Secrets:


PIC Interrupt Secrets EBook All About PIC Interrupts:

* A useful reference to quickly get your PIC interrupts going.

* Shows you how how they work and why they make your code more reliable.

* Full C code examples all fully debugged and ready to go.

This ebook shows you exactly how to use interrupts for any PIC micro.

And it gives you the knowledge to apply interrupts to any hardware and any situation (it's useful for non PIC devices because the methods discussed are generic).

Also included are typical Traps that you should avoid when using interrupt code and many other practical information tips to make effective use of interrupts.

Click the Button to Buy Now
only $9.95:

While I was creating the c code examples for the 18F series devices I got fed up looking through the data sheet and instead used the ebook - and it turns out that it gives you a quick easy guide pointing you in the right direction to use the interrupts.  

Sometimes when looking through a data sheet the information is all over the place whereas the ebook has everything arranged ordered in easy to navigate chapters so you won't waste time looking for information.


The ebook also comes with a zip file containig Pre compiled hex files for each example along with full project files for MikroC which have been fully debugged on hardware so they are guaranteed to work.

The ebook includes:
  • 8 Fully debugged interrupt examples.
  • Interrupt Code templates for starting interrupts FAST.
  • How to change an 18F interrupt priority (low to high & vice versa.).
  • much more (see the table of contents and 

Table of Contents

1 Other Resources    
1.1 PIC C Course    
1.2 Learn To Use state Machines To Maximum Effect.    
2 Legal    
3 Introduction
3.1 From Polling To Interrupts    
3.2 Real Time Events    
3.3 Achieving More Using Interrupts    
3.4 Why Interrupts are Essential for Critical Inputs    
3.5 Power Saving
4 Interrupts    
4.1 The Interrupt Module    
4.2 Polling disadvantages     
4.3 The Power of Interrupts    
4.4 How Does An Interrupt Affect The Main Code?
4.5 How to Ensure Interrupts and Main code Work    
4.6 Avoiding Accidental Code Increase In the ISR
4.6.1 Data Types    
4.6.2 Hidden Library Code    
5 How Interrupts Work    
5.1 Instruction cycle
6 Interrupt Service Routine (ISR)    
6.1 ISR : Interrupt Service Routine    
6.2 Interrupt Vector
6.3 Interrupt Code    
6.4 Context Switching    
6.4.1 Saving The Current State    
6.4.2 Saving the Program Counter    
6.4.3 Bank Context Saving    
7 Coding PIC Interrupts    
7.1 PIC Interrupt Registers    
7.2 PIR Peripheral Interrupt Register State (Flag)    
7.3 Peripheral Interrupt Enable PIE (Enable)
7.3.1 Interrupt Masks    
7.4 INTCON – Original Interrupt Control Register
7.5 Global And Peripheral Interrupt Enable    
7.5.1 GIE    
7.5.2 PEIE    
7.6 Using the Interrupt Flag Registers    
7.7 Interrupt Flow Diagram    
7.8 Interrupt Design Decisions    
7.8.1 Processing / Interrupt Time Analysis    
7.8.2 Three Interrupt Design Solutions     
7.8.3 Effect of using a 20MHz clock    
8 Design techniques    
8.1 Using FLAGS to communicate from ISR to main Program     
8.2 'Interrupt Cascade'®    
8.3 Measuring the ISR time    
8.3.1 Direct Pin Monitoring    
8.3.2 Simulating Interrupts    
8.3.2.1 Using #define Macros
8.3.3 Using A Timer    
8.3.3.1 Viewing the Timer Value    
9 An Error You Must Avoid    
10 18F Series Interrupts    
10.1 High or Low Priority Interrupts: Reason for Usage
10.2 Hardware for Prioritized Interrupts    
10.3 Prioritized Interrupt Mechanism    
10.4 Priority Enable Control Bit (backwards compatibility)
10.5 18F Series Registers    
10.6 18F Context Saving    
10.6.1 Fast Register Stack    
10.6.1.1 Using the Fast Register Stack for normal function calls    
11 Examples    
11.1 Hardware & Software
11.1.1 Hardware    
11.1.2 Serial port configuration    
11.1.3 16F88 Hardware Diagram    
11.1.4 18F2550 Hardware Diagram    
11.1.5 Software Downloads    
11.1.5.1 C Compiler download    
11.1.5.2 ICPROG    
11.1.5.3 WinPic (for the 18F2550 and many others)    
11.2 Interrupt Template    
11.2.1 Interrupt Template Code Action
11.2.2 Interrupt Template C Code    
11.3 16F Heartbeat Timer    
11.3.1 16F Heartbeat Timer Code Action    
11.3.2 16F Heart Beat Timer C Code    
11.4 Transmit Interrupts (no code but some important information).
11.5 RS232 Interrupt Reception    
11.5.1 16F RS232 Interrupt Reception Code Action    
11.5.2 16F RS232 Interrupt Reception C Code    
11.6 Simple Flag Example    
11.6.1 16F Simple Flag Interrupt Code Action    
11.6.2 16F Simple Flag Interrupt C Code    
11.7 Interrupt Simulation using Macros    
11.7.1 16F Interrupt Simulation Code Action    
11.7.2 16F Interrupt Simulation C Code
11.8 18F Interrupt Driven Blinking LED Example
11.8.1 18F Interrupt Driven Blinking LED Code Action    
11.8.2 18F Interrupt Driven Blinking LED C Code    
11.9 18F Prioritized Interrupt Example    
11.9.1 18F Prioritized Interrupt Code Action    
11.9.2 Priority Effect on LED at PORTB
11.9.3 18F Changing the interrupt priority    
11.9.4 18FPrioritized Interrupt C Code    
12 Highlights     

Highlights

The one thing you MUST NEVER DO when using interrupts;
Chapter 4.4 Page 14
.

Why interrupts allow you to achieve FAR MORE than using processor code alone; Chapter 3.3 Page 10.

Don't get caught out by this simple interrupt coding error (if you want Interrupts to work correctly and consistently!); Chapter 4.6.1 Page 16.

A simple way to REDUCE your interrupt code size (and NO its not calling a function from within the Interrupt code itself); Chapter 8.1 Page 30.

Use THREE FACTORS that affect Interrupt Code Performance to improve your system; Chapter 7.8 Page 27.

Why interrupts STILL WORK even if your code has CRASHED
Chapter 3.4 Page 11.

A simple INTERRUPT SIMULATION technique (you can't do it without this technique); Chapter 8.3.2 Page 33.

The one thing that Interrupts ALLOW but polling never can;
Chapter 3.5 Page 11
.

How to avoid ACCIDENTALLY making the interrupt routine too large; Chapter 4.6.1 Page 16.

Why interrupts make your programs SIMPLER; Chapter 4.3 Page 13.

An ESSENTIAL TECHNIQUE for using interrupts in critical code to avoid system disaster; Chapter 3.4 Page 10.

Why you WON'T FIND the “interrupt module” on the hardware diagram; Chapter 4.1 Page 12.

Why interrupts are so ELEGANT and polling is a bad idea; 
Chapter 4.2 Page 12.

How interrupts make multitasking possible; Chapter 3 Page 8.

Why interrupt code must be different to 'normal' code; Chapter 6.3 Page 19.

How interrupts fit into the “Normal Processor Instruction CycleChapter 4.1 Page 12.

Interrupt Cascade !?!; Chapter 8.2 Page 31.

THREE full C Code examples; Chapter 10 Page 38.

FULL C Code Template for easy coding of your C interrupts;
Chapter 10.2 Page 40
.

THREE different ways to measure an interrupt execution time; 
Chapter 8.3 Page 33.

Why using interrupts for timing purposes is BETTER than using built in delay routines; Chapter 10.3 Page 43.

Find out the one big error that is so easy to make and very subtle to find and sort out; Chapter 9 Page 36.

Why using RS232 Transmit Interrupts is easier than simply writing data to the RS232 transmit hardware; Chapter 10.4 Page 48.


BUY Now at the Incredibly Low Price of $9.95

Click Here:

P.S. This will be going up Very Soon so get it now while it is still a spectacular BARGAIN.

Jump from Interrupt Sales Page to
Best-Microcontroller-Projects Home Page



Don't forget to Sign Up for your

Microcontroller Newsletter

With "Essential tips and techniques",

..."New Site Info" and more...

Including a free project :

How to drive an LCD and 12key keypad using "Only One 8 Bit Port" with no interface logic!...

(Works for any microcontroller)

This costs you : Nothing...
Just fill out the form below and you'll get full C source code and project schematic and description.



Email

Name

Then

Don't worry -- your e-mail address is totally secure.
I promise to use it only to send you MicroZine.
Google
 
  Best Microcontroller projects.