* added debug functionality
* fixed mode switching by rc control