+ print "Erasing.";
+ client.SPIchiperase();
+ print "Testing erase.";
+ data=client.SPIpeekblock(0);
+ for i in data:
+ if ord(i)!=0xFF:
+ print "ERROR not properly erased!";
+ data=range(0,10);
+ client.SPIpokebytes(0,data);
+ print "Testing flash write.";
+ for i in data:
+ if(client.SPIpeek(i)!=i):
+ print "%06x not properly poked to %02x" % (i,i);
+ print "Test complete.";