diff --git a/src/platform/lm3s/platform.c b/src/platform/lm3s/platform.c index 69be5eb6..9532921e 100644 --- a/src/platform/lm3s/platform.c +++ b/src/platform/lm3s/platform.c @@ -8,6 +8,7 @@ #include #include #include +#include // Platform specific includes #include "hw_ints.h" @@ -37,7 +38,7 @@ static int uart_recv() // **************************************************************************** // Platform initialization -static u32 timer_base[] = { TIMER0_BASE, TIMER1_BASE, TIMER2_BASE, TIMER3_BASE }; +static const u32 timer_base[] = { TIMER0_BASE, TIMER1_BASE, TIMER2_BASE, TIMER3_BASE }; int platform_init() { @@ -92,6 +93,14 @@ int platform_pio_has_port( unsigned port ) return port <= 6; } +const char* platform_pio_get_prefix( unsigned port ) +{ + static char c[ 3 ]; + + sprintf( c, "P%c", ( char )( port + 'A' ) ); + return c; +} + int platform_pio_has_pin( unsigned port, unsigned pin ) { if( port <= 3 ) @@ -343,6 +352,11 @@ const char* platform_pd_get_name() return "LM3S"; } +const char* platform_pd_cpu_name() +{ + return "LM3S8962"; +} + u32 platform_pd_get_cpu_frequency() { return SysCtlClockGet();