Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
test
Import library
Public Types |
|
enum | status_t { M24512_SUCCESS = 0, M24512_I2C_ERROR = 1, M24512_RDY_TIMEOUT = 2, M24512_MEM_OVERFLOW = 3 } |
Return values for each function. More... |
|
Public Member Functions |
|
M24512 (PinName sda, PinName scl, uint8_t address=M24512_DEFAULT_ADDRESS) | |
Initialise
M24512
Interface.
|
|
~M24512 (void) | |
Destructor.
|
|
status_t | read (uint16_t addr, char *data, uint16_t size) |
Read continuous from address.
|
|
status_t | write (uint16_t addr, const char *data, uint16_t size) |
Write continuous to address.
|
|
void | frequency (uint32_t hz) |
Set the i2c frequency.
|
|
uint16_t | get_page_size () const |
Get page size.
|
|
uint16_t | get_page_count () const |
Get page count.
|
|
uint32_t | get_total_memory () const |
Get memory size in KiB.
|
|
status_t | ready (void) |
Check status of Memory chip after writing data.
|