[libst2205] HighBox Apache 2.4" hack problems January 10, 2014 06:11AM |
Registered: 10 years ago Posts: 10 |
user@ubuntu:~/st2205u/libst2205$ dmesg (...) [3261252.416745] usb 2-1.2: new full-speed USB device number 45 using ehci-pci [3261252.510865] usb 2-1.2: New USB device found, idVendor=1403, idProduct=0001 [3261252.510869] usb 2-1.2: New USB device strings: Mfr=1, Product=2, SerialNumber=0 [3261252.510872] usb 2-1.2: Product: Flash Disk [3261252.510874] usb 2-1.2: Manufacturer: USB [3261252.511246] scsi6 : usb-storage 2-1.2:1.0 [3261253.510902] scsi 6:0:0:0: Direct-Access SITRONIX MULTIMEDIA 0.09 PQ: 0 ANSI: 0 CCS [3261253.511452] sd 6:0:0:0: Attached scsi generic sg2 type 0 [3261253.514525] sd 6:0:0:0: [sdb] 4096 512-byte logical blocks: (2.09 MB/2.00 MiB) [3261253.515781] sd 6:0:0:0: [sdb] Write Protect is off [3261253.515785] sd 6:0:0:0: [sdb] Mode Sense: 0b 00 00 08 [3261253.516764] sd 6:0:0:0: [sdb] No Caching mode page found [3261253.516767] sd 6:0:0:0: [sdb] Assuming drive cache: write through [3261253.519760] sd 6:0:0:0: [sdb] No Caching mode page found [3261253.519763] sd 6:0:0:0: [sdb] Assuming drive cache: write through [3261253.540772] sdb: unknown partition table [3261253.545806] sd 6:0:0:0: [sdb] No Caching mode page found [3261253.545810] sd 6:0:0:0: [sdb] Assuming drive cache: write through [3261253.545813] sd 6:0:0:0: [sdb] Attached SCSI removable disk user@ubuntu:~/st2205u/libst2205$ lsusb (...) Bus 002 Device 004: ID 1403:0001 Sitronix Digital Photo Frame
user@ubuntu:~/st2205u/libst2205$ ./phack -m "baks r ok" /dev/sdb Expected response 8 on cmd 1, got 0x6! Found device with 1536 kb memory Xres: 320, Yres240, bpp: 272 ver: 261 (320) Message written.
//get image size sendcmd(f,CMD_GET_PIC_INFO,0,0,0); read_data(f,buff,0x200); int xsize = (buff[0]<<8)+buff[1]; int ysize = (buff[2]<<8)+buff[3]; int bpp = buff[4]+0x80; printf("Xres: %i, Yres%i, bpp: %i\n",xsize,ysize,bpp);
//get memory size buff=malloc_aligned(0x10000); sendcmd(f,1,0,0,0); read_data(f,buff,0x200); flash_size=(buff[0]*128*1024)/512; printf("Found device with %i kb memory\n",flash_size);
for (x=((2048-64)/32); x<(2048/32); x++)With
flash_size=(buff[0]*128*1024)/512; for (x=((flash_size-64)/32); x<(flash_size/32); x++)
user@ubuntu:~/st2205u/libst2205$ ./phack -d memimage.bin /dev/sdb Expected response 8 on cmd 1, got 0x6! Found device with 1536 kb memory Xres: 320, Yres240, bpp: 272 ver: 261 (320) .............................................................. Memory dumped. user@ubuntu:~/st2205u/libst2205$ ./phack -df fwimage.bin /dev/sdb Expected response 8 on cmd 1, got 0x6! Found device with 1536 kb memory Xres: 320, Yres240, bpp: 272 ver: 261 (320) .. Firmware dumped.
user@ubuntu:~/st2205u/libst2205$ perl ./generate-hack.pl /dev/sdb hack/m_apache
(...) Warning! multiple matches (2) - will use the first one after SEND_CSW location Guessing CTRTYPE... Eeek! expected single match but found 0 - dont know what to do!
;Spec-file for Apache. ;Please keep the way the adresses are entered ($ to indicate a hex number, ;adresses in 4 digits) intact or the hackfw.sh script won't work anymore. ;Adresses here refer to file-adresses; in runtime these are loaded $4000 ;bytes higher but that's accounted for in the hack-code itself. CMP_VAR1=$037A CMP_VAR2=$037B PATCH_AT=$2D93 EMPTY_AT=$2F38 SEND_CSW=$2C5B LEN0=$36C LEN1=$36D LEN2=$36E LEN3=$36F CONF_XRES=320 CONF_YRES=240 CONF_BPP=24 CONF_PROTO=0 CTRTYPE=0 ;PCF8833 OFFX=4 OFFY=4
Unable to get parm_block Open failed!
user@ubuntu:~/st2205u/libst2205$ ./phack -d memimage_new.bin /dev/sdb Expected response 8 on cmd 1, got 0x6! Found device with 1536 kb memory Xres: 320, Yres240, bpp: 272 ver: 261 (320) .............................................................. Memory dumped. user@ubuntu:~/st2205u/libst2205$ ./phack -df fwimage_new.bin /dev/sdb Expected response 8 on cmd 1, got 0x6! Found device with 1536 kb memory Xres: 320, Yres240, bpp: 272 ver: 261 (320) .. Firmware dumped.
Re: [libst2205] HighBox Apache 2.4" hack problems January 10, 2014 01:22PM |
Registered: 10 years ago Posts: 10 |
Quote
BMD_Online
But, searching "H4CK" sequence in memimage_new.bin
give me 2 locations.
flash_size = 1024; (...) for (x=((flash_size-64)/32); x<(flash_size/32); x++) {
Re: [libst2205] HighBox Apache 2.4" hack problems January 11, 2014 09:53AM |
Registered: 10 years ago Posts: 10 |
for (x=0; x<2; x++) { sendcmd(f,3,x|0x80000000,0x8000,0); y=read(o,buff,0x8000); write_data(f,buff,0x8000); sendcmd(f,2,x|0x80000000,0x8000,0); //sendcmd(f,2|0x80000000,x,0x8000,0); read_data(f,buff,0x200); sendcmd(f,3,x|0x1f40,0x8000,0); write_data(f,buff,0x8000); if (y!=0x8000) { printf("Premature file end. Hope everything still works OK.\n"); x=9999; } fprintf(stderr,"."); }The firmware is written in memory, from position 0x20000 to 0x2FFFF.
for (x=0; x<2; x++) { sendcmd(f,3,x|0x80000000,0x8000,0); //get ready for writting at 0x80000000 or 0x80000001 y=read(o,buff,0x8000); write_data(f,buff,0x8000); //write data sendcmd(f,2,x|0x80000000,0x8000,0); //buffer at '''0x80000000''' is ready //sendcmd(f,0,0x8000XX,0x04008300,0x2a040083); //x=0 XX=2B x=1 XX=10 ...probably arg1,arg2,arg3 means nothing if (x==0) { sendcmd(f,0,0x80002B,0x04008300,0x2a040083); //x=0 } else { sendcmd(f,0,0x800010,0x04008300,0x2a040083); //x=1 } sendcmd(f,3,x|0x80000000,0x8000,0); //dot it again.... on '''0x80000000''' write_data(f,buff,0x8000); if (y!=0x8000) { printf("Premature file end. Hope everything still works OK.\n"); x=9999; } fprintf(stderr,"."); }
Re: [libst2205] HighBox Apache 2.4" hack problems January 13, 2014 06:06AM |
Registered: 10 years ago Posts: 10 |
PePa
Re: [libst2205] HighBox Apache 2.4" hack problems November 09, 2014 09:18PM |