After upgrading the SDK from 1.2.0 to 1.9.0, I found a problem: the ICCID numbers that could be read are now unreadable! I still use the AT instruction "AT% XICCID" to read, and it returns an error prompt. Why? The IMEI number and IMSI number can still be read.
my modem fw is V1.3.1,and this is my function:
#define CMD_GET_IMEI "AT+CGSN" #define CMD_GET_IMSI "AT+CIMI" #define CMD_GET_ICCID "AT%XICCID" void func(void) { ... if(nrf_modem_at_cmd(tmpbuf, sizeof(tmpbuf), CMD_GET_IMEI) == 0) { #ifdef NB_DEBUG LOGD("imei:%s", tmpbuf); #endif strncpy(g_imei, tmpbuf, IMEI_MAX_LEN); } if(nrf_modem_at_cmd(tmpbuf, sizeof(tmpbuf), CMD_GET_IMSI) == 0) { #ifdef NB_DEBUG LOGD("imsi:%s", tmpbuf); #endif strncpy(g_imsi, tmpbuf, IMSI_MAX_LEN); } if(nrf_modem_at_cmd(tmpbuf, sizeof(tmpbuf), CMD_GET_ICCID) == 0) { #ifdef NB_DEBUG LOGD("iccid:%s", &tmpbuf[9]); #endif strncpy(g_iccid, &tmpbuf[9], ICCID_MAX_LEN); } ... }