FreeRTOS Support Archive
The FreeRTOS support forum is used to obtain active support directly from Real
Time Engineers Ltd. In return for using our top quality software and services for
free, we request you play fair and do your bit to help others too! Sign up
to receive notifications of new support topics then help where you can.
This is a read only archive of threads posted to the FreeRTOS support forum.
The archive is updated every week, so will not always contain the very latest posts.
Use these archive pages to search previous posts. Use the Live FreeRTOS Forum
link to reply to a post, or start a new support thread.
[FreeRTOS Home] [Live FreeRTOS Forum] [FAQ] [Archive Top] [May 2016 Threads] Recent changes that could affect behavior of vPortStartFirstTaskPosted by westmorelandeng on May 3, 2016 Hello,
Have there been any recent changes that could affect behavior of vPortStartFirstTask?
Specifically any of the ARM R4F ports?
Thanks,
John W.
Recent changes that could affect behavior of vPortStartFirstTaskPosted by rtel on May 3, 2016
Recent changes that could affect behavior of vPortStartFirstTaskPosted by westmorelandeng on May 5, 2016 Hello Richard,
I am having to do this in my portASM.s:
vPortStartFirstTask:
portRESTORECONTEXTFIRSTTASK ; will run in debugger
;; portRESTORECONTEXT ; this won't
And the difference is:
;;; LDR LR, [LR, #+60] ;; this will run standalone
LDR LR, [SP, #-0x04] ;; this runs in the debugger
Thanks,
John W.
Recent changes that could affect behavior of vPortStartFirstTaskPosted by westmorelandeng on May 5, 2016 Hello FreeRTOSer's,
A slight mod in port.c fixed this; I want to test this for a while before publishing the fix.
Regards,
John W.
Recent changes that could affect behavior of vPortStartFirstTaskPosted by westmorelandeng on May 11, 2016 Hello,
For the port I am running under IAR for the TI Hercules processor - I have made the following change in ./portable/ARM_Cortex-R4/port.c:
in StackTypet *pxPortInitialiseStack( StackTypet *pxTopOfStack, TaskFunction_t pxCode, void *pvParameters )
In order to get the first task to start properly:
pxTopOfStack = ( StackType_t ) 0x00000000; / R14 */
has been changed to:
pxTopOfStack = ( StackType_t ) pxOriginalTOS - 64; / R14 */
Here is my comment I have in my code:
// *** this is a fix for the first task to start - otherwise it
// *** is taking the contents of 0 (zero), adding 60 and taking
// *** that as the address before subtracting 4 and loading
// *** that to the PC; which is wrong. It doesn't hurt to do
// *** this fix-up since R14 is the LR for this architecture.
// *** --- jcw
Appears to be an innocuous fix to get the first task started.
Regards,
John W.
Recent changes that could affect behavior of vPortStartFirstTaskPosted by heinbali01 on May 11, 2016 Hi John,
What release of FreeRTOS are you using?
What version of port.c are you writing about?
Is it this file ?
~~~~
FreeRTOSV9.0.0rc2FreeRTOSSourceportableIARARMCM4Fport.c
~~~~
PS. The easiest way to include literal code is to surround it with two lines that only contains 4 tildas (~~~~)
~~~~
/* Asterix may be used within a code block /
pxTopOfStack = ( StackType_t ) 0x00000000; / R14 */
~~~~
A single word within a phrase can be put between /* backquotes */ .
And I guess that the backslash * also works to show special characters.
regards.
Recent changes that could affect behavior of vPortStartFirstTaskPosted by westmorelandeng on May 11, 2016 Hello Hein,
I am using the tip of the FreeRTOS SVN tree.
The port I am using isn't part of the official release. I took what was what you have pointed out (and is the same file I illustrated in my post) and have modified it. But that port.c is pretty much the same.
Regards,
John W.
Copyright (C) Amazon Web Services, Inc. or its affiliates. All rights reserved.
|