Changes

1,080 bytes added ,  15:19, 22 October 2020
Line 1,493: Line 1,493:  
This is used for communicating with accessories over local wifi - in particular, [[Mario Kart Live: Home Circuit]] uses this.
 
This is used for communicating with accessories over local wifi - in particular, [[Mario Kart Live: Home Circuit]] uses this.
   −
A beacon is broadcasted. The SSID in the beacon is hidden (all-zero with the same length as the original SSID). The beacon contains two custom Nintendo tags with OUI <code>00:22:aa</code>. The beacon is identical to ldn, except for the following (besides SSID length difference and the lp2p-only Nintendo tags):
+
A beacon is broadcasted.
* "Tag: Traffic Indication Map (TIM)": "DTIM count" for lp2p is 1, with ldn it's 0.
  −
* "Tag: HT Capabilities (802.11n D1.10)": "HT Short GI for 20MHz" is set to "Not supported", for ldn it's "Supported".
  −
* "Tag: Vendor Specific: Microsoft Corp.: WMM/WME: Parameter Element" "Ac Parameters ACI 0": "CW Min: 15" for lp2p, "CW Min: 63" for ldn.
      
Action frames are only sent when done so by [[#SendToOtherGroup]].
 
Action frames are only sent when done so by [[#SendToOtherGroup]].
Line 1,505: Line 1,502:     
The DHCP server thread is started by the "nn.lp2p.StateMachine" thread eventually during group [[#CreateGroup|creation]].
 
The DHCP server thread is started by the "nn.lp2p.StateMachine" thread eventually during group [[#CreateGroup|creation]].
 +
 +
=== Beacon ===
 +
The SSID in the beacon is hidden (all-zero with the same length as the original SSID). The beacon contains two custom Nintendo tags with OUI <code>00:22:aa</code>. The beacon is identical to ldn, except for the following (besides SSID length difference and the lp2p-only Nintendo tags):
 +
* "Tag: Traffic Indication Map (TIM)": "DTIM count" for lp2p is 1, with ldn it's 0.
 +
* "Tag: HT Capabilities (802.11n D1.10)": "HT Short GI for 20MHz" is set to "Not supported", for ldn it's "Supported".
 +
* "Tag: Vendor Specific: Microsoft Corp.: WMM/WME: Parameter Element" "Ac Parameters ACI 0": "CW Min: 15" for lp2p, "CW Min: 63" for ldn.
 +
 +
Note that during group creation the beacon may be missing the Nintendo tags in some cases, since group creation didn't finish yet.
 +
 +
The first Nintendo tag contains the following data:
 +
 +
{| class="wikitable" border="1"
 +
|-
 +
! Offset
 +
! Size
 +
! Description
 +
|-
 +
| 0x0 || 0x2 || Usually 06 00?
 +
|-
 +
| 0x2 || 0x2 || Usually 20 02?(Second byte depends on whether encryption is used?)
 +
|-
 +
| 0x4 || 0x2 || Usually 01 00 or 02 00?(varies)
 +
|-
 +
| 0x6 || 0x8 || Big-endian version of [[#GroupInfo]]+0x10.
 +
|-
 +
| 0xE || 0x10 || Same as [[#GroupInfo]]+0x0.
 +
|-
 +
| 0x1E || || Start of encrypted (and crypto-related) data if enabled. 0x22-bytes when encrypted, 0xE-bytes when plaintext.
 +
|}
 +
 +
The second Nintendo tag contains the following data (data starting at +0x2 is encrypted if enabled, there's also an additional 0x14-bytes when encrypted):
 +
 +
{| class="wikitable" border="1"
 +
|-
 +
! Offset
 +
! Size
 +
! Description
 +
|-
 +
| 0x0 || 0x2 || Usually 06 01?
 +
|-
 +
| 0x2 || 0x1 || Plaintext: usually 21?
 +
|-
 +
| 0x3 || 0x1 || Plaintext: AdvertiseData size
 +
|-
 +
| 0x4 || {above size} || Plaintext: AdvertiseData
 +
|}
    
=== ActionFrame ===
 
=== ActionFrame ===