Post Reply 
Sinclair Cambridge Programmable Program Library (more fun with the scanner)
11-30-2019, 03:42 PM
Post: #1
Sinclair Cambridge Programmable Program Library (more fun with the scanner)
I got ahold of a cheap copy of Sinclair's 4-volume program library for the Cambridge Programmable. For those not familiar with it, the Cambridge Programmable is a tiny, underpowered programmable scientific calculator that makes the HP 25 look like a 41CX.

It has:

- 19 keys
- 36 steps of program memory
- Trig and inverse trig
- Degree/radian conversions
- Natural log and anti-log
- Square, square root, and reciprocal
- Algebraic input with a single level of parentheses
- One storage memory
- Unconditional go-to and go-if-negative

It uses a typical unmerged keystroke programming model, but interestingly, all keys default to their upper shifted functions in a program. There's a special down-shift prefix key and a numeric constant prefix key if you want to enter lower shifted functions or numbers into your program.

So the calculator isn't particularly remarkable for it's (lack of) capabilities, but rather for the quality of its documentation and program library. They really managed to cram a lot of useful material into these four books, even if a lot of it is simple formula evaluation programs (i.e. no real decision making) or functions that would be built into most other scientific calculators (e.g. powers and roots).

They actually managed to implement prime factorization on this thing somehow - see page 63 in the PDF.

https://archive.org/details/sinclair-cam...am-library
Visit this user's website Find all posts by this user
Quote this message in a reply
11-30-2019, 04:47 PM
Post: #2
RE: Sinclair Cambridge Programmable Program Library (more fun with the scanner)
(11-30-2019 03:42 PM)Dave Britten Wrote:  I got ahold of a cheap copy of Sinclair's 4-volume program library for the Cambridge Programmable.

It's a good look at the calculator and has a wide range of topics but I wish it had more program analysis in it.

Tom L
I think therefore I am-Descartes
I think therefore you are-Gorgias
You're not here to think-Army Sergeant
Find all posts by this user
Quote this message in a reply
11-30-2019, 04:51 PM
Post: #3
RE: Sinclair Cambridge Programmable Program Library (more fun with the scanner)
(11-30-2019 04:47 PM)toml_12953 Wrote:  It's a good look at the calculator and has a wide range of topics but I wish it had more program analysis in it.

Yeah, some of them are pretty tough to follow with liberal use of parentheses and operator key tricks.
Visit this user's website Find all posts by this user
Quote this message in a reply
11-30-2019, 06:11 PM
Post: #4
RE: Sinclair Cambridge Programmable Program Library (more fun with the scanner)
(11-30-2019 04:51 PM)Dave Britten Wrote:  
(11-30-2019 04:47 PM)toml_12953 Wrote:  It's a good look at the calculator and has a wide range of topics but I wish it had more program analysis in it.

Yeah, some of them are pretty tough to follow with liberal use of parentheses and operator key tricks.

I'd also like references to the source of the equations and constants used. The moon landing program on page 31 is a good example of good documentation. On the other hand, page 34, the Sunday letter program, is totally without explanation. For example, what is the significance of 2107? What does Golden Number mean?

Tom L
I think therefore I am-Descartes
I think therefore you are-Gorgias
You're not here to think-Army Sergeant
Find all posts by this user
Quote this message in a reply
11-30-2019, 09:07 PM
Post: #5
RE: Sinclair Cambridge Programmable Program Library (more fun with the scanner)
(11-30-2019 03:42 PM)Dave Britten Wrote:  I got ahold of a cheap copy of Sinclair's 4-volume program library for the Cambridge Programmable. For those not familiar with it, the Cambridge Programmable is a tiny, underpowered programmable scientific calculator that makes the HP 25 look like a 41CX

Thanks for sharing. The rskey link you include is incredibly unfair to this little marvel, for instance he says:

Quote:Smallness, however, should be no excuse for sloppy design. But what else can explain the incredible inaccuracy of some of this machine's calculations?

Well, this link explains it all and, far from "sloppy", the programming is actually awesome to the max. Read here the true story, fully rcommended reading:

Reverse Engineering the Sinclair Rom

Have a nice weekend.
V.

  
Find All My HP-related Materials here:  Valentin Albillo's HP Collection
 
Visit this user's website Find all posts by this user
Quote this message in a reply
11-30-2019, 09:14 PM
Post: #6
RE: Sinclair Cambridge Programmable Program Library (more fun with the scanner)
(11-30-2019 09:07 PM)Valentin Albillo Wrote:  Well, this link explains it all and, far from "sloppy", the programming is actually awesome to the max. Read here the true story, fully rcommended reading:

Reverse Engineering the Sinclair Rom

Have a nice weekend.
V.

Note that the Sinclair Scientific is a very different animal from the Cambridge Programmable. I can't say how much of the ROM code and design constraints are shared by the two models.
Visit this user's website Find all posts by this user
Quote this message in a reply
11-30-2019, 10:15 PM
Post: #7
RE: Sinclair Cambridge Programmable Program Library (more fun with the scanner)
(11-30-2019 09:14 PM)Dave Britten Wrote:  Note that the Sinclair Scientific is a very different animal from the Cambridge Programmable.

Yes, I know, but they're sufficiently chronologically-close products to assume that the same awesome ingenuity displayed for the one would also apply to the other.

Certainly no sloppy programming there, cramming that much functionality (even with such limited accuracy) in 320 words of ROM deserves a Guinness record or something. It's almost as awesome as implementing all trigonometric functions and their inverses in 99 bytes (steps) in the HP-12C. Angel Big Grin

V.

  
Find All My HP-related Materials here:  Valentin Albillo's HP Collection
 
Visit this user's website Find all posts by this user
Quote this message in a reply
12-01-2019, 02:04 AM (This post was last modified: 12-01-2019 02:24 AM by Gamo.)
Post: #8
RE: Sinclair Cambridge Programmable Program Library (more fun with the scanner)
Sinclair Scientific Programmable Calculator 4-volume program library.

Yes I got hold of these program library for a long while and found that

The ALG style programming with this Sinclair programmable can be adapted

To work with the HP-12C Platinum on ALG mode as well. The only confusing

Part is the conditional test which use the so call [gin] key stand for (go if negative)

And since this calculator doesn’t have the [FRAC] and [INT] it Use some type of round up or round down style
with very large digits to add then subtract to only get the integer part.

The Moon Landing program is fun to play on the HP-12C Platinum (ALG mode)

The Equation Solving by Secant Method on page 19.8 is a good SOLVER for HP-12C Platinum


Gamo
Find all posts by this user
Quote this message in a reply
12-02-2019, 02:28 PM
Post: #9
RE: Sinclair Cambridge Programmable Program Library (more fun with the scanner)
Many thanks for scanning and uploading Dave!

By complete coincidence I'd only recently bought a copy - might have donated it to the CCH museum, once scanned, but it turns out they were the ones who sold it to me.
Find all posts by this user
Quote this message in a reply
12-07-2019, 10:50 AM
Post: #10
RE: Sinclair Cambridge Programmable Program Library (more fun with the scanner)
Here is the program example from the Mathematics Program Library

Page 23.1 “Factorial”

This program adapted to work on HP-12C Platinum on ALG mode

This algorithm will run slow with large n!

N < 70

Program for HP-12C Platinum on ALG mode
Code:

STO 0
STO 1
RCL 0
-
2
=
0
X<>Y
X≤Y
GTO 020
+
1
=
STO 0
X
RCL 1
=
STO 1
GTO 003
RCL 1
GTO 000

Gamo
Find all posts by this user
Quote this message in a reply
12-07-2019, 04:10 PM (This post was last modified: 12-07-2019 04:16 PM by StephenG1CMZ.)
Post: #11
RE: Sinclair Cambridge Programmable Program Library (more fun with the scanner)
Neither Vodafone or O2 in the UK can access the archive.Org link. O2 gives a tunnel error, and Vodafone wants a credit card because I am over 18.
Are any mobiles in the UK able to access the site?

Stephen Lewkowicz (G1CMZ)
The word "set" has the most definitions in the OED
Visit this user's website Find all posts by this user
Quote this message in a reply
12-08-2019, 04:37 AM (This post was last modified: 12-08-2019 04:46 AM by Gamo.)
Post: #12
RE: Sinclair Cambridge Programmable Program Library (more fun with the scanner)
General Finance Statistic Program Library

Page 7.8 “Interest on Loan”

This program was adapted to work on

HP-12C Platinum on ALG mode

https://www.hpmuseum.org/forum/thread-12187.html

————————————————————-
Mathematics Program Library

Page 19.3
“Solution of a Cubic by the Newton Raphson Method”

HP-12C Platinum on ALG mode

https://www.hpmuseum.org/forum/thread-12164.html

————————————————————

Gamo
Find all posts by this user
Quote this message in a reply
12-08-2019, 10:39 AM
Post: #13
RE: Sinclair Cambridge Programmable Program Library (more fun with the scanner)
(12-07-2019 04:10 PM)StephenG1CMZ Wrote:  Neither Vodafone or O2 in the UK can access the archive.Org link. O2 gives a tunnel error, and Vodafone wants a credit card because I am over 18.
Are any mobiles in the UK able to access the site?

I can access it from 3 (CK Hutchison) in the UK. You may have seen the current archive.org begging letter at the top of the linked page.

— Ian Abbott
Find all posts by this user
Quote this message in a reply
12-08-2019, 11:41 AM
Post: #14
RE: Sinclair Cambridge Programmable Program Library (more fun with the scanner)
Usually, the connection just fails without an obvious cause, but when I looked into this a while ago, it seems Vodafone want me to prove I am 18 because of all the dodgy stuff. (Or, is it the dodgy stuff that would like a card number?)
Apparently I could visit a shop with photo Id instead.

Stephen Lewkowicz (G1CMZ)
The word "set" has the most definitions in the OED
Visit this user's website Find all posts by this user
Quote this message in a reply
12-08-2019, 05:01 PM
Post: #15
RE: Sinclair Cambridge Programmable Program Library (more fun with the scanner)
(12-08-2019 11:41 AM)StephenG1CMZ Wrote:  Usually, the connection just fails without an obvious cause, but when I looked into this a while ago, it seems Vodafone want me to prove I am 18 because of all the dodgy stuff. (Or, is it the dodgy stuff that would like a card number?)
Apparently I could visit a shop with photo Id instead.

I'm not sure why archive.org triggers the adult filter, but you only have to turn it off once.

I'm not sure about visiting a shop with photo ID. I think that was one of the options for the AgeID system that was part of the seriously flawed Section 14(1) of the Digital Economy Act (2017), which has been quietly dropped after several delays to its implementation. It's unrelated to the voluntary (by the ISP) filters implemented by the mobile and other internet providers.

— Ian Abbott
Find all posts by this user
Quote this message in a reply
12-09-2019, 11:26 AM (This post was last modified: 12-09-2019 01:10 PM by EdS2.)
Post: #16
RE: Sinclair Cambridge Programmable Program Library (more fun with the scanner)
I know this is an off-topic diversion, but it turns out some UK mobile operators use the BBFC to classify sites, and the Internet Archive has twice been determined to merit an over-18 rating: see the December 2018 quarterly report. Different mobile operators and ISPs have taken different approaches to comply with the legislation, which is considered ill-advised and is subject to ISPs choosing their tactics. An affected customer might be able to get the block lifted for them by going through some preference or account settings update - I'm with giffgaff, who use O2, and I just did this online, needing my driving license number (or passport number). After a couple of hours, I was able to access archive.org
Find all posts by this user
Quote this message in a reply
12-12-2019, 12:06 AM
Post: #17
RE: Sinclair Cambridge Programmable Program Library (more fun with the scanner)
(12-09-2019 11:26 AM)EdS2 Wrote:  I know this is an off-topic diversion,

Isn't that like 90% of this site? Please, go right ahead! Smile
Visit this user's website Find all posts by this user
Quote this message in a reply
Post Reply 




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