Welcome to the Rockbox Technical Forums!
TestDisk 6.8, Data Recovery Utility, August 2007Christophe GRENIER <grenier@cgsecurity.org>http://www.cgsecurity.orgDisk /dev/sdd - 4075 MB / 3886 MiB - CHS 1019 126 62Current partition structure: Partition Start End Size in sectors 1 * Sys=72 99607 97 11 245730 44 51 1141509631Bad relative sector. 2 * NetWare 3.11+ 21593 80 47 269421 14 42 1936028240Bad relative sector. 3 * Sys=79 239360 18 30 487187 77 39 1936028192Bad relative sector. 4 * Sys=0D 369390 104 25 369397 117 33 55499Warning: Bad ending sector (CHS and LBA don't match)Only one partition must be bootable Next*=Primary bootable P=Primary L=Logical E=Extended D=Deleted
The harddisk (4075 MB / 3886 MiB) seems too small! (< 4077 MB / 3889 MiB)Check the harddisk size: HD jumpers settings, BIOS detection...The following partitions can't be recovered: Partition Start End Size in sectorsD FAT32 0 0 1 1019 68 28 7964672 [##PORT#]D FAT32 0 0 7 1019 68 34 7964672 [NO NAME]
[50417.044276] printk: 375 messages suppressed.[50417.044283] Buffer I/O error on device sdc7, logical block 786433
Warning: Incorrect number of heads/cylinder 255 (FAT) != 126 (HD)Warning: Incorrect number of sectors per track 63 (FAT) != 62 (HD) FAT32 0 0 1 1019 68 28 7964672 [##PORT#]Warning: Incorrect number of heads/cylinder 255 (FAT) != 126 (HD)Warning: Incorrect number of sectors per track 63 (FAT) != 62 (HD) FAT32 0 0 7 1019 68 34 7964672 [NO NAME]
0x1DFFC00-0x1DFFFFF 0 padding0x1E00000 FAT start0x1E00003 OEM name - MSWIN4.10x1E0000D Sectors/cluster - 640x1E0000E Reserved sector count - 320x1E00010 Number of file allocation tables - 20x1E00011 Max number of root directory entries - 00x1E00015 Media descriptor - 0xF8 : Hard disk. Single sided, 80 tracks per side, 9 sectors per track0x1E00016 Sectors per fat - 2420x1E00018 Sectors per track - 630x1E0001A Number of heads - 2550x1E00026 Extended boot signature - 0x290x1E00036 FAT file system type - FAT160x1E001FE Boot sector signature - 0x55 0xAA
rdiff patch e200pF.bin OFtoDUMP.delta dump.bin
OrigEntry: .word 0 /* Enable the GPIO module clock */ LDR R1, =CGU_PERI LDR R2, [R1] MOV R0, #0x10000 ORR R2, R2, R0 STR R2, [R1] /* Be sure GPIOA port is set to all inputs*/ LDR R1, =GPIOA_REG MOV R2, #0 STR R2, [R1, #0x400] /* A little delay - not sure it is needed but it doesn't hurt */loop: NOP ADDS R2, R2, #1 CMP R2, #100 BLT loop /* Read GPIOA pin 3 */ LDRB R2, [R1, #0x20] /* Check its state */ CMP R2, #0 MOV R0, #0x1 /* Delay only if bit is cleared (arbitrary) */ MOVEQ R0, #0x500000loop2: SUBS R0, R0, #1 BNE loop2 /* Jump back and resume! */ LDR PC, OrigEntry.set CGU_PERI, 0xC80F0014.set GPIOA_REG, 0xC80B0000
Ok so to read the GPIO A pin 3 (which could be the hold button in my findings), you will need to use something like this test.S file:Code: [Select] LDR R1, =GPIOA_REG... LDRB R2, [R1, #0x20]
LDR R1, =GPIOA_REG... LDRB R2, [R1, #0x20]
So that GPIO bits can be set without affect to other pins in a single write operation, the address bus is used as a mask on read/write operation. The data register covers 256 locations in the address space. The eight address lines used are PADDR[9:2]. During a write, only GPIO1_DATA,... bits corresponding to HIGH address bits are updated. During a read all data bits corresponding to HIGH address bits are read, the other bits are zero.
OrigEntry: .word 0 /* Enable the GPIO module clock */ LDR R1, =CGU_PERI LDR R2, [R1] MOV R0, #0x10000 ORR R2, R2, R0 STR R2, [R1] /* Be sure GPIOA port is set to all inputs*/ LDR R1, =GPIOA_REG MOV R2, #0 STR R2, [R1, #0x400] /* A little delay - not sure it is needed but it doesn't hurt */loop: NOP ADDS R2, R2, #1 CMP R2, #100 BLT loop /* Read GPIOA pin 3 */ LDRB R2, [R1, #0x20] /* Check its state */ MOV R0, #0x1 CMP R2, #0 /* Delay only if bit is set (arbitrary) */ MOVNE R0, #0x500000loop2: SUBS R0, R0, #1 BNE loop2 /* Jump back and resume! */ LDR PC, OrigEntry.set CGU_PERI, 0xC80F0014.set GPIOA_REG, 0xC80B0000
/* Read GPIOA pin 3 */ LDRB R2, [R1, #0x20]
LDRB R2, [R1, #0x8]....set GPIOA_REG, 0xC80D0000 /* not GPIOA but GPIOC */
Page created in 0.09 seconds with 18 queries.