PLANET-Q EEPROM Library
Dependents: IZU2020_AVIONICS IZU2020_POST_PROCESS IZU2020_AVIONICS
PQEEPROM.h@0:559c23c5884c, 2019-12-17 (annotated)
- Committer:
- tanahashi
- Date:
- Tue Dec 17 09:08:51 2019 +0000
- Revision:
- 0:559c23c5884c
- Child:
- 1:fccbd0a70492
first commit
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
tanahashi | 0:559c23c5884c | 1 | #ifndef PQEEPROM_H_ |
tanahashi | 0:559c23c5884c | 2 | #define PQEEPROM_H_ |
tanahashi | 0:559c23c5884c | 3 | |
tanahashi | 0:559c23c5884c | 4 | class EEPROM |
tanahashi | 0:559c23c5884c | 5 | { |
tanahashi | 0:559c23c5884c | 6 | private: |
tanahashi | 0:559c23c5884c | 7 | I2C *_i2c; |
tanahashi | 0:559c23c5884c | 8 | int _addr; |
tanahashi | 0:559c23c5884c | 9 | char cmd[130]; |
tanahashi | 0:559c23c5884c | 10 | char buff[128]; |
tanahashi | 0:559c23c5884c | 11 | public: |
tanahashi | 0:559c23c5884c | 12 | EEPROM(I2C &i2c); |
tanahashi | 0:559c23c5884c | 13 | void write(int addr, char *data, int size); |
tanahashi | 0:559c23c5884c | 14 | void read(int addr, char *data, int size); |
tanahashi | 0:559c23c5884c | 15 | }; |
tanahashi | 0:559c23c5884c | 16 | |
tanahashi | 0:559c23c5884c | 17 | #endif |