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

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

RE: [avr-libc-dev] Regarding power reduction registers in At90pwm81


From: Boyapati, Anitha
Subject: RE: [avr-libc-dev] Regarding power reduction registers in At90pwm81
Date: Mon, 27 Dec 2010 12:41:55 +0800


>-----Original Message-----
>From: address@hidden
>[mailto:address@hidden On
>Behalf Of Weddington, Eric
>Sent: Friday, December 24, 2010 10:29 AM
>To: Kaushik, Praveen_Kumar; address@hidden
>Subject: RE: [avr-libc-dev] Regarding power reduction registers in
>At90pwm81
>
>Hi Praveen,
>
>The XML files come with AVR Studio 5, not WinAVR.

Assuming that Praveen could have meant AVR Studio 4 (since studio 5 was not out 
and WinAVR never distributes device xml files), I took a look at io90pwm81.h 
header file present in avr-libc repository.

When generated with AT90PWM81.xml file distributed with AVR Studio 4, the 
resulting header file differs with the one present in avr-libc repository which 
was added long ago.

So, it is possible that AT90PWM81 XML file must have got changed (in one of 
those part pack releases) after adding the io90pwm81.h to avr-libc repository.

>
>The header file is supposed to match the XML file, not necessarily the
>datasheet. If the header file does not match the XML file, then please file
>a bug report at the avr-libc project.


I think this is a header file bug (worth quick fix). PRPSC0 has been used in 
header file while PRPSCR has been used in AT90PWM81.xml


Also, correct me if I am wrong, corresponding entry in power.h needs to be 
changed.

#elif defined(__AVR_AT90PWM81__)

...

/* Power Stage Controller 0 */
#define power_psc0_enable()     (PRR &= (uint8_t)~(1 << PRPSC0))
#define power_psc0_disable()    (PRR |= (uint8_t)(1 << PRPSC0))

/* Power Stage Controller 2 */
#define power_psc2_enable()     (PRR &= (uint8_t)~(1 << PRPSC2))
#define power_psc2_disable()    (PRR |= (uint8_t)(1 << PRPSC2))
...

There is no Power Stage Controller 0 in AT90PWM81.


Anitha

>
>> -----Original Message-----
>> From: address@hidden
>> [mailto:address@hidden On
>> Behalf Of Kaushik, Praveen_Kumar
>> Sent: Thursday, December 23, 2010 12:01 AM
>> To: address@hidden
>> Subject: [avr-libc-dev] Regarding power reduction registers in At90pwm81
>>
>> Hi,
>>
>>    In <avr-libc>/include/avr/power.h, under AT90PWM81, macro PRPSC0 is
>> used but the datasheet specifies this as PRPSCR.
>>
>> The XML file that came with WinAVR-2010 release also specifies this as
>> PRPSCR. Is there any particular reason for this or the header file is not
>> updated while the XML file has been upgraded?
>>
>>
>>
>> The datasheet can be found at:
>>
>> http://www.atmel.com/dyn/resources/prod_documents/doc77340.pdf
>>
>>
>>
>> Regards,
>>
>> Praveen Kaushik
>>
>> _______________________________________________
>> AVR-libc-dev mailing list
>> address@hidden
>> http://lists.nongnu.org/mailman/listinfo/avr-libc-dev
>
>_______________________________________________
>AVR-libc-dev mailing list
>address@hidden
>http://lists.nongnu.org/mailman/listinfo/avr-libc-dev



reply via email to

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