int ascii_counter = 33; // to see something we start with the first readable character in the ASCII table which is 33 == '!' Serial.println(); Serial.print("Writing data "); Serial.println(); for (int a=0; a<8; a++) // loop to go through the address array of the eeprom i.e. chip[a] { for (int b=0; b<256;b++) // each chip has one byte of addressable memory { writeData(chip[a],b,ascii_counter); // writing the value ascii_counter to chip chip[a] at address b Serial.print("chip :"); // let's see what it did Serial.print(chip[a], HEX); Serial.print(" address :"); Serial.print(b); Serial.print(" value :"); Serial.println(char(ascii_counter)); ascii_counter++; // next character of ASCII table if (ascii_counter > 126) {ascii_counter = 33;}; // ASCII characters greater 126 are not visible, go back to the first readable character at 33 } Serial.println(); } delay(10000); // let's wait some seconds

// READING DATA

Serial.println("Reading data..."); for (int a=0; a<8; a++) // same as above, we toogle through the 8 chips .... { Serial.print("Chip: "); Serial.println(chip[a],HEX); for (int b=0; b<256;b++) // and all 256 addresses in each (virtual) chip... { data_received=readData(chip[a],b); // and read the data there.... Serial.print(char(data_received)); // and print it to serial.... } Serial.println(); // new line for each chip }// since the chip has only a limited number of write cycles, we don't want to write again and again. Let's end the sketch do { delay(10000); } while ( 1 != 0);}