| You are in home \ microcontroller \ PicAxe \ Picaxe-08 Ports (back) |
|
Hardware
| |
| Bit_Pin | Leg | I/P | O/P | Notes | |
| 0 | 7 | - | CMOS | O/P only. Shared with programming cable. | |
| 1 | 6 | TTL / ADC | CMOS | Low-res ADC, used with readadc command. |
|
| 2 | 5 | SCHMITT | CMOS | GPIO | |
| 3 | 4 | TTL | - | Input only, requires diode to +V for serin use |
|
| 4 | 3 | TTL | CMOS | GPIO | |
| GPIO = General Purpose I/O (Bit-pins 1, 2 & 4) | |||||
![]() |
Power Supply Pins. +V (Physical Leg 1) and Ground (Physical Leg 8).
A wide supply voltage range is possible (2 V min. to 5.5 V max.) and excessive voltage is liable to damage the chip and should be protected against if the supply voltage isn't otherwise controlled. Insufficient supply voltage (ie. below 2 V) will result in unreliable operation (as well as reduced output drive capacity and altered input voltage trip-points). Providing protection from polarity reversal of supply should be considered and may be accomplished in several ways (eg reverse polarity protection diode, biased FET, fuse and shorting diode, zener limiter...). Supply decoupling odf at least one 0.1uF ceramic capacitor is highly recommended and the addition of a small electrolytic capacitor should be considered in some cases.
Several issues and solutions will be dealt with on the Power Supply page. |
![]() |
Serial-In (Physical Leg 2) for programming use only. This pin requires a pulldown for the PicAxe to operate. A positive edge on this pin will trigger the internal bootloader to download a new program into memory. The required pulldown is built in to the serial download interface circuit, so this can be used, allowing for later program updates as required.
Serial-Out (Physical Leg 7) is used by the programming cable when downloading programs, and can also be used as a digital Output Pin (known then as Port-Pin 0). See the description of Port-Pin 0 for considerations when using it for digital output.
downloadingto provide a |
![]() |
Output Port-Pin 0 (Physical Leg 7) is an Output only pin.
Although this pin is available for general purpose output, the fact that it shares its function with the programming cable means that consideration must be made that there is no interference between this function and usage as a digital output in the user circuit. (Often) this pin shgould be jumpered (or switched) to separate these functions, unless the circuitry is designed so that they don't interfere with each other.
|
![]() |
Input & Output Port-Pin 1 / Analog Input (Physical Leg 6)
This pin can function as an input or an output as desired, and also includes a Low-resolution Analog-to-Digital Converter function. Being a low-resolution ADC (Analog to Digital Converter) means it reads values in only the lower two-thirds of the input voltage range, and these values have been scaled up to 16 larger steps to match the scale of the full ADC's.
|
![]() |
Input & Output Port-Pin 2 (Physical Leg 5) This pin can function as an Input or an Output as desired. Input is by a Schmitt trigger buffer, which can make it a bit more versatile. I'll provide an interface circuit or two that takes advantage of the Schmitt trigger input specifically in the Interface section later. |
![]() |
Input Port-Pin 3 (Physical Leg 4) is an input only port.
You can use it for normal digital input like the other ports, but if you intend to use it for |
![]() |
Input & Output Port-Pin 4 (Physical Leg 3) This is a General Purpose port that can function as an Input or an Output as desired. |
low <port-pin> or high <port-pin> command on the appropriate pin(s) at initialisation. This will be dealt with more fully under the I/O in the Programming section.
Ensure that any output pins do not clash with other voltage levels or outputs, or a situation known as contention will occur, leading to excessive current flow and chip damage. Contentions can be tolerated if a current limiting resistor is provided in series with the pin(s) in question with a suitable value to limit the current below the absolute maximum of 25mA (eg. 220 Ohm).
Be careful when switching Capacitive or Inductive loads that discharge current (Charge dumping) or back EMF (spikes) are protected against.
Capacitive loads should have a current limiting resistor as protection, and Inductive loads should have a freewheeling diode fitted, and motors require a spike suppression capacitor (eg. 220nF) fitted across their terminals.
Also piezo's or speakers can produce voltages when stressed or knocked that can be damaging to your chip, so these must be adequately protected against. Note that although inductive loads will generally be driven via. a driver transistor, the protection measures are still required to protect the driver transistor and to prevent spikes being passed back through the supply lines to other equipment
I will cover these issues and various solutions on the other hardware pages.
Abs. max. Vsupply is 6.5 V
Abs. max. voltage on port-pin 3 (phys. leg 4) is 13.5 V.
Voltages on all other pins must not be more than 0.3 V below 0V or more than 0.3 V above +V.
Abs. Max. current out of 0V pin is 300 mA.
Abs. Max. current into +V pin is 250 mA.
Abs. Max. clamp current (i/p or o/p) with Vin < 0V or > +V) is 20 mA.
Abs. Max. current (sunk or sourced) by any I/O pin is 25 mA.
Abs. Max. current to be sourced or sunk by all I/O pins is 125 mA.