added card reading fixes