HID services: Difference between revisions

No edit summary
(5 intermediate revisions by the same user not shown)
Line 1,150: Line 1,150:


This was added to sdknso with 3.x.
This was added to sdknso with 3.x.
With sdknso versions pre-4.x PointingProcessor used to be DpdProcessor. The [[#PackedPointingProcessorConfig|packed-config]] with DpdProcessor (besides RequiredMcuVersion) used to be initialized from user-specified config, now it's hard-coded.


{| class="wikitable" border="1"
{| class="wikitable" border="1"
Line 1,223: Line 1,225:
| 0x0 || 0x4 || [[#IrCameraStatus]]
| 0x0 || 0x4 || [[#IrCameraStatus]]
|-
|-
| 0x4 || 0x4 || IrCameraInternalStatus
| 0x4 || 0x4 || [[#IrCameraInternalStatus]]
|-
|-
| 0x8 || 0x8 || [[#IrSensorMode]]
| 0x8 || 0x8 || [[#IrSensorMode]]
Line 1,369: Line 1,371:
Takes a PID-descriptor, an [[#IrCameraHandle]], and an [[AM_services|AppletResourceUserId]]. No output.
Takes a PID-descriptor, an [[#IrCameraHandle]], and an [[AM_services|AppletResourceUserId]]. No output.


sdknso uses this from the Run*Processor funcs to suspend the current Processor when the current [[#PackedFunctionLevel|FunctionLevel]] is >= 0x1, prior to starting another Processor if needed (depending on  what Processor was already active via a state field).
sdknso uses this from the Run*Processor funcs to suspend the current Processor when the current [[#PackedFunctionLevel|FunctionLevel]] is >= 0x1, prior to starting another Processor if needed (depending on  what Processor was already active via a state field). Hence, this cmd is only used with [4.0.0+].


== CheckFirmwareVersion ==
== CheckFirmwareVersion ==
Line 2,517: Line 2,519:
|-
|-
| 2 || Unconnected
| 2 || Unconnected
|}
= IrCameraInternalStatus =
This is "nn::irsensor::IrCameraInternalStatus". This is an u32.
{| class="wikitable" border="1"
!  Value
!  Description
|-
| 0 || Ok?
|-
| 1 ||
|-
| 2 ||
|-
| 3 ||
|-
| 4 ||
|-
| 5 ||
|-
| 6 ||
|-
| 7 || [4.0.0+] Ok?
|-
| 8 || [4.0.0+]
|}
|}


Line 2,541: Line 2,569:
|}
|}


= PackedMomentProcessorConfig =
= ImageProcessorStatus =
This is "nn::irsensor::PackedMomentProcessorConfig". This is a 0x20-byte struct.  
This is "nn::irsensor::ImageProcessorStatus". This is an u32.


{| class="wikitable" border="1"
{| class="wikitable" border="1"
!  Value
!  Description
|-
|-
! Offset || Size || Description
| 0 || Stopped
|-
|-
| 0x0 || 0x8 || ExposureTime (default is 0x493E0)
| 1 || Running
|-
|}
| 0x8 || 0x1 || LightTarget (default is 0)
 
= ImageTransferProcessorFormat =
This is "nn::irsensor::ImageTransferProcessorFormat". This is an u32.
 
This controls the IR Sensor image resolution.
 
{| class="wikitable" border="1"
!  Value
!  Description
|-
| 0 || 240x320
|-
| 1 || 120x160
|-
| 2 || 60x80
|-
| 3 || [4.0.0+] 30x40
|-
| 4 || [4.0.0+] 15x20
|}
 
= PackedMomentProcessorConfig =
This is "nn::irsensor::PackedMomentProcessorConfig". This is a 0x20-byte struct.
 
{| class="wikitable" border="1"
|-
! Offset || Size || Description
|-
| 0x0 || 0x8 || ExposureTime (default is 0x493E0)
|-
| 0x8 || 0x1 || LightTarget (default is 0)
|-
|-
| 0x9 || 0x1 || Gain (default is 0x8)
| 0x9 || 0x1 || Gain (default is 0x8)
Line 2,566: Line 2,626:
| 0x16 || 0x2 || WindowOfInterestHeight (default is 0xF0)
| 0x16 || 0x2 || WindowOfInterestHeight (default is 0xF0)
|-
|-
| 0x18 || 0x4 || [[#PackedMcuVersion|RequiredMcuVersion]] (default is 0xA0003)
| 0x18 || 0x4 || [[#PackedMcuVersion|RequiredMcuVersion]]
|-
|-
| 0x1C || 0x1 || Preprocess (default is 0x1)
| 0x1C || 0x1 || Preprocess (default is 0x1)
Line 2,613: Line 2,673:
|}
|}


= PackedImageTransferProcessorConfig =
= ImageTransferProcessorConfig =
This is "nn::irsensor::PackedImageTransferProcessorConfig". This is a 0x18-byte struct.
This is "nn::irsensor::ImageTransferProcessorConfig".


{| class="wikitable" border="1"
{| class="wikitable" border="1"
Line 2,622: Line 2,682:
| 0x0 || 0x8 || ExposureTime
| 0x0 || 0x8 || ExposureTime
|-
|-
| 0x8 || 0x1 || LightTarget
| 0x8 || 0x4 || LightTarget
|-
|-
| 0x9 || 0x1 || Gain
| 0xC || 0x4 || Gain
|-
|-
| 0xA || 0x1 || IsNegativeImageUsed
| 0x10 || 0x1 || IsNegativeImageUsed
|-
| 0x11 || 0x7 || Reserved
|-
| 0x18 || 0x4 || [[#ImageTransferProcessorFormat|Format]]
|}
 
= PackedImageTransferProcessorConfig =
This is "nn::irsensor::PackedImageTransferProcessorConfig". This is a 0x18-byte struct.
 
This is converted from [[#ImageTransferProcessorConfig]].
 
{| class="wikitable" border="1"
|-
! Offset || Size || Description
|-
| 0x0 || 0x8 || ExposureTime
|-
| 0x8 || 0x1 || LightTarget
|-
| 0x9 || 0x1 || Gain
|-
| 0xA || 0x1 || IsNegativeImageUsed
|-
|-
| 0xB || 0x5 || Reserved
| 0xB || 0x5 || Reserved
Line 2,632: Line 2,714:
| 0x10 || 0x4 || [[#PackedMcuVersion|RequiredMcuVersion]]
| 0x10 || 0x4 || [[#PackedMcuVersion|RequiredMcuVersion]]
|-
|-
| 0x14 || 0x1 || Format
| 0x14 || 0x1 || [[#ImageTransferProcessorFormat|Format]]
|-
|-
| 0x15 || 0x3 || Reserved
| 0x15 || 0x3 || Reserved
Line 2,653: Line 2,735:
= PackedTeraPluginProcessorConfig =
= PackedTeraPluginProcessorConfig =
This is "nn::irsensor::PackedTeraPluginProcessorConfig". This is a 0x8-byte struct.
This is "nn::irsensor::PackedTeraPluginProcessorConfig". This is a 0x8-byte struct.
The data starting at offset 0x5 is only initialized by the user-process with [6.0.0+].


{| class="wikitable" border="1"
{| class="wikitable" border="1"
Line 2,733: Line 2,817:
|-
|-
| [6.0.0+] || 0x3
| [6.0.0+] || 0x3
|}
= ImageTransferProcessorExConfig =
This is "nn::irsensor::ImageTransferProcessorExConfig".
{| class="wikitable" border="1"
|-
! Offset || Size || Description
|-
| 0x0 || 0x8 || ExposureTime
|-
| 0x8 || 0x4 || LightTarget
|-
| 0xC || 0x4 || Gain
|-
| 0x10 || 0x1 || IsNegativeImageUsed
|-
| 0x11 || 0x7 || Reserved
|-
| 0x18 || 0x4 || [[#ImageTransferProcessorFormat|OrigFormat]]
|-
| 0x1C || 0x4 || [[#ImageTransferProcessorFormat|TrimmingFormat]]
|-
| 0x20 || 0x2 || TrimmingStartX
|-
| 0x22 || 0x2 || TrimmingStartY
|-
| 0x24 || 0x1 || IsExternalLightFilterEnabled
|}
|}


= PackedImageTransferProcessorExConfig =
= PackedImageTransferProcessorExConfig =
This is "nn::irsensor::PackedImageTransferProcessorExConfig". This is a 0x20-byte struct.
This is "nn::irsensor::PackedImageTransferProcessorExConfig". This is a 0x20-byte struct.
This is converted from [[#ImageTransferProcessorExConfig]].


{| class="wikitable" border="1"
{| class="wikitable" border="1"
Line 2,754: Line 2,868:
| 0x10 || 0x4 || [[#PackedMcuVersion|RequiredMcuVersion]]
| 0x10 || 0x4 || [[#PackedMcuVersion|RequiredMcuVersion]]
|-
|-
| 0x14 || 0x1 || OrigFormat
| 0x14 || 0x1 || [[#ImageTransferProcessorFormat|OrigFormat]]
|-
|-
| 0x15 || 0x1 || TrimmingFormat
| 0x15 || 0x1 || [[#ImageTransferProcessorFormat|TrimmingFormat]]
|-
|-
| 0x16 || 0x2 || TrimmingStartX
| 0x16 || 0x2 || TrimmingStartX