Changes

Jump to navigation Jump to search
1,665 bytes added ,  20:10, 14 August 2022
no edit summary
Line 1,696: Line 1,696:  
| 1150 || [8.0.0+] SetTouchScreenMagnification
 
| 1150 || [8.0.0+] SetTouchScreenMagnification
 
|-
 
|-
| 1151 || [9.0.0+] GetTouchScreenFirmwareVersion
+
| 1151 || [9.0.0+] [[#GetTouchScreenFirmwareVersion]]
 
|-
 
|-
 
| 1152 || [9.0.0+] SetTouchScreenDefaultConfiguration
 
| 1152 || [9.0.0+] SetTouchScreenDefaultConfiguration
Line 1,917: Line 1,917:  
== GetHidbusSystemServiceObject ==
 
== GetHidbusSystemServiceObject ==
 
No input, returns an [[#IHidbusSystemServer]].
 
No input, returns an [[#IHidbusSystemServer]].
 +
 +
== GetTouchScreenFirmwareVersion ==
 +
No input. Returns a [[#FirmwareVersion]].
 +
 +
This requests the current firmware version from the touch screen IC.
 +
 +
It first ensures the touch screen IC's chip id is one of the following:
 +
0x7036 - STMicroelectronics FingerTipS FT9CJ
 +
0x4036 - STMicroelectronics FingerTipS FT9CF
 +
 +
Then constructs the final firmware version as follows:
 +
uint32_t FtsVersion = GetFtsReleasedVer();    // Matches the xxxx value found in the FTS_xxxx.fts256 firmware files.
 +
 +
uint8_t FtsVersionByte0 = (FtsVersion & 0xFF);
 +
uint8_t FtsVersionByte1 = (FtsVersion & 0xFF00);
 +
uint8_t FtsVersionByte2 = (FtsVersion & 0xFF0000);
 +
uint8_t FtsVersionByte3 = (FtsVersion & 0xFF000000);
 +
 +
uint8_t FirmwareVersionByte0 = FtsVersionByte3;
 +
uint8_t FirmwareVersionByte1 = FtsVersionByte2;
 +
uint8_t FirmwareVersionByte2 = FtsVersionByte1;
 +
uint8_t FirmwareVersionByte3 = FtsVersionByte0;
 +
 +
if (FtsVersionByte3 <= 0x31) {
 +
    FirmwareVersionByte3 = 0;
 +
    FirmwareVersionByte1 = 0;
 +
    FirmwareVersionByte0 = 0x31;
 +
 +
    if (FtsVersionByte2 == 0x5) {
 +
        FirmwareVersionByte2 = 2;
 +
    } else if (FtsVersionByte2 == 0x12) {
 +
        FirmwareVersionByte2 = 0;
 +
    } else if (FtsVersionByte2 == 0x1A) {
 +
        FirmwareVersionByte2 = 1;
 +
    } else {
 +
        // Throw error.
 +
    }
 +
}
 +
 +
uint8_t FirmwareVersion[0x10] = {0};
 +
*(uint32_t *)FirmwareVersion = (FirmwareVersionByte3 << 24) | (FirmwareVersionByte2 << 16) | (FirmwareVersionByte1 << 8) | FirmwareVersionByte0;
 +
*((uint32_t *)FirmwareVersion + 1) = 0x5354;  // "ST"
 +
 +
return FirmwareVersion;
    
== IsFirmwareAvailableForNotification ==
 
== IsFirmwareAvailableForNotification ==
Line 7,053: Line 7,097:  
| 3 || Default
 
| 3 || Default
 
|}
 
|}
 +
 +
= FirmwareVersion =
 +
This is "nn::hid::system::FirmwareVersion". This is a 0x10 byte value.
    
= AppletDetailedUiType =
 
= AppletDetailedUiType =

Navigation menu