Using the writeAnything utility without struct

This is currently what I have. I like to have more than one struct value so as to keep things organized in my mind:

struct config_settings { //these are stored in EEPROM @ 50
  int accel;  //(516 orginally) Offset for the accelerometer when setting level
  int gyro;   //(467 orginally) Offset for the gyro when setting level
} 
offset;

struct config_steering { //these are stored in EEPROM @ 25
  int center; //the value of the steering potentiometer in the center position
}
steering;

So then I can refer to them like:

steering.center
...or
offset.gyro

my question is: Since I only have one variable in the struct called steering, can I skip the struct, and just use a normal variable, like "steeringVal", and yet still use the writeAnything utility to save it to memory. I currently do this:

  EEPROM_writeAnything(25, steering);  //save the steering settings to EEPROM @ 25

Could I skip the struct thing and just do this?

int steeringVal = analogRead(steeringPin);
EEPROM_writeAnything(25, steeringVal);  //save the steering settings to EEPROM @ 25

http://playground.arduino.cc/Code/EEPROMWriteAnything
...sorry, I forgot to add this link to EEPROMWriteAnything

A small test sketch should show if it works or not. Just do one write/read in setup so it is executed only once.

I think it is not good programming to use two different structures at fixed EEPROM locations.

You can use normal variables at fixed locations, but since you are using structures, you can also organize the structure in the way you like. You could make for example make a new structure that contains the two other structures.

I think it is not good programming to use two different structures at fixed EEPROM locations.

depends 100% on the sketch but it is seldom seen .. (EEPROM version of a union?)

Thanks. The writeAnything call works with just an int variable! I tested it out in the setup, so it wouldn't run repeatedly.

I have used it with individual variables and it works fine. You just need to make sure not to put 2 variables at the same EEPROM address and you have to space the address far enough apart to not step on each other. But otherwise it works fine.