eeprog(8)
π eeprog(8) β the girlies' guide to poking at EEPROMs π
okay so real talk: eeprog is a System Administration manual page, and it's the one you want when you need to read and write 24Cxx EEPROMs connected to the I2C serial bus. She's small, she's mighty, she's giving hardware whisperer. Let's get into it bestie π«Ά
β¨ SYNOPSIS β¨
eeprog [-fqxdh] [-16|-8] [-r addr[:count]|-w addr] <device> <i2c-addr>
that's the whole vibe in one line, no cap π
πΈ DESCRIPTION πΈ
eeprog uses the SMBus protocol β which is lowkey the protocol most of the recent chipsets are running on. That's the tea. π
π NOTE π
Don't forget to load your i2c chipset and the i2c-dev drivers. fr fr, if you skip this step nothing works and you'll be sitting there like π.
Also!! these environment variables can be set instead of the command line arguments:
EEPROG_DEVβ stands in fordeviceEEPROG_I2C_ADDRβ stands in fori2c-addr
π PARAMETERS π
π¦ Address modes π¦
-8β use 8bit address mode for24c0x...24C16. this is the [default] btw, so if you say nothing she picks this one π«-16β use 16bit address mode for24c32...24C256
π Actions π
-r addr[:count]β readcountbytes (1 if you omit it) starting fromaddr, and print them to the standard output-w addrβ write whatever's coming in on stdin to addressaddrof the EEPROM-hβ print this help. the classic "bestie explain" button π«Ά
β Options β
-xβ set hex output mode-dβ Dummy mode: display what would have been done. it's the rehearsal, not the performance β¨-fβ disable warnings and don't ask confirmation. she just goes. no questions asked π-qβ quiet mode π€«
π Bus π
deviceβ the device file representing the I2C bus (eg./dev/i2c-0)i2c-addrβ the I2C bus address of the EEPROM (eg.0x3A)
π§ EXAMPLES π§
Read 64 bytes from the EEPROM at address 0x54 on bus 0 starting at address 123 (decimal)
eeprog /dev/i2c-0 0x54 -r 123:64
Print the hex codes of the first 32 bytes read from bus 1 at address 0x22
eeprog /dev/i2c-1 0x51 -x -r 0x22:0x20
Write the current timestamp at address 0x200 of the EEPROM on bus 0 at address 0x33
date | eeprog -f /dev/i2c-0 0x33 -w 0x200
see how the pipe just hands her the timestamp? iconic behaviour, she ate that π½οΈ
π AUTHOR π
Stefano Barbato β the mastermind, the moment, the main character π
and that's the whole page bestie!! this one ships with i2c-tools, dated Jul 2013, and lives at section 8 of the manual. slay, go read some EEPROMs πβ¨π
π¦ where this page comes from
- arch rolling: i2c-tools 4.4-4 Β· GPL
- fedora 43: i2c-tools 4.4-3.fc43 Β· GPL-2.0-or-later
- fedora 44: i2c-tools 4.4-4.fc44 Β· GPL-2.0-or-later
- Copyright (C) 2013 Jaromir Capik
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms