added some debug messages in the sd card code