The first question: Today, after my co-workers modified the link files to change the ram mapping address in an project , he couldn't enter the debug session, and then mine project neither, the computer could detect the open-sda port , and I had tried to upgrade the open-sda firmware app, but it couldn't help.
Is the chip be secured or the opensda wrong, I coultn't figure out what my co-workers done with the link files for now;
The second question , we found that the board couldn't plug out once we plug into our computer other than restart it, if not, we couldn['t get into the debug session;
The FSEC register is loaded from 0x40C during the reset sequence, so it depends on what is the content of the byte in flash. If FSEC[SEC] != 0b10 and FSEC[MEEM] == 0b10, the MCU can't be unsecured (22.214.171.124.4 Flash Security Register (FSEC)).
the byte of 0x40C is 0x51, that is FSEC[SEC] = 0b01, FSEC[MEEN] = 0b01, but I can't confirm it is the same with yesterday;
This chip may can't unsecure forever ?
if so the S32DS should be able to mass erase the MCU.
What message do you get from the IDE? It should report that the MCU is secured and ask if you want to mass erase the device.
The ide didn't report MCU is secured but reported can't get acess to the chip, I 'll paste the error tomorrow.
So we decided to repace the chip because we couldn't find a way to solve it
in the s32k144_64_flash.ld:
m_interrupts (RX) : ORIGIN = 0x00000000, LENGTH = 0x00000400
m_flash_config (RX) : ORIGIN = 0x00000400, LENGTH = 0x00000010
m_text (RX) : ORIGIN = 0x00000410, LENGTH = 0x0007FBF0
modeified as below：
m_text1 (RX) : ORIGIN = 0x00000000, LENGTH = 0x00000100
m_interrupts (RX) : ORIGIN = 0x00000100, LENGTH = 0x00000400
m_flash_config (RX) : ORIGIN = 0x00000500, LENGTH = 0x00000510
m_text2 (RX) : ORIGIN = 0x00000510, LENGTH = 0x0007FAF0