bug: you must set_mode(0)first before you reset set_mode(1)
bug: you must set_mode(0)first before you reset set_mode(1)