# Send AT commands

**URL:** <https://forum.sierrawireless.com/t/send-at-commands/2898>\
**Category:** Open AT\
**Created:** [February 5, 2009, 11:39am UTC](https://forum.sierrawireless.com/t/send-at-commands/2898 "2009-02-05T11:39:23Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![sperlot](https://avatars.discourse-cdn.com/v4/letter/s/da6949/32.png) [@sperlot](https://forum.sierrawireless.com/u/sperlot)\
**Post date:** [February 5, 2009, 11:39am UTC](https://forum.sierrawireless.com/t/send-at-commands/2898/1 "2009-02-05T11:39:23Z")

</div>

Good morning,

I am a beginner with OpenAT programming.

I cannot find how to send an AT command to my fastrack using a adl\_ function ! ☹  
This may seem obvious but I am really lost.

Can someone post a simple script showing how to send an at command (for exemple ATI3) and get the wavecom answer ?

With many thanks

MP

---

<div class="post-metadata">

**Author:** ![awneil](https://avatars.discourse-cdn.com/v4/letter/a/49beb7/32.png) [@awneil](https://forum.sierrawireless.com/u/awneil)\
**Post date:** [February 5, 2009, 12:17pm UTC](https://forum.sierrawireless.com/t/send-at-commands/2898/2 "2009-02-05T12:17:24Z")

</div>

adl\_atCmdCreate

---

<div class="post-metadata">

**Author:** ![sperlot](https://avatars.discourse-cdn.com/v4/letter/s/da6949/32.png) [@sperlot](https://forum.sierrawireless.com/u/sperlot)\
**Post date:** [February 5, 2009, 1:21pm UTC](https://forum.sierrawireless.com/t/send-at-commands/2898/3 "2009-02-05T13:21:01Z")

</div>

Thank you but now I want to catch the answer to the AT command in my code and for example print it.

Can you please tell me how to fill in the blank (…) in the following code ?  
Sorry, I have problems to handle pointers ☹

```auto
ascii ADC_Response_Handler (adl_atResponse_t *paras)
{
	
	adl_atSendResponse(ADL_AT_RSP,...);

	return TRUE;
}

void adl_main ( adl_InitType_e InitType ){

adl_atCmdCreate("at+cmgf=?\x1A", ADL_AT_PORT_TYPE( ADL_AT_UART1, TRUE ),(adl_atRspHandler_t) ADC_Response_Handler, "+CMGF: ", NULL);

}
```

With many thanks !!!

---

<div class="post-metadata">

**Author:** ![awneil](https://avatars.discourse-cdn.com/v4/letter/a/49beb7/32.png) [@awneil](https://forum.sierrawireless.com/u/awneil)\
**Post date:** [February 5, 2009, 2:27pm UTC](https://forum.sierrawireless.com/t/send-at-commands/2898/4 "2009-02-05T14:27:35Z")

</div>

> [@sperlot](#):
>
> Thank you but now I want to catch the answer to the AT command in my code and for example print it.

The “answer” to the command is delivered to your response handler.

There is no need for you to print it yourself - just follow the instructions and the response will be passed through to the external application…

> [@](#):
>
> Sorry, I have problems to handle pointers ☹

That is a really basic skill essential to any kind of ‘C’ programming - not at all specific to Open-AT.

Maybe you should spend some time getting up to speed with the basics of ‘C’ before adding the extra complexities of Open-AT…?
