-2

I found a couple old calculators and their LCD's have about 130 pins.

I was wondering if I can build an LCD driver to reduce the number of I/O pins, because I don't want to use like 14 I/O extenders; or can I make 1 huge extender?

  • 1
    Shift registers might be easier and cheaper as you don't need input capability like with IO extenders – chrisl Dec 4 '19 at 12:06
  • 1
    What kind of LCD is this? Is each pin connected to one segment/pixel, and all of them share the same backplane? Or is this a row-column-matrix? Please keep in mind that you need to apply alternating voltage to LCD because DC will be bad for it. – the busybee Dec 5 '19 at 7:32
  • It is a 32x96 dotmatrix the entire thing running on 1 1.5v lr44 – Gert Maree Dec 6 '19 at 4:43
0

This answer assumes that each LCD segment is controlled by a separate pin (see comment of Juraj).

With a 74HC595 (shift register) you can use SPI to control 8 outputs. You can daisy chain 4 of them to get 32 outputs with just the SPI pins, to get 128 pins. I assume two pins are for GND and VCC. If you need more than 128 GPIO output pins, than use 5 or more sets of daisy chained shift registers.

Now, since these shift registers use SPI, you can use the slave select to use multiple sets of daisy chained shift registers. I never tried this myself though.

The pins (except GND/VCC) you use is:

  • 3 SPI pins (MISO, MOSI, CLK)
  • 4 SS pins (one for each set of 4 daisy chained shift registers)

The idea is:

  1. Set SS pin to the first set of 4 shift registers
  2. Write 32 outputs for the first 32 segment output pins (using the 4 shift registers of the first set)
  3. Set SS pin to the next set of 4 shift registers
  4. Write 32 outputs for the next set
  5. Continue with the next 2 sets (so you can use 32 * 4 = 128 pins)
  6. In the next cycle, start with step 1 again
|improve this answer|||||
  • 1
    this assumes that one pin controls one segment on a LCD with digit segments – Juraj Dec 4 '19 at 12:26
  • @Juraj True, I added it in the answer, thanks. I would think it's otherwise anyway, why would you create a nontrivial protocol and still using 130 pins. And thanks for improving my answer. – Michel Keijzers Dec 4 '19 at 12:29
  • 1
    it could be a matrix, but now as I think about it, it doesn't change the answer – Juraj Dec 4 '19 at 12:34
  • @Juraj That would make a lot of segments possible (having an X-Y matrix). But indeed only the algorithm to fill the pins is more complicated. I expect like e.g. 10 digits * 8 segments = 80 pins, and some extra for the items/words around (since it's an old calculator). – Michel Keijzers Dec 4 '19 at 12:38
  • I see i was thinking of using 8 mcp23017 chips from 2 pins to get to 128 and use 15 for matrix buttons which leaves me 36 pins – Gert Maree Dec 6 '19 at 4:46

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.