on_o = show_debug();

or in a loop

if(key_o)
{
show_debug();
while(key_o){wait(1);}
}