Quality RTOS & Embedded Software

 Real time embedded FreeRTOS RSS feed 
Quick Start Supported MCUs PDF Books Trace Tools Ecosystem


Loading

Using the ATmega323 port for AT90s8515

Posted by Nobody/Anonymous on April 26, 2005
Hi, I'm a weird issue after porting to the AT90s8515. I have only modified portTOTAL_HEAP_SIZE ((set to 384) and portCOMPARE_MATCH_A_INTERRUPT_ENABLE (set to 0x40) from the ATmega323 port, to match the 8515 device.

All seems to work well when I just have one simple task that toggles a LED every 100mS. When I add another task to flash another LED using the same code (albiet in a new function) the first task seems works at an accelerated rate and the second task appears to execute once and then halts (only debugging by the LED's). I'm using the vTaskDelayUntil function to delay the task. All my variables are local to each function.

Any idea's?

I have been

RE: Using the ATmega323 port for AT90s8515

Posted by Nobody/Anonymous on April 26, 2005
Do you have any external RAM? I don't think the 8515 has enough internal RAM.

384 heap size is probably your problem. I suspect creating the second task is running out of ram.

RE: Using the ATmega323 port for AT90s8515

Posted by Nobody/Anonymous on April 26, 2005
I thought that may be the case but I have changed the portMINIMAL_STACK_SIZE from the original size (85) down to 30 and still the same issue. The 8515 has 512bytes Ram, a quick count means even with the Stack Size of 100 I should be able to fit three, even four tasks, if not using any global variables.

RE: Using the ATmega323 port for AT90s8515

Posted by Nobody/Anonymous on April 26, 2005
30 bytes of stack is unfortunately not enough to save the AVR context - so you will get stack corruption for sure.


[ Back to the top ]    [ About FreeRTOS ]    [ Sitemap ]    [ ]




Copyright (C) Amazon Web Services, Inc. or its affiliates. All rights reserved.

Latest News

FreeRTOS kernel V10.0.1 is available for immediate download. Now MIT licensed.


FreeRTOS Partners

ARM Connected RTOS partner for all ARM microcontroller cores

IAR Partner

Microchip Premier RTOS Partner

RTOS partner of NXP for all NXP ARM microcontrollers

STMicro RTOS partner supporting ARM7, ARM Cortex-M3, ARM Cortex-M4 and ARM Cortex-M0

Texas Instruments MCU Developer Network RTOS partner for ARM and MSP430 microcontrollers

OpenRTOS and SafeRTOS