Quality RTOS & Embedded Software

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




Loading

SAM7XDemo Build for Latest Yagarto!

Posted by Warren Bilgeri on February 21, 2012
Good day FreeRTOS forum,

Has any one been successful with compiling a working Yagarto build for the SAM7x lwIP web server project?
I have compiled the source code a few years back on an older Yagarto build, however the later Yagarto compiler needs a syscall addition to the linker addition when compiling. I did add this file and it complies with the latest Yagarto compiler. The project runs, however the web server is unstable.

I'd like to know if someone has been successful with this before I spend more days debugging this.

Best regards,
Warren

RE: SAM7XDemo Build for Latest Yagarto!

Posted by Rob Bekkers on February 21, 2012
Hi Warren,

I'm not sure if it will solve the problem but you could give it a try:

I found a bug in the linker script which causes the initialisation of c-variables to fail. It is described here:
https://sourceforge.net/projects/freertos/forums/forum/382005/topic/5055263

I didn't test it on the demo but when I started with FreeRTOS I had the same experience with the demo. Some tasks are dodgy. Let me know your results. My tasks are running stable now.

Regards,
Rob

RE: SAM7XDemo Build for Latest Yagarto!

Posted by Warren Bilgeri on February 23, 2012
Hello Rob,

Thank you for this advice! I followed your post and it fixed the problem of the USB task falling over when I plugged in the Ethernet cable. I'm still having a hassle with the webserver but I should get to the bottom of that a lot quicker now that the stability of the tasks has been resolved.

Did you also add a syscalls file to your project?

Best regards,
Warren

RE: SAM7XDemo Build for Latest Yagarto!

Posted by Richard on February 23, 2012
The Yagarto site used to have an FAQ on this, as I recall, and even supply a syscalls file for download. The file is only required to provide stubs of the functions that the linker is looking for (unless you actually make use of them of course). You may even find a syscalls.c containing these stubs in the FreeRTOS distribution.

Please post any updated/working files to the FreeRTOS interactive site.

Regards.

RE: SAM7XDemo Build for Latest Yagarto!

Posted by Rob Bekkers on February 23, 2012
Hi Warren,

Good to hear the fix at least solved part of the problems. And yes, I added a syscalls.c file to my project. I found a basic version on the internet and modified it until it works with the stdio library in combination with the debug unit of the microcontroller. You can find my modified version here: http://couchtiger.nl/files/syscalls.zip. Not all functions are tested but the read and write function work for standard input and standard output, which is the debug unit. The sbrk functionality also appears to work because FreeRTOS is able to allocate memory. The only thing you need to do is include this code to initialise the uart of the debug unit:

// Disable PIO control for debug unit RX/TX pins
AT91C_BASE_PIOA->PIO_PDR = AT91C_PIO_PA28 | AT91C_PIO_PA27;

/* Initialise the debug unit USART. */
DBGU_Configure(0x00000800, 9600, 48000000);


You can always change the baud rate and other communication parameters of course.

Success!

Regards,
Rob


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




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

Latest News

FreeRTOS kernel V10 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