From 3520d8e90e7f6e3ffc88f8d1ff47fa3cc0efe960 Mon Sep 17 00:00:00 2001 From: Rafaël Carré Date: Wed, 17 Jun 2009 19:55:27 +0000 Subject: Sansa c200v2 : lcd & backlight support, using the c200v1 lcd driver The LCD driver is unified and lcd_send_command now takes 2 arguments : the command and its argument. If there is no argument, it's set to 0 and a NOP command is issued If there is more than one argument (set X/Y address), the 2nd argument is sent as a 2nd command, and a NOP command is issued after it. Benefit : c200v2 transfers the command and the argument in one 16 bits transfer Performance should not be affected since commands without argument are only used in lcd_init() and lcd_enable() lcd_send_data() now transfers whole lines (or columns) instead of single pixels yuv is disabled for c200v2 for now Some buttons can be read, including left button (bit 6 of DBOP_DIN), but for some reason they have no effect in rockbox: to be investigated git-svn-id: svn://svn.rockbox.org/rockbox/trunk@21321 a1c6a512-1295-4272-9138-f99709370657 --- firmware/export/config-c200v2.h | 36 +++++++++++++++--------------------- 1 file changed, 15 insertions(+), 21 deletions(-) (limited to 'firmware/export/config-c200v2.h') diff --git a/firmware/export/config-c200v2.h b/firmware/export/config-c200v2.h index 775a39fc4c..03f6ac0698 100644 --- a/firmware/export/config-c200v2.h +++ b/firmware/export/config-c200v2.h @@ -1,21 +1,25 @@ /* - * This config file is for the Sandisk Sansa e200 + * This config file is for the Sandisk Sansa c200v2 */ #define TARGET_TREE /* this target is using the target tree system */ /* For Rolo and boot loader */ #define MODEL_NUMBER 44 #define MODEL_NAME "Sandisk Sansa c200v2 series" +#define FIRMWARE_OFFSET_FILE_DATA 8 +#define FIRMWARE_OFFSET_FILE_CRC 0 + +#if 0 #define HW_SAMPR_CAPS (SAMPR_CAP_44) -#if 0 /* define this if you have recording possibility */ #define HAVE_RECORDING #define REC_SAMPR_CAPS (SAMPR_CAP_22) #define REC_FREQ_DEFAULT REC_FREQ_22 /* Default is not 44.1kHz */ #define REC_SAMPR_DEFAULT SAMPR_22 + #endif /* Define bitmask of input sources - recordable bitmask can be defined @@ -55,7 +59,6 @@ #define LCD_DEPTH 16 /* 65536 colours */ #define LCD_PIXELFORMAT RGB565 /* rgb565 */ -#ifndef BOOTLOADER /* define this if you have LCD enable function */ #define HAVE_LCD_ENABLE @@ -63,22 +66,21 @@ should be defined as well. */ /* TODO: #define HAVE_LCD_SLEEP */ /* TODO: #define HAVE_LCD_SLEEP_SETTING <= optional */ -#endif + /* define this if you can flip your LCD */ #define HAVE_LCD_FLIP /* define this if you can invert the colours on your LCD */ /* TODO: #define HAVE_LCD_INVERT */ -#if 0 /* Define this if your LCD can set contrast */ #define HAVE_LCD_CONTRAST #define MIN_CONTRAST_SETTING 0 #define MAX_CONTRAST_SETTING 255 #define DEFAULT_CONTRAST_SETTING 85 -#endif -/* #define IRAM_LCDFRAMEBUFFER IDATA_ATTR *//* put the lcd frame buffer in IRAM */ + + #define IRAM_LCDFRAMEBUFFER IDATA_ATTR /* put the lcd frame buffer in IRAM */ #define CONFIG_KEYPAD SANSA_C200_PAD @@ -91,7 +93,7 @@ /* There is no hardware tone control */ #define HAVE_SW_TONE_CONTROLS -/* The PP5024 has a built-in AustriaMicrosystems AS3514 */ +/* The AS3525 has a built-in AS3514 (or a newer version) */ #define HAVE_AS3514 /* define this if you have a real-time clock */ @@ -114,7 +116,7 @@ #define AB_REPEAT_ENABLE 1 /* FM Tuner - suspected to be the SI4702 */ -#define CONFIG_TUNER SI4700 +//#define CONFIG_TUNER SI4700 /* #define HAVE_TUNER_PWR_CTRL */ /* Define this for LCD backlight available */ @@ -159,30 +161,22 @@ #define ROM_START 0x00000000 /* Define this to the CPU frequency */ -#define CPU_FREQ 75000000 +#define CPU_FREQ 250000000 /* Type of LCD TODO: hopefully the same as the x5 but check this*/ #define CONFIG_LCD LCD_C200 -/* Offset ( in the firmware file's header ) to the file CRC and data. These are - only used when loading the old format rockbox.e200 file */ -#define FIRMWARE_OFFSET_FILE_CRC 0x0 -#define FIRMWARE_OFFSET_FILE_DATA 0x8 - #define USB_HANDLED_BY_OF #ifndef BOOTLOADER -#define HAVE_MULTIVOLUME -#define HAVE_HOTSWAP +//#define HAVE_MULTIVOLUME +//#define HAVE_HOTSWAP #endif -/* USB On-the-go */ -#define CONFIG_USBOTG USBOTG_ARC - /* enable these for the experimental usb stack */ //#define HAVE_USBSTACK //#define USB_VENDOR_ID 0x0781 -//#define USB_PRODUCT_ID 0x7450 +//#define USB_PRODUCT_ID 0x7452 /* Virtual LED (icon) */ #define CONFIG_LED LED_VIRTUAL -- cgit v1.2.3