Can you check your logic level voltages between the BCM and your NVRAM? I have found that the BCM logic levels can change when the USB voltage is removed from UART RX. I found in my setup that the logic levels were fine between my BCM and my external ADC... until I removed the USB and tried to run on battery and voltage regulator. Then the logic level high was too low. (dropped by .2 volts when I disconnect UART_RX from USB).
All the variations of SW4 are not tested or documented anywhere, so let's back up and verify that a simpler configuration works.
Using the The specified item was not found. as a reference:
To program the TAG3 board with your PC connected via USB cable while using the NVRAM/EEPROM on the board (default configuration), you need the following configuration:
- Each of the eight DIP switches on the mini-switch SW4 set to ON.
- SW2 should be in the VUSB position (up) and SW3 should be in the VREG position (down)
This should work and no errors should be returned within the SDK during the process of programming the board.
Now proceed to remove the USB cable, and run the unit off the CR2032 battery (make sure the voltage of the battery is correct and that it does not need to be replaced - see the other posts in this discussion as they demonstrate what happens when this occurs).
- Disconnect the tag from the PC USB interface
- Set the position of both switches (SW2/SW3) on the right side of the board to the VCOIN position
- The switches should now be set to the opposite positions of that used for programming.
- Install a CR2032 coin cell in the battery holder on the bottom of the tag and ensure that the battery polarity is correct.
The board should now be powered by the battery and your application running.
At this point, are you seeing the same state information being lost?
It's my understanding that in order to now use the external SFLASH vs EEPROM, there are some Resistor Settings you need to make that are defined in Table 2 of the Hardware User Guide (SDK 2.x and TAG3 Board)
Along with some undocumented changes to the Make File Settings and SW4 that are described here: Re: Change BCW920737TAG from EEPROM to SFLASH failed
Based on your settings described above, it sounds like you may already be using this thread for configuration.
1. check the power swicth SW2 and SW3 whether is correct?
2. check the return value of bleprofile_WriteNVRAM whether is OK?
Please correct my if I am wrong. My BCM is configured to use SFLASH, so NVRAM should be located in SFLASH. I have measured VCC and WP on MX25U4035MI-25G and they are always both 3.31 V (board is configured to 3,3, so it is good value).
There is no difference when i change switches to power board from battery. NVRAM remember last state from session when i programmed device and haven't pluged out usb.
I will try to ask around internally and see if I can find someone with experience running the board off the serial flash.
We cannot reproduce this issue, sorry.