Update the MPU port so it supports all the public functions found in V9.0.0rc2.

This commit is contained in:
Richard Barry 2016-04-20 15:42:34 +00:00
parent da6c95edae
commit ac67c39be9
14 changed files with 1044 additions and 369 deletions

View file

@ -87,10 +87,14 @@ extern "C" {
* See http://www.freertos.org/a00110.html.
*----------------------------------------------------------*/
/* The MPU version of port.c includes and excludes functions depending on the
settings within this file. Therefore, to ensure all the functions in port.c
build, this configuration file has all options turned on. */
#define configUSE_PREEMPTION 1
#define configTICK_RATE_HZ ( 1000 )
#define configUSE_PORT_OPTIMISED_TASK_SELECTION 0
#define configUSE_QUEUE_SETS 0
#define configUSE_QUEUE_SETS 1
#define configUSE_IDLE_HOOK 1
#define configUSE_TICK_HOOK 1
#define configCPU_CLOCK_HZ 48000000
@ -98,23 +102,24 @@ extern "C" {
#define configMINIMAL_STACK_SIZE ( ( unsigned short ) 120 )
#define configTOTAL_HEAP_SIZE ( ( size_t ) ( 16 * 1024 ) )
#define configMAX_TASK_NAME_LEN ( 10 )
#define configUSE_TRACE_FACILITY 0
#define configUSE_TRACE_FACILITY 1
#define configUSE_16_BIT_TICKS 0
#define configIDLE_SHOULD_YIELD 1
#define configUSE_MUTEXES 0
#define configQUEUE_REGISTRY_SIZE 0
#define configUSE_MUTEXES 1
#define configQUEUE_REGISTRY_SIZE 5
#define configCHECK_FOR_STACK_OVERFLOW 2
#define configUSE_RECURSIVE_MUTEXES 0
#define configUSE_RECURSIVE_MUTEXES 1
#define configUSE_MALLOC_FAILED_HOOK 1
#define configUSE_APPLICATION_TASK_TAG 0
#define configUSE_COUNTING_SEMAPHORES 0
#define configSUPPORT_STATIC_ALLOCATION 0
#define configUSE_APPLICATION_TASK_TAG 1
#define configUSE_COUNTING_SEMAPHORES 1
#define configSUPPORT_STATIC_ALLOCATION 1
#define configUSE_TICKLESS_IDLE 0
#define configNUM_THREAD_LOCAL_STORAGE_POINTERS 2
/* Run time stats gathering definitions. */
#define configGENERATE_RUN_TIME_STATS 0
#define configGENERATE_RUN_TIME_STATS 1
#define portCONFIGURE_TIMER_FOR_RUN_TIME_STATS()
#define portGET_RUN_TIME_COUNTER_VALUE()
#define portGET_RUN_TIME_COUNTER_VALUE() 0
/* This demo makes use of one or more example stats formatting functions. These
format the raw data provided by the uxTaskGetSystemState() function in to human
@ -127,7 +132,7 @@ FreeRTOS/Source/tasks.c for limitations. */
#define configMAX_CO_ROUTINE_PRIORITIES ( 2 )
/* Software timer definitions. */
#define configUSE_TIMERS 0
#define configUSE_TIMERS 1
#define configTIMER_TASK_PRIORITY ( 2 )
#define configTIMER_QUEUE_LENGTH 5
#define configTIMER_TASK_STACK_DEPTH ( configMINIMAL_STACK_SIZE )

View file

@ -21,7 +21,7 @@
<View>
<WinId>204</WinId>
<ViewName>Performance Analyzer</ViewName>
<TableColWidths>1028 154 154 100</TableColWidths>
<TableColWidths>1028 154 154 278</TableColWidths>
</View>
</SECTreeCtrl>
@ -30,25 +30,25 @@
<WinId>1506</WinId>
<ViewName>Symbols</ViewName>
<UserString></UserString>
<TableColWidths>70 70 70</TableColWidths>
<TableColWidths>80 80 80</TableColWidths>
</View>
<View>
<WinId>1936</WinId>
<ViewName>Watch 1</ViewName>
<UserString></UserString>
<TableColWidths>70 164 70</TableColWidths>
<TableColWidths>80 80 80</TableColWidths>
</View>
<View>
<WinId>1937</WinId>
<ViewName>Watch 2</ViewName>
<UserString></UserString>
<TableColWidths>70 70 70</TableColWidths>
<TableColWidths>80 80 80</TableColWidths>
</View>
<View>
<WinId>1935</WinId>
<ViewName>Call Stack + Locals</ViewName>
<UserString></UserString>
<TableColWidths>70 70 70</TableColWidths>
<TableColWidths>80 80 80</TableColWidths>
</View>
<View>
<WinId>2506</WinId>
@ -75,25 +75,25 @@
<flags>2</flags>
<showCmd>3</showCmd>
<MinPosition>
<xPos>-1</xPos>
<yPos>-1</yPos>
<xPos>-32000</xPos>
<yPos>-32000</yPos>
</MinPosition>
<MaxPosition>
<xPos>-1</xPos>
<yPos>-1</yPos>
</MaxPosition>
<NormalPosition>
<Top>104</Top>
<Left>399</Left>
<Right>1341</Right>
<Bottom>976</Bottom>
<Top>92</Top>
<Left>350</Left>
<Right>1292</Right>
<Bottom>964</Bottom>
</NormalPosition>
</WindowPosition>
<MDIClientArea>
<RegID>0</RegID>
<MDITabState>
<Len>921</Len>
<Data>01000000040000000100000001000000010000000100000000000000020000000000000001000000010000000000000028000000280000000100000007000000000000000100000035433A5C455C4465765C4672656552544F535C576F726B696E67436F70795C4672656552544F535C536F757263655C71756575652E63000000000771756575652E6300000000F7B88600FFFFFFFF5A433A5C455C4465765C4672656552544F535C576F726B696E67436F70795C4672656552544F535C44656D6F5C434F525445585F4D50555F53696D756C61746F725F4B65696C5F4743435C4672656552544F53436F6E6669672E6800000000104672656552544F53436F6E6669672E6800000000BCA8E100FFFFFFFF67433A5C455C4465765C4672656552544F535C576F726B696E67436F70795C4672656552544F535C44656D6F5C434F525445585F4D50555F53696D756C61746F725F4B65696C5F4743435C4743435F53706563696669635C737461727475705F41524D434D342E530000000010737461727475705F41524D434D342E5300000000FFDC7800FFFFFFFF50433A5C455C4465765C4672656552544F535C576F726B696E67436F70795C4672656552544F535C44656D6F5C434F525445585F4D50555F53696D756C61746F725F4B65696C5F4743435C6D61696E2E6300000000066D61696E2E6300000000BCA8E100FFFFFFFF62433A5C455C4465765C4672656552544F535C576F726B696E67436F70795C4672656552544F535C44656D6F5C434F525445585F4D50555F53696D756C61746F725F4B65696C5F4743435C4743435F53706563696669635C73656374696F6E732E6C64000000000B73656374696F6E732E6C6400000000BECEA100FFFFFFFF35433A5C455C4465765C4672656552544F535C576F726B696E67436F70795C4672656552544F535C536F757263655C7461736B732E6300000000077461736B732E6300000000F0A0A100FFFFFFFF4D433A5C455C4465765C4672656552544F535C576F726B696E67436F70795C4672656552544F535C536F757263655C706F727461626C655C4743435C41524D5F434D335F4D50555C706F72742E630000000006706F72742E63000000009CC1B600FFFFFFFF0100000010000000C5D4F200FFDC7800BECEA100F0A0A100BCA8E1009CC1B600F7B88600D9ADC200A5C2D700B3A6BE00EAD6A300F6FA7D00B5E99D005FC3CF00C1838300CACAD500010000000000000002000000110100005E000000800700006C030000</Data>
<Len>276</Len>
<Data>01000000040000000100000001000000010000000100000000000000020000000000000001000000010000000000000028000000280000000100000001000000000000000100000050433A5C455C4465765C4672656552544F535C576F726B696E67436F70795C4672656552544F535C44656D6F5C434F525445585F4D50555F53696D756C61746F725F4B65696C5F4743435C6D61696E2E6300000000066D61696E2E6300000000FFDC7800FFFFFFFF0100000010000000C5D4F200FFDC7800BECEA100F0A0A100BCA8E1009CC1B600F7B88600D9ADC200A5C2D700B3A6BE00EAD6A300F6FA7D00B5E99D005FC3CF00C1838300CACAD500010000000000000002000000110100005E000000800700006C030000</Data>
</MDITabState>
</MDIClientArea>
<ViewEx>
@ -1287,8 +1287,8 @@
<RegID>59392</RegID>
<Name>File</Name>
<Buttons>
<Len>2391</Len>
<Data>00200000010000002800FFFF01001100434D4643546F6F6C426172427574746F6E00E100000000000000000000000000000000000000000000000100000001000000018001E100000000000001000000000000000000000000000000000100000001000000018003E1000000000000020000000000000000000000000000000001000000010000000180CD7F0000000000000300000000000000000000000000000000010000000100000001800000000001000000FFFFFFFF000000000000000000000000000100000001000000018023E100000000000004000000000000000000000000000000000100000001000000018022E100000000000005000000000000000000000000000000000100000001000000018025E10000000000000600000000000000000000000000000000010000000100000001800000000001000000FFFFFFFF00000000000000000000000000010000000100000001802BE10000000004000700000000000000000000000000000000010000000100000001802CE10000000004000800000000000000000000000000000000010000000100000001800000000001000000FFFFFFFF00000000000000000000000000010000000100000001807A8A0000000000000900000000000000000000000000000000010000000100000001807B8A0000000004000A00000000000000000000000000000000010000000100000001800000000001000000FFFFFFFF0000000000000000000000000001000000010000000180D3B00000000000000B000000000000000000000000000000000100000001000000018015B10000000004000C0000000000000000000000000000000001000000010000000180F4B00000000004000D000000000000000000000000000000000100000001000000018036B10000000004000E00000000000000000000000000000000010000000100000001800000000001000000FFFFFFFF0000000000000000000000000001000000010000000180FF88000000000000460000000000000000000000000000000001000000010000000180FE880000000000004500000000000000000000000000000000010000000100000001800B810000000000001300000000000000000000000000000000010000000100000001800C810000000000001400000000000000000000000000000000010000000100000001800000000001000000FFFFFFFF0000000000000000000000000001000000010000000180F0880000020000000F000000000000000000000000000000000100000001000000FFFF0100120043555646696E64436F6D626F427574746F6EE803000000000000000000000000000000000000000000000001000000010000009600000002002050000000002274736B535441544943414C4C595F414C4C4F43415445445F535441434B5F4F4E4C59960000000000000014002274736B535441544943414C4C595F414C4C4F43415445445F535441434B5F4F4E4C59065354415449430005737461636B0352414D064D454D4F52590B504F53534942494C495459135F4D696E696D756D5F537461636B5F53697A650644414D4147450665787465726E0A5F5F537461636B546F7007766563746F727306756C4D61696E2574736B535441544943414C4C595F414C4C4F43415445445F535441434B5F414E445F54434206535441434B5F1F636F6E666967535550504F52545F5354415449435F414C4C4F434154494F4E157563537461746963616C6C79416C6C6F6361746564047563537408696E6469636174651D74736B5354415449435F414C4C4F434154494F4E5F504F535349424C450000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000018024E10000000000001100000000000000000000000000000000010000000100000001800A810000000000001200000000000000000000000000000000010000000100000001800000000001000000FFFFFFFF000000000000000000000000000100000001000000018022800000020000001500000000000000000000000000000000010000000100000001800000000001000000FFFFFFFF0000000000000000000000000001000000010000000180C488000000000000160000000000000000000000000000000001000000010000000180C988000000000400180000000000000000000000000000000001000000010000000180C788000000000000190000000000000000000000000000000001000000010000000180C8880000000000001700000000000000000000000000000000010000000100000001800000000001000000FFFFFFFF000000000000000000000000000100000001000000FFFF01001500434D4643546F6F6C4261724D656E75427574746F6E4C010000020001001A0000000F2650726F6A6563742057696E646F77000000000000000000000000010000000100000000000000000000000100000008002880DD880000000000001A0000000750726F6A656374000000000000000000000000010000000100000000000000000000000100000000002880DC8B0000000000003A00000005426F6F6B73000000000000000000000000010000000100000000000000000000000100000000002880E18B0000000000003B0000000946756E6374696F6E73000000000000000000000000010000000100000000000000000000000100000000002880E28B000000000000400000000954656D706C6174657300000000000000000000000001000000010000000000000000000000010000000000288018890000000000003D0000000E536F757263652042726F777365720000000000000000000000000100000001000000000000000000000001000000000028800000000000000400FFFFFFFF00000000000000000001000000000000000100000000000000000000000100000000002880D988000000000000390000000C4275696C64204F7574707574000000000000000000000000010000000100000000000000000000000100000000002880E38B000000000000410000000B46696E64204F75747075740000000000000000000000000100000001000000000000000000000001000000000001800000000001000000FFFFFFFF0000000000000000000000000001000000010000000180FB7F0000000000001B000000000000000000000000000000000100000001000000000000000446696C6572030000</Data>
<Len>2178</Len>
<Data>00200000010000002800FFFF01001100434D4643546F6F6C426172427574746F6E00E100000000000000000000000000000000000000000000000100000001000000018001E100000000000001000000000000000000000000000000000100000001000000018003E1000000000000020000000000000000000000000000000001000000010000000180CD7F0000000000000300000000000000000000000000000000010000000100000001800000000001000000FFFFFFFF000000000000000000000000000100000001000000018023E100000000040004000000000000000000000000000000000100000001000000018022E100000000040005000000000000000000000000000000000100000001000000018025E10000000000000600000000000000000000000000000000010000000100000001800000000001000000FFFFFFFF00000000000000000000000000010000000100000001802BE10000000000000700000000000000000000000000000000010000000100000001802CE10000000004000800000000000000000000000000000000010000000100000001800000000001000000FFFFFFFF00000000000000000000000000010000000100000001807A8A0000000000000900000000000000000000000000000000010000000100000001807B8A0000000004000A00000000000000000000000000000000010000000100000001800000000001000000FFFFFFFF0000000000000000000000000001000000010000000180D3B00000000000000B000000000000000000000000000000000100000001000000018015B10000000004000C0000000000000000000000000000000001000000010000000180F4B00000000004000D000000000000000000000000000000000100000001000000018036B10000000004000E00000000000000000000000000000000010000000100000001800000000001000000FFFFFFFF0000000000000000000000000001000000010000000180FF88000000000400460000000000000000000000000000000001000000010000000180FE880000000004004500000000000000000000000000000000010000000100000001800B810000000004001300000000000000000000000000000000010000000100000001800C810000000004001400000000000000000000000000000000010000000100000001800000000001000000FFFFFFFF0000000000000000000000000001000000010000000180F0880000020000000F000000000000000000000000000000000100000001000000FFFF0100120043555646696E64436F6D626F427574746F6EE803000000000000000000000000000000000000000000000001000000010000009600000002002050000000000A5553455F54494D455253960000000000000007000A5553455F54494D455253001E636F6E6669675553455F4150504C49434154494F4E5F5441534B5F5441471D636F6E66696747454E45524154455F52554E5F54494D455F53544154531F636F6E666967535550504F52545F5354415449435F414C4C4F434154494F4E11707276537461727446697273745461736B0E73746172747363686564756C657200000000000000000000000000000000000000000000000000000000018024E10000000000001100000000000000000000000000000000010000000100000001800A810000000000001200000000000000000000000000000000010000000100000001800000000001000000FFFFFFFF000000000000000000000000000100000001000000018022800000020000001500000000000000000000000000000000010000000100000001800000000001000000FFFFFFFF0000000000000000000000000001000000010000000180C488000000000000160000000000000000000000000000000001000000010000000180C988000000000400180000000000000000000000000000000001000000010000000180C788000000000000190000000000000000000000000000000001000000010000000180C8880000000000001700000000000000000000000000000000010000000100000001800000000001000000FFFFFFFF000000000000000000000000000100000001000000FFFF01001500434D4643546F6F6C4261724D656E75427574746F6E4C010000020001001A0000000F2650726F6A6563742057696E646F77000000000000000000000000010000000100000000000000000000000100000008002880DD880000000000001A0000000750726F6A656374000000000000000000000000010000000100000000000000000000000100000000002880DC8B0000000000003A00000005426F6F6B73000000000000000000000000010000000100000000000000000000000100000000002880E18B0000000000003B0000000946756E6374696F6E73000000000000000000000000010000000100000000000000000000000100000000002880E28B000000000000400000000954656D706C6174657300000000000000000000000001000000010000000000000000000000010000000000288018890000000000003D0000000E536F757263652042726F777365720000000000000000000000000100000001000000000000000000000001000000000028800000000000000400FFFFFFFF00000000000000000001000000000000000100000000000000000000000100000000002880D988000000000000390000000C4275696C64204F7574707574000000000000000000000000010000000100000000000000000000000100000000002880E38B000000000000410000000B46696E64204F75747075740000000000000000000000000100000001000000000000000000000001000000000001800000000001000000FFFFFFFF0000000000000000000000000001000000010000000180FB7F0000000000001B000000000000000000000000000000000100000001000000000000000446696C6572030000</Data>
</Buttons>
<OriginalItems>
<Len>1423</Len>
@ -2528,8 +2528,8 @@
<RegID>59392</RegID>
<Name>File</Name>
<Buttons>
<Len>2391</Len>
<Data>00200000010000002800FFFF01001100434D4643546F6F6C426172427574746F6E00E100000000000000000000000000000000000000000000000100000001000000018001E100000000000001000000000000000000000000000000000100000001000000018003E1000000000000020000000000000000000000000000000001000000010000000180CD7F0000000000000300000000000000000000000000000000010000000100000001800000000001000000FFFFFFFF000000000000000000000000000100000001000000018023E100000000040004000000000000000000000000000000000100000001000000018022E100000000040005000000000000000000000000000000000100000001000000018025E10000000000000600000000000000000000000000000000010000000100000001800000000001000000FFFFFFFF00000000000000000000000000010000000100000001802BE10000000000000700000000000000000000000000000000010000000100000001802CE10000000004000800000000000000000000000000000000010000000100000001800000000001000000FFFFFFFF00000000000000000000000000010000000100000001807A8A0000000000000900000000000000000000000000000000010000000100000001807B8A0000000004000A00000000000000000000000000000000010000000100000001800000000001000000FFFFFFFF0000000000000000000000000001000000010000000180D3B00000000000000B000000000000000000000000000000000100000001000000018015B10000000004000C0000000000000000000000000000000001000000010000000180F4B00000000004000D000000000000000000000000000000000100000001000000018036B10000000004000E00000000000000000000000000000000010000000100000001800000000001000000FFFFFFFF0000000000000000000000000001000000010000000180FF88000000000400460000000000000000000000000000000001000000010000000180FE880000000004004500000000000000000000000000000000010000000100000001800B810000000004001300000000000000000000000000000000010000000100000001800C810000000004001400000000000000000000000000000000010000000100000001800000000001000000FFFFFFFF0000000000000000000000000001000000010000000180F0880000020000000F000000000000000000000000000000000100000001000000FFFF0100120043555646696E64436F6D626F427574746F6EE803000000000000000000000000000000000000000000000001000000010000009600000002002050000000002274736B535441544943414C4C595F414C4C4F43415445445F535441434B5F4F4E4C59960000000000000014002274736B535441544943414C4C595F414C4C4F43415445445F535441434B5F4F4E4C59065354415449430005737461636B0352414D064D454D4F52590B504F53534942494C495459135F4D696E696D756D5F537461636B5F53697A650644414D4147450665787465726E0A5F5F537461636B546F7007766563746F727306756C4D61696E2574736B535441544943414C4C595F414C4C4F43415445445F535441434B5F414E445F54434206535441434B5F1F636F6E666967535550504F52545F5354415449435F414C4C4F434154494F4E157563537461746963616C6C79416C6C6F6361746564047563537408696E6469636174651D74736B5354415449435F414C4C4F434154494F4E5F504F535349424C450000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000018024E10000000000001100000000000000000000000000000000010000000100000001800A810000000000001200000000000000000000000000000000010000000100000001800000000001000000FFFFFFFF000000000000000000000000000100000001000000018022800000020003001500000000000000000000000000000000010000000100000001800000000001000000FFFFFFFF0000000000000000000000000001000000010000000180C488000000000000160000000000000000000000000000000001000000010000000180C988000000000400180000000000000000000000000000000001000000010000000180C788000000000000190000000000000000000000000000000001000000010000000180C8880000000000001700000000000000000000000000000000010000000100000001800000000001000000FFFFFFFF000000000000000000000000000100000001000000FFFF01001500434D4643546F6F6C4261724D656E75427574746F6E4C010000020001001A0000000F2650726F6A6563742057696E646F77000000000000000000000000010000000100000000000000000000000100000008002880DD880000000000001A0000000750726F6A656374000000000000000000000000010000000100000000000000000000000100000000002880DC8B0000000000003A00000005426F6F6B73000000000000000000000000010000000100000000000000000000000100000000002880E18B0000000000003B0000000946756E6374696F6E73000000000000000000000000010000000100000000000000000000000100000000002880E28B000000000000400000000954656D706C6174657300000000000000000000000001000000010000000000000000000000010000000000288018890000000000003D0000000E536F757263652042726F777365720000000000000000000000000100000001000000000000000000000001000000000028800000000000000400FFFFFFFF00000000000000000001000000000000000100000000000000000000000100000000002880D988000000000000390000000C4275696C64204F7574707574000000000000000000000000010000000100000000000000000000000100000000002880E38B000000000000410000000B46696E64204F75747075740000000000000000000000000100000001000000000000000000000001000000000001800000000001000000FFFFFFFF0000000000000000000000000001000000010000000180FB7F0000000000001B000000000000000000000000000000000100000001000000000000000446696C6572030000</Data>
<Len>2178</Len>
<Data>00200000010000002800FFFF01001100434D4643546F6F6C426172427574746F6E00E100000000000000000000000000000000000000000000000100000001000000018001E100000000000001000000000000000000000000000000000100000001000000018003E1000000000000020000000000000000000000000000000001000000010000000180CD7F0000000000000300000000000000000000000000000000010000000100000001800000000001000000FFFFFFFF000000000000000000000000000100000001000000018023E100000000040004000000000000000000000000000000000100000001000000018022E100000000040005000000000000000000000000000000000100000001000000018025E10000000000000600000000000000000000000000000000010000000100000001800000000001000000FFFFFFFF00000000000000000000000000010000000100000001802BE10000000000000700000000000000000000000000000000010000000100000001802CE10000000004000800000000000000000000000000000000010000000100000001800000000001000000FFFFFFFF00000000000000000000000000010000000100000001807A8A0000000000000900000000000000000000000000000000010000000100000001807B8A0000000004000A00000000000000000000000000000000010000000100000001800000000001000000FFFFFFFF0000000000000000000000000001000000010000000180D3B00000000000000B000000000000000000000000000000000100000001000000018015B10000000004000C0000000000000000000000000000000001000000010000000180F4B00000000004000D000000000000000000000000000000000100000001000000018036B10000000004000E00000000000000000000000000000000010000000100000001800000000001000000FFFFFFFF0000000000000000000000000001000000010000000180FF88000000000400460000000000000000000000000000000001000000010000000180FE880000000004004500000000000000000000000000000000010000000100000001800B810000000004001300000000000000000000000000000000010000000100000001800C810000000004001400000000000000000000000000000000010000000100000001800000000001000000FFFFFFFF0000000000000000000000000001000000010000000180F0880000020000000F000000000000000000000000000000000100000001000000FFFF0100120043555646696E64436F6D626F427574746F6EE803000000000000000000000000000000000000000000000001000000010000009600000002002050000000000A5553455F54494D455253960000000000000007000A5553455F54494D455253001E636F6E6669675553455F4150504C49434154494F4E5F5441534B5F5441471D636F6E66696747454E45524154455F52554E5F54494D455F53544154531F636F6E666967535550504F52545F5354415449435F414C4C4F434154494F4E11707276537461727446697273745461736B0E73746172747363686564756C657200000000000000000000000000000000000000000000000000000000018024E10000000000001100000000000000000000000000000000010000000100000001800A810000000000001200000000000000000000000000000000010000000100000001800000000001000000FFFFFFFF000000000000000000000000000100000001000000018022800000020001001500000000000000000000000000000000010000000100000001800000000001000000FFFFFFFF0000000000000000000000000001000000010000000180C488000000000000160000000000000000000000000000000001000000010000000180C988000000000400180000000000000000000000000000000001000000010000000180C788000000000000190000000000000000000000000000000001000000010000000180C8880000000000001700000000000000000000000000000000010000000100000001800000000001000000FFFFFFFF000000000000000000000000000100000001000000FFFF01001500434D4643546F6F6C4261724D656E75427574746F6E4C010000020001001A0000000F2650726F6A6563742057696E646F77000000000000000000000000010000000100000000000000000000000100000008002880DD880000000000001A0000000750726F6A656374000000000000000000000000010000000100000000000000000000000100000000002880DC8B0000000000003A00000005426F6F6B73000000000000000000000000010000000100000000000000000000000100000000002880E18B0000000000003B0000000946756E6374696F6E73000000000000000000000000010000000100000000000000000000000100000000002880E28B000000000000400000000954656D706C6174657300000000000000000000000001000000010000000000000000000000010000000000288018890000000000003D0000000E536F757263652042726F777365720000000000000000000000000100000001000000000000000000000001000000000028800000000000000400FFFFFFFF00000000000000000001000000000000000100000000000000000000000100000000002880D988000000000000390000000C4275696C64204F7574707574000000000000000000000000010000000100000000000000000000000100000000002880E38B000000000000410000000B46696E64204F75747075740000000000000000000000000100000001000000000000000000000001000000000001800000000001000000FFFFFFFF0000000000000000000000000001000000010000000180FB7F0000000000001B000000000000000000000000000000000100000001000000000000000446696C6572030000</Data>
</Buttons>
<OriginalItems>
<Len>1423</Len>
@ -2586,65 +2586,11 @@
<MDIGroup>
<Size>100</Size>
<ActiveTab>0</ActiveTab>
<Doc>
<Name>..\..\..\Source\queue.c</Name>
<ColumnNumber>2</ColumnNumber>
<TopLine>23</TopLine>
<CurrentLine>68</CurrentLine>
<Folding>1</Folding>
<ContractedFolders></ContractedFolders>
<PaneID>0</PaneID>
</Doc>
<Doc>
<Name>..\FreeRTOSConfig.h</Name>
<ColumnNumber>0</ColumnNumber>
<TopLine>148</TopLine>
<CurrentLine>192</CurrentLine>
<Folding>1</Folding>
<ContractedFolders></ContractedFolders>
<PaneID>0</PaneID>
</Doc>
<Doc>
<Name>.\startup_ARMCM4.S</Name>
<ColumnNumber>0</ColumnNumber>
<TopLine>125</TopLine>
<CurrentLine>139</CurrentLine>
<Folding>1</Folding>
<ContractedFolders></ContractedFolders>
<PaneID>0</PaneID>
</Doc>
<Doc>
<Name>..\main.c</Name>
<ColumnNumber>0</ColumnNumber>
<TopLine>273</TopLine>
<CurrentLine>316</CurrentLine>
<Folding>1</Folding>
<ContractedFolders></ContractedFolders>
<PaneID>0</PaneID>
</Doc>
<Doc>
<Name>C:\E\Dev\FreeRTOS\WorkingCopy\FreeRTOS\Demo\CORTEX_MPU_Simulator_Keil_GCC\GCC_Specific\sections.ld</Name>
<ColumnNumber>52</ColumnNumber>
<TopLine>13</TopLine>
<CurrentLine>4</CurrentLine>
<Folding>1</Folding>
<ContractedFolders></ContractedFolders>
<PaneID>0</PaneID>
</Doc>
<Doc>
<Name>..\..\..\Source\tasks.c</Name>
<ColumnNumber>0</ColumnNumber>
<TopLine>3596</TopLine>
<CurrentLine>3608</CurrentLine>
<Folding>1</Folding>
<ContractedFolders></ContractedFolders>
<PaneID>0</PaneID>
</Doc>
<Doc>
<Name>..\..\..\Source\portable\GCC\ARM_CM3_MPU\port.c</Name>
<ColumnNumber>0</ColumnNumber>
<TopLine>390</TopLine>
<CurrentLine>402</CurrentLine>
<TopLine>70</TopLine>
<CurrentLine>358</CurrentLine>
<Folding>1</Folding>
<ContractedFolders></ContractedFolders>
<PaneID>0</PaneID>

View file

@ -145,30 +145,23 @@
<Name>-UV1115SAE -O2983 -S0 -C0 -P00 -N00("ARM CoreSight JTAG-DP") -D00(4BA00477) -L00(4) -TO18 -TC10000000 -TP21 -TDS8007 -TDT0 -TDC1F -TIEFFFFFFFF -TIP8 -FO11 -FN1 -FC1000 -FD20000000 -FF0NEW_DEVICE -FL080000 -FS00 -FP0($$Device:ARMCM4_FP$Device\ARM\Flash\NEW_DEVICE.FLM)</Name>
</SetRegEntry>
</TargetDriverDllRegistry>
<Breakpoint>
<Bp>
<Number>0</Number>
<Type>0</Type>
<LineNumber>3619</LineNumber>
<EnabledFlag>1</EnabledFlag>
<Address>8634</Address>
<ByteObject>0</ByteObject>
<HtxType>0</HtxType>
<ManyObjects>0</ManyObjects>
<SizeOfObject>0</SizeOfObject>
<BreakByAccess>0</BreakByAccess>
<BreakIfRCount>1</BreakIfRCount>
<Filename>C:\E\Dev\FreeRTOS\WorkingCopy\FreeRTOS\Source\tasks.c</Filename>
<ExecCommand></ExecCommand>
<Expression>\\RTOSDemo\../../../Source/tasks.c\3619</Expression>
</Bp>
</Breakpoint>
<Breakpoint/>
<WatchWindow1>
<Ww>
<count>0</count>
<WinNumber>1</WinNumber>
<ItemText>xTickCount</ItemText>
</Ww>
<Ww>
<count>1</count>
<WinNumber>1</WinNumber>
<ItemText>ulStillAliveCounts</ItemText>
</Ww>
<Ww>
<count>2</count>
<WinNumber>1</WinNumber>
<ItemText>ulStatus</ItemText>
</Ww>
</WatchWindow1>
<MemoryWindow1>
<Mm>
@ -224,7 +217,7 @@
<Group>
<GroupName>System</GroupName>
<tvExp>1</tvExp>
<tvExp>0</tvExp>
<tvExpOptDlg>0</tvExpOptDlg>
<cbSel>0</cbSel>
<RteFlg>0</RteFlg>
@ -244,7 +237,7 @@
<Group>
<GroupName>main_and_config</GroupName>
<tvExp>1</tvExp>
<tvExp>0</tvExp>
<tvExpOptDlg>0</tvExpOptDlg>
<cbSel>0</cbSel>
<RteFlg>0</RteFlg>
@ -276,7 +269,7 @@
<Group>
<GroupName>FreeRTOS_Source</GroupName>
<tvExp>1</tvExp>
<tvExp>0</tvExp>
<tvExpOptDlg>0</tvExpOptDlg>
<cbSel>0</cbSel>
<RteFlg>0</RteFlg>

View file

@ -153,6 +153,11 @@ static void prvOldStyleUserModeTask( void *pvParameters );
*/
static void prvOldStylePrivilegedModeTask( void *pvParameters );
/*
* A task that is deleted by the Idle task. This is just done for code
* coverage test purposes.
*/
static void prvTaskToDelete( void *pvParameters );
/*-----------------------------------------------------------*/
/* Prototypes for other misc functions. --------------------*/
@ -176,7 +181,7 @@ static void prvDeleteMe( void ) __attribute__((noinline));
* If a reg test task detects an error it will delete itself, and in so doing
* prevent itself from sending any more 'I'm Alive' messages to the check task.
*/
static void prvSendImAlive( QueueHandle_t xHandle, unsigned long ulTaskNumber );
static void prvSendImAlive( QueueHandle_t xHandle, uint32_t ulTaskNumber );
/*
* The check task is created with access to three memory regions (plus its
@ -197,6 +202,10 @@ to gain access to the queue. See the comments in the tasks themselves for
further information. */
static QueueHandle_t xFileScopeCheckQueue = NULL;
/* Holds the handle of a task that is deleted in the idle task hook - this is
done for code coverage test purposes only. */
static TaskHandle_t xTaskToDelete = NULL;
/*-----------------------------------------------------------*/
/* Data used by the 'check' task. ---------------------------*/
@ -312,12 +321,45 @@ static TaskParameters_t xRegTest2Parameters =
/*-----------------------------------------------------------*/
/*-----------------------------------------------------------*/
/* Configures the task that is deleted. ---------------------*/
/*-----------------------------------------------------------*/
/* Define the constants used to allocate the stack of the task that is
deleted. Note that that stack size is defined in words, not bytes. */
#define mainDELETE_TASK_STACK_SIZE_WORDS 128
#define mainTASK_TO_DELETE_STACK_ALIGNMENT ( mainDELETE_TASK_STACK_SIZE_WORDS * sizeof( portSTACK_TYPE ) )
/* Declare the stack that will be used by the task that gets deleted. The
kernel will automatically create an MPU region for the stack. The stack
alignment must match its size, so if 128 words are reserved for the stack
then it must be aligned to ( 128 * 4 ) bytes. */
static portSTACK_TYPE xDeleteTaskStack[ mainDELETE_TASK_STACK_SIZE_WORDS ] mainALIGN_TO( mainTASK_TO_DELETE_STACK_ALIGNMENT );
static TaskParameters_t xTaskToDeleteParameters =
{
prvTaskToDelete, /* pvTaskCode - the function that implements the task. */
"DeleteMe", /* pcName */
mainDELETE_TASK_STACK_SIZE_WORDS, /* usStackDepth */
( void * ) NULL, /* pvParameters - this task uses the parameter to pass in a queue handle, but the queue is not created yet. */
tskIDLE_PRIORITY + 1, /* uxPriority */
xDeleteTaskStack, /* puxStackBuffer - the array to use as the task stack, as declared above. */
{ /* xRegions - this task does not use any non-stack data hence all members are zero. */
/* Base address Length Parameters */
{ 0x00, 0x00, 0x00 },
{ 0x00, 0x00, 0x00 },
{ 0x00, 0x00, 0x00 }
}
};
/*-----------------------------------------------------------*/
int main( void )
{
prvSetupHardware();
/* Create the queue used to pass "I'm alive" messages to the check task. */
xFileScopeCheckQueue = xQueueCreate( 1, sizeof( unsigned long ) );
xFileScopeCheckQueue = xQueueCreate( 1, sizeof( uint32_t ) );
/* One check task uses the task parameter to receive the queue handle.
This allows the file scope variable to be accessed from within the task.
@ -331,6 +373,11 @@ int main( void )
xTaskCreateRestricted( &xRegTest2Parameters, NULL );
xTaskCreateRestricted( &xCheckTaskParameters, NULL );
/* Create a task that does nothing but get deleted. This is done for code
coverage test purposes only. The task's handle is saved in xTaskToDelete
so it can get deleted in the idle task hook. */
xTaskCreateRestricted( &xTaskToDeleteParameters, &xTaskToDelete );
/* Create the tasks that are created using the original xTaskCreate() API
function. */
xTaskCreate( prvOldStyleUserModeTask, /* The function that implements the task. */
@ -366,9 +413,10 @@ queue variable. Take a stack copy of this before the task is set into user
mode. Once that task is in user mode the file scope queue variable will no
longer be accessible but the stack copy will. */
QueueHandle_t xQueue = xFileScopeCheckQueue;
long lMessage;
unsigned long ulStillAliveCounts[ 2 ] = { 0 };
int32_t lMessage;
uint32_t ulStillAliveCounts[ 2 ] = { 0 };
const char *pcStatusMessage = "PASS\r\n";
volatile uint32_t ulStatus = pdPASS;
/* Just to remove compiler warning. */
@ -409,12 +457,14 @@ const char *pcStatusMessage = "PASS\r\n";
/* One or both of the test tasks are no longer sending
'still alive' messages. */
pcStatusMessage = "FAIL\r\n";
/* ulStatus can be viewed (live) in the Keil watch window. */
ulStatus = pdFAIL;
( void ) ulStatus;
}
/* Print a pass/fail message to the terminal. This will be
visible in the CrossWorks IDE. */
// MPU_debug_printf( pcStatusMessage );
( void ) pcStatusMessage;
/* print pcStatusMessage here. */
( void ) pcStatusMessage;
/* Reset the count of 'still alive' messages. */
memset( ulStillAliveCounts, 0x00, sizeof( ulStillAliveCounts ) );
@ -432,7 +482,7 @@ const char *pcStatusMessage = "PASS\r\n";
static void prvTestMemoryRegions( void )
{
long l;
int32_t x;
char cTemp;
/* The check task (from which this function is called) is created in the
@ -459,10 +509,10 @@ char cTemp;
/*cPrivilegedOnlyAccessArray[ 0 ] = 'a';*/
/* The read/write array can still be successfully read and written. */
for( l = 0; l < mainREAD_WRITE_ALIGN_SIZE; l++ )
for( x = 0; x < mainREAD_WRITE_ALIGN_SIZE; x++ )
{
cReadWriteArray[ l ] = 'a';
if( cReadWriteArray[ l ] != 'a' )
cReadWriteArray[ x ] = 'a';
if( cReadWriteArray[ x ] != 'a' )
{
/* Something unexpected happened. Delete this task so the error is
apparent (no output will be displayed). */
@ -477,9 +527,9 @@ char cTemp;
/* cReadWriteArray[ mainREAD_WRITE_ALIGN_SIZE ] = 0x00; */
/* The read only array can be successfully read... */
for( l = 0; l < mainREAD_ONLY_ALIGN_SIZE; l++ )
for( x = 0; x < mainREAD_ONLY_ALIGN_SIZE; x++ )
{
cTemp = cReadOnlyArray[ l ];
cTemp = cReadOnlyArray[ x ];
}
/* ...but cannot be written. Uncomment the following line to test. */
@ -645,15 +695,26 @@ QueueHandle_t xQueue = ( QueueHandle_t ) pvParameters;
}
/*-----------------------------------------------------------*/
static void prvTaskToDelete( void *pvParameters )
{
/* Remove compiler warnings about unused parameters. */
( void ) pvParameters;
/* This task has nothing to do - for code coverage test purposes it is
deleted by the Idle task. */
vTaskSuspend( NULL );
}
/*-----------------------------------------------------------*/
void vApplicationIdleHook( void )
{
extern unsigned long __SRAM_segment_end__[];
extern unsigned long __privileged_data_start__[];
extern unsigned long __privileged_data_end__[];
extern unsigned long __FLASH_segment_start__[];
extern unsigned long __FLASH_segment_end__[];
volatile unsigned long *pul;
volatile unsigned long ulReadData;
extern uint32_t __SRAM_segment_end__[];
extern uint32_t __privileged_data_start__[];
extern uint32_t __privileged_data_end__[];
extern uint32_t __FLASH_segment_start__[];
extern uint32_t __FLASH_segment_end__[];
volatile uint32_t *pul;
volatile uint32_t ulReadData;
/* The idle task, and therefore this function, run in Supervisor mode and
can therefore access all memory. Try reading from corners of flash and
@ -685,26 +746,34 @@ volatile unsigned long ulReadData;
/* pul = __SRAM_segment_end__ + 1;
ulReadData = *pul; */
/* One task is created purely so it can be deleted - done for code coverage
test purposes. */
if( xTaskToDelete != NULL )
{
vTaskDelete( xTaskToDelete );
xTaskToDelete = NULL;
}
( void ) ulReadData;
}
/*-----------------------------------------------------------*/
static void prvOldStyleUserModeTask( void *pvParameters )
{
extern unsigned long __privileged_data_start__[];
extern unsigned long __privileged_data_end__[];
extern unsigned long __SRAM_segment_end__[];
extern unsigned long __privileged_functions_end__[];
extern unsigned long __FLASH_segment_start__[];
extern unsigned long __FLASH_segment_end__[];
//const volatile unsigned long *pulStandardPeripheralRegister = ( volatile unsigned long * ) 0x400FC0C4;
volatile unsigned long *pul;
volatile unsigned long ulReadData;
extern uint32_t __privileged_data_start__[];
extern uint32_t __privileged_data_end__[];
extern uint32_t __SRAM_segment_end__[];
extern uint32_t __privileged_functions_end__[];
extern uint32_t __FLASH_segment_start__[];
extern uint32_t __FLASH_segment_end__[];
/*const volatile uint32_t *pulStandardPeripheralRegister = ( volatile uint32_t * ) 0x40000000;*/
volatile uint32_t *pul;
volatile uint32_t ulReadData;
/* The following lines are commented out to prevent the unused variable
compiler warnings when the tests that use the variable are also commented out.
extern unsigned long __privileged_functions_start__[];
const volatile unsigned long *pulSystemPeripheralRegister = ( volatile unsigned long * ) 0xe000e014; */
compiler warnings when the tests that use the variable are also commented out. */
/*extern uint32_t __privileged_functions_start__[];
const volatile uint32_t *pulSystemPeripheralRegister = ( volatile uint32_t * ) 0xe000e014;*/
( void ) pvParameters;
@ -727,29 +796,29 @@ const volatile unsigned long *pulSystemPeripheralRegister = ( volatile unsigned
ulReadData = *pul;
/* Standard peripherals are accessible. */
// ulReadData = *pulStandardPeripheralRegister;
/*ulReadData = *pulStandardPeripheralRegister;*/
/* System peripherals are not accessible. Uncomment the following line
to test. Also uncomment the declaration of pulSystemPeripheralRegister
at the top of this function. */
/* ulReadData = *pulSystemPeripheralRegister; */
at the top of this function.
ulReadData = *pulSystemPeripheralRegister; */
/* Reading from anywhere inside the privileged Flash or RAM should cause a
fault. This can be tested by uncommenting any of the following pairs of
lines. Also uncomment the declaration of __privileged_functions_start__
at the top of this function. */
/* pul = __privileged_functions_start__;
ulReadData = *pul; */
/*pul = __privileged_functions_start__;
ulReadData = *pul;*/
/* pul = __privileged_functions_end__ - 1;
ulReadData = *pul; */
/*pul = __privileged_functions_end__ - 1;
ulReadData = *pul;*/
/* pul = __privileged_data_start__;
ulReadData = *pul; */
/*pul = __privileged_data_start__;
ulReadData = *pul;*/
/* pul = __privileged_data_end__ - 1;
ulReadData = *pul; */
/*pul = __privileged_data_end__ - 1;
ulReadData = *pul;*/
/* Must not just run off the end of a task function, so delete this task.
Note that because this task was created using xTaskCreate() the stack was
@ -762,17 +831,17 @@ const volatile unsigned long *pulSystemPeripheralRegister = ( volatile unsigned
static void prvOldStylePrivilegedModeTask( void *pvParameters )
{
extern unsigned long __privileged_data_start__[];
extern unsigned long __privileged_data_end__[];
extern unsigned long __SRAM_segment_end__[];
extern unsigned long __privileged_functions_start__[];
extern unsigned long __privileged_functions_end__[];
extern unsigned long __FLASH_segment_start__[];
extern unsigned long __FLASH_segment_end__[];
volatile unsigned long *pul;
volatile unsigned long ulReadData;
const volatile unsigned long *pulSystemPeripheralRegister = ( volatile unsigned long * ) 0xe000e014; /* Systick */
//const volatile unsigned long *pulStandardPeripheralRegister = ( volatile unsigned long * ) 0x400FC0C4;
extern uint32_t __privileged_data_start__[];
extern uint32_t __privileged_data_end__[];
extern uint32_t __SRAM_segment_end__[];
extern uint32_t __privileged_functions_start__[];
extern uint32_t __privileged_functions_end__[];
extern uint32_t __FLASH_segment_start__[];
extern uint32_t __FLASH_segment_end__[];
volatile uint32_t *pul;
volatile uint32_t ulReadData;
const volatile uint32_t *pulSystemPeripheralRegister = ( volatile uint32_t * ) 0xe000e014; /* Systick */
/*const volatile uint32_t *pulStandardPeripheralRegister = ( volatile uint32_t * ) 0x40000000;*/
( void ) pvParameters;
@ -808,7 +877,7 @@ const volatile unsigned long *pulSystemPeripheralRegister = ( volatile unsigned
/* Finally, accessing both System and normal peripherals should both be
possible. */
ulReadData = *pulSystemPeripheralRegister;
// ulReadData = *pulStandardPeripheralRegister;
/*ulReadData = *pulStandardPeripheralRegister;*/
/* Must not just run off the end of a task function, so delete this task.
Note that because this task was created using xTaskCreate() the stack was
@ -825,7 +894,7 @@ static void prvDeleteMe( void )
}
/*-----------------------------------------------------------*/
static void prvSendImAlive( QueueHandle_t xHandle, unsigned long ulTaskNumber )
static void prvSendImAlive( QueueHandle_t xHandle, uint32_t ulTaskNumber )
{
if( xHandle != NULL )
{
@ -841,9 +910,9 @@ static void prvSetupHardware( void )
void vApplicationTickHook( void )
{
static unsigned long ulCallCount;
const unsigned long ulCallsBetweenSends = 5000 / portTICK_PERIOD_MS;
const unsigned long ulMessage = mainPRINT_SYSTEM_STATUS;
static uint32_t ulCallCount;
const uint32_t ulCallsBetweenSends = 5000UL / configTICK_RATE_HZ;
const uint32_t ulMessage = mainPRINT_SYSTEM_STATUS;
portBASE_TYPE xDummy;
/* If configUSE_TICK_HOOK is set to 1 then this function will get called
@ -887,26 +956,26 @@ void vApplicationMallocFailedHook( void )
}
/*-----------------------------------------------------------*/
void hard_fault_handler(unsigned int * hardfault_args)
void hard_fault_handler( uint32_t * hardfault_args )
{
volatile unsigned int stacked_r0;
volatile unsigned int stacked_r1;
volatile unsigned int stacked_r2;
volatile unsigned int stacked_r3;
volatile unsigned int stacked_r12;
volatile unsigned int stacked_lr;
volatile unsigned int stacked_pc;
volatile unsigned int stacked_psr;
volatile uint32_t stacked_r0;
volatile uint32_t stacked_r1;
volatile uint32_t stacked_r2;
volatile uint32_t stacked_r3;
volatile uint32_t stacked_r12;
volatile uint32_t stacked_lr;
volatile uint32_t stacked_pc;
volatile uint32_t stacked_psr;
stacked_r0 = ((unsigned long) hardfault_args[0]);
stacked_r1 = ((unsigned long) hardfault_args[1]);
stacked_r2 = ((unsigned long) hardfault_args[2]);
stacked_r3 = ((unsigned long) hardfault_args[3]);
stacked_r0 = ((uint32_t) hardfault_args[0]);
stacked_r1 = ((uint32_t) hardfault_args[1]);
stacked_r2 = ((uint32_t) hardfault_args[2]);
stacked_r3 = ((uint32_t) hardfault_args[3]);
stacked_r12 = ((unsigned long) hardfault_args[4]);
stacked_lr = ((unsigned long) hardfault_args[5]);
stacked_pc = ((unsigned long) hardfault_args[6]);
stacked_psr = ((unsigned long) hardfault_args[7]);
stacked_r12 = ((uint32_t) hardfault_args[4]);
stacked_lr = ((uint32_t) hardfault_args[5]);
stacked_pc = ((uint32_t) hardfault_args[6]);
stacked_psr = ((uint32_t) hardfault_args[7]);
/* Inspect stacked_pc to locate the offending instruction. */
for( ;; );
@ -939,7 +1008,7 @@ void HardFault_Handler( void )
}
/*-----------------------------------------------------------*/
void MPU_Fault_ISR( void ) __attribute__((naked));
void MemManage_Handler( void ) __attribute__((naked));
void MemManage_Handler( void )
{
__asm volatile
@ -957,5 +1026,51 @@ void MemManage_Handler( void )
/*-----------------------------------------------------------*/
#warning Why must configSUPPORT_STATIC_ALLOCATION be set to 1 when the MPU is used?
#warning Linker script is crippled for use with the simulator.
/* configUSE_STATIC_ALLOCATION is set to 1, so the application must provide an
implementation of vApplicationGetIdleTaskMemory() to provide the memory that is
used by the Idle task. */
void vApplicationGetIdleTaskMemory( StaticTask_t **ppxIdleTaskTCBBuffer, StackType_t **ppxIdleTaskStackBuffer, uint32_t *pulIdleTaskStackSize )
{
/* If the buffers to be provided to the Idle task are declared inside this
function then they must be declared static - otherwise they will be allocated on
the stack and so not exists after this function exits. */
static StaticTask_t xIdleTaskTCB;
static StackType_t uxIdleTaskStack[ configMINIMAL_STACK_SIZE ];
/* Pass out a pointer to the StaticTask_t structure in which the Idle task's
state will be stored. */
*ppxIdleTaskTCBBuffer = &xIdleTaskTCB;
/* Pass out the array that will be used as the Idle task's stack. */
*ppxIdleTaskStackBuffer = uxIdleTaskStack;
/* Pass out the size of the array pointed to by *ppxIdleTaskStackBuffer.
Note that, as the array is necessarily of type StackType_t,
configMINIMAL_STACK_SIZE is specified in words, not bytes. */
*pulIdleTaskStackSize = configMINIMAL_STACK_SIZE;
}
/*-----------------------------------------------------------*/
/* configUSE_STATIC_ALLOCATION and configUSE_TIMERS are both set to 1, so the
application must provide an implementation of vApplicationGetTimerTaskMemory()
to provide the memory that is used by the Timer service task. */
void vApplicationGetTimerTaskMemory( StaticTask_t **ppxTimerTaskTCBBuffer, StackType_t **ppxTimerTaskStackBuffer, uint32_t *pulTimerTaskStackSize )
{
/* If the buffers to be provided to the Timer task are declared inside this
function then they must be declared static - otherwise they will be allocated on
the stack and so not exists after this function exits. */
static StaticTask_t xTimerTaskTCB;
static StackType_t uxTimerTaskStack[ configTIMER_TASK_STACK_DEPTH ];
/* Pass out a pointer to the StaticTask_t structure in which the Timer
task's state will be stored. */
*ppxTimerTaskTCBBuffer = &xTimerTaskTCB;
/* Pass out the array that will be used as the Timer task's stack. */
*ppxTimerTaskStackBuffer = uxTimerTaskStack;
/* Pass out the size of the array pointed to by *ppxTimerTaskStackBuffer.
Note that, as the array is necessarily of type StackType_t,
configMINIMAL_STACK_SIZE is specified in words, not bytes. */
*pulTimerTaskStackSize = configTIMER_TASK_STACK_DEPTH;
}