| ??? 04/23/03 06:16 Read: times |
#43984 - RE: interfacing in C language. Responding to: ???'s previous message |
Hi,
A good start to interfacing the PC is at www.beyondlogic.org, there you will find how to use the parallel and the serial ports. Parallel port is really easy to use, if you execute this command in C: outportb(0x317, 0); you will be sending 0 to the parallel port, that means that all the data pins (pins 2 to 9) on the DB25 LPT1 back there the CPU will be logic 0. A nice start is simply connect leds (with a 330R resistor in serie...) to this pins and watch them blik as you send the outportb's. (If you really connect the leds try this...: unsigned char c; while (1) { outportb(0x378, c++) delay(20); } and you will see the leds counting in binary fashion....!) PS: you might want to check the BIOS of your micro for the address of the LPT1 if this (0x378) doesn't work. |
| Topic | Author | Date |
| interfacing in C language. | 01/01/70 00:00 | |
| RE: interfacing in C language. | 01/01/70 00:00 | |
| RE: interfacing in C language. | 01/01/70 00:00 | |
| RE: interfacing in C language. | 01/01/70 00:00 | |
| RE: interfacing in C language. | 01/01/70 00:00 | |
| RE: interfacing in C language. | 01/01/70 00:00 | |
| RE: interfacing in C language. | 01/01/70 00:00 | |
| RE: interfacing in C language. | 01/01/70 00:00 | |
| RE: interfacing in C language, Gabriel | 01/01/70 00:00 | |
| RE: interfacing in C language Ragunathan | 01/01/70 00:00 | |
RE: interfacing in C language. - Nabeel | 01/01/70 00:00 |



