Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7824903
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 2, 20262026-06-02T08:45:27+00:00 2026-06-02T08:45:27+00:00

I have a program I want to make which will ask to see whether

  • 0

I have a program I want to make which will ask to see whether a variable already exists. If it does, it displays it, if it does not, it creates it and stores it in the Arduino using the PROGMEM command. Can someone explain more about PROGMEM and how to make the program I’m talking about?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-02T08:45:28+00:00Added an answer on June 2, 2026 at 8:45 am

    Generally speaking if you are creating any variables in functions they are existing only there when function is closed all variables are deleted. If you want to keep them alive try to create global variables or use static before it;
    like here

    static int myvariable;
    

    And here is answer for your question

     if (myvariable!=NULL)
        {
         printfucntion(myvariable);
        }
    

    solution for eeprom

    EEPROM Read
    Reads the value of each byte of the EEPROM and prints it to the computer.

    #include <EEPROM.h>
    
    // start reading from the first byte (address 0) of the EEPROM
    int address = 0;
    byte value;
    
    void setup()
    {
      Serial.begin(9600);
    }
    
    void loop()
    {
      // read a byte from the current address of the EEPROM
      value = EEPROM.read(address);
    
      Serial.print(address);
      Serial.print("\t");
      Serial.print(value, DEC);
      Serial.println();
    
      //move to next address of the EEPROM
      address = address + 1;
    
      // there are only 512 bytes of EEPROM, from 0 to 511, so if you are
      // on address 512, wrap around to address 0
      // if you have arduinoMega probably there is more eeprom space
      if (address == 512)
        address = 0;
    
      delay(500);
    }
    

    I hope I helped.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I want to make a program in C which will ask the user to
I have a program and want to debug it in gdb. Will I see
I want to know whether unhandled exception will make WCF service crash. I have
I want to implement in my program functionality, which will make it able to
I have a little program that I want to make open automatically when my
I have program that runs fast enough. I want to see the number of
I have a program which plays two sounds. I want the user to know
I have a FindFile routine in my program which will list files, but if
I have a Java program which will produce a large matrix, at the end
I want to make a field, which will be automatically filled, and stay unique.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.