The following warnings occurred:
Warning [2] count(): Parameter must be an array or an object that implements Countable - Line: 795 - File: showthread.php PHP 7.4.33 (FreeBSD)
File Line Function
/showthread.php 795 errorHandler->error





Post Reply 
HP-21 repaired
06-20-2017, 06:19 PM (This post was last modified: 06-24-2017 12:05 PM by PANAMATIK.)
Post: #1
HP-21 repaired
I think many HP-21 calculators were repaired in the past, sometimes there is only a battery contact problem, sometimes there could be a chip replaced from another calculator, sometimes a new ACT chip could have been helpful. But some of them refused to be repaired, because the display drivers were defective.

I already build a replacement for the display anode driver 1818-0153, which is described in the thread ACT available. But this time, I achieved a new kind of repair.

One of my HP-21s had a bad display cathode driver 1820-1382, this is the 20-pin chip at the right side below the display. Until today there was no replacement for this chip. Because I urgently need new cathode drivers also for my HP-19C and HP-97 repair projects, I decided to build one. After some measurements with the oscilloscope it turned out, that the logic was very easy. And I used one of my rejected second quality ACT boards for programming it as a cathode driver.

[Image: uc?export=view&id=0Bwx8KUfOUL_RQjJkblRvaF9Vdm8]

CH1 STR signal, generated by the display anode driver
CH2 K1 Signal generated by 1820-1382 cathode driver
EXT unvisible RCD signal at "T", generated by the ACT chip, Reset Counter Display

CH2 shows the timing for all display segments for "-1. E00". You can see at the left two exponent zeros, followed by a single minus segment, then three segments number 1 with dot.

[Image: uc?export=view&id=0Bwx8KUfOUL_RQkRYWHlxaWh5RDA]

The HP-21 board with missing cathode driver.

[Image: uc?export=view&id=0Bwx8KUfOUL_RVERWUWhVUVY5b0k]

Same board bottom with replacement driver, for space reasons it had to be placed away from the original chip.

[Image: uc?export=view&id=0Bwx8KUfOUL_RV3N5Z2lqeTFFU2c]

The result is a reborn HP-21 calculator.

Code:
// Woodstock Calculator Cathode Driver Replacement with PIC16F1516
// simulate a 12 digit shift register with one bit low, all others high

// 12 digit outputs RA0-RA6, RC0-RC4, connected to K1 - K12
// RCD Input RB4
// STR Input RB0
//
// Suitable for HP-21/22/25/27/29 Cathode driver 1820-1382 and also for HP-19C HP-67/97
// digit 0  = leftmost digit, mantissa minus sign
// digit 11 = rightmost digit, exponent ones
// digit 0-11 from left to right

void DoDisplayScan()
{
uint8_t digit,mask;

  TRISA=0x00; // RA0-RA7 output
  TRISB=0xD9; // RCD input
  TRISC=0xA0; // RC0-4 output, RC5 input, TX output RX input not used

  while(TRUE)
  {
    while(STR==0); // wait for STR high, will be high for 5,5 us

// from here to while(STR); only 22 machine instructions are allowed, 5500 ns/250 ns = 22

    if(RCD==0)   // if RCD is low during STR high, then reset the shift register
      digit=11;  // reset digit count to 11, rightmost digit will be shown after RCD low

    PORTA=0xFF;  // switch all digits off during STR high
    PORTC=0xFF;
    if(digit<7)  // first seven digits are connected to RA0-RA6 Port bits
    {
        mask=~(1<<digit); // precalculation to save time
        while(STR);       // wait for STR negative edge
        PORTA=mask;       // set digit low immediately after STR goes low
    } else if(digit<12)   // next 5 digits are connected to RC0-RC4 ports bits
    {
        mask=~(1<<(digit-7)); // precalculation to save time
        while(STR);       // wait for STR negative edge
        PORTC=mask;       // set digit low immediately after STR goes low
    }
    else
    {
        while(STR);       // wait for STR negative edge
    }

    if(++digit>=12) // increment shift register counter
      digit=0;
  }
}

I need to mention: Now every woodstock calculator electronics can be repaired, regardless of the cause of its malfunction, because all components have found a modern replacement.

Bernhard

That's one small step for a man - one giant leap for mankind.
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
HP-21 repaired - PANAMATIK - 06-20-2017 06:19 PM
RE: HP-21 repaired - rprosperi - 06-20-2017, 08:35 PM
RE: HP-21 repaired - PANAMATIK - 06-20-2017, 09:21 PM
RE: HP-21 repaired - rprosperi - 06-21-2017, 01:49 AM



User(s) browsing this thread: 1 Guest(s)