updated stuff to smart.c
added more to smart_control fcn