added debug for serial