My further comments preceded by "Followup:"
Mike,
In answer to your questions:
1. LE goes low when the calculator's input register (which is what received keyboard input!) is empty, flag 3 is cleared, and the program is halted.
2. "Not containing data" means there's no currently pending keyboard input. The interface simply fills the keyboard buffer with up to 10 keycodes (which are limited to the digits 0-9, the decimal point, EEX, ENTER, A, and CHS.)
3. No instruction is needed to read data. Data gets read the same way keyboard input is processed. In other words, the
interface merely emulates keystrokes when the calculator is idle. One of the keystrokes can be a call to "A", causing your program to continue.
Followup: There are 10 BCD inpus on the interface. After the LE goes low (ready for input). Does BCD(A) become the first key input and BCD(B) become the 2nd key input and none of this seen until LOAD is active? Say I want to display 12.3 on the input would this be the sequence:
1) Place LE active as in 1 and 2 above.
2) Set BCD(A) to 1
3) Set BCD(B) to 2
4) Set BCD(D) to .
5) Set BCD(D) to 3
6) Set BCD(E) to Enter
7) Bring LOAD to active state
Alternatively, I might do (although inefficient):
1) Place LE active as in 1 and 2 above.
2) Set BCD(A) to 1
3) Set LOAD to active state
4) Set BCD(A) to 2
5) Set LOAD to active state
6) Set BCD(A) to .
7) Set LOAD to active state
8) Set BCD(A) to 3
9) Set BCD(B) to Enter
10) Set LOAD to active state
At which point would 12.3 show up on LED? I know I could just try this but this is too valuable to take a chance on screwing something up.
Related what would be the use for the EEX key?
Victor continues:
4. F0-F3 are the four flags.
5. The interface has no direction. It has input lines corresponding with up to 10 keystrokes that are then serialized (by the interface) and fed back to the calculator; and it has 4 output lines corresponding with the 4 flags. It has some control lines that, however, cannot be directly read, or manipulated, from a program.
Followup: So, no data can be output on the BCD lines. Is that correct?
These, then, are the only output capability? Essentially, this could be a single BCD output. If this was to be used as a BCD output, how could it be signaled to the external device that the BCD digit is ready to be read?
Victor continues:
6-7. I have actually built a CMOS clock that can be set, and read, by the HP-97S. See http://www.rskey.org/hp97s.htm.
The hardware decodes the flags in order to decide what to do (i.e., increment the hour or minute counter), and it fills the keyboard buffer with the current time readout, followed by a call to subroutine "A". The design also demonstrates how a low-power device can be isolated power-wise from the HP-97S and how one can provide a certain degree of protection against transients when the HP-97S is powered up or down.
Viktor
Followup: Thanks for the help. You clock design gives me a lot of information about how to use the interface. Thanks.