Writing a nonvolatile bit in the configuration 3 register of a S25HL512T device

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
bharris
Level 2
Level 2
10 sign-ins 5 replies posted 5 sign-ins

Hello,
I am trying to write bit 3 of configuration register 3 in a S25HL250T device.  I see in the data sheet that the bit is only writeable in the nonvolatille memory space address 0x000004. 
My sequence is as follows:
read config 3 using a polling transfer routine // read data = 0x04... I was expecting 0x00 based on the data sheet??
data |=  0x08; //set bit 3 of the write data
WRENB_0_0;// write the write enable bit command 0x06

uint8_t command_buff[5] __attribute__ ((aligned (4)));

command_buff[0] = CYPRESS_WRITE_ANY_REG; //0x71
command_buff[1] = 0x00;
command_buff[2] = 0x00;
command_buff[3] = 0x04;
command_buff[4] = new_reg_data;

MSS_QSPI_polled_transfer_block(3, command_buff, 1, (uint8_t*)0, 0,0); 
//Polled transfer variables =(#address bytes, command, # of bytes after command, read buf, #of read bytes, # of idle cycles)

The write seems to work fine, but the register does not get written.
Any help would be appreciated.

Thanks,

Byron

0 Likes
1 Solution
bharris
Level 2
Level 2
10 sign-ins 5 replies posted 5 sign-ins

Hi Yong,

I have after several days finally got the time to try setting the device into 4 address byte mode (EN4BA_0_0), and this worked.  I was able to write configuration register 3 bit 3  and read back the correct data.

Thank you for your help, it is very much appreciated.

Byron

View solution in original post

0 Likes
10 Replies