Reading from EEPROM and combining I'm trying to read from the EEPROM and combine the information and send it out over SoftwareSerial using write() function but i'm getting the following error

error: invalid operands of types 'const char [3]' and 'const char*' to binary 'operator+'




void loop()  
{ 
  const char* eTest1 = EEPROM.read(1);
  const char* eTest2 = EEPROM.read(2);
  const char* eTest3 = EEPROM.read(3);

  char combinedVal[] = eTest1+":"+eTest2+":"+eTest3;
  bluetooth.write(combinedVal);
}
You cannot use the + operator for that. 

However, since EEPROM.read only returns one byte and not a string, you can do a much easier implementation:

void loop()  
{ 
  char result[] = "1:2:3";
  for (int item = 0; item &lt; 3; item++)
  {
    result[item * 2] = EEPROM.read(1 + item);
  }
}


This first create a string "1:2:3", where the digits are overwritten in the for loop by that item. Note that the digits in the string do not matter, it's just some free 'comment', it also should work when using "x:x:x".