0
\$\begingroup\$

Can we use 8255A (programmable peripheral interface) as a 24 bit input or 24 bit output? we know there are 3 ports PORT A,B and C each of 8 bits. How they can be used as 24 bits I/O ports?

\$\endgroup\$
  • 3
    \$\begingroup\$ Have you tried reading the data sheet? \$\endgroup\$ – WhatRoughBeast May 3 '16 at 16:26
  • \$\begingroup\$ 8255 of the 8085 family circa 1980 or earlier. Is it really worth a question? \$\endgroup\$ – StainlessSteelRat May 3 '16 at 16:54
  • \$\begingroup\$ @StainlessSteelRat We seem to get 8085 questions from time to time (if you search for 8085, you will get around 100 results). Seems somewhere there are EE course(s) (such as this one that haven't upgraded their material and/or lab equipment for 30 years. \$\endgroup\$ – tcrosley May 3 '16 at 17:04
  • \$\begingroup\$ My comment was with respect to 24 bits. For me, it is not a logical question. It is not reasonable to expect a device with 40 pins to have 24 bit ports. \$\endgroup\$ – StainlessSteelRat May 3 '16 at 17:14
1
\$\begingroup\$

You cannot address all 24 bits at the same time (e.g. a 24-bit data bus). Only one of the eight-bit three ports (A, B, C) an be addressed at a time. This is done using address bits A0 and A1. The data bus of the 8255 is only 8-bits wide (D0 through D7).

A1 A0
-----
 0  0  Port A
 0  1  Port B
 1  0  Port C
 1  1  control register

The control register determines whether the bits in the various register are used as input or output or handshaking.

enter image description here

\$\endgroup\$
  • \$\begingroup\$ if the source sends 32 bits data at a time, is there any way to receive it by slicing into 8 bits into the ports? @tcrosley \$\endgroup\$ – user6149854 May 3 '16 at 16:58
  • \$\begingroup\$ That would take some external circuitry, with some sort of two-bit counter to sequence the A0-A1 leads. \$\endgroup\$ – tcrosley May 3 '16 at 17:02
  • \$\begingroup\$ can you please give the detailed circuit? @tcrosley \$\endgroup\$ – user6149854 May 3 '16 at 17:06
  • 1
    \$\begingroup\$ @user6149854 Is this for homework? In any case, we are not a circuit design service (that's something I do for a living). It doesn't make any sense to build something like this, since the first step would be to latch all 24 data bits into a set of 24 latches so they could be read out 8 bits at a time -- which in that case the 8255 would be completely redundant. \$\endgroup\$ – tcrosley May 3 '16 at 17:14

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.