Some updates to the fledgling RL78 demo application. Not yet complete.

pull/4/head
Richard Barry 14 years ago
parent 9290e3e71f
commit 5e583219d6

@ -88,19 +88,19 @@ asm file. It is valid in a C file, but not valid in an asm file. */
#endif /* __IAR_SYSTEMS_ICC__ */ #endif /* __IAR_SYSTEMS_ICC__ */
#define configUSE_PREEMPTION 1 #define configUSE_PREEMPTION 1
#define configTICK_RATE_HZ ( ( portTickType ) 1000 ) #define configTICK_RATE_HZ ( ( unsigned short ) 1000 )
#define configMAX_PRIORITIES ( ( unsigned portBASE_TYPE ) 4 ) #define configMAX_PRIORITIES ( ( unsigned portBASE_TYPE ) 4 )
#define configMINIMAL_STACK_SIZE ( ( unsigned short ) 100 ) #define configMINIMAL_STACK_SIZE ( ( unsigned short ) 100 )
#define configMAX_TASK_NAME_LEN ( 10 ) #define configMAX_TASK_NAME_LEN ( 10 )
#define configUSE_TRACE_FACILITY 0 #define configUSE_TRACE_FACILITY 0
#define configUSE_16_BIT_TICKS 1 #define configUSE_16_BIT_TICKS 1
#define configIDLE_SHOULD_YIELD 1 #define configIDLE_SHOULD_YIELD 1
#define configTOTAL_HEAP_SIZE ( (size_t ) ( 2900 ) ) #define configTOTAL_HEAP_SIZE ( (size_t ) ( 3500 ) )
#define configCHECK_FOR_STACK_OVERFLOW 2 #define configCHECK_FOR_STACK_OVERFLOW 2
#define configUSE_MUTEXES 1 #define configUSE_MUTEXES 1
/* Hook function definitions. */ /* Hook function definitions. */
#define configUSE_IDLE_HOOK 0 #define configUSE_IDLE_HOOK 1
#define configUSE_TICK_HOOK 0 #define configUSE_TICK_HOOK 0
#define configUSE_MALLOC_FAILED_HOOK 1 #define configUSE_MALLOC_FAILED_HOOK 1

@ -96,11 +96,11 @@
<option> <option>
<name>GenLibOutFormatter</name> <name>GenLibOutFormatter</name>
<version>0</version> <version>0</version>
<state>2</state> <state>3</state>
</option> </option>
<option> <option>
<name>GenLibOutFormatterDescription</name> <name>GenLibOutFormatterDescription</name>
<state>No specifier a or A, no specifier n, no float.</state> <state>No specifier a or A, no specifier n, no float, no flags.</state>
</option> </option>
<option> <option>
<name>GenStackSize</name> <name>GenStackSize</name>
@ -108,7 +108,7 @@
</option> </option>
<option> <option>
<name>GenNearHeapSize</name> <name>GenNearHeapSize</name>
<state>256</state> <state>0</state>
</option> </option>
<option> <option>
<name>GenFarHeapSize</name> <name>GenFarHeapSize</name>
@ -1717,15 +1717,9 @@
<name>Demo Source</name> <name>Demo Source</name>
<group> <group>
<name>StandardDemos</name> <name>StandardDemos</name>
<file>
<name>$PROJ_DIR$\..\Common\Minimal\blocktim.c</name>
</file>
<file> <file>
<name>$PROJ_DIR$\..\Common\Minimal\dynamic.c</name> <name>$PROJ_DIR$\..\Common\Minimal\dynamic.c</name>
</file> </file>
<file>
<name>$PROJ_DIR$\..\Common\Minimal\GenQTest.c</name>
</file>
<file> <file>
<name>$PROJ_DIR$\..\Common\Minimal\PollQ.c</name> <name>$PROJ_DIR$\..\Common\Minimal\PollQ.c</name>
</file> </file>

@ -68,6 +68,8 @@
/* Standard demo includes. */ /* Standard demo includes. */
#include "dynamic.h" #include "dynamic.h"
#include "PollQ.h"
#include "semtest.h"
/* The period at which the check timer will expire, in ms, provided no errors /* The period at which the check timer will expire, in ms, provided no errors
have been reported by any of the standard demo tasks. ms are converted to the have been reported by any of the standard demo tasks. ms are converted to the
@ -139,6 +141,8 @@ short main( void )
API functions being used and also to test the kernel port. More information API functions being used and also to test the kernel port. More information
is provided on the FreeRTOS.org WEB site. */ is provided on the FreeRTOS.org WEB site. */
vStartDynamicPriorityTasks(); vStartDynamicPriorityTasks();
vStartPolledQueueTasks( tskIDLE_PRIORITY );
vStartSemaphoreTasks( tskIDLE_PRIORITY + 1U );
/* Create the RegTest tasks as described at the top of this file. */ /* Create the RegTest tasks as described at the top of this file. */
xTaskCreate( vRegTest1, "Reg1", configMINIMAL_STACK_SIZE, NULL, 0, NULL ); xTaskCreate( vRegTest1, "Reg1", configMINIMAL_STACK_SIZE, NULL, 0, NULL );
@ -176,6 +180,16 @@ static portBASE_TYPE xChangedTimerPeriodAlready = pdFALSE, xErrorStatus = pdPASS
xErrorStatus = pdFAIL; xErrorStatus = pdFAIL;
} }
if( xArePollingQueuesStillRunning() != pdTRUE )
{
xErrorStatus = pdFAIL;
}
if( xAreSemaphoreTasksStillRunning() != pdTRUE )
{
xErrorStatus = pdFAIL;
}
if( sRegTestStatus != pdPASS ) if( sRegTestStatus != pdPASS )
{ {
xErrorStatus = pdFAIL; xErrorStatus = pdFAIL;
@ -310,3 +324,19 @@ void vApplicationStackOverflowHook( xTaskHandle *pxTask, signed char *pcTaskName
taskDISABLE_INTERRUPTS(); taskDISABLE_INTERRUPTS();
for( ;; ); for( ;; );
} }
/*-----------------------------------------------------------*/
void vApplicationIdleHook( void )
{
volatile size_t xFreeHeapSpace;
/* This is just a trivial example of an idle hook. It is called on each
cycle of the idle task. It must *NOT* attempt to block. In this case the
idle task just queries the amount of FreeRTOS heap that remains. See the
memory management section on the http://www.FreeRTOS.org web site for memory
management options. If there is a lot of heap memory free then the
configTOTAL_HEAP_SIZE value in FreeRTOSConfig.h can be reduced to free up
RAM. */
xFreeHeapSpace = xPortGetFreeHeapSize();
}

@ -31,7 +31,7 @@
<Wnd2> <Wnd0>
<Tabs> <Tabs>
<Tab> <Tab>
<Identity>TabID-30626-17561</Identity> <Identity>TabID-30626-17561</Identity>
@ -47,7 +47,7 @@
</Tab> </Tab>
</Tabs> </Tabs>
<SelectedTab>0</SelectedTab></Wnd2><Wnd3> <SelectedTab>0</SelectedTab></Wnd0><Wnd1>
<Tabs> <Tabs>
<Tab> <Tab>
<Identity>TabID-8606-17564</Identity> <Identity>TabID-8606-17564</Identity>
@ -55,24 +55,24 @@
<Factory>Workspace</Factory> <Factory>Workspace</Factory>
<Session> <Session>
<NodeDict><ExpandedNode>RTOSDemo</ExpandedNode></NodeDict></Session> <NodeDict><ExpandedNode>RTOSDemo</ExpandedNode><ExpandedNode>RTOSDemo/Demo Source</ExpandedNode><ExpandedNode>RTOSDemo/Demo Source/StandardDemos</ExpandedNode></NodeDict></Session>
</Tab> </Tab>
</Tabs> </Tabs>
<SelectedTab>0</SelectedTab></Wnd3></Windows> <SelectedTab>0</SelectedTab></Wnd1></Windows>
<Editor> <Editor>
<Pane><Tab><Factory>TextEditor</Factory><Filename>$WS_DIR$\main.c</Filename><XPos>0</XPos><YPos>123</YPos><SelStart>6138</SelStart><SelEnd>6138</SelEnd></Tab><Tab><Factory>TextEditor</Factory><Filename>$WS_DIR$\..\..\Source\include\portable.h</Filename><XPos>0</XPos><YPos>41</YPos><SelStart>9284</SelStart><SelEnd>9284</SelEnd></Tab><Tab><Factory>TextEditor</Factory><Filename>$WS_DIR$\..\..\Source\tasks.c</Filename><XPos>0</XPos><YPos>455</YPos><SelStart>20208</SelStart><SelEnd>20208</SelEnd></Tab><Tab><Factory>TextEditor</Factory><Filename>$WS_DIR$\FreeRTOSConfig.h</Filename><XPos>0</XPos><YPos>95</YPos><SelStart>5356</SelStart><SelEnd>5356</SelEnd></Tab><Tab><Factory>TextEditor</Factory><Filename>$WS_DIR$\..\..\Source\portable\IAR\RL78\port.c</Filename><XPos>0</XPos><YPos>6</YPos><SelStart>0</SelStart><SelEnd>0</SelEnd></Tab><Tab><Factory>TextEditor</Factory><Filename>$WS_DIR$\..\..\Source\queue.c</Filename><XPos>0</XPos><YPos>20</YPos><SelStart>2846</SelStart><SelEnd>2846</SelEnd></Tab><Tab><Factory>TextEditor</Factory><Filename>$WS_DIR$\..\..\Source\portable\IAR\RL78\portasm.s87</Filename><XPos>0</XPos><YPos>35</YPos><SelStart>2965</SelStart><SelEnd>2965</SelEnd></Tab><Tab><Factory>TextEditor</Factory><Filename>$WS_DIR$\..\..\Source\include\FreeRTOS.h</Filename><XPos>0</XPos><YPos>118</YPos><SelStart>6432</SelStart><SelEnd>6476</SelEnd></Tab><Tab><Factory>TextEditor</Factory><Filename>$WS_DIR$\..\..\Source\portable\IAR\RL78\portmacro.h</Filename><XPos>0</XPos><YPos>51</YPos><SelStart>3711</SelStart><SelEnd>3711</SelEnd></Tab><Tab><Factory>TextEditor</Factory><Filename>$WS_DIR$\..\..\Source\list.c</Filename><XPos>0</XPos><YPos>30</YPos><SelStart>0</SelStart><SelEnd>3157</SelEnd></Tab><Tab><Factory>TextEditor</Factory><Filename>$WS_DIR$\RegTest.s87</Filename><XPos>0</XPos><YPos>183</YPos><SelStart>0</SelStart><SelEnd>0</SelEnd></Tab><Tab><Factory>TextEditor</Factory><Filename>$WS_DIR$\..\Common\Minimal\dynamic.c</Filename><XPos>0</XPos><YPos>344</YPos><SelStart>14819</SelStart><SelEnd>14819</SelEnd></Tab><ActiveTab>11</ActiveTab></Pane><ActivePane>0</ActivePane><Sizes><Pane><X>1000000</X><Y>1000000</Y></Pane></Sizes><SplitMode>1</SplitMode></Editor> <Pane><Tab><Factory>TextEditor</Factory><Filename>$WS_DIR$\main.c</Filename><XPos>0</XPos><YPos>157</YPos><SelStart>10672</SelStart><SelEnd>10672</SelEnd></Tab><ActiveTab>0</ActiveTab><Tab><Factory>TextEditor</Factory><Filename>$WS_DIR$\..\Common\Minimal\semtest.c</Filename><XPos>0</XPos><YPos>248</YPos><SelStart>11198</SelStart><SelEnd>11228</SelEnd></Tab></Pane><ActivePane>0</ActivePane><Sizes><Pane><X>1000000</X><Y>1000000</Y></Pane></Sizes><SplitMode>1</SplitMode></Editor>
<Positions> <Positions>
<Top><Row0><Sizes><Toolbar-013361d0><key>iaridepm.enu1</key></Toolbar-013361d0></Sizes></Row0><Row1><Sizes><Toolbar-04b9a7e8><key>debuggergui.enu1</key></Toolbar-04b9a7e8><Toolbar-0b7be258><key>rl78ocd.enu1</key></Toolbar-0b7be258></Sizes></Row1></Top><Left><Row0><Sizes><Wnd3><Rect><Top>-2</Top><Left>-2</Left><Bottom>662</Bottom><Right>344</Right><x>-2</x><y>-2</y><xscreen>346</xscreen><yscreen>254</yscreen><sizeHorzCX>205952</sizeHorzCX><sizeHorzCY>258656</sizeHorzCY><sizeVertCX>205952</sizeVertCX><sizeVertCY>676171</sizeVertCY></Rect></Wnd3></Sizes></Row0></Left><Right><Row0><Sizes/></Row0></Right><Bottom><Row0><Sizes><Wnd2><Rect><Top>-2</Top><Left>-2</Left><Bottom>252</Bottom><Right>1682</Right><x>-2</x><y>-2</y><xscreen>1684</xscreen><yscreen>254</yscreen><sizeHorzCX>1002381</sizeHorzCX><sizeHorzCY>258656</sizeHorzCY><sizeVertCX>205952</sizeVertCX><sizeVertCY>258656</sizeVertCY></Rect></Wnd2></Sizes></Row0></Bottom><Float><Sizes/></Float></Positions> <Top><Row0><Sizes><Toolbar-013362c8><key>iaridepm.enu1</key></Toolbar-013362c8></Sizes></Row0><Row1><Sizes><Toolbar-04c02860><key>debuggergui.enu1</key></Toolbar-04c02860><Toolbar-08707c28><key>rl78ocd.enu1</key></Toolbar-08707c28></Sizes></Row1><Row2><Sizes/></Row2><Row3><Sizes/></Row3><Row4><Sizes/></Row4><Row5><Sizes/></Row5><Row6><Sizes/></Row6></Top><Left><Row0><Sizes><Wnd1><Rect><Top>-2</Top><Left>-2</Left><Bottom>662</Bottom><Right>344</Right><x>-2</x><y>-2</y><xscreen>346</xscreen><yscreen>254</yscreen><sizeHorzCX>205952</sizeHorzCX><sizeHorzCY>258656</sizeHorzCY><sizeVertCX>205952</sizeVertCX><sizeVertCY>676171</sizeVertCY></Rect></Wnd1></Sizes></Row0></Left><Right><Row0><Sizes/></Row0></Right><Bottom><Row0><Sizes><Wnd0><Rect><Top>-2</Top><Left>-2</Left><Bottom>252</Bottom><Right>1682</Right><x>-2</x><y>-2</y><xscreen>1684</xscreen><yscreen>254</yscreen><sizeHorzCX>1002381</sizeHorzCX><sizeHorzCY>258656</sizeHorzCY><sizeVertCX>205952</sizeVertCX><sizeVertCY>258656</sizeVertCY></Rect></Wnd0></Sizes></Row0></Bottom><Float><Sizes/></Float></Positions>
</Desktop> </Desktop>
</Project> </Project>

@ -15,7 +15,7 @@ TypeViolation=1
UnspecRange=1 UnspecRange=1
ActionState=1 ActionState=1
[DebugChecksum] [DebugChecksum]
Checksum=-445921582 Checksum=-185012109
[DisAssemblyWindow] [DisAssemblyWindow]
NumStates=_ 1 NumStates=_ 1
State 1=_ 1 State 1=_ 1

@ -25,7 +25,7 @@
<Factory>Workspace</Factory> <Factory>Workspace</Factory>
<Session> <Session>
<NodeDict><ExpandedNode>RTOSDemo</ExpandedNode><ExpandedNode>RTOSDemo/Demo Source</ExpandedNode><ExpandedNode>RTOSDemo/Kernel Source</ExpandedNode></NodeDict></Session> <NodeDict><ExpandedNode>RTOSDemo</ExpandedNode><ExpandedNode>RTOSDemo/Demo Source</ExpandedNode><ExpandedNode>RTOSDemo/Demo Source/StandardDemos</ExpandedNode><ExpandedNode>RTOSDemo/Kernel Source</ExpandedNode></NodeDict></Session>
</Tab> </Tab>
</Tabs> </Tabs>
@ -35,14 +35,14 @@
<Pane><Tab><Factory>TextEditor</Factory><Filename>$WS_DIR$\main.c</Filename><XPos>0</XPos><YPos>123</YPos><SelStart>6138</SelStart><SelEnd>6138</SelEnd></Tab><ActiveTab>0</ActiveTab></Pane><ActivePane>0</ActivePane><Sizes><Pane><X>1000000</X><Y>1000000</Y></Pane></Sizes><SplitMode>1</SplitMode></Editor> <Pane><Tab><Factory>TextEditor</Factory><Filename>$WS_DIR$\main.c</Filename><XPos>0</XPos><YPos>157</YPos><SelStart>10672</SelStart><SelEnd>10672</SelEnd></Tab><ActiveTab>0</ActiveTab><Tab><Factory>TextEditor</Factory><Filename>$WS_DIR$\..\Common\Minimal\semtest.c</Filename><XPos>0</XPos><YPos>248</YPos><SelStart>11198</SelStart><SelEnd>11228</SelEnd></Tab></Pane><ActivePane>0</ActivePane><Sizes><Pane><X>1000000</X><Y>1000000</Y></Pane></Sizes><SplitMode>1</SplitMode></Editor>
<Positions> <Positions>
<Top><Row0><Sizes><Toolbar-013361d0><key>iaridepm.enu1</key></Toolbar-013361d0></Sizes></Row0><Row1><Sizes/></Row1><Row2><Sizes/></Row2><Row3><Sizes/></Row3><Row4><Sizes/></Row4><Row5><Sizes/></Row5><Row6><Sizes/></Row6></Top><Left><Row0><Sizes><Wnd0><Rect><Top>-2</Top><Left>-2</Left><Bottom>629</Bottom><Right>318</Right><x>-2</x><y>-2</y><xscreen>263</xscreen><yscreen>200</yscreen><sizeHorzCX>156548</sizeHorzCX><sizeHorzCY>203666</sizeHorzCY><sizeVertCX>190476</sizeVertCX><sizeVertCY>642566</sizeVertCY></Rect></Wnd0></Sizes></Row0></Left><Right><Row0><Sizes/></Row0></Right><Bottom><Row0><Sizes><Wnd1><Rect><Top>-2</Top><Left>-2</Left><Bottom>309</Bottom><Right>1682</Right><x>-2</x><y>-2</y><xscreen>1684</xscreen><yscreen>311</yscreen><sizeHorzCX>1002381</sizeHorzCX><sizeHorzCY>316701</sizeHorzCY><sizeVertCX>205357</sizeVertCX><sizeVertCY>258656</sizeVertCY></Rect></Wnd1></Sizes></Row0></Bottom><Float><Sizes/></Float></Positions> <Top><Row0><Sizes><Toolbar-013362c8><key>iaridepm.enu1</key></Toolbar-013362c8></Sizes></Row0><Row1><Sizes/></Row1><Row2><Sizes/></Row2><Row3><Sizes/></Row3><Row4><Sizes/></Row4><Row5><Sizes/></Row5><Row6><Sizes/></Row6><Row7><Sizes/></Row7><Row8><Sizes/></Row8><Row9><Sizes/></Row9><Row10><Sizes/></Row10></Top><Left><Row0><Sizes><Wnd0><Rect><Top>-2</Top><Left>-2</Left><Bottom>629</Bottom><Right>318</Right><x>-2</x><y>-2</y><xscreen>263</xscreen><yscreen>200</yscreen><sizeHorzCX>156548</sizeHorzCX><sizeHorzCY>203666</sizeHorzCY><sizeVertCX>190476</sizeVertCX><sizeVertCY>642566</sizeVertCY></Rect></Wnd0></Sizes></Row0></Left><Right><Row0><Sizes/></Row0></Right><Bottom><Row0><Sizes><Wnd1><Rect><Top>-2</Top><Left>-2</Left><Bottom>309</Bottom><Right>1682</Right><x>-2</x><y>-2</y><xscreen>1684</xscreen><yscreen>311</yscreen><sizeHorzCX>1002381</sizeHorzCX><sizeHorzCY>316701</sizeHorzCY><sizeVertCX>205357</sizeVertCX><sizeVertCY>258656</sizeVertCY></Rect></Wnd1></Sizes></Row0></Bottom><Float><Sizes/></Float></Positions>
</Desktop> </Desktop>
</Workspace> </Workspace>

Loading…
Cancel
Save