Commit 301a714b971cb26c237665e4f0a5b33a3c91de8d

Authored by 刘琴
1 parent 692f24c1

提交协议英文版校验版本

Communication protocol-B200W-MQTT Protocol.md
... ... @@ -13,17 +13,17 @@ MQTT server requirements:
13 13  
14 14 Manufacturers use <a href="https://www.emqx.io/get-started" target="_blank" >EMQX </a> for testing
15 15  
16   -Able to send and receive MQTT data normally.
  16 +and it is able to send and receive MQTT data normally.
17 17  
18 18 The performance parameters of the server are determined by the business.
19 19  
20   -domain name:
  20 +Domain name:
21 21  
22 22 Public network domain name or IP or LAN IP where the base station is located.
23 23  
24   -Check the MQTT server configuration results
  24 +Check the MQTT server configuration results:
25 25  
26   -Use the MQTT.FX client to configure the domain name, port, username and password information, and then connect. If the connection is successful, it means that the MQTT server is available. The base station clientid is the base station number.
  26 +Use the MQTT.FX client to configure the domain name, port, username and password information, and then connect. If the connection is successful, it means that the MQTT server is available. The base station clientid is the base station SN number.
27 27  
28 28 ![](img/mqtt_2.png)
29 29  
... ... @@ -32,10 +32,10 @@ Use the MQTT.FX client to configure the domain name, port, username and password
32 32  
33 33 # Function Description
34 34  
35   -## Theme Description
36   -\${baseSN}is the SN code of the specified base station and cannot be empty. To receive base station feedback data, you need to subscribe to the receiving topic of the corresponding base station SN.
  35 +## Topic Description
  36 +\${baseSN}is the SN number of the specified base station and it cannot be empty. To receive base station feedback data, you need to subscribe to the receiving topic of the corresponding base station SN.
37 37 ### Published topics
38   -Topics published by the application to which the base station subscribes <br>
  38 +Topics published by the application, the base station subscribes to<br>
39 39 /client/\${baseSN}/send <br>
40 40 /client/multiBase/send
41 41  
... ... @@ -51,7 +51,7 @@ The topic subscribed by the application, published by the base station &lt;br&gt;
51 51 |set| Set parameter attribute status and data in standby state | Standby state|
52 52 |start| Run a single-process business instance (function) | Standby state|
53 53 |stop| Stop a single-process business instance (function) | Standby state|
54   -|rtXXX| Methods and functions can be executed in real time online ||
  54 +|rtXXX| Methods and functions can be executed in real time when online ||
55 55  
56 56 ## Event Description
57 57 |Event ID| Description| Constraints|
... ... @@ -59,8 +59,8 @@ The topic subscribed by the application, published by the base station &lt;br&gt;
59 59 |sEvtXXX|System Event | Auto Return|
60 60 |fEvtXXX|Command event | Return after calling the corresponding command|
61 61  
62   -## Data format convention
63   -- The data format is unified as **json**, and the MQTT message sending and receiving encoding is unified as **UTF-8**
  62 +## Data Format Specification
  63 +- The data format is unified as **json**, and the encoding of MQTT message sending and receiving is unified as **UTF-8**
64 64 - The general format of json is as follows:
65 65  
66 66 ```json
... ... @@ -79,7 +79,7 @@ The topic subscribed by the application, published by the base station &lt;br&gt;
79 79 |dataTag| Data tag, used for corresponding sent and received data|Length does not exceed 4, can be a combination of 0-9a-zA-Z|
80 80 |data| Data content|Object or array, can be empty|
81 81  
82   -**Note: The length of the command data received by the base station at a time does not exceed 2K. When sending a command using a specified keypad, if the command length exceeds the limit, it is recommended to split the command and send it in batches. If the command is executed by all keypad, keySns can be set to an empty array to not use the specified keypad mode**
  82 +**Note: The length of the command data received by the base station at a time does not exceed 2K. When sending a command using a specified keypad, if the command length exceeds the limit, it is recommended to split the command and send it in parts. If the command is executed by all keypad, keySns can be set to an empty array to not use the specified keypad mode**
83 83  
84 84 ## Quick function checking list
85 85 ### Base Station Management
... ... @@ -88,7 +88,7 @@ The topic subscribed by the application, published by the base station &lt;br&gt;
88 88 |Base station connection - Get online base station|Actively obtain online base station information<br>When the base station SN is uncertain|[getBsOnlineState](#getbsonlinestate)|[fEvtBsOnlineState](#fevtbsonlinestate)||
89 89 |Base station connection - Actively obtain status|Actively obtain base station connection status|[getBsConnectState](#getbsconnectstate)|[sEvtBsConnectState](#sevtbsconnectstate)||
90 90 |Base station connection - Automatically obtain status|System notification of base station connection changes|-|[sEvtBsConnectState](#sevtbsconnectstate)||
91   -|Base station timing|Base station timing is used to calibrate time|[timeSync](#timesync)|[sEvtStateCode](#sevtstatecode)||
  91 +|Base station timing|Time synchronization for base stations to calibrate time|[timeSync](#timesync)|[sEvtStateCode](#sevtstatecode)||
92 92 |Keypad online notification|Single Keypad online system notification|-|[sEvtBsKpOnlineMsg](#sevtbskponlinemsg)||
93 93 |Identify Settings - Base Station Model|Read Base Station Model|[getBsModel](#getbsmodel)|[fEvtBsModel](#fevtbsmodel)|
94 94 |Identify Settings - Firmware Version|Get Base Station Firmware Version|[getBsFWVersion](#getbsfwversion)|[fEvtBsFWVersion](#fevtbsfwversion)|
... ... @@ -135,16 +135,16 @@ The topic subscribed by the application, published by the base station &lt;br&gt;
135 135 ||Stop Numeric|[stopQANum](#stopqanum)|[sEvtStateCode](#sevtstatecode)|
136 136 |Rush Answer|Start Rush Answer|[startQAQuicker](#startqaquicker)|[sEvtStateCode](#sevtstatecode)<br>[fEvtQAQuicker](#fevtqaquicker)|
137 137 ||Stop Rush Answer|[stopQAQuicker](#stopqaquicker)|[sEvtStateCode](#sevtstatecode)|
138   -### Online Quiz
  138 +### Online Exam/Test
139 139 |Function classification|Function|API command|Command event|
140 140 |---|---|---|---|
141 141 |Standard Exam|Start Standard Exam|[startKpExam](#startkpexam)|[sEvtStateCode](#sevtstatecode)<br>[fEvtKpExam](#fevtkpexam)<br>[fEvtFinalSubmit](#fevtfinalsubmit)|
142 142 ||Stop Standard Exam|[stopKpExam](#stopkpexam)|[sEvtStateCode](#sevtstatecode)|
143   -||Allow keypad submission and rollback|[rtAllowEdited](#rtkpallowedited)|[sEvtStateCode](#sevtstatecode)<br>[fEvtFinalSubmit](#fevtfinalsubmit)|
  143 +||Allow keypad to return for modifications after submission|[rtAllowEdited](#rtkpallowedited)|[sEvtStateCode](#sevtstatecode)<br>[fEvtFinalSubmit](#fevtfinalsubmit)|
144 144  
145 145 ## Public Events
146 146 ### sEvtBsConnectState
147   -- **Subject**: /basestation/\${baseSN}/receive
  147 +- **Topic**: /basestation/\${baseSN}/receive
148 148 - **Function description**:Returns the base station model and base station SN when the base station is successfully connected, and returns disconnected when the base station is disconnected from the connected state
149 149 - **Parameter Description**
150 150  
... ... @@ -183,7 +183,7 @@ The topic subscribed by the application, published by the base station &lt;br&gt;
183 183 ```
184 184  
185 185 ### sEvtBsChannelConflict
186   -- **Subject**: /basestation/\${baseSN}/receive
  186 +- **Topic**: /basestation/\${baseSN}/receive
187 187 - **Function description**:Actively report when base station channels conflict, and the application can modify the base station channels according to actual case
188 188 - **Parameter Description**
189 189  
... ... @@ -207,7 +207,7 @@ The topic subscribed by the application, published by the base station &lt;br&gt;
207 207 ```
208 208  
209 209 ### sEvtBsNfcResults
210   -- **Subject**: /basestation/\${baseSN}/receive
  210 +- **Topic**: /basestation/\${baseSN}/receive
211 211 - **Function description**: Actively report when swiping the card with the keypad, and report failure if the capacity of the base station is exceeded
212 212 - **Parameter Description**
213 213  
... ... @@ -224,7 +224,7 @@ The topic subscribed by the application, published by the base station &lt;br&gt;
224 224 ```json
225 225 {
226 226 "fun":"sEvtBsNfcResults",
227   - "dataTag":"1", //an empty string can be passed if not needed|
  227 + "dataTag":"1", //An empty string can be passed if not needed|
228 228 "data":{
229 229 "keySn":"1234567890",
230 230 "value":1
... ... @@ -233,7 +233,7 @@ The topic subscribed by the application, published by the base station &lt;br&gt;
233 233 ```
234 234  
235 235 ### sEvtBsKpOnlineMsg
236   -- **Subject**: /basestation/\${baseSN}/receive
  236 +- **Topic**: /basestation/\${baseSN}/receive
237 237 - **Function description**: Keypad online notification, active reporting, and also reporting after successful keypad upgrade
238 238 - **Parameter Description**
239 239  
... ... @@ -263,7 +263,7 @@ The topic subscribed by the application, published by the base station &lt;br&gt;
263 263 ```
264 264  
265 265 ### sEvtStateCode
266   -- **Subject**: /basestation/\${baseSN}/receive
  266 +- **Topic**: /basestation/\${baseSN}/receive
267 267 - **Function description**: Return the status information of base station receiving command
268 268 - **Parameter Description**
269 269  
... ... @@ -309,7 +309,7 @@ The topic subscribed by the application, published by the base station &lt;br&gt;
309 309 #### Method
310 310  
311 311 ##### getBsOnlineState
312   -- **Subject**:<span class="yellowFill">/client/multiBase/send</span>
  312 +- **Topic**:<span class="yellowFill">/client/multiBase/send</span>
313 313 - **Function description**: Actively obtain all online base station information, online base station reply
314 314 - **Parameter Description**
315 315  
... ... @@ -327,7 +327,7 @@ The topic subscribed by the application, published by the base station &lt;br&gt;
327 327 ```
328 328  
329 329 ##### getBsConnectState
330   -- **Subject**:/client/\${baseSN}/send
  330 +- **Topic**:/client/\${baseSN}/send
331 331 - **Function description**: Actively obtain base station connection status
332 332 - **Parameter Description**
333 333  
... ... @@ -350,7 +350,7 @@ The topic subscribed by the application, published by the base station &lt;br&gt;
350 350 See Base Station Connection Change System Notification
351 351  
352 352 ##### fEvtBsOnlineState
353   -- **Subject**: <span class="yellowFill">/basestation/mutilBase/receive</span>
  353 +- **Topic**: <span class="yellowFill">/basestation/mutilBase/receive</span>
354 354 - **Function description**: The base station returns the base station model and base station SN online
355 355 - **Parameter Description**
356 356  
... ... @@ -380,10 +380,10 @@ See Base Station Connection Change System Notification
380 380 }
381 381 ```
382 382  
383   -### Base station timing
  383 +### Base station time synchronization
384 384 #### Method
385 385 ##### timeSync
386   -- **Subject**:/client/\${baseSN}/send
  386 +- **Topic**:/client/\${baseSN}/send
387 387 - **Function description**: Send the current timestamp to the base station for time calibration
388 388 - **Parameter Description**
389 389  
... ... @@ -406,14 +406,14 @@ See Base Station Connection Change System Notification
406 406 }
407 407 ```
408 408  
409   -#### event
  409 +#### Event
410 410 ##### [sEvtStateCode](#sevtstatecode)
411 411 Returns the command reception status
412 412  
413 413 ### Identification Settings
414 414 #### method
415 415 ##### getBsModel
416   -- **Subject**:/client/\${baseSN}/send
  416 +- **Topic**:/client/\${baseSN}/send
417 417 - **Function description**: Get base station model
418 418 - **Parameter Description**
419 419  
... ... @@ -432,7 +432,7 @@ Returns the command reception status
432 432 ```
433 433  
434 434 ##### getBsFWVersion
435   -- **Subject**:/client/\${baseSN}/send
  435 +- **Topic**:/client/\${baseSN}/send
436 436 - **Function description**: Get base station firmware version
437 437 - **Parameter Description**
438 438  
... ... @@ -452,7 +452,7 @@ Returns the command reception status
452 452  
453 453 #### Event
454 454 ##### fEvtBsSN
455   -- **Subject**: /basestation/\${baseSN}/receive
  455 +- **Topic**: /basestation/\${baseSN}/receive
456 456 - **Function description**: Return the factory code of the base station
457 457 - **Parameter Description**
458 458  
... ... @@ -476,7 +476,7 @@ Returns the command reception status
476 476 ```
477 477  
478 478 ##### fEvtBsModel
479   -- **Subject**: /basestation/\${baseSN}/receive
  479 +- **Topic**: /basestation/\${baseSN}/receive
480 480 - **Function description**: Returns the model of the base station
481 481 - **Parameter Description**
482 482  
... ... @@ -500,7 +500,7 @@ Returns the command reception status
500 500 ```
501 501  
502 502 ##### fEvtBsFWVersion
503   -- **Subject**: /basestation/\${baseSN}/receive
  503 +- **Topic**: /basestation/\${baseSN}/receive
504 504 - **Function description**: Returns the firmware version of the base station
505 505 - **Parameter Description**
506 506  
... ... @@ -526,7 +526,7 @@ Returns the command reception status
526 526 ### Network settings
527 527 #### Method
528 528 ##### getBsPairCode
529   -- **Subject**:/client/\${baseSN}/send
  529 +- **Topic**:/client/\${baseSN}/send
530 530 - **Function description**: Get base station pairing code
531 531 - **Parameter Description**
532 532  
... ... @@ -545,8 +545,8 @@ Returns the command reception status
545 545 ```
546 546  
547 547 ##### getBsNfcLogin
548   -- **Subject**:/client/\${baseSN}/send
549   -- **Function description**: Get card pairing status
  548 +- **Topic**:/client/\${baseSN}/send
  549 +- **Function description**: Get card swipe pairing status
550 550 - **Parameter Description**
551 551  
552 552  
... ... @@ -566,7 +566,7 @@ Returns the command reception status
566 566 ```
567 567  
568 568 ##### setBsNfcLogin
569   -- **Subject**:/client/\${baseSN}/send
  569 +- **Topic**:/client/\${baseSN}/send
570 570 - **Function description**: Set the base station card swipe pairing status
571 571 - **Parameter Description**
572 572  
... ... @@ -575,7 +575,7 @@ Returns the command reception status
575 575 |fun|string|-|True|Command name|
576 576 |dataTag|string|-|False|Data packet tag, can be an empty string|
577 577 |data|object|-|True|The object to pass parameters|
578   -|+value|string|-|True|Set the base station card pairing status<br>0-Close card pairing<br>1-Open card pairing|
  578 +|+value|string|-|True|Set the base station card swipe pairing status<br>0-Close card swipe pairing<br>1-Open card swipe pairing|
579 579  
580 580 - **Sample Code**
581 581  
... ... @@ -590,7 +590,7 @@ Returns the command reception status
590 590 ```
591 591  
592 592 ##### getBsChannel
593   -- **Subject**:/client/\${baseSN}/send
  593 +- **Topic**:/client/\${baseSN}/send
594 594 - **Function description**: Get base station channel
595 595 - **Parameter Description**
596 596  
... ... @@ -609,7 +609,7 @@ Returns the command reception status
609 609 ```
610 610  
611 611 ##### setBsChannel
612   -- **Subject**:/client/\${baseSN}/send
  612 +- **Topic**:/client/\${baseSN}/send
613 613 - **Function description**: Set base station channel
614 614 - **Parameter Description**
615 615  
... ... @@ -634,7 +634,7 @@ Returns the command reception status
634 634  
635 635 #### Event
636 636 ##### fEvtBsPairCode
637   -- **Subject**: /basestation/\${baseSN}/receive
  637 +- **Topic**: /basestation/\${baseSN}/receive
638 638 - **Function description**: Return base station pairing code
639 639 - **Parameter Description**
640 640  
... ... @@ -658,8 +658,8 @@ Returns the command reception status
658 658 ```
659 659  
660 660 ##### fEvtBsChannel
661   -- **Subject**: /basestation/\${baseSN}/receive
662   -- **Function description**: Return to base station channel
  661 +- **Topic**: /basestation/\${baseSN}/receive
  662 +- **Function description**: Return the base station channel
663 663 - **Parameter Description**
664 664  
665 665 |Parameter name|Type|Restriction|Not null|Description|
... ... @@ -682,7 +682,7 @@ Returns the command reception status
682 682 ```
683 683  
684 684 ##### fEvtBsNfcLogin
685   -- **Subject**: /basestation/\${baseSN}/receive
  685 +- **Topic**: /basestation/\${baseSN}/receive
686 686 - **Function description**: Returns whether the base station allows NFC card swiping
687 687 - **Parameter Description**
688 688  
... ... @@ -709,7 +709,7 @@ Returns the command reception status
709 709 #### Method
710 710 ##### getBsSSID
711 711 Get the base station login name
712   -- **Subject**:/client/\${baseSN}/send
  712 +- **Topic**:/client/\${baseSN}/send
713 713 - **Function description**: Get the base station login name
714 714 - **Parameter Description**
715 715  
... ... @@ -728,7 +728,7 @@ Get the base station login name
728 728 ```
729 729  
730 730 ##### setBsSSID
731   -- **Subject**:/client/\${baseSN}/send
  731 +- **Topic**:/client/\${baseSN}/send
732 732 - **Function description**: Set the base station login name
733 733 - **Parameter Description**
734 734  
... ... @@ -753,7 +753,7 @@ Get the base station login name
753 753  
754 754 #### Event
755 755 ##### fEvtBsSSID
756   -- **Subject**: /basestation/\${baseSN}/receive
  756 +- **Topic**: /basestation/\${baseSN}/receive
757 757 - **Function description**: Return the base station name
758 758 - **Parameter Description**
759 759  
... ... @@ -779,7 +779,7 @@ Get the base station login name
779 779 ### Keypad unified settings
780 780 #### Method
781 781 ##### getBsKpLanguage
782   -- **Subject**:/client/\${baseSN}/send
  782 +- **Topic**:/client/\${baseSN}/send
783 783 - **Function description**: Get Keypad language
784 784 - **Parameter Description**
785 785  
... ... @@ -799,7 +799,7 @@ Get the base station login name
799 799 ```
800 800  
801 801 ##### setBsKpLanguage
802   -- **Subject**:/client/\${baseSN}/send
  802 +- **Topic**:/client/\${baseSN}/send
803 803 - **Function description**: Set keypad language
804 804 - **Parameter Description**
805 805  
... ... @@ -825,7 +825,7 @@ Get the base station login name
825 825  
826 826 #### Event
827 827 ##### fEvtBsKpLanguage
828   -- **Subject**: /basestation/\${baseSN}/receive
  828 +- **Topic**: /basestation/\${baseSN}/receive
829 829 - **Function description**: Return keypad language
830 830 - **Parameter Description**
831 831  
... ... @@ -851,7 +851,7 @@ Get the base station login name
851 851 ### Network parameter settings
852 852 #### Method
853 853 ##### getBsTcpipParams
854   -- **Subject**:/client/\${baseSN}/send
  854 +- **Topic**:/client/\${baseSN}/send
855 855 - **Function description**: Get base station TCP/IP parameters
856 856 - **Parameter Description**
857 857  
... ... @@ -870,7 +870,7 @@ Get the base station login name
870 870 ```
871 871  
872 872 ##### setBsTcpipParams
873   -- **Subject**:/client/\${baseSN}/send
  873 +- **Topic**:/client/\${baseSN}/send
874 874 - **Function description**: Set base station TCP/IP parameters
875 875 - **Parameter Description**
876 876  
... ... @@ -900,7 +900,7 @@ Get the base station login name
900 900 ```
901 901  
902 902 ##### getBsMqttParams
903   -- **Subject**:/client/\${baseSN}/send
  903 +- **Topic**:/client/\${baseSN}/send
904 904 - **Function description**: Get base station MQTT parameters
905 905 - **Parameter Description**
906 906  
... ... @@ -919,7 +919,7 @@ Get the base station login name
919 919 ```
920 920  
921 921 ##### setBsMqttParams
922   -- **Subject**:/client/\${baseSN}/send
  922 +- **Topic**:/client/\${baseSN}/send
923 923 - **Function description**: Set base station MQTT parameters
924 924 - **Parameter Description**
925 925  
... ... @@ -952,7 +952,7 @@ Get the base station login name
952 952  
953 953 #### Event
954 954 ##### fEvtBsTcpipParams
955   -- **Subject**: /basestation/\${baseSN}/receive
  955 +- **Topic**: /basestation/\${baseSN}/receive
956 956 - **Function description**: Return base station TCP/IP parameters
957 957 - **Parameter Description**
958 958  
... ... @@ -984,7 +984,7 @@ Get the base station login name
984 984 ```
985 985  
986 986 ##### fEvtBsMqttParams
987   -- **Subject**: /basestation/\${baseSN}/receive
  987 +- **Topic**: /basestation/\${baseSN}/receive
988 988 - **Function description**: Return base station MQTT parameters
989 989 - **Parameter Description**
990 990  
... ... @@ -1018,7 +1018,7 @@ Get the base station login name
1018 1018 ### Base Station Maintenance
1019 1019 #### Method
1020 1020 ##### getBsLogInfo
1021   -- **Subject**:/client/\${baseSN}/send
  1021 +- **Topic**:/client/\${baseSN}/send
1022 1022 - **Function description**: Get base station logs, which are used to obtain internal log records of base stations when a fault occurs and needs to be investigated
1023 1023 - **Parameter Description**
1024 1024  
... ... @@ -1044,7 +1044,7 @@ Returns the command reception status
1044 1044 ### Interaction Settings
1045 1045 #### Method
1046 1046 ##### rtSetKpUserPrompt
1047   -- **Subject**:/client/\${baseSN}/send
  1047 +- **Topic**:/client/\${baseSN}/send
1048 1048 - **Function description**: Real-time setting prompt feedback information
1049 1049 - **Parameter Description**
1050 1050  
... ... @@ -1089,10 +1089,10 @@ Returns the command reception status
1089 1089  
1090 1090 #### Event
1091 1091 ##### [sEvtStateCode](#sevtstatecode)
1092   -Return to receiving status after sending command
  1092 +Return the receiving status after sending command
1093 1093  
1094 1094 ##### fEvtSetKpUserPrompt
1095   -- **Subject**:/basestation/\${baseSN}/receive
  1095 +- **Topic**:/basestation/\${baseSN}/receive
1096 1096 - **Function description**: Returns whether the real-time setting prompt is successful
1097 1097 - **Parameter Description**
1098 1098  
... ... @@ -1130,7 +1130,7 @@ Return to receiving status after sending command
1130 1130 ### Online status
1131 1131 #### Method
1132 1132 ##### startGetKpOnline
1133   -- **Subject**:/client/\${baseSN}/send
  1133 +- **Topic**:/client/\${baseSN}/send
1134 1134 - **Function description**: Start to get keypad online information, keypad online returns keypad information [sEvtBsKpOnlineMsg](#sevtbskponlinemsg)
1135 1135 - **Parameter Description**
1136 1136  
... ... @@ -1149,7 +1149,7 @@ Return to receiving status after sending command
1149 1149 ```
1150 1150  
1151 1151 ##### stopGetKpOnline
1152   -- **Subject**:/client/\${baseSN}/send
  1152 +- **Topic**:/client/\${baseSN}/send
1153 1153 - **Function description**: Stop obtaining keypad online information
1154 1154 - **Parameter Description**
1155 1155  
... ... @@ -1177,7 +1177,7 @@ The keypad is online and returns this event
1177 1177 ### Maintenance Function
1178 1178 #### Method
1179 1179 ##### remoteKpSleep
1180   -- **Subject**:/client/\${baseSN}/send
  1180 +- **Topic**:/client/\${baseSN}/send
1181 1181 - **Function description**: Remote control keypad sleep
1182 1182 - **Parameter Description**
1183 1183  
... ... @@ -1208,7 +1208,7 @@ Returns the command reception status
1208 1208 ### Wireless Binding
1209 1209 #### Method
1210 1210 ##### rtSetKpBindingInfo
1211   -- **Subject**:/client/\${baseSN}/send
  1211 +- **Topic**:/client/\${baseSN}/send
1212 1212 - **Function description**: Set binding information to keypad in real time
1213 1213 - **Parameter Description**
1214 1214  
... ... @@ -1230,18 +1230,18 @@ Returns the command reception status
1230 1230 "data": [
1231 1231 {
1232 1232 "keySn": "1479824643",
1233   - "info": "张三"
  1233 + "info": "John"
1234 1234 },
1235 1235 {
1236 1236 "keySn": "1479824644",
1237   - "info": "李四"
  1237 + "info": "John"
1238 1238 }
1239 1239 ]
1240 1240 }
1241 1241 ```
1242 1242  
1243 1243 ##### clearKpBindingInfo
1244   -- **Subject**:/client/\${baseSN}/send
  1244 +- **Topic**:/client/\${baseSN}/send
1245 1245 - **Function description**: Clear keypad binding information
1246 1246 - **Parameter Description**
1247 1247  
... ... @@ -1267,10 +1267,10 @@ Returns the command reception status
1267 1267  
1268 1268 #### Event
1269 1269 ##### [sEvtStateCode](#sevtstatecode)
1270   -Return to receiving status after sending command
  1270 +Return the receiving status after sending command
1271 1271  
1272 1272 ##### fEvtKpBindingInfo
1273   -- **Subject**:/basestation/\${baseSN}/receive
  1273 +- **Topic**:/basestation/\${baseSN}/receive
1274 1274 - **Function description**: Returns whether the keypad real-time setting binding information status is successful
1275 1275 - **Parameter Description**
1276 1276  
... ... @@ -1302,7 +1302,7 @@ Return to receiving status after sending command
1302 1302 ```
1303 1303  
1304 1304 ##### fEvtClearKpBindingInfo
1305   -- **Subject**:/basestation/\${baseSN}/receive
  1305 +- **Topic**:/basestation/\${baseSN}/receive
1306 1306 - **Function description**: Returns whether the command status of clearing binding information is successful
1307 1307 - **Parameter Description**
1308 1308  
... ... @@ -1329,7 +1329,7 @@ Return to receiving status after sending command
1329 1329 ### Sign in at any time
1330 1330 #### Method
1331 1331 ##### rtStartKpSignIn
1332   -- **Subject**:/client/\${baseSN}/send
  1332 +- **Topic**:/client/\${baseSN}/send
1333 1333 - **Function description**: Enable binding for sign in at any time
1334 1334 - **Parameter Description**
1335 1335  
... ... @@ -1353,7 +1353,7 @@ Return to receiving status after sending command
1353 1353 ```
1354 1354  
1355 1355 ##### rtStopKpSignIn
1356   -- **Subject**:/client/\${baseSN}/send
  1356 +- **Topic**:/client/\${baseSN}/send
1357 1357 - **Function description**: Stop binding for signing in
1358 1358 - **Parameter Description**
1359 1359  
... ... @@ -1373,7 +1373,7 @@ Return to receiving status after sending command
1373 1373 ```
1374 1374  
1375 1375 ##### rtSetKpLoginAllowed
1376   -- **Subject**:/client/\${baseSN}/send
  1376 +- **Topic**:/client/\${baseSN}/send
1377 1377 - **Function description**: Real-time PIN binding authorization, authorization can be cancelled
1378 1378 - **Parameter Description**
1379 1379  
... ... @@ -1383,7 +1383,7 @@ Return to receiving status after sending command
1383 1383 |dataTag|string|-|False|Data packet tag, can be an empty string|
1384 1384 |data|object|-|False|The object to pass parameters|
1385 1385 |+keySn|string|-|True|Keypad SN|
1386   -|+state|int|-|True|1-Authorization successful<br>2-Authorization failed<br>3-Release authorization|
  1386 +|+state|int|-|True|1-Authorization successful<br>2-Authorization failed<br>3-Revoke authorization|
1387 1387  
1388 1388 - **Sample Code**
1389 1389  
... ... @@ -1400,11 +1400,11 @@ Return to receiving status after sending command
1400 1400  
1401 1401 #### Event
1402 1402 ##### [sEvtStateCode](#sevtstatecode)
1403   -Return to receiving status after sending command
  1403 +Return the receiving status after sending command
1404 1404  
1405 1405 ##### fEvtKpSignIn
1406   -- **Subject**:/basestation/\${baseSN}/receive
1407   -- **Function description**: Return to the keypad to submit sign-in information
  1406 +- **Topic**:/basestation/\${baseSN}/receive
  1407 +- **Function description**: Returns the sign-in information submitted by the keypad
1408 1408 - **Parameter Description**
1409 1409  
1410 1410 |Parameter name|Type|Restriction|Not null|Description|
... ... @@ -1437,7 +1437,7 @@ Return to receiving status after sending command
1437 1437 ```
1438 1438  
1439 1439 ##### fEvtKpLoginAllowed
1440   -- **Subject**:/basestation/\${baseSN}/receive
  1440 +- **Topic**:/basestation/\${baseSN}/receive
1441 1441 - **Function description**: Return keypad authorization status
1442 1442 - **Parameter Description**
1443 1443  
... ... @@ -1466,7 +1466,7 @@ Return to receiving status after sending command
1466 1466 ### True or False
1467 1467 #### Method
1468 1468 ##### startQATrueFalse
1469   -- **Subject**:/client/\${baseSN}/send
  1469 +- **Topic**:/client/\${baseSN}/send
1470 1470 - **Function description**: Start true or false questions
1471 1471 - **Parameter Description**
1472 1472  
... ... @@ -1496,7 +1496,7 @@ Return to receiving status after sending command
1496 1496 ```
1497 1497  
1498 1498 ##### stopQATrueFalse
1499   -- **Subject**:/client/\${baseSN}/send
  1499 +- **Topic**:/client/\${baseSN}/send
1500 1500 - **Function description**: Stop true or false questions
1501 1501 - **Parameter Description**
1502 1502  
... ... @@ -1516,11 +1516,11 @@ Return to receiving status after sending command
1516 1516  
1517 1517 #### Event
1518 1518 ##### [sEvtStateCode](#sevtstatecode)
1519   -Return to receiving status after sending command
  1519 +Return the receiving status after sending command
1520 1520  
1521 1521 ##### fEvtQATrueFalse
1522   -- **Subject**:/basestation/\${baseSN}/receive
1523   -- **Function description**: Return to the keypad to submit answer information
  1522 +- **Topic**:/basestation/\${baseSN}/receive
  1523 +- **Function description**: Returns the answer information submitted by the keypad
1524 1524 - **Parameter Description**
1525 1525  
1526 1526 |Parameter name|Type|Restriction|Not null|Description|
... ... @@ -1547,11 +1547,11 @@ Return to receiving status after sending command
1547 1547 }
1548 1548 ```
1549 1549  
1550   -### Multiple choice questions
  1550 +### Choice questions
1551 1551 #### Method
1552 1552 ##### startQAChoice
1553   -- **Subject**:/client/\${baseSN}/send
1554   -- **Function description**: Start multiple-choice questions
  1553 +- **Topic**:/client/\${baseSN}/send
  1554 +- **Function description**: Start choice questions
1555 1555 - **Parameter Description**
1556 1556  
1557 1557 |Parameter name|Type|Restriction|Required|Description|
... ... @@ -1561,7 +1561,7 @@ Return to receiving status after sending command
1561 1561 |data|object|-|True|The object to pass parameters|
1562 1562 |+keySns|array||True|The specified Keypad SN array, an empty array means all online keypads|
1563 1563 |+mode|int||True|Display mode<br>1:display letters (default value) </br>2:display numbers|
1564   -|+lessMode|int||True|Forced selection mode<br>0: optional (default value) </br>1: cannot missing </br>2: Repeated input is allowed</br>3: Repeated input is allowed and cannot be missing |
  1564 +|+lessMode|int||True|Forced selection mode<br>0: optional (default value) </br>1: Cannot be omitted </br>2: Repeated input is allowed</br>3: Repeated input is allowed and cannot be omitted |
1565 1565 |+options|int||True|the number of options,1≤M≤10(Default 4)|
1566 1566 |+optionalN|int||True|the selectable number of options,1≤N≤M(Defaule 1)|
1567 1567 |+allowModify|int||True|Modify mode<br>0 - Do not allow modification<br>1 - Allow modification|
... ... @@ -1586,8 +1586,8 @@ Return to receiving status after sending command
1586 1586 ```
1587 1587  
1588 1588 ##### stopQAChoice
1589   -- **Subject**:/client/\${baseSN}/send
1590   -- **Function description**: Stop multiple-choice questions
  1589 +- **Topic**:/client/\${baseSN}/send
  1590 +- **Function description**: Stop choice questions
1591 1591 - **Parameter Description**
1592 1592  
1593 1593 |Parameter name|Type|Restriction|Required|Description|
... ... @@ -1606,11 +1606,11 @@ Return to receiving status after sending command
1606 1606  
1607 1607 #### Event
1608 1608 ##### [sEvtStateCode](#sevtstatecode)
1609   -Return to receiving status after sending command
  1609 +Return the receiving status after sending command
1610 1610  
1611 1611 ##### fEvtQAChoice
1612   -- **Subject**:/basestation/\${baseSN}/receive
1613   - **Function description**: Return to the keypad to submit answer information
  1612 +- **Topic**:/basestation/\${baseSN}/receive
  1613 + **Function description**: Returns the answer information submitted by the keypad
1614 1614 - **Parameter Description**
1615 1615  
1616 1616 |Parameter name|Type|Restriction|Not null|Description|
... ... @@ -1639,7 +1639,7 @@ Return to receiving status after sending command
1639 1639 ### Numeric
1640 1640 #### Method
1641 1641 ##### startQANum
1642   -- **Subject**:/client/\${baseSN}/send
  1642 +- **Topic**:/client/\${baseSN}/send
1643 1643 - **Function description**: Start Numeric Question
1644 1644 - **Parameter Description**
1645 1645  
... ... @@ -1675,7 +1675,7 @@ Return to receiving status after sending command
1675 1675 ```
1676 1676  
1677 1677 ##### stopQANum
1678   -- **Subject**:/client/\${baseSN}/send
  1678 +- **Topic**:/client/\${baseSN}/send
1679 1679 - **Function description**: Stop Numeric Question
1680 1680 - **Parameter Description**
1681 1681  
... ... @@ -1695,11 +1695,11 @@ Return to receiving status after sending command
1695 1695  
1696 1696 #### Event
1697 1697 ##### [sEvtStateCode](#sevtstatecode)
1698   -Return to receiving status after sending command
  1698 +Return the receiving status after sending command
1699 1699  
1700 1700 ##### fEvtQANum
1701   -- **Subject**:/basestation/\${baseSN}/receive
1702   -- **Function description**: Return to the keypad to submit answer information
  1701 +- **Topic**:/basestation/\${baseSN}/receive
  1702 +- **Function description**: Returns the answer information submitted by the keypad
1703 1703 - **Parameter Description**
1704 1704  
1705 1705 |Parameter name|Type|Restriction|Not null|Description|
... ... @@ -1728,7 +1728,7 @@ Return to receiving status after sending command
1728 1728 ### Rush Answer
1729 1729 #### Method
1730 1730 ##### startQAQuicker
1731   -- **Subject**:/client/\${baseSN}/send
  1731 +- **Topic**:/client/\${baseSN}/send
1732 1732 - **Function description**: Start Rush Answer
1733 1733 - **Parameter Description**
1734 1734  
... ... @@ -1758,7 +1758,7 @@ Return to receiving status after sending command
1758 1758 ```
1759 1759  
1760 1760 ##### stopQAQuicker
1761   -- **Subject**:/client/\${baseSN}/send
  1761 +- **Topic**:/client/\${baseSN}/send
1762 1762 - **Function description**: Start Rush Answer
1763 1763 - **Parameter Description**
1764 1764  
... ... @@ -1778,11 +1778,11 @@ Return to receiving status after sending command
1778 1778  
1779 1779 #### Event
1780 1780 ##### [sEvtStateCode](#sevtstatecode)
1781   -Return to receiving status after sending command
  1781 +Return the receiving status after sending command
1782 1782  
1783 1783 ##### fEvtQAQuicker
1784   -- **Subject**:/basestation/\${baseSN}/receive
1785   -- **Function description**: Return to the keypad to submit answer information
  1784 +- **Topic**:/basestation/\${baseSN}/receive
  1785 +- **Function description**: Returns the answer information submitted by the keypad
1786 1786 - **Parameter Description**
1787 1787  
1788 1788 |Parameter name|Type|Restriction|Not null|Description|
... ... @@ -1808,11 +1808,11 @@ Return to receiving status after sending command
1808 1808 }
1809 1809 ```
1810 1810  
1811   -## Online Quiz
  1811 +## Online Exam/Test
1812 1812 ### Standard Test
1813 1813 #### Method
1814 1814 ##### startKpExam
1815   -- **Subject**:/client/\${baseSN}/send
  1815 +- **Topic**:/client/\${baseSN}/send
1816 1816 - **Function description**: Start standard test
1817 1817 - **Parameter Description**
1818 1818  
... ... @@ -1822,7 +1822,7 @@ Return to receiving status after sending command
1822 1822 |dataTag|string|-|False|Data packet tag, can be an empty string|
1823 1823 |data|object|-|True|The object to pass parameters|
1824 1824 |+examNo|int||True|0-9999<br>=0,new test<br>>0, continue the test if the roll number is the same as the last one , otherwise start a new test|
1825   -|+mode|int||True|Display mode<br>0-Do not display the beginning<br>1-Display the beginning of "Q"<br>2-Display the beginning of "题"|
  1825 +|+mode|int||True|Display mode<br>0-Do not display the beginning<br>1-Display the beginning as "Q"<br>2-Display the beginning as "Qustion"|
1826 1826 |+questions|array||True|question details|
1827 1827 |++symbol | string||True | Question prefix, can be empty|
1828 1828 |++quesType | int||True| Question type<br>1: Single choice<br>2: Multiple choices (sort)<br>3: Numeric<br>4: Judgement|
... ... @@ -1869,7 +1869,7 @@ Return to receiving status after sending command
1869 1869 }
1870 1870 }
1871 1871  
1872   -//Display the beginning of Q
  1872 +//Display the beginning as Q
1873 1873 {
1874 1874 "fun": "startKpExam",
1875 1875 "dataTag":"1",
... ... @@ -1905,7 +1905,7 @@ Return to receiving status after sending command
1905 1905 ```
1906 1906  
1907 1907 ##### stopKpExam
1908   -- **Subject**:/client/\${baseSN}/send
  1908 +- **Topic**:/client/\${baseSN}/send
1909 1909 - **Function description**: Stop standard test
1910 1910 - **Parameter Description**
1911 1911  
... ... @@ -1924,7 +1924,7 @@ Return to receiving status after sending command
1924 1924 ```
1925 1925  
1926 1926 ##### rtKpAllowEdited
1927   -- **Subject**:/client/\${baseSN}/send
  1927 +- **Topic**:/client/\${baseSN}/send
1928 1928 - **Function description**: After keypad submission, allow the keypad to modify the answer
1929 1929 - **Parameter Description**
1930 1930  
... ... @@ -1949,11 +1949,11 @@ Return to receiving status after sending command
1949 1949  
1950 1950 #### Event
1951 1951 ##### [sEvtStateCode](#sevtstatecode)
1952   -Return to receiving status after sending command
  1952 +Return the receiving status after sending command
1953 1953  
1954 1954 ##### fEvtKpExam
1955   -- **Subject**:/basestation/\${baseSN}/receive
1956   -- **Function description**: Return to the keypad to submit answer information
  1955 +- **Topic**:/basestation/\${baseSN}/receive
  1956 +- **Function description**: Returns the answer information from the keypad
1957 1957 - **Parameter Description**
1958 1958  
1959 1959 |Parameter name|Type|Restriction|Not null|Description|
... ... @@ -1986,8 +1986,8 @@ Return to receiving status after sending command
1986 1986 ```
1987 1987  
1988 1988 ##### fEvtFinalSubmit
1989   -- **Subject**:/basestation/\${baseSN}/receive
1990   -- **Function description**: Return to the manual tests submission mark on the keypad
  1989 +- **Topic**:/basestation/\${baseSN}/receive
  1990 +- **Function description**: Return the manual submission mark of the keypad
1991 1991 - **Parameter Description**
1992 1992  
1993 1993 |Parameter name|Type|Restriction|Not null|Description|
... ... @@ -1996,7 +1996,7 @@ Return to receiving status after sending command
1996 1996 |dataTag|string|-|False|Data packet tag, can be an empty string|
1997 1997 |data|array|-|True|The object array to pass parameters|
1998 1998 |++keySn|string||True|Keypad SN|
1999   -|++keyValue|string||True|0 - Not submitted (reported when modifying keypad operation submission)<br>1 - Submitted|
  1999 +|++keyValue|string||True|0 - Not submitted (Allow keypad to report when modifying answers after submission)<br>1 - Submitted|
2000 2000 |++keyTime|double||True|The time to answer the question, calculated from the start, in seconds|
2001 2001  
2002 2002 - **Sample Code**
... ...