summaryrefslogtreecommitdiff
path: root/include/driver/eeprom24lc64.h
blob: 3be9d148c44d63d6731d6d4ab2aca3e6952ba363 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
/*
 * Copyright 2020 Daniel Friesel
 *
 * SPDX-License-Identifier: BSD-2-Clause
 */
#ifndef EEPROM24LC64_H
#define EEPROM24LC64_H

class EEPROM24LC64 {
	private:
		EEPROM24LC64(const EEPROM24LC64 &copy);
		unsigned char const address;
		unsigned char txbuf[34];

	public:
		EEPROM24LC64(unsigned char const addr) : address(addr) {}

		void writePage(unsigned short addr, char *buf);
		void readPage(unsigned short addr, char *buf);
};

extern EEPROM24LC64 eeprom24lc64;

#endif