Indication of SIM Initailisation

Hello
Please can u tel me if is there way to activate an unsolisited reponse to indicate that the SIM is full initalised.

Thanks :slight_smile:

Hello Malek,

You should be able to subscribe to +WIND indications to tell when the SIM reaches various states of rediness. Have a look under the +WIND command in the AT documentation and adl_UnSoSuscribe in the ADL documentation for more inforamtion on how to activate hooks and interpret the different WIND indications.

Kind regards,
Mike

If you use the ADL, then the +wind is initialised to the invariable decimal value β€˜511’ (0x1FF) which means that the first 9 indications levels (bit 0 to bit 8) are set. Its not recommended to change this value.

If you (as [color=blue]MikeBean wrote) subscribe to the β€˜+WIND:4’ unsolicited result:

adl_atUnSoSubscribe("+WIND: 4", (adl_atUnSoHandler_t) atUnSoResponse_PlusWIND4_Handler);

Then you’ll know when the unit is properly initialised to receive all AT-commands (SIM is fully initialised)

The callback routine to β€œcatch” the unsolited result could look something like:

bool atUnSoResponse_PlusWIND4_Handler(adl_atUnsolicited_t * response)
{
	TRACE (( 1, "atUnSoResponse_PlusWIND4_Handler" ));

	return FALSE;  // do not send to external application
}

You can in the same way subscribe to any other +WIND indication.
However, some needs to be activated with +WFM command.

Good Luck

/Snoooze

The best way consist in subscribing to SIM events with adl_Simsubscribe and wait for the ADL_SIM_EVENT_FULL_INIT.
See also adl_SIM.h for other SIM events.

Remember that it is highly recommended to wait to the full init, before issuing any GPRS action

Cheers