Replace use of legacy portTYPE macros from old demos and standard demo files.

This commit is contained in:
Richard Barry 2013-12-29 14:49:03 +00:00
parent 3e20aa7d60
commit b54158d1dc
123 changed files with 736 additions and 736 deletions

View file

@ -123,12 +123,12 @@ to PDR09 (SEG1) are used by the prvFlashCoRoutine() and PDR00 (SEG2) are used by
/*
* The 'fixed delay' co-routine as described at the top of the file.
*/
static void prvFixedDelayCoRoutine( xCoRoutineHandle xHandle, unsigned portBASE_TYPE uxIndex );
static void prvFixedDelayCoRoutine( CoRoutineHandle_t xHandle, unsigned portBASE_TYPE uxIndex );
/*
* The 'flash' co-routine as described at the top of the file.
*/
static void prvFlashCoRoutine( xCoRoutineHandle xHandle, unsigned portBASE_TYPE uxIndex );
static void prvFlashCoRoutine( CoRoutineHandle_t xHandle, unsigned portBASE_TYPE uxIndex );
/* The queue used to pass data between the 'fixed delay' co-routines and the
'flash' co-routine. */
@ -168,7 +168,7 @@ unsigned portBASE_TYPE uxIndex;
}
/*-----------------------------------------------------------*/
static void prvFixedDelayCoRoutine( xCoRoutineHandle xHandle, unsigned portBASE_TYPE uxIndex )
static void prvFixedDelayCoRoutine( CoRoutineHandle_t xHandle, unsigned portBASE_TYPE uxIndex )
{
/* Even though this is a co-routine the xResult variable does not need to be
static as we do not need it to maintain its state between blocks. */
@ -209,7 +209,7 @@ static const portTickType xFlashRates[ crfMAX_FLASH_TASKS ] = { 150 / portTICK_R
}
/*-----------------------------------------------------------*/
static void prvFlashCoRoutine( xCoRoutineHandle xHandle, unsigned portBASE_TYPE uxIndex )
static void prvFlashCoRoutine( CoRoutineHandle_t xHandle, unsigned portBASE_TYPE uxIndex )
{
/* Even though this is a co-routine the variable do not need to be
static as we do not need it to maintain their state between blocks. */

View file

@ -130,7 +130,7 @@
#define mainGENERIC_QUEUE_PRIORITY ( tskIDLE_PRIORITY )
/* Baud rate used by the COM test tasks. */
#define mainCOM_TEST_BAUD_RATE ( ( unsigned portLONG ) 19200 )
#define mainCOM_TEST_BAUD_RATE ( ( unsigned long ) 19200 )
/* The frequency at which the 'Check' tasks executes. See the comments at the
top of the page. When the system is operating error free the 'Check' task
@ -167,7 +167,7 @@ static void prvErrorChecks( void *pvParameters );
* Called by the Check task. Returns pdPASS if all the other tasks are found
* to be operating without error - otherwise returns pdFAIL.
*/
static portSHORT prvCheckOtherTasksAreStillRunning( void );
static short prvCheckOtherTasksAreStillRunning( void );
/*
* Setup the microcontroller as used by this demo.
@ -187,7 +187,7 @@ static void vSecondRegisterTestTask( void *pvParameters );
/* The variable that is set to true should an error be found in one of the
register test tasks. */
unsigned portLONG ulRegTestError = pdFALSE;
unsigned long ulRegTestError = pdFALSE;
/*---------------------------------------------------------------------------*/
@ -274,7 +274,7 @@ portTickType xDelayPeriod = mainNO_ERROR_CHECK_DELAY, xLastExecutionTime;
}
/*-----------------------------------------------------------*/
static portSHORT prvCheckOtherTasksAreStillRunning( void )
static short prvCheckOtherTasksAreStillRunning( void )
{
portBASE_TYPE lReturn = pdPASS;
@ -405,7 +405,7 @@ static void prvSetupHardware( void )
static void vFirstRegisterTestTask( void *pvParameters )
{
extern volatile unsigned portLONG ulCriticalNesting;
extern volatile unsigned long ulCriticalNesting;
/* Fills the registers with known values (different to the values
used in vSecondRegisterTestTask()), then checks that the registers still
@ -503,7 +503,7 @@ extern volatile unsigned portLONG ulCriticalNesting;
static void vSecondRegisterTestTask( void *pvParameters )
{
extern volatile unsigned portLONG ulCriticalNesting;
extern volatile unsigned long ulCriticalNesting;
/* Fills the registers with known values (different to the values
used in vFirstRegisterTestTask()), then checks that the registers still

View file

@ -70,8 +70,8 @@
#define partstNUM_LEDs 8
static unsigned portCHAR sState[ partstNUM_LEDs ] = { pdFALSE };
static unsigned portCHAR sState1[ partstNUM_LEDs ] = { pdFALSE };
static unsigned char sState[ partstNUM_LEDs ] = { pdFALSE };
static unsigned char sState1[ partstNUM_LEDs ] = { pdFALSE };
/*-----------------------------------------------------------*/

View file

@ -87,17 +87,17 @@ static xQueueHandle xRxedChars;
/* The queue used to hold characters waiting transmission. */
static xQueueHandle xCharsForTx;
static volatile portSHORT sTHREEmpty;
static volatile short sTHREEmpty;
/*-----------------------------------------------------------*/
xComPortHandle xSerialPortInitMinimal( unsigned portLONG ulWantedBaud, unsigned portBASE_TYPE uxQueueLength )
xComPortHandle xSerialPortInitMinimal( unsigned long ulWantedBaud, unsigned portBASE_TYPE uxQueueLength )
{
portENTER_CRITICAL();
{
/* Create the queues used by the com test task. */
xRxedChars = xQueueCreate( uxQueueLength, ( unsigned portBASE_TYPE ) sizeof( signed portCHAR ) );
xCharsForTx = xQueueCreate( uxQueueLength, ( unsigned portBASE_TYPE ) sizeof( signed portCHAR ) );
xRxedChars = xQueueCreate( uxQueueLength, ( unsigned portBASE_TYPE ) sizeof( signed char ) );
xCharsForTx = xQueueCreate( uxQueueLength, ( unsigned portBASE_TYPE ) sizeof( signed char ) );
/* Initialize UART asynchronous mode */
BGR02 = configPER_CLOCK_HZ / ulWantedBaud;
@ -120,7 +120,7 @@ xComPortHandle xSerialPortInitMinimal( unsigned portLONG ulWantedBaud, unsigned
}
/*-----------------------------------------------------------*/
signed portBASE_TYPE xSerialGetChar( xComPortHandle pxPort, signed portCHAR *pcRxedChar, portTickType xBlockTime )
signed portBASE_TYPE xSerialGetChar( xComPortHandle pxPort, signed char *pcRxedChar, portTickType xBlockTime )
{
/* Get the next character from the buffer. Return false if no characters
are available, or arrive before xBlockTime expires. */
@ -135,7 +135,7 @@ signed portBASE_TYPE xSerialGetChar( xComPortHandle pxPort, signed portCHAR *pcR
}
/*-----------------------------------------------------------*/
signed portBASE_TYPE xSerialPutChar( xComPortHandle pxPort, signed portCHAR cOutChar, portTickType xBlockTime )
signed portBASE_TYPE xSerialPutChar( xComPortHandle pxPort, signed char cOutChar, portTickType xBlockTime )
{
signed portBASE_TYPE xReturn;
@ -191,7 +191,7 @@ signed portBASE_TYPE xReturn;
*/
__interrupt void UART2_RxISR (void)
{
signed portCHAR cChar;
signed char cChar;
portBASE_TYPE xHigherPriorityTaskWoken = pdFALSE;
/* Get the character from the UART and post it on the queue of Rxed
@ -216,7 +216,7 @@ signed portBASE_TYPE xReturn;
*/
__interrupt void UART2_TxISR (void)
{
signed portCHAR cChar;
signed char cChar;
signed portBASE_TYPE xTaskWoken = pdFALSE;
/* The previous character has been transmitted. See if there are any

View file

@ -63,7 +63,7 @@ char Getch5( void ) /* waits for and returns incomming char */
void Puts5( const char *Name5 ) /* Puts a String to UART */
{
volatile portSHORT i, len;
volatile short i, len;
len = strlen( Name5 );
for( i = 0; i < len; i++ ) /* go through string */
@ -79,7 +79,7 @@ void Puts5( const char *Name5 ) /* Puts a String to UART */
void Puthex5( unsigned long n, unsigned char digits )
{
unsigned portCHAR digit = 0, div = 0, i;
unsigned char digit = 0, div = 0, i;
div = ( 4 * (digits - 1) ); /* init shift divisor */
for( i = 0; i < digits; i++ )
@ -92,8 +92,8 @@ void Puthex5( unsigned long n, unsigned char digits )
void Putdec5( unsigned long x, int digits )
{
portSHORT i;
portCHAR buf[10], sign = 1;
short i;
char buf[10], sign = 1;
if( digits < 0 )
{ /* should be print of zero? */
@ -139,10 +139,10 @@ void vUtilityStartTraceTask( unsigned portBASE_TYPE uxPriority )
static void vUART5Task( void *pvParameters )
{
static portCHAR buff[ 900 ] = { 0 };
unsigned portLONG trace_len, j;
static char buff[ 900 ] = { 0 };
unsigned long trace_len, j;
unsigned portCHAR ch;
unsigned char ch;
SSR05_RIE = 1;
Puts5( "\n -------------MB91467D FreeRTOS DEMO Task List and Trace Utility----------- \n" );
@ -210,7 +210,7 @@ static void vUART5Task( void *pvParameters )
__interrupt void UART5_RxISR( void )
{
unsigned portCHAR ch;
unsigned char ch;
portBASE_TYPE xHigherPriorityTaskWoken = pdFALSE;
ch = RDR05;

View file

@ -49,7 +49,7 @@ static void prvWatchdogTask ( void *pvParameters )
* The below function creates hardware watchdog task.
*---------------------------------------------------------------------------*/
#if WATCHDOG == WTC_IN_TASK
void vStartWatchdogTask( unsigned portSHORT uxPriority )
void vStartWatchdogTask( unsigned short uxPriority )
{
xTaskCreate( prvWatchdogTask , "KickWTC", portMINIMAL_STACK_SIZE, ( void * ) NULL, uxPriority, ( xTaskHandle * ) NULL );
}