2009-01-10 03:41:39 +01:00
|
|
|
#ifndef EEPROM_H
|
|
|
|
#define EEPROM_H
|
2008-09-23 01:00:10 +02:00
|
|
|
|
2016-06-05 00:59:43 +02:00
|
|
|
#ifdef __LIBRETRO__
|
|
|
|
extern void eepromSaveGame(u8* &data);
|
|
|
|
extern void eepromReadGame(const u8 *&data, int version);
|
|
|
|
#else
|
2008-09-23 01:00:10 +02:00
|
|
|
extern void eepromSaveGame(gzFile _gzFile);
|
|
|
|
extern void eepromReadGame(gzFile _gzFile, int version);
|
2016-06-05 00:59:43 +02:00
|
|
|
#endif
|
2008-09-23 01:00:10 +02:00
|
|
|
extern void eepromReadGameSkip(gzFile _gzFile, int version);
|
|
|
|
extern int eepromRead(u32 address);
|
|
|
|
extern void eepromWrite(u32 address, u8 value);
|
|
|
|
extern void eepromInit();
|
|
|
|
extern void eepromReset();
|
2016-06-05 00:59:43 +02:00
|
|
|
#ifdef __LIBRETRO__
|
|
|
|
extern u8 *eepromData;
|
|
|
|
#else
|
2008-09-23 01:00:10 +02:00
|
|
|
extern u8 eepromData[0x2000];
|
2016-06-05 00:59:43 +02:00
|
|
|
#endif
|
2008-09-23 01:00:10 +02:00
|
|
|
extern bool eepromInUse;
|
|
|
|
extern int eepromSize;
|
|
|
|
|
|
|
|
#define EEPROM_IDLE 0
|
|
|
|
#define EEPROM_READADDRESS 1
|
|
|
|
#define EEPROM_READDATA 2
|
|
|
|
#define EEPROM_READDATA2 3
|
|
|
|
#define EEPROM_WRITEDATA 4
|
|
|
|
|
2009-01-10 03:41:39 +01:00
|
|
|
#endif // EEPROM_H
|