For RL78GCC port/demo:

- Added YRDKRL78G14 build configuration.
- Runs provided the dynamic priority tasks are not started.
- Does not run with the debugger connected.
This commit is contained in:
Richard Barry 2013-03-04 20:04:02 +00:00
parent fba04057ec
commit 08b959f143
10 changed files with 365 additions and 57 deletions

View file

@ -150,9 +150,9 @@ unsigned long *pulLocal;
/* These values are just spacers. The return address of the function
would normally be written here. */
*pxTopOfStack = ( portSTACK_TYPE ) 0xcdcd;
*pxTopOfStack = ( portSTACK_TYPE ) 0x00;
pxTopOfStack--;
*pxTopOfStack = ( portSTACK_TYPE ) 0xcdcd;
*pxTopOfStack = ( portSTACK_TYPE ) 0x00;
pxTopOfStack--;
/* The start address / PSW value is also written in as a 32bit value,
@ -186,6 +186,29 @@ unsigned long *pulLocal;
}
#endif
#ifdef This_was_an_alternative_to_the_two_above
/* Parameters are passed in on the stack. */
*pxTopOfStack = ( portSTACK_TYPE ) pvParameters;
pxTopOfStack--;
#warning Why is the offset necessary? Presumably because the parameter could be 20 bits.
pxTopOfStack--;
pxTopOfStack--;
/* Task function address is written to the stack first. As it is
written as a 32bit value a space is left on the stack for the second
two bytes. */
pxTopOfStack--;
/* Task function start address combined with the PSW. */
pulLocal = ( unsigned long * ) pxTopOfStack;
*pulLocal = ( ( ( unsigned long ) pxCode ) | ( portPSW << 24UL ) );
pxTopOfStack--;
/* An initial value for the AX register. */
*pxTopOfStack = ( portSTACK_TYPE ) 0xaaaa;
pxTopOfStack--;
#endif
/* An initial value for the HL register. */
*pxTopOfStack = ( portSTACK_TYPE ) 0x2222;
pxTopOfStack--;

View file

@ -99,11 +99,12 @@ extern "C" {
#define portSTACK_TYPE unsigned short
#define portBASE_TYPE short
#if __DATA_MODEL__ == __DATA_MODEL_FAR__
#define portPOINTER_SIZE_TYPE unsigned long
#else
#define portPOINTER_SIZE_TYPE unsigned short
#endif
//_RB_#if __DATA_MODEL__ == __DATA_MODEL_FAR__
// #define portPOINTER_SIZE_TYPE unsigned long
//#else
// #define portPOINTER_SIZE_TYPE unsigned short
//#endif
#define portPOINTER_SIZE_TYPE unsigned short
#if ( configUSE_16_BIT_TICKS == 1 )