   Serial.begin(UART_BAUD_RATE);
   Serial << F("YaesuTest: starting ...") << endl;
   
- #if defined (__AVR__)
-  Serial << F("Free SRAM: ") << availableMemory() << endl;
- #endif // (__AVR__)
+  Serial << F("Free SRAM: ") << getFreeRAM() << endl;
 #endif // DEBUG
 
   // set the data rate for the SoftwareSerial port(s)

#endif // (__AVR__)

// local prototypes
#if defined (__AVR__)
static int availableMemory();
#endif // (__AVR__)

void setup() {


/** Set the desired frequency and mode of the TX (one quantity at a time). */
static void txSetFrequencyAndMode(YaesuCAT& ft817, 
                                  uint32_t& desired_frequency,
                                  byte desired_mode,
                                  unsigned long interval=500) {
  
  static unsigned long s_time = millis();
