[bsp] Add IAR EWARM project template for SCONS project auto generation.

This commit is contained in:
ArdaFu 2014-07-21 19:09:15 +08:00
parent d1a4f2e8fe
commit b21c35df63
7 changed files with 1917 additions and 10 deletions

View File

@ -61,6 +61,7 @@ extern void HardFault_Handler(void);
*/
void rt_hw_board_init()
{
MAP_IntMasterDisable();
IntRegister(FAULT_HARD, HardFault_Handler);
IntRegister(FAULT_PENDSV, PendSV_Handler);
IntRegister(FAULT_SYSTICK, SysTick_Handler);
@ -87,7 +88,7 @@ void rt_hw_board_init()
MAP_SysTickEnable();
/* set pend exception priority */
IntPrioritySet(FAULT_PENDSV, (1 << 5) - 1);
//IntPrioritySet(FAULT_PENDSV, (1 << 5) - 1);
/*init uart device*/
rt_hw_uart_init();

View File

@ -36,7 +36,7 @@ typedef struct hw_uart_device
static rt_err_t hw_configure(struct rt_serial_device *serial, struct serial_configure *cfg)
{
uint32_t config;
uint32_t config = 0;
hw_uart_t* uart;
RT_ASSERT(serial != RT_NULL);
uart = mUartGetHwPtr(serial);
@ -206,7 +206,7 @@ int rt_hw_uart_init(void)
MAP_SysCtlPeripheralEnable(SYSCTL_PERIPH_UART0);
/* preemption = 1, sub-priority = 1 */
IntPrioritySet(INT_UART0, ((0x01 << 5) | 0x01));
//IntPrioritySet(INT_UART0, ((0x01 << 5) | 0x01));
/* Enable Interrupt for UART channel */
UARTIntRegister(uart->hw_base, UART0_IRQHandler);

View File

@ -50,7 +50,10 @@ static void IntDefaultHandler(void);
//
//*****************************************************************************
extern void __iar_program_start(void);
extern void PendSV_Handler(void);
extern void SysTick_Handler(void);
extern void UART0_IRQHandler(void);
extern void HardFault_Handler(void);
//*****************************************************************************
//
// Reserve space for the system stack.
@ -84,7 +87,7 @@ __root const uVectorEntry __vector_table[] @ ".intvec" =
// The initial stack pointer
ResetISR, // The reset handler
NmiSR, // The NMI handler
FaultISR, // The hard fault handler
HardFault_Handler, // The hard fault handler
IntDefaultHandler, // The MPU fault handler
IntDefaultHandler, // The bus fault handler
IntDefaultHandler, // The usage fault handler
@ -95,14 +98,14 @@ __root const uVectorEntry __vector_table[] @ ".intvec" =
IntDefaultHandler, // SVCall handler
IntDefaultHandler, // Debug monitor handler
0, // Reserved
IntDefaultHandler, // The PendSV handler
IntDefaultHandler, // The SysTick handler
PendSV_Handler, //IntDefaultHandler, // The PendSV handler
SysTick_Handler,//IntDefaultHandler, // The SysTick handler
IntDefaultHandler, // GPIO Port A
IntDefaultHandler, // GPIO Port B
IntDefaultHandler, // GPIO Port C
IntDefaultHandler, // GPIO Port D
IntDefaultHandler, // GPIO Port E
IntDefaultHandler, // UART0 Rx and Tx
UART0_IRQHandler, //IntDefaultHandler, // UART0 Rx and Tx
IntDefaultHandler, // UART1 Rx and Tx
IntDefaultHandler, // SSI0 Rx and Tx
IntDefaultHandler, // I2C0 Master and Slave

View File

@ -45,6 +45,8 @@ extern int main(void);
extern void SysTick_Handler(void);
extern void PendSV_Handler(void);
extern void UART0_IRQHandler(void);
extern void HardFault_Handler(void);
//*****************************************************************************
//
// Reserve space for the system stack.
@ -65,7 +67,7 @@ void (* const g_pfnVectors[])(void) =
// The initial stack pointer
ResetISR, // The reset handler
NmiSR, // The NMI handler
FaultISR, // The hard fault handler
HardFault_Handler, // The hard fault handler
IntDefaultHandler, // The MPU fault handler
IntDefaultHandler, // The bus fault handler
IntDefaultHandler, // The usage fault handler
@ -83,7 +85,7 @@ void (* const g_pfnVectors[])(void) =
IntDefaultHandler, // GPIO Port C
IntDefaultHandler, // GPIO Port D
IntDefaultHandler, // GPIO Port E
IntDefaultHandler, // UART0 Rx and Tx
UART0_IRQHandler, // UART0 Rx and Tx
IntDefaultHandler, // UART1 Rx and Tx
IntDefaultHandler, // SSI0 Rx and Tx
IntDefaultHandler, // I2C0 Master and Slave

1889
bsp/tm4c129x/template.ewp Normal file

File diff suppressed because it is too large Load Diff

10
bsp/tm4c129x/template.eww Normal file
View File

@ -0,0 +1,10 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<workspace>
<project>
<path>$WS_DIR$\template.ewp</path>
</project>
<batchBuild/>
</workspace>

View File

@ -76,3 +76,5 @@ place at start of SRAM { section VTABLE };
// Place all read/write items into SRAM.
//
place in SRAM { readwrite, block HEAP };
keep { section FSymTab };
keep { section VSymTab };