Extracting the code from a printer cartridge chip

You don't need to read the data to reprogram the cartridge, you just need to overwrite it with the default data.