This commit is contained in:
hathach
2012-12-18 15:08:30 +07:00
parent 50c89192d8
commit ec4a3f6048
35 changed files with 1570 additions and 3637 deletions

View File

@@ -10,25 +10,20 @@
__CRP const unsigned int CRP_WORD = CRP_NO_CRP ;
#endif
volatile uint32_t system_tick = 0;
void SysTick_Handler (void)
{
system_tick++;
}
int main(void)
{
uint32_t current_tick = system_tick;
uint32_t current_tick = system_ticks;
board_init();
tusb_init(0);
while (1)
{
if (current_tick + 1000 < system_tick)
if (current_tick + 1000 < system_ticks)
{
current_tick += 1000;
board_leds(0x03, (current_tick/1000)%2); /* Toggle LED once per second */
printf("hello world");
}
}
}