cleanup and functions.  red to yellow fctn