当前位置:网站首页>What is the at instruction set often used in the development of IOT devices?
What is the at instruction set often used in the development of IOT devices?
2022-07-01 05:32:00 【ordersyhack】
What is? AT Instructions
AT namely Attention,AT Instructions are used to define Terminal equipment TE(TerminalEquipment) and Mobile MT(Mobile Terminal) The rules of interaction , When Terminal equipment Enter a AT After the instruction , Communicating with Mobile Will reply with a result , So one-on-one . As shown in the figure below .
Wide area communication GSM In the network , The user can go through AT Order to proceed call 、 SMS 、 telephone book 、 Data business 、 Fax And so on .
AT Command related nouns
AT Command format
AT The order is based on AT To begin with , The string at the end of the character ,AT The response packet of the instruction is in . Whether each instruction is executed successfully or not has a corresponding return . Other unexpected information modules will have corresponding information prompts , The receiving end can do corresponding processing .
Every AT Only one... Can be included in the instruction AT Instructions ; except AT Two characters apart , Up to 1056 The length of characters ( Including the last empty character ).
AT The instruction set can be divided into three types :
common AT Instructions
Query module serial number AT+CGSN
AT+CGSN=<snt>, If no write <snt>, Only return to "OK”.
<snt>=0, return <sn>.
<snt>=1, return IMEI( International mobile device identification number ), Each module is unique .
<snt>=2, return IMEISV( International mobile radio device identity and software version ).
<snt>=3, Return the software version number SVN.
dispatch orders :
AT+CGSN=1
Module return :
+CGSN:868744036640526
OK
Check firmware version AT+CGMR
Execute this command to return the firmware version .
dispatch orders :
AT+CGMM
Module return :
<Revision>
OK
Query terminal error AT+CMEE
Used to set up terminal error reporting , When enabled send AT When an error is executed, the terminal will return the error code , This makes it easy to locate the problem .
Turn on error code reporting
dispatch orders :
AT+CMEE=1
Module return :
OK
Restart the module AT+NRB
For terminal device restart .
dispatch orders
AT+NRB
Module return :REBOOTING
****
Boot: Unsigned
Security B.. Verified
Protocol A.. Verified
Apps A...... Verified
REBOOT_CAUSE_APPLICATION_AT
Neul
OK
Query signal strength AT+CSQ
The return value is +CSQ:<rssi>,<ber>.rssi The bigger it is , The stronger the signal . Signal strength and rssi The conversion formula is : Signal strength =113dBm+(rssi*2).ber Field not used , Equal to 99.
dispatch orders :
AT+CSQ
Module return
+CSQ:31,99
OK
Check if the network is active AT+CGATT
return :+CGATT:1, Indicates that the network is activated ; If returns :+CGATT:0, It means the network is not activated , Please try to restart the module to activate the network .
dispatch orders :
AT+CGATT?
Module return :
+CGATT:1
OK
Query network registration status AT+CEREG
This command is used to query the terminal EPS Network registration status . When enabled to prompt , The network registration status information of the terminal has changed , Will actively report to the user terminal . Different settings allow you to report EPS Registration status 、 Location area code 、 community ID、 Access technology and other information of the service community , In general, it only needs to be set to auto report EPS Registration status .
dispatch orders :
AT+CEREG=1
Module return :
OK
After setting successfully , When the network registration status information changes , Will actively report to the user terminal , Such as :
+CEREG:1,1
OK
Query the current connection status of the network AT+CSCON
The return format is :+CSCON:<n>,<mode>?
<n> It's notification settings . Value and description :0 To cancel asynchronous notification , When the network is connected , Serial port will not actively report +CSCON command ;1 To enable asynchronous notification , Serial port actively reports +CSCON.
<mode> Is the current module connection status , Value and description :0 be in IDLE state ,1 In connected state . When in IDLE In the state of , Just send the data or restart the device , It will become connected .
dispatch orders :
AT+CSCON?
Module return :
+CSCON:0,1
OK
Set the RF function of the module AT+CFUN
This command is used to set and query whether the RF function of the module is on .
AT+CFUN=0 // Turn off RF function
OK
AT+CFUN=1 // Turn on the RF function of the module
OK
AT+CFUN? // Check the RF on status of the module
+CFUN:1 // RF function has been turned on successfully , If reply 0 Usually because SIM The circuit of the card is not connected to the module successfully
边栏推荐
- Global and Chinese market of high-end home theater 2022-2028: Research Report on technology, participants, trends, market size and share
- Leetcode top 100 question 2 Add two numbers
- LevelDB源码分析之memtable
- Actual combat: gateway api-2022.2.13
- Application of industrial conductive slip ring
- [RootersCTF2019]babyWeb
- Tar command
- More than one file was found with OS independent path ‘lib/armeabi-v7a/libyuv. so‘.
- rust猜数字游戏
- Speed regulation and stroke control based on Ti drv8424 driving stepper motor
猜你喜欢
Typeorm framework
Usage and principle of synchronized
Copy baby prompt: material cannot be empty. How to solve it?
基于TI DRV8424驱动步进电机实现调速和行程控制
Practice of combining rook CEPH and rainbow, a cloud native storage solution
How to create a progress bar that changes color according to progress
液压滑环的特点讲解
Fluentd is easy to use. Combined with the rainbow plug-in market, log collection is faster
JDBC common interview questions
Mongodb learning chapter: introduction after installation lesson 1
随机推荐
Understand several related problems in JVM - JVM memory layout, class loading mechanism, garbage collection
Unit testing with mongodb
Rainbond结合NeuVector实践容器安全管理
Use and principle of Park unpark
Usage and principle of synchronized
Copier le matériel de conseils de bébé ne peut pas être vide, comment résoudre?
云原生存储解决方案Rook-Ceph与Rainbond结合的实践
QDataStream的簡單讀寫驗證
Global and Chinese market of search engine optimization (SEO) software 2022-2028: Research Report on technology, participants, trends, market size and share
Actual combat: basic use of Redux
Copy baby prompt: material cannot be empty. How to solve it?
Fluentd is easy to use. Combined with the rainbow plug-in market, log collection is faster
工业导电滑环的应用
Web Security (x) what is OAuth 2.0?
eBPF Cilium实战(2) - 底层网络可观测性
Simple implementation of database connection pool
SSGSSRCSR区别
Qt编译时,出现 first defined here,原因及解决方法
Use and principle of reentrantlock
JDBC常见面试题