Difference between revisions of "ACI:GetConnectingNetworkMtu"

From 3dbrew
Jump to navigation Jump to search
(Created page with "=Request= {| class="wikitable" border="1" |- ! Index Word ! Description |- | 0 | Header code [0x04A20000] |} =Response= {| class="wikitable" border="1" |- ! Index Word !...")
 
m
 
(6 intermediate revisions by the same user not shown)
Line 19: Line 19:
 
|-
 
|-
 
| 2
 
| 2
| Output MTU value.
+
| MTU value.
 
|}
 
|}
  
 
=Description=
 
=Description=
If 3DS is connected to Internet return current access point MTU value.
+
Return the current access point to MTU value.
If 3DS isn't connected to Internet return last connected access point MTU value.(If 3DS has never connected any access point return 0)
+
If the 3DS is connected to the internet, return the current access point's MTU value.
 +
If the 3DS isn't connected to the internet, return the last connected access point's MTU value.
 +
(If the 3DS has never connected to any access point return to 0)
 +
 
 +
=Example=
 +
 
 +
Handle share_ac_handle;
 +
 
 +
u32* cache_buffer = getThreadCommandBuffer();
 +
 
 +
srvGetServiceHandle(&share_ac_handle, "ac:i");
 +
 
 +
cache_buffer[0] = IPC_MakeHeader(0x4A2, 0, 0); // 0x04A20000
 +
 +
svcSendSyncRequest(share_ac_handle);
 +
 
 +
printf("Result : 0x%lx", cache_buffer[1]);
 +
 
 +
printf("MTU value : %ld", cache_buffer[2]);
 +
 
 +
svcCloseHandle(share_ac_handle);

Latest revision as of 05:36, 5 November 2019

Request[edit]

Index Word Description
0 Header code [0x04A20000]

Response[edit]

Index Word Description
1 Result code
2 MTU value.

Description[edit]

Return the current access point to MTU value. If the 3DS is connected to the internet, return the current access point's MTU value. If the 3DS isn't connected to the internet, return the last connected access point's MTU value. (If the 3DS has never connected to any access point return to 0)

Example[edit]

Handle share_ac_handle;

u32* cache_buffer = getThreadCommandBuffer();

srvGetServiceHandle(&share_ac_handle, "ac:i");

cache_buffer[0] = IPC_MakeHeader(0x4A2, 0, 0); // 0x04A20000

svcSendSyncRequest(share_ac_handle);

printf("Result : 0x%lx", cache_buffer[1]);

printf("MTU value : %ld", cache_buffer[2]);

svcCloseHandle(share_ac_handle);