Exemplo n.º 1
0
/** Check for debug input periodically */
void db_periodic (void)
{
#ifdef CONFIG_BPT
	if (!in_test && button_check (SW_ESCAPE))
		bpt_stop ();
#endif

#ifdef CONFIG_DEBUG_INPUT
	if (pinio_debug_read_ready ())
	{
		char c = pinio_debug_read ();
		puts_handler = puts_debug;
		switch (c)
		{
#ifdef DEBUGGER
			case 'a':
				/* Dump all debugging information */
				db_dump_all ();
				break;
#endif

#ifdef CONFIG_BPT
			case 'p':
				/* Stop the system */
				bpt_stop ();
				break;
#endif

			default:
				break;
		}
	}
#endif /* DEBUGGER */
}
Exemplo n.º 2
0
CALLSET_ENTRY (error, init_complete)
{
#ifdef CONFIG_BPT
	if (new_fatal_error)
	{
		bpt_stop ();
		new_fatal_error = FALSE;
	}
#endif
}
Exemplo n.º 3
0
/** Check for debug input periodically */
void db_periodic (void)
{
	extern void MACHINE_DEBUGGER_HOOK (U8);

#ifdef CONFIG_BPT
	if (!in_test && button_check (SW_ESCAPE))
		bpt_stop ();
#endif

#ifdef DEBUGGER
	if (wpc_debug_read_ready ())
	{
		char c = wpc_debug_read ();
		db_puts = db_puts_orkin;
		switch (c)
		{
			case 'a':
				/* Dump all debugging information */
				db_dump_all ();
				break;

#ifdef CONFIG_BPT
			case 'p':
				/* Stop the system */
				bpt_stop ();
				break;
#endif

			default:
#ifdef MACHINE_DEBUGGER_HOOK
				/* Allow the machine to define additional commands.
				 * This function must reside in the system page. */
				MACHINE_DEBUGGER_HOOK (c);
#endif
				break;
		}
	}
#endif /* DEBUGGER */
}