mirror of
https://github.com/FreeRTOS/FreeRTOS-Kernel.git
synced 2025-09-12 00:57:44 -04:00
ATmegaxxxx - discern architecture rather than device
This commit is contained in:
parent
5e32393035
commit
c19e711ba5
2 changed files with 6 additions and 6 deletions
|
@ -222,7 +222,7 @@ void wdt_interrupt_reset_enable (const uint8_t value)
|
||||||
*
|
*
|
||||||
* r0 is set to __tmp_reg__ as the compiler expects it to be thus.
|
* r0 is set to __tmp_reg__ as the compiler expects it to be thus.
|
||||||
*
|
*
|
||||||
* #if defined(__AVR_ATmega2560__) || defined(__AVR_ATmega2561__)
|
* #if defined(__AVR_3_BYTE_PC__)
|
||||||
* #define __RAMPZ__ 0x3B
|
* #define __RAMPZ__ 0x3B
|
||||||
* #define __EIND__ 0x3C
|
* #define __EIND__ 0x3C
|
||||||
* #endif
|
* #endif
|
||||||
|
@ -230,7 +230,7 @@ void wdt_interrupt_reset_enable (const uint8_t value)
|
||||||
* The interrupts will have been disabled during the call to portSAVE_CONTEXT()
|
* The interrupts will have been disabled during the call to portSAVE_CONTEXT()
|
||||||
* so we need not worry about reading/writing to the stack pointer.
|
* so we need not worry about reading/writing to the stack pointer.
|
||||||
*/
|
*/
|
||||||
#if defined(__AVR_ATmega2560__) || defined(__AVR_ATmega2561__)
|
#if defined(__AVR_3_BYTE_PC__)
|
||||||
/* 3-Byte PC Save */
|
/* 3-Byte PC Save */
|
||||||
#define portSAVE_CONTEXT() \
|
#define portSAVE_CONTEXT() \
|
||||||
__asm__ __volatile__ ( "push __tmp_reg__ \n\t" \
|
__asm__ __volatile__ ( "push __tmp_reg__ \n\t" \
|
||||||
|
@ -332,7 +332,7 @@ void wdt_interrupt_reset_enable (const uint8_t value)
|
||||||
* Opposite to portSAVE_CONTEXT(). Interrupts will have been disabled during
|
* Opposite to portSAVE_CONTEXT(). Interrupts will have been disabled during
|
||||||
* the context save so we can write to the stack pointer.
|
* the context save so we can write to the stack pointer.
|
||||||
*/
|
*/
|
||||||
#if defined(__AVR_ATmega2560__) || defined(__AVR_ATmega2561__)
|
#if defined(__AVR_3_BYTE_PC__)
|
||||||
/* 3-Byte PC Restore */
|
/* 3-Byte PC Restore */
|
||||||
#define portRESTORE_CONTEXT() \
|
#define portRESTORE_CONTEXT() \
|
||||||
__asm__ __volatile__ ( "lds r26, pxCurrentTCB \n\t" \
|
__asm__ __volatile__ ( "lds r26, pxCurrentTCB \n\t" \
|
||||||
|
@ -451,7 +451,7 @@ uint16_t usAddress;
|
||||||
/* The start of the task code will be popped off the stack last, so place
|
/* The start of the task code will be popped off the stack last, so place
|
||||||
it on first. */
|
it on first. */
|
||||||
|
|
||||||
#if defined(__AVR_ATmega2560__) || defined(__AVR_ATmega2561__)
|
#if defined(__AVR_3_BYTE_PC__)
|
||||||
/* The AVR ATmega2560/ATmega2561 have 256KBytes of program memory and a 17-bit
|
/* The AVR ATmega2560/ATmega2561 have 256KBytes of program memory and a 17-bit
|
||||||
* program counter. When a code address is stored on the stack, it takes 3 bytes
|
* program counter. When a code address is stored on the stack, it takes 3 bytes
|
||||||
* instead of 2 for the other ATmega* chips.
|
* instead of 2 for the other ATmega* chips.
|
||||||
|
@ -491,7 +491,7 @@ uint16_t usAddress;
|
||||||
*pxTopOfStack = portFLAGS_INT_ENABLED;
|
*pxTopOfStack = portFLAGS_INT_ENABLED;
|
||||||
pxTopOfStack--;
|
pxTopOfStack--;
|
||||||
|
|
||||||
#if defined(__AVR_ATmega2560__) || defined(__AVR_ATmega2561__)
|
#if defined(__AVR_3_BYTE_PC__)
|
||||||
|
|
||||||
/* If we have an ATmega256x, we are also saving the RAMPZ and EIND registers.
|
/* If we have an ATmega256x, we are also saving the RAMPZ and EIND registers.
|
||||||
* We should default those to 0.
|
* We should default those to 0.
|
||||||
|
|
|
@ -132,7 +132,7 @@ extern void vPortYield( void ) __attribute__ ( ( naked ) );
|
||||||
#define portYIELD() vPortYield()
|
#define portYIELD() vPortYield()
|
||||||
/*-----------------------------------------------------------*/
|
/*-----------------------------------------------------------*/
|
||||||
|
|
||||||
#if defined(__AVR_ATmega2560__) || defined(__AVR_ATmega2561__)
|
#if defined(__AVR_3_BYTE_PC__)
|
||||||
/* Task function macros as described on the FreeRTOS.org WEB site. */
|
/* Task function macros as described on the FreeRTOS.org WEB site. */
|
||||||
|
|
||||||
/* Add .lowtext tag from the avr linker script avr6.x for ATmega2560 and ATmega2561
|
/* Add .lowtext tag from the avr linker script avr6.x for ATmega2560 and ATmega2561
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue