32x: a hack for dealing with pwm inaccuracy
[picodrive.git] / platform / gp2x / soc.h
CommitLineData
42171343 1typedef enum {
2 SOCID_MMSP2 = 1,
3 SOCID_POLLUX,
4} gp2x_soc_t;
5
42171343 6gp2x_soc_t soc_detect(void);
7
8void mmsp2_init(void);
9void mmsp2_finish(void);
10
11void pollux_init(void);
12void pollux_finish(void);
13
274f95a9 14void dummy_init(void);
15void dummy_finish(void);
16
0d9bf4fc 17/* SoC specific functions */
ee2a3bdf 18extern void (*gp2x_video_flip)(void);
19extern void (*gp2x_video_flip2)(void);
cc41eb4f 20/* negative bpp means rotated mode (for Wiz) */
ee2a3bdf 21extern void (*gp2x_video_changemode_ll)(int bpp);
22extern void (*gp2x_video_setpalette)(int *pal, int len);
23extern void (*gp2x_video_RGB_setscaling)(int ln_offs, int W, int H);
24extern void (*gp2x_video_wait_vsync)(void);
0d9bf4fc 25
ee2a3bdf 26extern void (*gp2x_set_cpuclk)(unsigned int mhz);
0d9bf4fc 27
ee2a3bdf 28extern void (*set_lcd_custom_rate)(int is_pal);
29extern void (*unset_lcd_custom_rate)(void);
30extern void (*set_lcd_gamma)(int g100, int A_SNs_curve);
0d9bf4fc 31
ee2a3bdf 32extern void (*set_ram_timings)(void);
33extern void (*unset_ram_timings)(void);
61753a67 34extern int (*gp2x_read_battery)(void);
0d9bf4fc 35
b24e0f6c 36/* gettimeofday is not suitable for Wiz, at least fw 1.1 or lower */
37extern unsigned int (*gp2x_get_ticks_ms)(void);
38extern unsigned int (*gp2x_get_ticks_us)(void);