Arduino Powered Weather Station

Hey, nice work on your display!

I'm trying to adapt your code for use in my project. I was wondering if I could get some help.

I've stripped the serial connectivity out of your code because I don't use it. I would really like to be able to display the contents of a array or variable to only one display. I'd like to, for example, do something along these lines:

myarray[] = {
"LINE ONE TEXT","LINE TWO NUMS"
}

Then, just update the contents of the array as I need to change the display. I'm using a pot as a selector knob here is what I'm doing now and it works somewhat

val = analogRead(potPin);
if (val <= 50)
{
  disp[0] ="ONE    ";
  totalsteps = 1000;
}
else if (val >= 51 && val < 100)
{
  disp[0] ="TWO    ";
  totalsteps = 2000;
}
else if (val >= 101 && val < 150)
{
  disp[0] ="THREE  ";
  totalsteps = 3000;
}
else if (val >= 151 && val < 200)
{
  disp[0] ="FOUR   ";
  totalsteps = 4000;
}
else if (val >= 201 && val < 250)
{
  disp[0] ="FIVE   ";
  totalsteps = 5000;
}
else if (val >= 251 && val < 300)
{
  disp[0] ="SIX    ";
  totalsteps = 6000;
}
else if (val >= 301 && val < 350)
{
  disp[0] ="SEVEN  ";
  totalsteps = 7000;
}
else if (val >= 351 && val < 400)
{
  disp[0] ="EIGHT  ";
  totalsteps = 8000;
}
else if (val >= 401 && val < 450)
{
  disp[0] ="NINE   ";
  totalsteps = 9000;
}
else if (val >= 451 && val < 500)
{
  disp[0] ="TEN    ";
  totalsteps = 10000;
 
}
else
{
disp[0] ="HIGH   ";
remStep = 0;
}

All I'm doing is writing to your existing array the text I need updated on display 1, line 1, frame 1.

It's very messy and I'd like to clean it up a bit, but I'm having trouble modifying your code to my needs.

Thanks for your help (and your code :slight_smile: )