             // Check if card has been changed
             // OK Beep + Set credits on vending machine
             Serial.print("S");
-            uint16_t number = current_credits;            // 0001 0110 0100 0111
-            uint16_t mask   = B11111111;          // 0000 0000 1111 1111
-            uint8_t first_half   = number >> 8;   // >>>> >>>> 0001 0110
-            uint8_t sencond_half = number & mask; // ____ ____ 0100 0111
-            Serial.write(sencond_half);
-            Serial.write(first_half);
+            char error = rfid_transmit(current_credits);
+            if(error != 0){
+              // Could not update machine credits - attempt to save credits to card again!
+              card.credits = current_credits;
+              updateAndVerify(addr,card);
+            }
           } else {
             // ERR Beep + display "ERR  EEPROM BAD" ?
             //Serial.println("ERR  EEPROM BAD");
-            Serial.println("B");
+            Serial.print("B");
             // Halt PICC
             mfrc522.PICC_HaltA();
             // Return

          if(card.credits == 0){
            // ERR Beep + display "NO CREDITS"?
            //Serial.println("NO CREDITS - KNOWN CARD");
            Serial.println("N");
            // Halt PICC
            mfrc522.PICC_HaltA();
            // Return

  EEPROM_updateAnything(addr,card);
  if(EEPROM_compareAnything(addr,card)){
    //Serial.print("Update OK - new credits:");
    //Serial.println(card.credits);
    return true;
  }
  //Serial.print("Update verify error at address: ");
