SIM300 基本命令集

//基本命令集
//------------------------------------------------------------------
const romchar AT_AT[] = {"AT/r/n"};
const romchar AT_CBC[] ={"AT+CBC/r/n"}; //检查充电状态,以及电池电量占容量的百分比+CBC: 0,97,4164
const romchar AT_CREG[] = {"AT+CREG?/r/n"}; //查询网络注册状态
const romchar AT_CREGINIT[] = {"AT+CREG=1/r/n"}; //初始化网络注册状态
const romchar AT_ATE[] = {"ATE0/r/n"}; //存储当前的设置参数
const romchar AT_Save[] = {"AT&W/r/n"}; //存储当前的参数
//0 disable slow clock1 enable slow clock
const romchar AT_CSCLK[] = {"AT+CSCLK=1/r/n"}; //enable slow clock
//0 minimum functionality 1 full functionality (Default) 4 disable phone both transmit and receive RF circuits
const romchar AT_CFUN[] = {"AT+CFUN=1/r/n"}; //使模块在重启后电源进入功能性的电平
const romchar AT_CGMR[] = {"AT+CGMR/r/n"}; //软件版本标识
const romchar AT_CCID[] = {"AT+CCID/r/n"}; //获得SIM卡标识
const romchar AT_CGSN[]={"AT+CGSN/r/n"}; //IMEI
const romchar AT_CSQ[]={"AT+CSQ/r/n"}; //信号强度
const romchar AT_CSMINS[]={"AT+CSMINS?/r/n"}; //检测SIM卡是否插入+CSMINS: 0,1
const romchar AT_COPS[]={"AT+COPS?/r/n"};
const romchar AT_CPOL[]={"AT+CPOL?/r/n"};
const romchar AT_REG_COPS[]={"AT+CPOL=1,2,/""};
//******************************************************************************
//SMS命令集
//------------------------------------------------------------------
const romchar AT_CMGF[] = {"AT+CMGF=1/r/n"}; //指定信息的输入输出格式为文本格式
const romchar AT_CMGFNMEA[] = {"AT+CMGF=0/r/n"}; //指定信息的输入输出格式为PDU格式
const romchar AT_CSCS[] = {"AT+CSCS=/"GSM/"/r/n"}; //AT+CSCS=“GSM”设置什么样的字体让模块接受
const romchar AT_CMGS[] = {"AT+CMGS=/""}; //发短信
const romchar AT_CMGR[] = {"/r/nAT+CMGR="}; //读短信
const romchar AT_CMGD1[] = {"AT+CMGD=1/r/n"}; //删除短信
const romchar AT_CMGD2[] = {"AT+CMGD=2/r/n"}; //删除短信
const romchar AT_CMGD3[] = {"AT+CMGD=3/r/n"}; //删除短信
const romchar AT_CMGD4[] = {"AT+CMGD=4/r/n"}; //删除短信
const romchar AT_CMGD5[] = {"AT+CMGD=5/r/n"}; //删除短信
const romchar AT_CMGD6[] = {"AT+CMGD=6/r/n"}; //删除短信
const romchar AT_CMGD7[] = {"AT+CMGD=7/r/n"}; //删除短信
const romchar AT_CMGD8[] = {"AT+CMGD=8/r/n"}; //删除短信
const romchar AT_CMGD9[] = {"AT+CMGD=9/r/n"}; //删除短信

const romchar AT_CNMI[] = {"AT+CNMI=2,1/r/n"}; // ?初始化AT指令时要用上
const romchar AT_CMGL[] = {"AT+CMGL=/"REC UNREAD/"/r/n"}; //接收没有读的信息
//const romchar AT_CSMP[] = {"AT+CSMP=17,167,0,240 /r/n"};
//const romchar AT_IFC[] = {"AT+IFC=2,2 /r/n"}; //建立数据呼叫,通过RTS和CTS控制
//const romchar AT_CBST[] = {"AT+CBST=0,0, 1 /r/n"};
//------------------------------------------------------------------
//GPRS命令集
//------------------------------------------------------------------
const romchar Gprs_class[] = {"AT+CGCLASS=/"B/"/r/n"}; //length = 16B 显示GPRS信息移动的类型
const romchar Gprs_apn[] = {"AT+CSTT=/""}; //GPRS通用的名字
const romchar Gprs_CSTT[]={"AT+CIPCSGP=1,/""}; //设置GPRS为无线连接的模式
const romchar Gprs_cgatt[] = {"AT+CGATT=1/r/n"}; //length = 12B显示GPRS配置是附加的
const romchar Gprs_cgreg[] = {"AT+CGREG?/r/n"}; //查询GPRS网络注册状态
const romchar Gprs_cgreginit[] = {"AT+CGREG=1/r/n"}; //初始化GPRS网络注册状态
const romchar Gprs_T_S[] = {"AT+CIPSTART=/"TCP/",/""}; //建立TCP连接; 连接成功反馈CONNECT OK
const romchar Gprs_U_S[] = {"AT+CIPSTART=/"UDP/",/""}; //建立UDP连接
const romchar Gprs_ipshut[] = {"AT+CIPSHUT/r/n"}; ////使GPRS的PDP失效
const romchar Gprs_send[] = {"AT+CIPSEND/r/n"}; //发送数据;
const romchar Gprs_dpdp[] = {"AT+CIPDPDP=1,60,3/r/n"}; //自动检测GPRS是否为附着状态;60毫秒,检测3次
const romchar SetBand[]= "AT+IPR=9600/r/n"; //设置与终端设备通信的波特率为9600
//------------------------------------------------------------------
//通话命令集
//------------------------------------------------------------------
const romchar Gsm_cmd_call_view[] = {"AT+CLIP=1/r/n"}; //使能来电显示
const romchar Gsm_P_ATD[] = {"/r/nATD"}; //拨号
const romchar Gsm_cmd_call_ack[] = {"ATA/r/n"}; //接通
const romchar Gsm_call_connect[] = {"AT+CLCC/r/n"}; //查询是否接通
const romchar Gsm_cmd_call_noack[] = {"ATH/r/n"}; //挂断
const romchar Gsm_cmd_call_sel[] = {"AT+CHFA=0/r/n"}; //选主通道
const romchar Gsm_cmd_call_CMIC[] = {"AT+CMIC=0,9/r/n"}; //MIC增益+13.5dB,选择主麦克风
const romchar Gsm_cmd_call_CLVL[] = {"AT+CLVL=90/r/n"}; //受话器音量级别
const romchar Gsm_cmd_Voice_num1[] = {"AT+VTS=1/r/n"}; //拨号键3
const romchar Gsm_cmd_Voice_num2[] = {"AT+VTS=2/r/n"}; //拨号键3
const romchar Gsm_cmd_Voice_num3[] = {"AT+VTS=3/r/n"}; //拨号键3
const romchar Gsm_cmd_Voice_num4[] = {"AT+VTS=4/r/n"}; //拨号键3
const romchar Gsm_cmd_Voice_num5[] = {"AT+VTS=5/r/n"}; //拨号键3
const romchar Gsm_cmd_Voice_num6[] = {"AT+VTS=6/r/n"}; //拨号键3
const romchar AT_VTS[] = {"AT+VTS=/r/n"}; //Send DTMF
const romchar ATMicOn[]="AT+CMUT=0/r/n";
const romchar ATMicOff[]="AT+CMUT=1/r/n";
const romchar Gsm_cmd_Turn_Off[] = {"AT+CPOWD=1/r/n"}; //关模块命令
【SIM300 基本命令集】

    推荐阅读