Add n_boot_sections and boot_section_size to part definitions
This commit is contained in:
parent
883d9494c8
commit
9599bf2243
|
@ -70,6 +70,8 @@ Component_t avr_comp[] = {
|
||||||
part_comp_desc(mcuid, COMP_INT),
|
part_comp_desc(mcuid, COMP_INT),
|
||||||
part_comp_desc(n_interrupts, COMP_INT),
|
part_comp_desc(n_interrupts, COMP_INT),
|
||||||
part_comp_desc(n_page_erase, COMP_INT),
|
part_comp_desc(n_page_erase, COMP_INT),
|
||||||
|
part_comp_desc(n_boot_sections, COMP_INT),
|
||||||
|
part_comp_desc(boot_section_size, COMP_INT),
|
||||||
|
|
||||||
// AVRMEM
|
// AVRMEM
|
||||||
mem_comp_desc(n_word_writes, COMP_INT),
|
mem_comp_desc(n_word_writes, COMP_INT),
|
||||||
|
|
|
@ -615,7 +615,7 @@ static void dev_part_strct(const AVRPART *p, bool tsv, const AVRPART *base, bool
|
||||||
dev_print_comment(cp->comms);
|
dev_print_comment(cp->comms);
|
||||||
|
|
||||||
if(p->parent_id && *p->parent_id)
|
if(p->parent_id && *p->parent_id)
|
||||||
dev_info("part parent %s\n", p->parent_id);
|
dev_info("part parent \"%s\"\n", p->parent_id);
|
||||||
else
|
else
|
||||||
dev_info("part\n");
|
dev_info("part\n");
|
||||||
}
|
}
|
||||||
|
@ -627,6 +627,8 @@ static void dev_part_strct(const AVRPART *p, bool tsv, const AVRPART *base, bool
|
||||||
_if_partout(intcmp, "%d", mcuid);
|
_if_partout(intcmp, "%d", mcuid);
|
||||||
_if_partout(intcmp, "%d", n_interrupts);
|
_if_partout(intcmp, "%d", n_interrupts);
|
||||||
_if_partout(intcmp, "%d", n_page_erase);
|
_if_partout(intcmp, "%d", n_page_erase);
|
||||||
|
_if_partout(intcmp, "%d", n_boot_sections);
|
||||||
|
_if_partout(intcmp, "%d", boot_section_size);
|
||||||
_if_partout(intcmp, "%d", hvupdi_variant);
|
_if_partout(intcmp, "%d", hvupdi_variant);
|
||||||
_if_partout(intcmp, "0x%02x", stk500_devcode);
|
_if_partout(intcmp, "0x%02x", stk500_devcode);
|
||||||
_if_partout(intcmp, "0x%02x", avr910_devcode);
|
_if_partout(intcmp, "0x%02x", avr910_devcode);
|
||||||
|
|
|
@ -1866,6 +1866,8 @@ part
|
||||||
mcuid = <num>; # unique id in 0..2039 for 8-bit AVRs
|
mcuid = <num>; # unique id in 0..2039 for 8-bit AVRs
|
||||||
n_interrupts = <num>; # number of interrupts, used for vector bootloaders
|
n_interrupts = <num>; # number of interrupts, used for vector bootloaders
|
||||||
n_page_erase = <num>; # if set, number of pages erased during SPM erase
|
n_page_erase = <num>; # if set, number of pages erased during SPM erase
|
||||||
|
n_boot_sections = <num>; # Number of boot sections
|
||||||
|
boot_section_size = <num>; # Size of (smallest) boot section, if any
|
||||||
hvupdi_variant = <num> ; # numeric -1 (n/a) or 0..2
|
hvupdi_variant = <num> ; # numeric -1 (n/a) or 0..2
|
||||||
devicecode = <num> ; # deprecated, use stk500_devcode
|
devicecode = <num> ; # deprecated, use stk500_devcode
|
||||||
stk500_devcode = <num> ; # numeric
|
stk500_devcode = <num> ; # numeric
|
||||||
|
|
|
@ -121,7 +121,9 @@ SIGN [+-]
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
prog_modes|mcuid|n_interrupts|n_page_erase|n_word_writes { /* Components for assignment */
|
(?x: prog_modes | mcuid | n_interrupts | n_page_erase | n_word_writes | n_boot_sections |
|
||||||
|
boot_section_size ) { /* Components for assignment */
|
||||||
|
|
||||||
Component_t *cp = cfg_comp_search(yytext, current_strct);
|
Component_t *cp = cfg_comp_search(yytext, current_strct);
|
||||||
if(!cp) {
|
if(!cp) {
|
||||||
yyerror("Unknown component %s in %s", yytext, cfg_strct_name(current_strct));
|
yyerror("Unknown component %s in %s", yytext, cfg_strct_name(current_strct));
|
||||||
|
|
|
@ -237,6 +237,8 @@ typedef struct avrpart {
|
||||||
int mcuid; /* Unique id in 0..2039 for urclock programmer */
|
int mcuid; /* Unique id in 0..2039 for urclock programmer */
|
||||||
int n_interrupts; /* Number of interrupts, used for vector bootloaders */
|
int n_interrupts; /* Number of interrupts, used for vector bootloaders */
|
||||||
int n_page_erase; /* If set, number of pages erased during NVM erase */
|
int n_page_erase; /* If set, number of pages erased during NVM erase */
|
||||||
|
int n_boot_sections; /* Number of boot sections */
|
||||||
|
int boot_section_size; /* Size of (smallest) boot section, if any */
|
||||||
int hvupdi_variant; /* HV pulse on UPDI pin, no pin or RESET pin */
|
int hvupdi_variant; /* HV pulse on UPDI pin, no pin or RESET pin */
|
||||||
int stk500_devcode; /* stk500 device code */
|
int stk500_devcode; /* stk500 device code */
|
||||||
int avr910_devcode; /* avr910 device code */
|
int avr910_devcode; /* avr910 device code */
|
||||||
|
|
Loading…
Reference in New Issue