Jump to content

Template:Networking rutos manual mobile utilities: Difference between revisions

no edit summary
No edit summary
Line 543: Line 543:
         <th width=300">Action</th>
         <th width=300">Action</th>
         <th width=852">Post/get URL examples</th>
         <th width=852">Post/get URL examples</th>
</tr>
<tr>
        <td>Enable/Disable mobile data connection</td>
        <td>http://<span style="color: black;">192.168.1.1</span>/cgi-bin/mobile_date?username=user1&password=user_pass&value=on/off
        </td>
</tr>
<tr>
        <td>Set SIM PIN</td>
        <td>http://<span style="color: black;">192.168.1.1</span>/cgi-bin/mobile_sim_pin?username=user1&password=user_pass&pin=0000
        </td>
</tr>
</tr>
<tr>
<tr>
Line 581: Line 591:
     <li>SMS related post/get commands. Possible values are:
     <li>SMS related post/get commands. Possible values are:
         <ul>
         <ul>
            <li><i>mobile_data</i> - enables/disables mobile data connection</li>
            <li><i>mobile_sim_pin</i> - set SIM PIN for default sim</li>
             <li><i>sms_list</i> - view all SMS messages in storage</li>
             <li><i>sms_list</i> - view all SMS messages in storage</li>
             <li><i>sms_read</i> - read a single SMS message by specified SMS index (number)</li>
             <li><i>sms_read</i> - read a single SMS message by specified SMS index (number)</li>
Line 592: Line 604:
     <li><b>username</b> - SMS post/get configuration user name</li>
     <li><b>username</b> - SMS post/get configuration user name</li>
     <li><b>password</b> - SMS post/get configuration password</li>
     <li><b>password</b> - SMS post/get configuration password</li>
    <li><b>value</b> - Mobile data On/Off values</li>
    <li><b>pin</b> - SIM PIN code</li>
     <li><b>number</b> - SMS message index or (depending on context) recipient's phone number. SMS message indexes can be
     <li><b>number</b> - SMS message index or (depending on context) recipient's phone number. SMS message indexes can be
         viewed with the <i>sms_list</i> command.<br>Correct phone number format is:
         viewed with the <i>sms_list</i> command.<br>Correct phone number format is:
Line 616: Line 630:
     <li><b>View SMS list:</b><br><pre>curl -X GET "http://192.168.1.1/cgi-bin/sms_list?username=user1&password=user_pass"</pre></li>
     <li><b>View SMS list:</b><br><pre>curl -X GET "http://192.168.1.1/cgi-bin/sms_list?username=user1&password=user_pass"</pre></li>
     <li><b>Send SMS:</b><br><pre>curl -X GET "http://192.168.1.1/cgi-bin/sms_send?username=user1&password=user_pass&number=0037000000000&text=testmessage"</pre></li>
     <li><b>Send SMS:</b><br><pre>curl -X GET "http://192.168.1.1/cgi-bin/sms_send?username=user1&password=user_pass&number=0037000000000&text=testmessage"</pre></li>
</ul>
<b>Responses:</b>
<ul>
    <li><b>View SMS list:</b><br><pre>Index: the oldest received message starts with index 0
Date: date of message
Sender: the sender's phone number
Text: mesagge text
Status: read</pre></li>
    <li><b>Send SMS:</b><br><pre>OK: when SMS was sent
Error: when an SMS cannot be sent or the SMS limit is reached</pre></li>
    <li><b>Read SMS:</b><br><pre>Index: the oldest received message starts with index 0
Date: date of message
Sender: the sender's phone number
Text: mesagge text
Status: read
WRONG_NUMBER: when the wrong sms number is specified</pre></li>
    <li><b>View mobile messages total:</b><br><pre>Used: information about used memory
Total: information about available memory</pre></li>
    <li><b>Delete mobile message:</b><br><pre>OK: message deleted
WRONG_NUMBER: when the wrong sms number is specified</pre></li>
    <li><b>Set SIM PIN:</b><br><pre>PIN state: Required PIN or OK
Set SIM PIN successfully: after succesul SIM PIN set
PIN is not specified or it's format is incorrect: wrong format of SIM PIN
Failed to set PIN: Invalid response (5): wen etered wrong SIM PIN
</pre></li>
</ul>
</ul>