added delay() to drive functions