Win32 API 日本語リファレンス
ホームDevices.Geolocation › GNSS_DEVICE_CAPABILITY

GNSS_DEVICE_CAPABILITY

構造体
サイズx64: 604 バイト / x86: 604 バイト

サイズ=各フィールドのバイト数(x64/x86 で異なる場合は x64/x86 と併記)。x64/x86 列=フィールドのバイトオフセット(HSPで dupptr / lpoke / wpoke 等に使用)。

フィールド

フィールドサイズx64x86説明
SizeDWORD4+0+0この構造体のサイズをバイト単位で示すDWORD。
VersionDWORD4+4+4構造体のバージョンを示すDWORD。
SupportMultipleFixSessionsBOOL4+8+8複数の測位セッションを同時サポートするかを示すBOOL。
SupportMultipleAppSessionsBOOL4+12+12複数のアプリセッションを同時サポートするかを示すBOOL。
RequireAGnssInjectionBOOL4+16+16A-GNSS支援データの注入を必要とするかを示すBOOL。
AgnssFormatSupportedDWORD4+20+20サポートするA-GNSSデータ形式を示すDWORD。
AgnssFormatPreferredDWORD4+24+24優先するA-GNSSデータ形式を示すDWORD。
SupportDistanceTrackingBOOL4+28+28距離ベースの追跡をサポートするかを示すBOOL。
SupportContinuousTrackingBOOL4+32+32連続追跡をサポートするかを示すBOOL。
Reserved1DWORD4+36+36予約フィールド。将来の拡張用。
Reserved2BOOL4+40+40予約フィールド。将来の拡張用。
Reserved3BOOL4+44+44予約フィールド。将来の拡張用。
Reserved4BOOL4+48+48予約フィールド。将来の拡張用。
Reserved5BOOL4+52+52予約フィールド。将来の拡張用。
GeofencingSupportDWORD4+56+56ジオフェンシング機能のサポート状況を示すDWORD。
Reserved6BOOL4+60+60予約フィールド。将来の拡張用。
Reserved7BOOL4+64+64予約フィールド。将来の拡張用。
SupportCpLocationBOOL4+68+68制御プレーン測位(CP)をサポートするかを示すBOOL。
SupportUplV2BOOL4+72+72UPL v2をサポートするかを示すBOOL。
SupportSuplV1BOOL4+76+76SUPL v1をサポートするかを示すBOOL。
SupportSuplV2BOOL4+80+80SUPL v2をサポートするかを示すBOOL。
SupportedSuplVersionGNSS_SUPL_VERSION8+84+84サポートするSUPLバージョンを示すGNSS_SUPL_VERSION。
MaxGeofencesSupportedDWORD4+92+92サポート可能なジオフェンスの最大数を示すDWORD。
SupportMultipleSuplRootCertBOOL4+96+96複数のSUPLルート証明書をサポートするかを示すBOOL。
GnssBreadCrumbPayloadVersionDWORD4+100+100ブレッドクラム(軌跡)ペイロードのバージョンを示すDWORD。
MaxGnssBreadCrumbFixesDWORD4+104+104保持可能なブレッドクラム測位点の最大数を示すDWORD。
UnusedBYTE496+108+108未使用の予約バイト配列。

各言語での定義

#include <windows.h>

// GNSS_SUPL_VERSION  (x64 8 / x86 8 バイト)
typedef struct GNSS_SUPL_VERSION {
    DWORD MajorVersion;
    DWORD MinorVersion;
} GNSS_SUPL_VERSION;

// GNSS_DEVICE_CAPABILITY  (x64 604 / x86 604 バイト)
typedef struct GNSS_DEVICE_CAPABILITY {
    DWORD Size;
    DWORD Version;
    BOOL SupportMultipleFixSessions;
    BOOL SupportMultipleAppSessions;
    BOOL RequireAGnssInjection;
    DWORD AgnssFormatSupported;
    DWORD AgnssFormatPreferred;
    BOOL SupportDistanceTracking;
    BOOL SupportContinuousTracking;
    DWORD Reserved1;
    BOOL Reserved2;
    BOOL Reserved3;
    BOOL Reserved4;
    BOOL Reserved5;
    DWORD GeofencingSupport;
    BOOL Reserved6;
    BOOL Reserved7;
    BOOL SupportCpLocation;
    BOOL SupportUplV2;
    BOOL SupportSuplV1;
    BOOL SupportSuplV2;
    GNSS_SUPL_VERSION SupportedSuplVersion;
    DWORD MaxGeofencesSupported;
    BOOL SupportMultipleSuplRootCert;
    DWORD GnssBreadCrumbPayloadVersion;
    DWORD MaxGnssBreadCrumbFixes;
    BYTE Unused[496];
} GNSS_DEVICE_CAPABILITY;
using System;
using System.Runtime.InteropServices;

[StructLayout(LayoutKind.Sequential, CharSet = CharSet.Unicode)]
public struct GNSS_SUPL_VERSION
{
    public uint MajorVersion;
    public uint MinorVersion;
}

[StructLayout(LayoutKind.Sequential, CharSet = CharSet.Unicode)]
public struct GNSS_DEVICE_CAPABILITY
{
    public uint Size;
    public uint Version;
    [MarshalAs(UnmanagedType.Bool)] public bool SupportMultipleFixSessions;
    [MarshalAs(UnmanagedType.Bool)] public bool SupportMultipleAppSessions;
    [MarshalAs(UnmanagedType.Bool)] public bool RequireAGnssInjection;
    public uint AgnssFormatSupported;
    public uint AgnssFormatPreferred;
    [MarshalAs(UnmanagedType.Bool)] public bool SupportDistanceTracking;
    [MarshalAs(UnmanagedType.Bool)] public bool SupportContinuousTracking;
    public uint Reserved1;
    [MarshalAs(UnmanagedType.Bool)] public bool Reserved2;
    [MarshalAs(UnmanagedType.Bool)] public bool Reserved3;
    [MarshalAs(UnmanagedType.Bool)] public bool Reserved4;
    [MarshalAs(UnmanagedType.Bool)] public bool Reserved5;
    public uint GeofencingSupport;
    [MarshalAs(UnmanagedType.Bool)] public bool Reserved6;
    [MarshalAs(UnmanagedType.Bool)] public bool Reserved7;
    [MarshalAs(UnmanagedType.Bool)] public bool SupportCpLocation;
    [MarshalAs(UnmanagedType.Bool)] public bool SupportUplV2;
    [MarshalAs(UnmanagedType.Bool)] public bool SupportSuplV1;
    [MarshalAs(UnmanagedType.Bool)] public bool SupportSuplV2;
    public GNSS_SUPL_VERSION SupportedSuplVersion;
    public uint MaxGeofencesSupported;
    [MarshalAs(UnmanagedType.Bool)] public bool SupportMultipleSuplRootCert;
    public uint GnssBreadCrumbPayloadVersion;
    public uint MaxGnssBreadCrumbFixes;
    [MarshalAs(UnmanagedType.ByValArray, SizeConst = 496)] public byte[] Unused;
}
Imports System.Runtime.InteropServices

<StructLayout(LayoutKind.Sequential, CharSet:=CharSet.Unicode)>
Public Structure GNSS_SUPL_VERSION
    Public MajorVersion As UInteger
    Public MinorVersion As UInteger
End Structure

<StructLayout(LayoutKind.Sequential, CharSet:=CharSet.Unicode)>
Public Structure GNSS_DEVICE_CAPABILITY
    Public Size As UInteger
    Public Version As UInteger
    <MarshalAs(UnmanagedType.Bool)> Public SupportMultipleFixSessions As Boolean
    <MarshalAs(UnmanagedType.Bool)> Public SupportMultipleAppSessions As Boolean
    <MarshalAs(UnmanagedType.Bool)> Public RequireAGnssInjection As Boolean
    Public AgnssFormatSupported As UInteger
    Public AgnssFormatPreferred As UInteger
    <MarshalAs(UnmanagedType.Bool)> Public SupportDistanceTracking As Boolean
    <MarshalAs(UnmanagedType.Bool)> Public SupportContinuousTracking As Boolean
    Public Reserved1 As UInteger
    <MarshalAs(UnmanagedType.Bool)> Public Reserved2 As Boolean
    <MarshalAs(UnmanagedType.Bool)> Public Reserved3 As Boolean
    <MarshalAs(UnmanagedType.Bool)> Public Reserved4 As Boolean
    <MarshalAs(UnmanagedType.Bool)> Public Reserved5 As Boolean
    Public GeofencingSupport As UInteger
    <MarshalAs(UnmanagedType.Bool)> Public Reserved6 As Boolean
    <MarshalAs(UnmanagedType.Bool)> Public Reserved7 As Boolean
    <MarshalAs(UnmanagedType.Bool)> Public SupportCpLocation As Boolean
    <MarshalAs(UnmanagedType.Bool)> Public SupportUplV2 As Boolean
    <MarshalAs(UnmanagedType.Bool)> Public SupportSuplV1 As Boolean
    <MarshalAs(UnmanagedType.Bool)> Public SupportSuplV2 As Boolean
    Public SupportedSuplVersion As GNSS_SUPL_VERSION
    Public MaxGeofencesSupported As UInteger
    <MarshalAs(UnmanagedType.Bool)> Public SupportMultipleSuplRootCert As Boolean
    Public GnssBreadCrumbPayloadVersion As UInteger
    Public MaxGnssBreadCrumbFixes As UInteger
    <MarshalAs(UnmanagedType.ByValArray, SizeConst:=496)> Public Unused() As Byte
End Structure
import ctypes
from ctypes import wintypes

class GNSS_SUPL_VERSION(ctypes.Structure):
    _fields_ = [
        ("MajorVersion", wintypes.DWORD),
        ("MinorVersion", wintypes.DWORD),
    ]

class GNSS_DEVICE_CAPABILITY(ctypes.Structure):
    _fields_ = [
        ("Size", wintypes.DWORD),
        ("Version", wintypes.DWORD),
        ("SupportMultipleFixSessions", wintypes.BOOL),
        ("SupportMultipleAppSessions", wintypes.BOOL),
        ("RequireAGnssInjection", wintypes.BOOL),
        ("AgnssFormatSupported", wintypes.DWORD),
        ("AgnssFormatPreferred", wintypes.DWORD),
        ("SupportDistanceTracking", wintypes.BOOL),
        ("SupportContinuousTracking", wintypes.BOOL),
        ("Reserved1", wintypes.DWORD),
        ("Reserved2", wintypes.BOOL),
        ("Reserved3", wintypes.BOOL),
        ("Reserved4", wintypes.BOOL),
        ("Reserved5", wintypes.BOOL),
        ("GeofencingSupport", wintypes.DWORD),
        ("Reserved6", wintypes.BOOL),
        ("Reserved7", wintypes.BOOL),
        ("SupportCpLocation", wintypes.BOOL),
        ("SupportUplV2", wintypes.BOOL),
        ("SupportSuplV1", wintypes.BOOL),
        ("SupportSuplV2", wintypes.BOOL),
        ("SupportedSuplVersion", GNSS_SUPL_VERSION),
        ("MaxGeofencesSupported", wintypes.DWORD),
        ("SupportMultipleSuplRootCert", wintypes.BOOL),
        ("GnssBreadCrumbPayloadVersion", wintypes.DWORD),
        ("MaxGnssBreadCrumbFixes", wintypes.DWORD),
        ("Unused", ctypes.c_ubyte * 496),
    ]
#[repr(C)]
pub struct GNSS_SUPL_VERSION {
    pub MajorVersion: u32,
    pub MinorVersion: u32,
}

#[repr(C)]
pub struct GNSS_DEVICE_CAPABILITY {
    pub Size: u32,
    pub Version: u32,
    pub SupportMultipleFixSessions: i32,
    pub SupportMultipleAppSessions: i32,
    pub RequireAGnssInjection: i32,
    pub AgnssFormatSupported: u32,
    pub AgnssFormatPreferred: u32,
    pub SupportDistanceTracking: i32,
    pub SupportContinuousTracking: i32,
    pub Reserved1: u32,
    pub Reserved2: i32,
    pub Reserved3: i32,
    pub Reserved4: i32,
    pub Reserved5: i32,
    pub GeofencingSupport: u32,
    pub Reserved6: i32,
    pub Reserved7: i32,
    pub SupportCpLocation: i32,
    pub SupportUplV2: i32,
    pub SupportSuplV1: i32,
    pub SupportSuplV2: i32,
    pub SupportedSuplVersion: GNSS_SUPL_VERSION,
    pub MaxGeofencesSupported: u32,
    pub SupportMultipleSuplRootCert: i32,
    pub GnssBreadCrumbPayloadVersion: u32,
    pub MaxGnssBreadCrumbFixes: u32,
    pub Unused: [u8; 496],
}
import "golang.org/x/sys/windows"

type GNSS_SUPL_VERSION struct {
	MajorVersion uint32
	MinorVersion uint32
}

type GNSS_DEVICE_CAPABILITY struct {
	Size uint32
	Version uint32
	SupportMultipleFixSessions int32
	SupportMultipleAppSessions int32
	RequireAGnssInjection int32
	AgnssFormatSupported uint32
	AgnssFormatPreferred uint32
	SupportDistanceTracking int32
	SupportContinuousTracking int32
	Reserved1 uint32
	Reserved2 int32
	Reserved3 int32
	Reserved4 int32
	Reserved5 int32
	GeofencingSupport uint32
	Reserved6 int32
	Reserved7 int32
	SupportCpLocation int32
	SupportUplV2 int32
	SupportSuplV1 int32
	SupportSuplV2 int32
	SupportedSuplVersion GNSS_SUPL_VERSION
	MaxGeofencesSupported uint32
	SupportMultipleSuplRootCert int32
	GnssBreadCrumbPayloadVersion uint32
	MaxGnssBreadCrumbFixes uint32
	Unused [496]byte
}
type
  GNSS_SUPL_VERSION = record
    MajorVersion: DWORD;
    MinorVersion: DWORD;
  end;

  GNSS_DEVICE_CAPABILITY = record
    Size: DWORD;
    Version: DWORD;
    SupportMultipleFixSessions: BOOL;
    SupportMultipleAppSessions: BOOL;
    RequireAGnssInjection: BOOL;
    AgnssFormatSupported: DWORD;
    AgnssFormatPreferred: DWORD;
    SupportDistanceTracking: BOOL;
    SupportContinuousTracking: BOOL;
    Reserved1: DWORD;
    Reserved2: BOOL;
    Reserved3: BOOL;
    Reserved4: BOOL;
    Reserved5: BOOL;
    GeofencingSupport: DWORD;
    Reserved6: BOOL;
    Reserved7: BOOL;
    SupportCpLocation: BOOL;
    SupportUplV2: BOOL;
    SupportSuplV1: BOOL;
    SupportSuplV2: BOOL;
    SupportedSuplVersion: GNSS_SUPL_VERSION;
    MaxGeofencesSupported: DWORD;
    SupportMultipleSuplRootCert: BOOL;
    GnssBreadCrumbPayloadVersion: DWORD;
    MaxGnssBreadCrumbFixes: DWORD;
    Unused: array[0..495] of Byte;
  end;
const GNSS_SUPL_VERSION = extern struct {
    MajorVersion: u32,
    MinorVersion: u32,
};

const GNSS_DEVICE_CAPABILITY = extern struct {
    Size: u32,
    Version: u32,
    SupportMultipleFixSessions: i32,
    SupportMultipleAppSessions: i32,
    RequireAGnssInjection: i32,
    AgnssFormatSupported: u32,
    AgnssFormatPreferred: u32,
    SupportDistanceTracking: i32,
    SupportContinuousTracking: i32,
    Reserved1: u32,
    Reserved2: i32,
    Reserved3: i32,
    Reserved4: i32,
    Reserved5: i32,
    GeofencingSupport: u32,
    Reserved6: i32,
    Reserved7: i32,
    SupportCpLocation: i32,
    SupportUplV2: i32,
    SupportSuplV1: i32,
    SupportSuplV2: i32,
    SupportedSuplVersion: GNSS_SUPL_VERSION,
    MaxGeofencesSupported: u32,
    SupportMultipleSuplRootCert: i32,
    GnssBreadCrumbPayloadVersion: u32,
    MaxGnssBreadCrumbFixes: u32,
    Unused: [496]u8,
};
type
  GNSS_SUPL_VERSION {.bycopy.} = object
    MajorVersion: uint32
    MinorVersion: uint32

  GNSS_DEVICE_CAPABILITY {.bycopy.} = object
    Size: uint32
    Version: uint32
    SupportMultipleFixSessions: int32
    SupportMultipleAppSessions: int32
    RequireAGnssInjection: int32
    AgnssFormatSupported: uint32
    AgnssFormatPreferred: uint32
    SupportDistanceTracking: int32
    SupportContinuousTracking: int32
    Reserved1: uint32
    Reserved2: int32
    Reserved3: int32
    Reserved4: int32
    Reserved5: int32
    GeofencingSupport: uint32
    Reserved6: int32
    Reserved7: int32
    SupportCpLocation: int32
    SupportUplV2: int32
    SupportSuplV1: int32
    SupportSuplV2: int32
    SupportedSuplVersion: GNSS_SUPL_VERSION
    MaxGeofencesSupported: uint32
    SupportMultipleSuplRootCert: int32
    GnssBreadCrumbPayloadVersion: uint32
    MaxGnssBreadCrumbFixes: uint32
    Unused: array[496, uint8]
struct GNSS_SUPL_VERSION
{
    uint MajorVersion;
    uint MinorVersion;
}

struct GNSS_DEVICE_CAPABILITY
{
    uint Size;
    uint Version;
    int SupportMultipleFixSessions;
    int SupportMultipleAppSessions;
    int RequireAGnssInjection;
    uint AgnssFormatSupported;
    uint AgnssFormatPreferred;
    int SupportDistanceTracking;
    int SupportContinuousTracking;
    uint Reserved1;
    int Reserved2;
    int Reserved3;
    int Reserved4;
    int Reserved5;
    uint GeofencingSupport;
    int Reserved6;
    int Reserved7;
    int SupportCpLocation;
    int SupportUplV2;
    int SupportSuplV1;
    int SupportSuplV2;
    GNSS_SUPL_VERSION SupportedSuplVersion;
    uint MaxGeofencesSupported;
    int SupportMultipleSuplRootCert;
    uint GnssBreadCrumbPayloadVersion;
    uint MaxGnssBreadCrumbFixes;
    ubyte[496] Unused;
}

HSP用 定義

HSP3.7/3.8 は構造体機能が無いため4byte整数配列(dim)+peek/poke で操作(32/64bitでサイズ・位置が異なる場合はタブで分割)。IronHSP は NSTRUCT(#defstruct/stdim/->)で32/64bit共通。

; HSP3.7/3.8 は構造体機能が無いため、4byte整数の配列変数で操作します。(x64 レイアウト)
; GNSS_DEVICE_CAPABILITY サイズ: 604 バイト(x64)
dim st, 151    ; 4byte整数×151(構造体サイズ 604 / 4 切り上げ)
; Size : DWORD (+0, 4byte)  st.0 = 値  /  値 = st.0   (lpoke/lpeek も可)
; Version : DWORD (+4, 4byte)  st.1 = 値  /  値 = st.1   (lpoke/lpeek も可)
; SupportMultipleFixSessions : BOOL (+8, 4byte)  st.2 = 値  /  値 = st.2   (lpoke/lpeek も可)
; SupportMultipleAppSessions : BOOL (+12, 4byte)  st.3 = 値  /  値 = st.3   (lpoke/lpeek も可)
; RequireAGnssInjection : BOOL (+16, 4byte)  st.4 = 値  /  値 = st.4   (lpoke/lpeek も可)
; AgnssFormatSupported : DWORD (+20, 4byte)  st.5 = 値  /  値 = st.5   (lpoke/lpeek も可)
; AgnssFormatPreferred : DWORD (+24, 4byte)  st.6 = 値  /  値 = st.6   (lpoke/lpeek も可)
; SupportDistanceTracking : BOOL (+28, 4byte)  st.7 = 値  /  値 = st.7   (lpoke/lpeek も可)
; SupportContinuousTracking : BOOL (+32, 4byte)  st.8 = 値  /  値 = st.8   (lpoke/lpeek も可)
; Reserved1 : DWORD (+36, 4byte)  st.9 = 値  /  値 = st.9   (lpoke/lpeek も可)
; Reserved2 : BOOL (+40, 4byte)  st.10 = 値  /  値 = st.10   (lpoke/lpeek も可)
; Reserved3 : BOOL (+44, 4byte)  st.11 = 値  /  値 = st.11   (lpoke/lpeek も可)
; Reserved4 : BOOL (+48, 4byte)  st.12 = 値  /  値 = st.12   (lpoke/lpeek も可)
; Reserved5 : BOOL (+52, 4byte)  st.13 = 値  /  値 = st.13   (lpoke/lpeek も可)
; GeofencingSupport : DWORD (+56, 4byte)  st.14 = 値  /  値 = st.14   (lpoke/lpeek も可)
; Reserved6 : BOOL (+60, 4byte)  st.15 = 値  /  値 = st.15   (lpoke/lpeek も可)
; Reserved7 : BOOL (+64, 4byte)  st.16 = 値  /  値 = st.16   (lpoke/lpeek も可)
; SupportCpLocation : BOOL (+68, 4byte)  st.17 = 値  /  値 = st.17   (lpoke/lpeek も可)
; SupportUplV2 : BOOL (+72, 4byte)  st.18 = 値  /  値 = st.18   (lpoke/lpeek も可)
; SupportSuplV1 : BOOL (+76, 4byte)  st.19 = 値  /  値 = st.19   (lpoke/lpeek も可)
; SupportSuplV2 : BOOL (+80, 4byte)  st.20 = 値  /  値 = st.20   (lpoke/lpeek も可)
; SupportedSuplVersion : GNSS_SUPL_VERSION (+84, 8byte)  varptr(st)+84 を基点に操作(8byte:入れ子/配列)
; MaxGeofencesSupported : DWORD (+92, 4byte)  st.23 = 値  /  値 = st.23   (lpoke/lpeek も可)
; SupportMultipleSuplRootCert : BOOL (+96, 4byte)  st.24 = 値  /  値 = st.24   (lpoke/lpeek も可)
; GnssBreadCrumbPayloadVersion : DWORD (+100, 4byte)  st.25 = 値  /  値 = st.25   (lpoke/lpeek も可)
; MaxGnssBreadCrumbFixes : DWORD (+104, 4byte)  st.26 = 値  /  値 = st.26   (lpoke/lpeek も可)
; Unused : BYTE (+108, 496byte)  varptr(st)+108 を基点に操作(496byte:入れ子/配列)
; ※4byte境界の整数は添字 st.N(N=オフセット/4)で読み書き可。それ以外は peek/poke 系を使用。
; IronHSP は NSTRUCT(構造体)をサポート。32bit/64bit どちらでも同じコードで動作します。
; ※GUID・入れ子構造体はデフォルト型でないため、依存する #defstruct を先に定義(下記に同梱)。
#defstruct global GNSS_SUPL_VERSION
    #field int MajorVersion
    #field int MinorVersion
#endstruct

#defstruct global GNSS_DEVICE_CAPABILITY
    #field int Size
    #field int Version
    #field bool SupportMultipleFixSessions
    #field bool SupportMultipleAppSessions
    #field bool RequireAGnssInjection
    #field int AgnssFormatSupported
    #field int AgnssFormatPreferred
    #field bool SupportDistanceTracking
    #field bool SupportContinuousTracking
    #field int Reserved1
    #field bool Reserved2
    #field bool Reserved3
    #field bool Reserved4
    #field bool Reserved5
    #field int GeofencingSupport
    #field bool Reserved6
    #field bool Reserved7
    #field bool SupportCpLocation
    #field bool SupportUplV2
    #field bool SupportSuplV1
    #field bool SupportSuplV2
    #field GNSS_SUPL_VERSION SupportedSuplVersion
    #field int MaxGeofencesSupported
    #field bool SupportMultipleSuplRootCert
    #field int GnssBreadCrumbPayloadVersion
    #field int MaxGnssBreadCrumbFixes
    #field byte Unused 496
#endstruct

stdim st, GNSS_DEVICE_CAPABILITY        ; NSTRUCT 変数を確保
st->Size = 100
mes "Size=" + st->Size