Arduino Stack Exchange is a question and answer site for developers of open-source hardware and software that is compatible with Arduino. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I need to know how can I write the integer value in EEPROM and retain the value on Power ON.?

  char *Red = strstr(myTestUrl, "/R");
  if (Red)
  {
    int RedValue  = atoi(Red + 2);
    analogWrite(12, RedValue);
    Serial.println("Red :");
    Serial.println(RedValue);
  }

I want to write "RedValue" in EEPROM. How can it be done?

share|improve this question
    
Have a look in the EEPROM sample sketches that are installed when you add ESP8266 support to the arduino ide – Jaromanda X Jul 3 '16 at 2:47
    
@JaromandaX Thanks, mate! – Anuj Mattóõ Jul 3 '16 at 9:39

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.