Rearrange the pinout for the programmer to be a little more logical.

Provide hooks to support a buffered programmer, pin 6 is now used to
enable a buffer that can be used to isolate the target system from the
parallel port pins.  This is important when programming the target
in-system.

Totally change the way the pin definitions are defined.  Actually
set/clear pins based on the way more intuitive pin number, instead of
PPI data register, bit number combination.  A table of pin data is
used so that any hardware inversion done by the parallel port is
accounted for, what you set is actually what appears at the pin.
Retain the old method for handling Vcc, however, because the hold
method is much easier to use when setting / retrieving multiple pins
simultaneously.


git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@49 81a1dc3b-b13d-400b-aceb-764788c761c2
This commit is contained in:
Brian S. Dean
2001-01-24 18:45:58 +00:00
parent 6593c1e534
commit fc56e6b4f9
5 changed files with 218 additions and 67 deletions

28
ppi.h
View File

@@ -41,21 +41,33 @@ enum {
PPISTATUS
};
int ppi_getops ( int reg, unsigned long * get, unsigned long * set );
int ppi_getops ( int reg, unsigned long * get, unsigned long * set );
int ppi_set ( int fd, int reg, int bit );
int ppi_set ( int fd, int reg, int bit );
int ppi_clr ( int fd, int reg, int bit );
int ppi_clr ( int fd, int reg, int bit );
int ppi_get ( int fd, int reg, int bit );
int ppi_get ( int fd, int reg, int bit );
int ppi_toggle ( int fd, int reg, int bit );
int ppi_toggle ( int fd, int reg, int bit );
int ppi_getall ( int fd, int reg );
int ppi_getall ( int fd, int reg );
int ppi_setall ( int fd, int reg, int val );
int ppi_setall ( int fd, int reg, int val );
int ppi_pulse ( int fd, int reg, int bit );
int ppi_pulse ( int fd, int reg, int bit );
int ppi_setpin ( int fd, int pin, int value );
int ppi_getpin ( int fd, int pin );
int ppi_pulsepin ( int fd, int pin );
int ppi_getpinmask ( int pin );
int ppi_getpinreg ( int pin );
int ppi_sense ( int fd );
#endif