??? 10/20/06 11:23 Read: times |
#126800 - The Code Responding to: ???'s previous message |
sfr P0 = 0x80;
sfr P1 = 0x90; sfr P2 = 0xA0; sfr P3 = 0xB0; sfr P5 = 0xD8; sfr TCON = 0x88; sfr IEN0 = 0xA8; sbit P5_0 = P5^0; sbit P1_5 = P1^5; sbit IT0 = TCON^0; sbit EX0 = IEN0^0; sbit EA = IEN0^7; unsigned char temp; int i = 0; int A = 1; int B = 1; void main () { P1 = 0x63; /*P1 (0-7): -CS0,-CS1,A2,A1,A0,-RESET,-DMARQ,Not connected*/ P5 = 0xF; /*P5 (0-3): -DIOR,-DIOW,Not connected,Not connected*/ P1_5 = 0x00; for (i; i<40; i++ ) /*Delay (unknown duration) but more than 25us*/ { A = A+B; } P1_5 = 1; A = 1; i = 0; for (i; i<70; i++) /*Delay (unknown duration) but more than 2ms*/ { B = A+B; } /*All previous to setup HDD*/ P1 = 0xFE; P5_0 = 0; P5_0 = 1; temp = P2; P5_0 = 0; P0 = temp; /*The above to read status register of the HDD*/ } |
Topic | Author | Date |
AT89C51SND1C with IDE interface | 01/01/70 00:00 | |
we need to see the code | 01/01/70 00:00 | |
narrow your options | 01/01/70 00:00 | |
The Code | 01/01/70 00:00 | |
How to post schematics, etc | 01/01/70 00:00 | |
Check | 01/01/70 00:00 | |
a quick (10 secoonds) search ... | 01/01/70 00:00 | |
There is code all over | 01/01/70 00:00 | |
A Little off Subject but not much. | 01/01/70 00:00 | |
Press the green button!![]() | 01/01/70 00:00 |