Re: LCD screen for your dockstar (cheap! <$5) May 30, 2012 04:21AM |
Registered: 12 years ago Posts: 9 |
Re: LCD screen for your dockstar (cheap! <$5) May 30, 2012 06:13AM |
Registered: 12 years ago Posts: 7 |
Re: LCD screen for your dockstar (cheap! <$5) May 30, 2012 09:11AM |
Registered: 12 years ago Posts: 61 |
Re: LCD screen for your dockstar (cheap! <$5) May 30, 2012 10:01AM |
Registered: 12 years ago Posts: 365 |
Re: LCD screen for your dockstar (cheap! <$5) May 31, 2012 08:36AM |
Registered: 12 years ago Posts: 365 |
Re: LCD screen for your dockstar (cheap! <$5) May 31, 2012 02:36PM |
Registered: 12 years ago Posts: 7 |
Re: LCD screen for your dockstar (cheap! <$5) May 31, 2012 04:39PM |
Registered: 12 years ago Posts: 3 |
Tim
Re: LCD screen for your dockstar (cheap! <$5) June 01, 2012 12:42PM |
Re: LCD screen for your dockstar (cheap! <$5) June 01, 2012 01:54PM |
Registered: 12 years ago Posts: 9 |
Tim
Re: LCD screen for your dockstar (cheap! <$5) June 01, 2012 04:21PM |
ax206term
Re: LCD screen for your dockstar (cheap! <$5) June 01, 2012 08:24PM |
+int dpf_copy(ADDR dst, unsigned char *src, unsigned short n) +{ + unsigned char *cmd = g_excmd; + + cmd[6] = 0x01; // memory_write + cmd[7] = dst; + cmd[8] = dst >> 8; + cmd[9] = n; + cmd[10] = n >> 8; + + return wrap_scsi(g_dpf, cmd, sizeof(g_excmd), DIR_OUT, src, n); +} + +int set_screen(DPFContext *h, const unsigned char *col) +{ + unsigned char *cmd = g_excmd; + + unsigned short len = 128 * 64; + + cmd[6] = 0xff; + cmd[7] = col[0]; + cmd[8] = col[1]; + cmd[9] = len; + cmd[10] = len >> 8; + + return wrap_scsi(h, cmd, sizeof(g_excmd), DIR_IN, 0, 0); +} + +int write_screen(DPFContext *h, const unsigned char *buf, unsigned int len) +{ + unsigned char *cmd = g_excmd; + unsigned int l; + unsigned char factor; + + if (len > 0xffff) { + factor = 2; l = len >> 1; + } else { + factor = 1; l = len; + } + + cmd[6] = 0x11; + cmd[7] = factor; + cmd[8] = 0; + cmd[9] = l; + cmd[10] = l >> 8; + + return wrap_scsi(h, cmd, sizeof(g_excmd), DIR_OUT, + (unsigned char*) buf, len); +} + + +void dpf_writefb(DPFContext *h, unsigned char *buffer) +{ + int len; + + len = h->width * h->height * h->bpp; + write_screen(h, buffer, len); +} + +void dpf_backlight(DPFContext *h, int on) +{ + +} +I managed to compile this version of lcd4linux by hand editing. But I think the correct way to do this is to merge the changes back to dpflib in dpf-ax.
Re: LCD screen for your dockstar (cheap! <$5) June 02, 2012 04:32AM |
Registered: 12 years ago Posts: 3 |
diff libdpf.h dpf.h 7a8,9 > #include "usbuser.h" > #include "spiflash.h" 11,12c13,17 < #define MODE_USB 0x00 ///< libusb operation mode (hacked) < #define MODE_SG 0x01 ///< generic device mode (original) --- > #define MODE_SG 0x00 ///< generic device mode (original) > #define MODE_USB 0x01 ///< libusb operation mode (hacked) > #define MODE_USBHID 0x02 ///< libusb HID boot mode > > #define FLAG_CAN_LOCK 0x80 ///< Has the locking feature (new firmware) 21a27 > DEVERR_UNSUPP, 24a31,48 > struct dpf_context; > #define DPFHANDLE struct dpf_context * > > typedef struct { > int (*mem_read)(DPFHANDLE h, unsigned char *buf, ADDR offset, int len); > int (*mem_write)(DPFHANDLE h, > ADDR dst, const unsigned char *buf, unsigned short n); > int (*go)(DPFHANDLE h, ADDR start); > int (*bootstrap)(DPFHANDLE h, > ADDR dest, unsigned char *src, unsigned short n, ADDR start); > int (*flash_probe)(DPFHANDLE h, unsigned char *id); > int (*flash_cmd)(DPFHANDLE h, int command, int cmdlen, ADDR addr); > int (*flash_status)(DPFHANDLE h, uint8_t *status); > int (*flash_read)(DPFHANDLE h, uint8_t *buf, ADDR offset, int len); > int (*flash_writechunk)(DPFHANDLE h, > const uint8_t *buf, ADDR offset, int len); > int (*flash_lock)(DPFHANDLE h, char enable); > } AccessMethods; 28a53 > unsigned char flags; 32a58 > AccessMethods methods; 43c69,82 < #define DPFHANDLE struct dpf_context * --- > > /** A value proxy for the property API */ > typedef struct dpf_proxy { > union { > short integer; > char *sequence; > } value; > char type; > } DPFValue; > > enum { > TYPE_INTEGER, > TYPE_STRING, > }; 54c93,100 < /* --- > /** Set color register > * \param rgb RGB tuple */ > int dpf_setcol(DPFHANDLE h, const unsigned char *rgb); > > /** Blit data to screen > * > * \param buf buffer to 16 bpp RGB 565 image data > * \param rect rectangle tuple: [x0, y0, x1, y1] 56d101 < void dpf_writefb(DPFHANDLE h, unsigned char *fb); 60,63c105,109 < /* < Turn the backlight on or off < */ < void dpf_backlight(DPFHANDLE h, int on); --- > /** Set property on DPF > * \param token Property token > * \param value Pointer to value > */ > int dpf_setproperty(DPFHANDLE h, int token, const DPFValue *value); 73c119 < usb_dev_handle *dpf_usb_open(void); --- > int dpf_usb_open(int index, usb_dev_handle **u); 74a121,128 > int usb_rawread(usb_dev_handle *dev, unsigned char *buf, int len); > int usb_rawwrite(usb_dev_handle *dev, const unsigned char *buf, int len); > int probe(DPFHANDLE h); > > //////////////////////////////////////////////////////////////////////////// > // Bootloader functionality > > int bl_go(DPFContext *dpf, uint16_t jmpoffset); 82,83c136,140 < int read_mem(DPFHANDLE h, unsigned char *buf, ADDR offset, int len); < int write_mem(DPFHANDLE h, const char *hexfile); --- > int read_mem(DPFHANDLE h, unsigned char *buf, ADDR src, unsigned short len); > int write_mem(DPFHANDLE h, > ADDR dst, const unsigned char *buf, unsigned short len); > > int load_hexfile(DPFHANDLE h, const char *hexfile); 85a143,145 > int dpf_bootstrap(DPFHANDLE h, > ADDR dst, unsigned char *src, unsigned short n, ADDR start); > 88a149 > int flash_erase_full(DPFHANDLE h); 92c153 < int load_ihx(const char *fname, unsigned char *data, --- > int load_ihx(DPFHANDLE h, const char *fname, unsigned char *data, 108c169 < int dpf_copy(ADDR dst, unsigned char *src, unsigned short n); --- > #define RGB565_S(r, g, b) ((RGB565_0(r, g, b) << 8) | RGB565_1(r, g, b)) 110c171,173 < int set_screen(DPFHANDLE h, const unsigned char *col); --- > int dpfcpy(ADDR dst, unsigned char *src, unsigned short n); > > // int clr_screen(DPFHANDLE h, const unsigned char *col); 121c184,188 < #define OFFSET_RESOLUTION 0x23 ///< w[2]:LE : Resolution X, Y --- > // FIXME: Should be 0x0020, once we have the firmware replaced > #define OFFSET_PROPS 0x3f0020 ///< w[2]:LE : Resolution X, Y > > >
Re: LCD screen for your dockstar (cheap! <$5) June 02, 2012 05:30AM |
Registered: 12 years ago Posts: 365 |
Tim
Re: LCD screen for your dockstar (cheap! <$5) June 02, 2012 06:26AM |
Re: LCD screen for your dockstar (cheap! <$5) June 02, 2012 08:10AM |
Registered: 12 years ago Posts: 365 |
Tim
Re: LCD screen for your dockstar (cheap! <$5) June 02, 2012 09:02AM |
_custom_backlighttbl:: .db 0x00, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, 0x10, 0x11, 0x12 .db 0x13, 0x14, 0x15, 0x17, 0x1b, 0x1f, 0x23, 0x27, 0x2b, 0x2d .db 0x3c, 0x3f _custom_backlighttbl_len:: .db 22 _custom_backlighttbl2:: .db 0x00, 0x03, 0x06, 0x07, 0x08, 0x09, 0x0a, 0x0a, 0x0b, 0x0b .db 0x0c, 0x0c, 0x0d, 0x0d, 0x0f, 0x11, 0x13, 0x15, 0x17, 0x18 .db 0x1c, 0x1d _custom_backlighttbl2_len:: .db 22
ax206term
Re: LCD screen for your dockstar (cheap! <$5) June 02, 2012 09:24AM |
if test "$ST2205" = "yes"; then if test "$has_st2205" = "true"; then GRAPHIC="yes" DRIVERS="$DRIVERS drv_st2205.o" DRVLIBS="$DRVLIBS -L/usr/local/lib -lst2205" $as_echo "#define WITH_ST2205 1" >>confdefs.h else { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: st2205.h not found: st2205 driver disabled" >&5 $as_echo "$as_me: WARNING: st2205.h not found: st2205 driver disabled" >&2;} fi fiThe mplayer ax206 patch somewhere in this thread follows a similar approach.
Re: LCD screen for your dockstar (cheap! <$5) June 02, 2012 09:40AM |
Registered: 12 years ago Posts: 365 |
Re: LCD screen for your dockstar (cheap! <$5) June 03, 2012 06:01AM |
Registered: 12 years ago Posts: 365 |
Re: LCD screen for your dockstar (cheap! <$5) June 05, 2012 04:24PM |
Registered: 12 years ago Posts: 3 |
meltwater
Re: LCD screen for your dockstar (cheap! <$5) June 13, 2012 03:02AM |
scsi 0:0:0:0: CD-ROM buildwin Photo Frame 1.01 PQ: 0 ANSI: 2 sr0: scsi3-mmc drive: 40x/40x writer cd/rw xa/form2 cdda tray cdrom: Uniform CD-ROM driver Revision: 3.20 sr 0:0:0:0: Attached scsi CD-ROM sr0 usb 1-1.2.1: reset full speed USB device number 6 using dwc_otg usb 1-1.2.1: USB disconnect, device number 6 usb 1-1.2.1: new full speed USB device number 7 using dwc_otg usb 1-1.2.1: New USB device found, idVendor=1908, idProduct=3318 usb 1-1.2.1: New USB device strings: Mfr=2, Product=1, SerialNumber=3 usb 1-1.2.1: Product: BL206v1.0.0 usb 1-1.2.1: Manufacturer: BUILDWIN usb 1-1.2.1: SerialNumber: 000001 generic-usb 0003:1908:3318.0002: timeout initializing reports generic-usb 0003:1908:3318.0002: hiddev0: USB HID v2.01 Device [BUILDWIN BL206v1.0.0] on usb-bcm2708_usb-1.2.1/input0
Re: LCD screen for your dockstar (cheap! <$5) June 13, 2012 06:02AM |
Registered: 12 years ago Posts: 9 |
meltwater
Re: LCD screen for your dockstar (cheap! <$5) June 13, 2012 06:53AM |
meltwater
Re: LCD screen for your dockstar (cheap! <$5) June 13, 2012 07:28AM |
Re: LCD screen for your dockstar (cheap! <$5) June 13, 2012 09:06AM |
Registered: 12 years ago Posts: 365 |
meltwater
Re: LCD screen for your dockstar (cheap! <$5) June 13, 2012 10:37AM |
sairon
Re: LCD screen for your dockstar (cheap! <$5) June 19, 2012 02:05PM |
sairon@ntbk-ubuntu:~/dpf-ax/trunk/fw$ sudo python detect.py /dev/sg3 Opening generic SCSI device '/dev/sg3' Manufacturer: Apple Size : 1 MB sairon@ntbk-ubuntu:~/dpf-ax/trunk/fw$ sudo python identify.py full.bin Looking for firmware.............: Found (buildwin, 128x128 px). Looking for known version info...: None. Looking for Openwin..............: OpenWin at 0x1280 (0x0006a0), len 0x3c, CRC = 0xfa7b6f9c Written to openwin_tmp.bin. Looking for LcdIniTbl............: Module 37: LcdInit !NOTBL! at 0x1330 (0x048800) Module 51: LcdScheduleTbl at 0x156d (0x04a1ad), len 0x00 Invalid LcdIniTbl! None. WARNING: This is no "standard" buildwin software! Looking for known signatures.....: None. Sorry, no matching dpf found.
sairon
Re: LCD screen for your dockstar (cheap! <$5) June 19, 2012 02:36PM |
sairon@ntbk-ubuntu:~/dpf-ax/trunk$ hexdump -C tbl.bin 00000000 50 72 6f 63 54 62 6c 33 0b 30 0b b1 1c 06 00 00 |ProcTbl3.0......| 00000010 0b 2a 0d 27 dc 06 00 00 0b 2a 0c e7 dc 08 00 00 |.*.'.....*......| 00000020 0b 2a 0d 18 9a 0a 00 00 0e 00 0e 7c 88 0c 00 00 |.*.........|....| 00000030 0b 2a 0c 9c 04 0d 00 00 0b 2a 0c 65 08 12 00 00 |.*.......*.e....| 00000040 0b 30 0d fd 44 13 00 00 0c 80 10 a2 12 16 00 00 |.0..D...........| 00000050 0b 30 0c b5 34 1a 00 00 0b 30 0f 61 ba 1b 00 00 |.0..4....0.a....| 00000060 0b 30 0c 53 ec 1f 00 00 0b 30 0f c6 2c 23 00 00 |.0.S.....0..,#..| 00000070 0b 30 0e 67 c2 27 00 00 0b 30 0c 55 5c 2c 00 00 |.0.g.'...0.U\,..| 00000080 0b 30 0b 5d 82 2d 00 00 0b 30 0d 45 b0 2d 00 00 |.0.].-...0.E.-..| 00000090 0b 30 0f 84 64 30 00 00 0b 30 0f cf b8 34 00 00 |.0..d0...0...4..| 000000a0 0b 30 0e 66 58 39 00 00 0b 30 0f b4 8e 3c 00 00 |.0.fX9...0...<..| 000000b0 0b 30 0f ca 12 41 00 00 0b 30 0e f4 ac 45 00 00 |.0...A...0...E..| 000000c0 0b 30 0f 92 70 49 00 00 0b 30 0f 46 d2 4d 00 00 |.0..pI...0.F.M..| 000000d0 0b 30 0f 11 e8 51 00 00 0b 30 0d bb ca 55 00 00 |.0...Q...0...U..| 000000e0 0b 30 10 fa 56 58 00 00 0b 30 10 63 20 5e 00 00 |.0..VX...0.c ^..| 000000f0 0b 30 0d 71 54 63 00 00 0b 30 10 4d 96 65 00 00 |.0.qTc...0.M.e..| 00000100 0b 30 0e 2f ce 6c 00 00 0b 30 0e 2b ce 6f 00 00 |.0./.l...0.+.o..| 00000110 0b 30 0e b3 ca 72 00 00 0b 30 0e 55 4e 76 00 00 |.0...r...0.UNv..| 00000120 0b 30 0f 79 74 79 00 00 0b 30 0f be 00 88 04 00 |.0.yty...0......| 00000130 0b 30 0b bb 26 8e 04 00 0b 30 0b 62 8e 8c 04 00 |.0..&....0.b....| 00000140 0b 30 0b 90 c0 8c 04 00 0b 30 0c 35 20 8d 04 00 |.0.......0.5 ...| 00000150 0b 30 0c 91 fa 2a 00 00 0b 30 10 ec b2 8e 04 00 |.0...*...0......| 00000160 0b 30 0c 50 6e 94 04 00 0b 30 0e 8c 8e 95 04 00 |.0.Pn....0......| 00000170 0b 30 10 13 ea 98 04 00 0b 30 0c d2 ce 9d 04 00 |.0.......0......| 00000180 0b 30 0d 4b 10 21 00 00 0b 2a 0b fa 38 11 00 00 |.0.K.!...*..8...| 00000190 0b 30 0d 4a b4 6a 00 00 0b 30 0d 6e 70 9f 04 00 |.0.J.j...0.np...| 000001a0 2d 45 6e 64 54 62 6c 2d ff ff ff ff ff ff ff ff |-EndTbl-........|
Re: LCD screen for your dockstar (cheap! <$5) June 20, 2012 02:25AM |
Registered: 12 years ago Posts: 365 |
sairon
Re: LCD screen for your dockstar (cheap! <$5) June 20, 2012 05:28AM |