Add 'serial' and 'parallel' keywords to the grammar so that one can

say whether parts support these programming modes or not.  Possible
values for 'serial' are 'yes' or 'no'.  Possible values for 'parallel'
are 'yes', 'no', or 'pseudo'.  Add a bit mask of flags to the AVRPART
structure to capture these settings.  Use these within
stk500_initialize() to set the device parameters correctly.

Defaults for 'serial' and 'parallel' are 'yes' unless specified
otherwise.


git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk@208 81a1dc3b-b13d-400b-aceb-764788c761c2
This commit is contained in:
Brian S. Dean
2003-02-20 19:46:23 +00:00
parent 099dc2248d
commit 5a2d120ec2
6 changed files with 70 additions and 9 deletions

View File

@@ -58,6 +58,7 @@ AVRPART * avr_new_part(void)
p->id[0] = 0;
p->desc[0] = 0;
p->reset_disposition = RESET_DEDICATED;
p->flags = AVRPART_SERIALOK | AVRPART_PARALLELOK;
p->mem = lcreat(NULL, 0);
@@ -1073,17 +1074,22 @@ void avr_display(FILE * f, AVRPART * p, char * prefix, int verbose)
AVRMEM * m;
fprintf(f,
"%sAVR Part : %s\n"
"%sChip Erase delay : %d us\n"
"%sPAGEL : P%02X\n"
"%sBS2 : P%02X\n"
"%sRESET disposition : %s\n"
"%sMemory Detail :\n\n",
"%sAVR Part : %s\n"
"%sChip Erase delay : %d us\n"
"%sPAGEL : P%02X\n"
"%sBS2 : P%02X\n"
"%sRESET disposition : %s\n"
"%sserial program mode : %s\n"
"%sparallel program mode : %s\n"
"%sMemory Detail :\n\n",
prefix, p->desc,
prefix, p->chip_erase_delay,
prefix, p->pagel,
prefix, p->bs2,
prefix, reset_disp_str(p->reset_disposition),
prefix, (p->flags & AVRPART_SERIALOK) ? "yes" : "no",
prefix, (p->flags & AVRPART_PARALLELOK) ?
((p->flags & AVRPART_PSEUDOPARALLEL) ? "psuedo" : "yes") : "no",
prefix);
px = prefix;