int main(int argc, char* argv[]) { const char* title = "\nam18x library for rtc!\n"; arm_intr_enable(); systick_start(); printk(title); printk("tary, compiled date : %s %s\n", __DATE__, __TIME__); rtc_operation(); printk("\n"); arm_intr_disable(); return 0; }
/* * Reset the device. */ static int reboot_cmd (void *arg, Tcl_Interp *interp, int argc, unsigned char **argv) { stream_t *stream = arg; int x; puts (stream, "Rebooting...\n\n"); fflush (stream); timer_delay (&timer, 200); /* Light LINK led. */ control_link_led (1); arm_intr_disable (&x); for (;;) continue; return 0; }