-
Notifications
You must be signed in to change notification settings - Fork 3
/
pspusbgps.h
85 lines (69 loc) · 2.11 KB
/
pspusbgps.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
/*
* PSP Software Development Kit - http://www.pspdev.org
* -----------------------------------------------------------------------
* Licensed under the BSD license, see LICENSE in PSPSDK root for details.
*
* pspusbcam.h - Prototypes for the sceUsbCam library
*
* Copyright (c) 2005 John Kelley <ps2dev@kelley.ca>
*
* $Id: pspgps.h
*/
#ifndef __PSPUSBGPS_H__
#define __PSPUSBGPS_H__
#ifdef __cplusplus
extern "C" {
#endif
#define PSP_USBGPS_PID 0x283
#define PSP_USBGPS_DRIVERNAME "USBGps_Driver"
typedef struct
{
short year; //0
short month; //2
short date; //4
short hour; //6
short minute; //8
short second; //10
float garbage1; //12
float hdop; //16
float garbage2; //20
float latitude; //24
float longitude; //28
float altitude; //32
float garbage3; //36
float speed; //40
float bearing; //44
} gpsdata;
typedef struct
{
unsigned char id;
unsigned char elevation;
short azimuth;
unsigned char snr;
unsigned char good;
short garbage;
} satinfo;
typedef struct
{
short satellites_in_view;
short gargage;
satinfo satinf[24];
} satdata;
// Unknow
int sceUsbGps_31F95CDE (void); // ?
int sceUsbGps_69E4AAA8 (void); // ?
int sceUsbGps_9D8F99E8 (u32 a0, u32 a1); // ?
int sceUsbGpsReset (u32 a0); // ?
// Init
int sceUsbGpsOpen (void); // Open the GPS device
int sceUsbGpsClose (void); // Close the GPS device
int sceUsbGpsSetInitDataLocation (long a0); // ?
int sceUsbGpsGetInitDataLocation (long *a0); // ?
// Data
int sceUsbGpsGetData (gpsdata* g, satdata* s); // Get data from GPS (size of buffer = 0x30 u32 ?)
// State
int sceUsbGpsGetState (u32 *state); // Get GPS device state
#ifdef __cplusplus
}
#endif
#endif