reduce while loops in main to one and fix a possible CPU hog when LCDd is missing (thanks Martijn!), update comments