mirror of
https://github.com/Rockbox/rockbox.git
synced 2025-11-15 16:12:28 -05:00
Simulator for Samsung YP-R0
Enable simulator for the target ypr0 to be built and used. Change-Id: I1b080f07ab90f5c4856881d08ad70e1053bbb0c0 Reviewed-on: http://gerrit.rockbox.org/618 Reviewed-by: Frank Gevaerts <frank@gevaerts.be>
This commit is contained in:
parent
d13e5b964e
commit
9a8ed6ba35
7 changed files with 114 additions and 9 deletions
|
|
@ -14,7 +14,7 @@ powermgmt.c
|
|||
target/hosted/cpuinfo-linux.c
|
||||
#endif
|
||||
|
||||
#ifndef SAMSUNG_YPR0 /* uses as3514 rtc */
|
||||
#if !defined(SAMSUNG_YPR0) || defined(SIMULATOR) /* uses as3514 rtc */
|
||||
target/hosted/rtc.c
|
||||
#endif
|
||||
|
||||
|
|
@ -74,7 +74,7 @@ target/hosted/sdl/app/button-application.c
|
|||
#endif
|
||||
#endif
|
||||
|
||||
#ifdef SAMSUNG_YPR0
|
||||
#if defined(SAMSUNG_YPR0) && !defined(SIMULATOR)
|
||||
drivers/adc-as3514.c
|
||||
drivers/lcd-memframe.c
|
||||
#if (CONFIG_RTC == RTC_AS3514)
|
||||
|
|
|
|||
|
|
@ -5,16 +5,15 @@
|
|||
|
||||
/* We don't run on hardware directly */
|
||||
/* YP-R0 need it too of course */
|
||||
#ifndef SIMULATOR
|
||||
#define CONFIG_PLATFORM (PLATFORM_HOSTED)
|
||||
#endif
|
||||
|
||||
/* For Rolo and boot loader */
|
||||
#define MODEL_NUMBER 100
|
||||
|
||||
#define MODEL_NAME "Samsung YP-R0"
|
||||
|
||||
/*TODO: implement USB data transfer management -> see safe mode script and think a way to implemtent it in the code */
|
||||
#define USB_NONE
|
||||
|
||||
/* define this if you have a bitmap LCD display */
|
||||
#define HAVE_LCD_BITMAP
|
||||
|
||||
|
|
@ -90,6 +89,12 @@
|
|||
#define CONFIG_KEYPAD SAMSUNG_YPR0_PAD
|
||||
#define BUTTON_DRIVER_CLOSE
|
||||
|
||||
/** Non-simulator section **/
|
||||
#ifndef SIMULATOR
|
||||
|
||||
/*TODO: implement USB data transfer management -> see safe mode script and think a way to implemtent it in the code */
|
||||
#define USB_NONE
|
||||
|
||||
/* The YPR0 has a as3534 codec */
|
||||
#define HAVE_AS3514
|
||||
#define HAVE_AS3543
|
||||
|
|
@ -109,6 +114,12 @@
|
|||
/* We have a GPIO pin that detects this */
|
||||
#define HAVE_HEADPHONE_DETECTION
|
||||
|
||||
/* Define current usage levels. */
|
||||
#define CURRENT_NORMAL 24 /* ~25h, on 600mAh that's about 24mA */
|
||||
#define CURRENT_BACKLIGHT 62 /* ~6,5h -> 92mA. Minus 24mA normal that gives us 68mA */
|
||||
|
||||
#endif /* SIMULATOR */
|
||||
|
||||
/* FIXME
|
||||
* Lot of people reports bad battery life and funny charging times.
|
||||
* Check what's going on...
|
||||
|
|
@ -120,10 +131,6 @@
|
|||
#define BATTERY_CAPACITY_INC 0 /* capacity increment */
|
||||
#define BATTERY_TYPES_COUNT 1 /* only one type */
|
||||
|
||||
/* Define current usage levels. */
|
||||
#define CURRENT_NORMAL 24 /* ~25h, on 600mAh that's about 24mA */
|
||||
#define CURRENT_BACKLIGHT 62 /* ~6,5h -> 92mA. Minus 24mA normal that gives us 68mA */
|
||||
|
||||
#define CONFIG_BATTERY_MEASURE VOLTAGE_MEASURE
|
||||
|
||||
/* Linux controlls charging, we can monitor */
|
||||
|
|
|
|||
|
|
@ -473,6 +473,13 @@
|
|||
#define UI_WIDTH LCD_WIDTH
|
||||
#define UI_HEIGHT LCD_HEIGHT
|
||||
|
||||
#elif defined(SAMSUNG_YPR0)
|
||||
#define UI_TITLE "Samsung YP-R0"
|
||||
#define UI_WIDTH 313 /* width of GUI window */
|
||||
#define UI_HEIGHT 560 /* height of GUI window */
|
||||
#define UI_LCD_POSX 36
|
||||
#define UI_LCD_POSY 37
|
||||
|
||||
#elif defined(SIMULATOR)
|
||||
#error no UI defines
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue