CyReadUserFlash only returns zeroes on CYC7C65211 (Linux) | Cypress Semiconductor
CyReadUserFlash only returns zeroes on CYC7C65211 (Linux)
I'm trying to read out the flash data on a CYC7C65211 on a Linux host, but failing with that. We want to be able to write the flash later with our custom configuration, but I want to be able to read first to see that at least very basic things work.
My program is basically (apart from checking return values, which I do everywhere, there are no failures):
dev = Loop through devices to find the Cypress One (Test_Utility.c::isCypressDevice()).
CyOpen(dev, 0, &handle);
// Fill in buf with a pointer and length == 512
CyReadUserFlash(handle, &buf, 0, 0);
By doing this I get 512 bytes of data out from it, but all data is always zero. Looking at the output configurations from the windows utility, I'd expect it to be something else. I've also tried reading 128-byte chunks from CyReadUserFlash, but it looks the same way. The values are really zeroed, since I can set the buffer to some other value before the call and still get zeroes.
Do you have a working example somewhere which I can take a look at?