Introduction to PICAXE Programming and Projects in Software

Make Denso QR Bar Code in Software Introduction to PICAXE Programming and Projects

CHAPTER
QR Code 2d Barcode Reader In None
Using Barcode Control SDK for Software Control to generate, create, read, scan barcode image in Software applications.
QR Code 2d Barcode Generator In None
Using Barcode creation for Software Control to generate, create QR Code JIS X 0510 image in Software applications.
Introduction to PICAXE Programming and Projects
QR Code 2d Barcode Decoder In None
Using Barcode decoder for Software Control to read, scan read, scan image in Software applications.
Draw Quick Response Code In C#.NET
Using Barcode generation for .NET framework Control to generate, create QR Code ISO/IEC18004 image in .NET applications.
I HAVE NEVER BEEN A FAN of microcontroller project books that take three or four chapters to get to the first project, so we re going to tackle the handson part as soon as possible However, there are a few things about the PICAXE programming system that we need do to cover before we jump into our first project Essentially, the required information can be divided into four areas:
Paint QR Code In VS .NET
Using Barcode printer for ASP.NET Control to generate, create QR Code 2d barcode image in ASP.NET applications.
Make QR Code 2d Barcode In .NET Framework
Using Barcode printer for .NET Control to generate, create QR Code image in .NET framework applications.
I I I
Paint QR-Code In VB.NET
Using Barcode printer for .NET framework Control to generate, create Denso QR Bar Code image in .NET framework applications.
Printing USS Code 39 In None
Using Barcode printer for Software Control to generate, create Code 39 image in Software applications.
surprising amount of computing power in its little eight-pin package, which is shown in Figure 1-1 The 08M2 can operate with a power supply anywhere between +18V and +50V, so the simplest way to power it is to use a two- or threeAA cell battery pack, which is what we ll do in our first project
Data Matrix 2d Barcode Creation In None
Using Barcode creation for Software Control to generate, create Data Matrix 2d barcode image in Software applications.
Code 128C Printer In None
Using Barcode creator for Software Control to generate, create ANSI/AIM Code 128 image in Software applications.
Never use a four-cell battery pack Six volts can easily damage or destroy any PICAXE chip
Print Barcode In None
Using Barcode drawer for Software Control to generate, create barcode image in Software applications.
UPC-A Supplement 2 Encoder In None
Using Barcode maker for Software Control to generate, create Universal Product Code version A image in Software applications.
Choosing a PICAXE processor Interfacing a project with your Mac or PC Using RevEd s free Programming Editor or AXEpad software Programming in PICAXE BASIC
USS Code 93 Creation In None
Using Barcode creator for Software Control to generate, create USS Code 93 image in Software applications.
Code-39 Generation In Java
Using Barcode generator for BIRT Control to generate, create Code 39 Extended image in Eclipse BIRT applications.
CAUTION
Linear Creation In VB.NET
Using Barcode generation for .NET Control to generate, create 1D Barcode image in VS .NET applications.
Draw Code-39 In VS .NET
Using Barcode encoder for Reporting Service Control to generate, create Code 39 image in Reporting Service applications.
Choosing a PICAXE Processor
Generate Data Matrix 2d Barcode In Java
Using Barcode maker for Eclipse BIRT Control to generate, create Data Matrix 2d barcode image in BIRT reports applications.
Painting GTIN - 12 In VS .NET
Using Barcode generation for Reporting Service Control to generate, create UPC-A Supplement 2 image in Reporting Service applications.
For our first project, we want to get started as quickly as possible, so we re going to use the PICAXE-08M2 It s the smallest (and therefore the simplest) processor in the PICAXE lineup, but don t let that fool you the 08M2 packs a
USS Code 128 Creator In Objective-C
Using Barcode drawer for iPhone Control to generate, create Code 128 image in iPhone applications.
Make UPC-A Supplement 2 In None
Using Barcode maker for Font Control to generate, create UPC-A image in Font applications.
The power connections for the 08M2 are made to pins 1 (+V) and 8 (0V or Ground) The Serial In and Serial Out pins are used for downloading programs from your Mac or PC (We ll get to that shortly) Once a program is downloaded to the 08M2, the Serial Out pin can also function as an output for your program, and the Serial In pin can function as an input, which gives the 08M2 a total of six I/O pins: output C0, inputs C3 and C5, and I/O pins C1, C2, and C4 The different numbering of the I/O pins and external pins can be
Figure 1-1
PICAXE-08M2 pin-out
PICAXE Microcontroller Projects for the Evil Genius
a little confusing at first, but it s necessary because of the underlying structure of the Microchip PIC microprocessor on which the 08M2 is based As you can see in Figure 1-1, many of the 08M2 s I/O pins have multiple functions We ll get into the details as the need arises; right now, I just want to mention that the function listed closest to each pin is always that pin s default function In other words, when a chip is first powered up, each I/O pin is configured to implement the function that is adjacent to it, as shown in Figure 1-1 Any pin that can be either an input or an output always starts up as an input This is a safety precaution that prevents the activation of any peripheral devices until your program is properly configured If you have any previous experience with microcontrollers, you will notice the absence of dedicated crystal or resonator pins in Figure 1-1 Part of the simplicity of the 08M2 is its internal 4MHz resonator (which can also be switched to 8, 16, or 32MHz by your program) The internal resonator is not as accurate as the external one found on many of the larger PICAXE processors, but it s accurate enough for the vast majority of 08M2 projects If greater accuracy is needed, there s a BASIC command (calibfreq) that allows you to fine-tune the 08M2 s operating frequency Of course, you would need a frequency counter or oscilloscope to make the necessary adjustments
long before the serial port is totally obsolete Fortunately, the PICAXE programming interface is essentially the same for serial or USB connections Actually, there are two versions of the programming interface basic and enhanced both of which are presented in Figure 1-2 The basic version only includes the 10k and 22k resistors; the enhanced version adds two optional parts (the BAT85 diode and the 180 resistor) to improve the accuracy of the serial download circuit For USB connections, the 10k and 22k resistors are all that s required, but the enhanced circuit will also function correctly in this situation as well If you still use a serial connection to your computer, my recommendation would be to try the basic interface first If programs download reliably to your PICAXE processors, you re all set If a download occasionally fails, try including the 180 resistor and the BAT85 diode If you do include the diode, be sure to install it backwards, that is, with its anode (rather than its cathode) connected to Ground, as shown in Figure 1-2 If your computer only has USB ports, you will need a USB-to-serial adapter to program any PICAXE chip Before you run out and buy one, however, you need to know that most currently available adapters simply don t work with PICAXE processors Fortunately, RevEd produces the AXE027 USB programming cable, which is available at wwwsparkfuncom (SKU: PGM-08312) and elsewhere The AXE027 USB programming cable terminates in a 35-mm mini-stereo plug that provides the necessary serial in, serial out, and Ground connections for programming all PICAXE processors Unfortunately, a mini-stereo plug is obviously not what you would call breadboard-friendly Since most of the projects in this book will be implemented on breadboards, we re going to need a way to adapt the mini-stereo plug for breadboard use We will do exactly that in our Hello World! project later in this chapter
Copyright © OnBarcode.com . All rights reserved.