avr-libc-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [avr-libc-dev] Re: avr-libc-dev archives


From: Volkmar Dierkes
Subject: Re: [avr-libc-dev] Re: avr-libc-dev archives
Date: Mon, 23 Dec 2002 00:45:32 +0100
User-agent: 40tude_Dialog/2.0.3.1 Hamster/1.3.23.205

On Tue, 17 Dec 2002 15:57:16 -0700, E. Weddington wrote:

> What I'm proposing is a *low-level* API that right now a user has to 
> write themselves, more of a boot loader *support* API:
>
> boot_page_fill(address, data) // Fill the temporary page write buffer
> boot_page_erase(address)      // Erase page
> boot_page_write(address)              // Write page
> boot_mem_read(address)                // Read memory byte
> boot_rww_enable()                     // Enable RWW section
> boot_lock_bits_set(__lock_bits) // Set lock bits
> boot_spm_interrupt_enable()   // Enable SPM interrupt
> boot_spm_interrupt_disable()  // Disable SPM interrupt
> is_boot_spm_interrupt()               // Check if SPM interrupt enabled
> boot_rww_busy()                               // Check if RWW section is busy
> boot_spm_busy()                               // Check if SPM is busy
> boot_spm_busy_wait()          // Wait while SPM is busy
>
>
> This doesn't provide a whole bootloader; that is up to the programmer 
> to write. But it does provide the *tools* for a programmer to write 
> one. This API pretty much corresponds to the Boot Loader Support 
> section in all the AVR data sheets. Right now avrlibc does not 
> provide any such functions.

I agree with your proposal. I think I got a copy of your avr-boot.h 
in an indirect way ;-) I found a small bug because your are testing 
it on a mega128 and at the moment I try to get it working with a 
mega8.

Look in __boot_mem_read_normal__, change
            : "=r" ((unsigned char)__result),  \
into
            : "=r" ((unsigned char)__result)   \

I deleted the comma at the end.

But I have also a question. There are some differences in the 
mega's: Especially the pagesize is different. Is there a possibility 
to include such things in the iomxxx.h (or whereever)?

Volkmar



reply via email to

[Prev in Thread] Current Thread [Next in Thread]