Documentation for `SIMCONNECT_RECV_EXCEPTION` is incorrect

Version: 1.1.2

Frequency: Consistently

Severity: High

Marketplace package name: N/A

Context: MSFS 2024 SDK Documentation

Similar MSFS 2020 issue: N/A

Bug description: The documentation for SIMCONNECT_RECV_EXCEPTION states that the dwIndex field is set to 0 if the index is unknown. There is no indicated similar special value for the dwSendID field. However, in SimConnect.h we can find:

SIMCONNECT_REFSTRUCT SIMCONNECT_RECV_EXCEPTION : public SIMCONNECT_RECV   // when dwID == SIMCONNECT_RECV_ID_EXCEPTION
{
    DWORD   dwException;    // see SIMCONNECT_EXCEPTION
    static const DWORD UNKNOWN_SENDID = 0;
    DWORD   dwSendID;       // see SimConnect_GetLastSentPacketID
    static const DWORD UNKNOWN_INDEX = DWORD_MAX;
    DWORD   dwIndex;        // index of parameter that was source of error
};

A developer depending on the documentation rather than the special value, will check for the wrong value. Note also that there is no indication that the two special values need to be referred to using qualified names, as in “SIMCONNECT_RECV_EXCEPTION::UNKNOWN_SENDID” and “SIMCONNECT_RECV_EXCEPTION::UNKNOWN_INDEX”.

Repro steps: N/A

Attachments: N/A

Private attachments: N/A

A fix has been made in the documentation SU3.

Regards,
Boris

Hey Boris,
What SDK version will this be in? Maybe even better; where can I find a mapping between SUs and SDK versions?

In SIMCONNECT_RECV_OPEN we get versions (major, minor, and build) for the “application” (I presume the simulator) and “SimConnect”, but it is unclear to me how this corresponds to Simulator versions, Service Updates, and SDK versions.

You should have the fix in the lastest SU3 sdk documentation version.
About the version number, MSFS24 is version 12x.x.x and MSFS2020 11.x.x.x
For minor and build number, it changes when we update the SimConnect API.

For SDK versions, SU3 is 1.4.5
SU4 will be 1.5.x and so on..

Hope this helps,

Regards,
Boris

For SDK versions, SU3 is 1.4.5

Ok, I downloaded that, but is still states the values are both zero.

Went to the file on disk to make doubly sure:

      <tr>
        <td><code class="inline">dwSendID</code></td>
        <td>
          <p>The ID of the packet that contained the error, see Remarks below.</p>
          <p>Special case: <code class="inline">UNKNOWN_SENDID = 0</code>.</p>
          <p>Note that if this special case is returned, there has been an <em>internal</em> problem.</p>
        </td>
      </tr>
      <tr>
        <td><code class="inline">dwIndex</code></td>
        <td>
          <p>The index number (starting at 1) of the first parameter that caused an error.</p>
          <p>Special case: <code class="inline">UNKNOWN_INDEX = 0</code>.</p>
        </td>
      </tr>

@Boris I have now downloaded the SU4 Beta (SDK version 1.5.2) and both values are still listed as being 0. SimConnect.h is also unchanged.

Hello,

I’m checking with the dev and I will let you know when I have some news to share about this.
Thank you.

Regards,
Boris

1 Like

Hello,
This should be fixed in SU5.

Regards,
Boris

@Boris Could you provide me with an overview of SU vs SimConnect reported simulator/simconnect version & build vs SDK version? Today I downloaded MSFS 2024 SDK version 1.6.6 and it is still showing “UNKNOWN_INDEX = 0” .

Bert

I’m sorry but I’m not sure to understand.

In simconnect.h :

And this is what’s documented in the documentation 1.6.6.0.

What do you expect exactly ? (I think I already answered this in my above posts).

Ok, I see where the confusion is:

My issue is about the documentation, the SimConnect.h header file was always as you state. In the documentation, file /Documentation/html/6_Programming_APIs/SimConnect/API_Reference/Structures_And_Enumerations/SIMCONNECT_RECV_EXCEPTION.htm, it states:

dwSendID | The ID of the packet that contained the error, see Remarks below. Special case: UNKNOWN_SENDID = 0. Note that if this special case is returned, there has been an internal problem.
dwIndex | The index number (starting at 1) of the first parameter that caused an error. Special case: UNKNOWN_INDEX = 0.

The documentation for UNKNOWN_INDEX is incorrect, as its value is not zero. Also, both UNKNOWN_SENDID and UNKNOWN_INDEX must always be prefixed with the struct’s name, so “SIMCONNECT_RECV_EXCEPTION::UNKNOWN_SENDID” and “SIMCONNECT_RECV_EXCEPTION::UNKNOWN_INDEX”, as they’re defined locally to that struct.

With respect to SU numbering: I don’t get SU numbers when I download the SDK, so “It is fixed in SU5” doesn’t help, because I don’t know which versions of the SDK belong to that particular Service Update. Updating the simulator also is pretty automatic, without it telling me “I am now updating to SU5”. Also, when I connect to the simulator using SimConnect, I get a message that contains version- and build-numbers, not SU numbers.

Bert

Thank you,

I updated the ticket we have in the backlog with all the info and this will be fixed.

When you download the SDK you can see the version

For the sim build number :

I agree. I will make sure to provide you with the exact SDK version once the documentation fix is available.

Regards,
Boris

Hello @BenkeiBuddy ,

We updated the documentation in SU6 flighting version 1.7.2.0

I just installed 1.7.2. The new documentation browser looks great, but…

Both still shown as 0.

Bert

You need to make sure that you are using the Flighting version of the documentation and not the retail one.


Ah. “Flighting” means “beta”. I was wondering about that, because I thought is was a “Flight Simulator” related thing.

Ok, seen it.

1 Like