Sinclair Scientific Calculator Emulator
A register level TMS0805 CPU emulator on an Arduino Nano runs the original 320 instruction calculator program. A custom PCB houses it all.
Resources
- Reversing Sinclair's amazing 1974 calculator hack
Now Texas Instruments offered him an inexpensive calculator chip that could barely do four-function math. Could he use this chip to build a $100 scientific calculator?
Texas Instruments' engineers said this was impossible - their chip only had 3 storage registers, no subroutine calls, and no storage for constants such as π. The ROM storage in the calculator held only 320 instructions, just enough for basic arithmetic. How could they possibly squeeze any scientific functions into this chip?
Fortunately Clive Sinclair, head of Sinclair Radionics, had a secret weapon - programming whiz and math PhD Nigel Searle. In a few days in Texas, they came up with new algorithms and wrote the code for the world's first single-chip scientific calculator, somehow programming sine, cosine, tangent, arcsine, arccos, arctan, log, and exponentiation into the chip. The engineers at Texas Instruments were amazed.
- Project page & build instructions: Sinclair Scientific Calculator Emulator
Programming
The board uses Arduino Nano:
- Software: https://gitlab.com/arduinoenigma/ArduinoNanoSinclairScientificCalculator/-/tree/master?ref_type=heads
- Use https://gitlab.com/arduinoenigma/ArduinoNanoSinclairScientificCalculator/-/blob/master/SinclairScientific7/SinclairScientific7.ino?ref_type=heads (SinclairScientific7.ino)
- Add library ZIP (Sketch / Include Library / Add .ZIP Library...) from: https://gitlab.com/arduinoenigma/ArduinoNanoSinclairScientificCalculator/-/blob/master/SinclairScientific1/libraries/Arduino-GPIO-master.zip?ref_type=heads (SinclairScientific7.ino)
- I have changed serial sttings on line 310 to use more standard baud rate
diff --git a/SinclairScientific7/SinclairScientific7.ino b/SinclairScientific7/SinclairScientific7.ino index 487d8f2..ec2e143 100644 --- a/SinclairScientific7/SinclairScientific7.ino +++ b/SinclairScientific7/SinclairScientific7.ino @@ -307,7 +307,7 @@ void setup() { // put your setup code here, to run once: - Serial.begin(2000000); + Serial.begin(115200); // makes it easier to see if an arduino is programmed or not Serial.print(F("SINCLAIR v7 092318"));
After using IDE to build and upload you can connect to it via UART to get hello message:
hxd@morgana ~> tio /dev/ttyUSB0
[22:06:24.423] tio v2.7
[22:06:24.423] Press ctrl-t q to quit
[22:06:24.424] Connected
SINCLAIR v7 092318 -Common Anode -Aligned Right
