Added ping routine to prevent app sleep