Read/write to parallel/serial port 
Author Message
 Read/write to parallel/serial port

I would like to read and write to the parallel or serial port.
I have been programming i tp and bp for some time, but havent found
any function the enables this. Is there a function, or should a start
to learn Tasm to be able to do this.

And is there FAQ about this problem

***************************
* Jacob Heder  :-)        *
* Aalborg Universty       *
* Denmark                 *
* http://www.*-*-*.com/ ~31jh *

***************************



Wed, 18 Jun 1902 08:00:00 GMT  
 Read/write to parallel/serial port

Quote:

> I would like to read and write to the parallel or serial port.
> I have been programming i tp and bp for some time, but havent found
> any function the enables this. Is there a function, or should a start
> to learn Tasm to be able to do this.

Oh dear, why do all people think they need assembler for things like
that?
You can send every byte you like to the ports. These are the registers
of the Universal Asynchron Receiver Transmitter (UART), the IC which
*is* the serial port:

Adress           Read            Write

Base Adress      Receive         Transmit and Baudrate LSB
B.A. + 1         -               Interr. Activate and Baudrate MSB
B.A. + 2         Int. identif.   -
B.A. + 3         -               Transm. control
B.A. + 4         Modem control   Modem control
B.A. + 5         Transm. status  -
B.A. + 6         Modem status    -

(8250 UART)

If you are interested in more detailed information, please e-mail me.
It's also possible to use software interrupts to initialize the ports.

The base adresses are:

COM1:    $3f8
COM2:    $2f8
COM3:    $3e8
COM4:    $2e8

The parallel port uses an 8255, which has the following registers:

Adress           Read            Write

Base Adress      Data(sometimes) Data
B.A. + 1         Status          -
B.A. + 2         Control         Control

For more detailed information... you know what to do...

   Basti

--
------------------------------------------------------------------

  Fleestedt, Germany
------------------------------------------------------------------



Wed, 18 Jun 1902 08:00:00 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. HELP ON SERIALS AND PARALLEL PORTS

2. Turbo Pascal v7.0 -- Controlling Parallel/Serial Port bits

3. Reading a parallel port

4. PARALLEL PORT READING

5. Read from Parallel Port

6. HELP - Reading from parallel port

7. Reading parallel port

8. How do I read in from a serial port

9. Read/Write parrallel port pins

10. Reading and Writing Directly to an IO Port

11. Port Writing / Reading and C Conversion

12. Parallel port control

 

 
Powered by phpBB® Forum Software