|
Rockbox mail archiveSubject: AW: More port pins revealedAW: More port pins revealed
From: edx <Felix.Arends_at_gmx.de>
Date: Sun, 6 Jan 2002 19:33:43 +0100 Hehe great! I have been experimenting with the input pins as well (but I didn't get any useful result). I'm getting more and more angry about my damaged JukeBox (want to try all this). > PA15: USB cable connected I thought the firmware from the ROM would manage the USB connection to the computer. Does that mean that it would theoretically be possible to develop another format for transmitting the hd-content? I have also noticed that the USB connection is not activated if one of our "hack-OSs" is running while the cable is plugged in. Maybe the original firmware shuts down if a USB cable gets connected to establish the connection to the computer? /edx (Felix Arends) ----- Original Message ----- Now with working lcd code (at least for me ;) I have been able to find which port pins the keys are connected to: ON: PA5 MENU: PC1 PLAY: PC4 STOP: PA11 NEXT: PC3 PREV: PC0 Other interesting pins: PA14: goes low on every key press except ON PA15: USB cable connected PA0: DC adapter connected Note: All of the above are active low. Idle values for the ports are: Port A: FF7F Port B: 7BEB Port C: 7AFF (note: upper 8 bits of register PCDR are undefined) The code used for this experiment: ----- void hex16( unsigned char* buf, unsigned short value ) { static char* hexcode = "0123456789ABCDEF"; buf[0] = hexcode[(value & 0xf000) >> 12]; buf[1] = hexcode[(value & 0x0f00) >> 8]; buf[2] = hexcode[(value & 0x00f0) >> 4]; buf[3] = hexcode[value & 0x000f]; buf[4] = 0; } int main(void) { char buf[5]; int i; /* clear screen */ lcd_printxy(0,0," ",11); lcd_printxy(0,1," ",11); while (1) { hex16(buf,PADR); lcd_printxy(0,0,buf,4); hex16(buf,PBDR); lcd_printxy(6,0,buf,4); hex16(buf,PCDR); lcd_printxy(0,1,buf,4); PBDR ^= 0x40; /* toggle LED (PB6) */ for ( i=0; i<1000000; i++ ); } } ----- /Björn Received on 2002-01-06 Page template was last modified "Tue Sep 7 00:00:02 2021" The Rockbox Crew -- Privacy Policy |