There are some things I don't understand about Klaus Leidingers code, so I
take a look at avrdude. How does avrdude write?

--- avrdude-5.0-BETA, butterfly.c -------------------------------

--- avrdude-5.0-BETA, butterfly.c -------------------------------

static int butterfly_paged_write(PROGRAMMER * pgm, AVRPART * p, AVRMEM * m,
                                 int page_size, int n_bytes)

blocksize: when writing to eeprom, blocksize is set to one byte, although 
           the programmer is able to handle larger blocks. For flash writes,
           the blocksize returned by the programmer is used. If the memory 
           to be written is larger than blocksize, several 'B' commands
           are used. 
           
'write program memory page' is not issued by avrdude! So Klaus Leidinger is 
right to do so after every 'B' command. It makes me think that I should
provide an internal buffer which is big enough to hold a whole page,
otherwise I'd flash every page more than once. 

Furthermore, avrdude doesn't adjust the size of a block transfer to the
pagesize of the device. It always uses the blocksize returned by the
programmer. Therefore the programmer itself needs to track pages.
