Calculator for the zx81
Calculator for the zx81
Is there a graphical calculator for the zx81?
Not a text-based one. A calculator with buttons. Is there any?
Not a text-based one. A calculator with buttons. Is there any?
Our music sent up to God.
Partituræ Immortales | Ghost Label records | Spotify Playlist Curators | Artists' Database
Partituræ Immortales | Ghost Label records | Spotify Playlist Curators | Artists' Database
Re: Calculator for the zx81
Ok after searching online for thirty minutes, I didn't find anything, and I thought perhaps we could all together build one !!!
I start first!
But because I am the most stupid, I will only do the graphics! So the clever people can take over!

Let's build a calculator !

I start first!
But because I am the most stupid, I will only do the graphics! So the clever people can take over!

Let's build a calculator !

Code: Select all
10 LET A = 0
1000 PRINT AT 0,0
1050 PRINT "\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##"
1100 PRINT "\##\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\##"
1120 PRINT "\##\::0 \::\##"
1130 PRINT "\##\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\##"
1150 PRINT "\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##"
1210 PRINT "\##\::\::\::\::\::\##\::\::\::\::\::\##\::\::\::\::\::\##\::\::\::\::\::\##\::\::\::\::\::\##"
1220 PRINT "\##\::\::%7\::\::\##\::\::%8\::\::\##\::\::%9\::\::\##\::\::%/\::\::\##\::C%L%R\::\##"
1230 PRINT "\##\::\::\::\::\::\##\::\::\::\::\::\##\::\::\::\::\::\##\::\::\::\::\::\##\::\::\::\::\::\##"
1250 PRINT "\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##"
1310 PRINT "\##\::\::\::\::\::\##\::\::\::\::\::\##\::\::\::\::\::\##\::\::\::\::\::\##\::\::\::\::\::\##"
1320 PRINT "\##\::\::%4\::\::\##\::\::%5\::\::\##\::\::%6\::\::\##\::\::%*\::\::\##\::%R%U%T\::\##"
1330 PRINT "\##\::\::\::\::\::\##\::\::\::\::\::\##\::\::\::\::\::\##\::\::\::\::\::\##\::\::\::\::\::\##"
1350 PRINT "\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##"
1410 PRINT "\##\::\::\::\::\::\##\::\::\::\::\::\##\::\::\::\::\::\##\::\::\::\::\::\##\::\::\::\::\::\##"
1420 PRINT "\##\::\::%1\::\::\##\::\::%2\::\::\##\::\::%3\::\::\##\::\::%-\::\::\##\::%S%Q%R\::\##"
1430 PRINT "\##\::\::\::\::\::\##\::\::\::\::\::\##\::\::\::\::\::\##\::\::\::\::\::\##\::\::\::\::\::\##"
1450 PRINT "\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##"
1510 PRINT "\##\::\::\::\::\::\##\::\::\::\::\::\##\::\::\::\::\::\##\::\::\::\::\::\##\::\::\::\::\::\##"
1520 PRINT "\##\::\::%0\::\::\##\::\::%,\::\::\##\::%P%E%R\::\##\::\::%+\::\::\##\::\::%=\::\::\##"
1530 PRINT "\##\::\::\::\::\::\##\::\::\::\::\::\##\::\::\::\::\::\##\::\::\::\::\::\##\::\::\::\::\::\##"
1550 PRINT "\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##\##"
Our music sent up to God.
Partituræ Immortales | Ghost Label records | Spotify Playlist Curators | Artists' Database
Partituræ Immortales | Ghost Label records | Spotify Playlist Curators | Artists' Database
Re: Calculator for the zx81
That looks text based 

In theory, there is no difference between theory and practice. But, in practice, there is.
Re: Calculator for the zx81
No. Text based are those that ask you "Would you like to add, subtrack, divide or multiply? Mine is very advanced and futuristic.

And please be so kind to help me with the coral rom before I destroy a dozen of eproms.

And please be so kind to help me with the coral rom before I destroy a dozen of eproms.
Our music sent up to God.
Partituræ Immortales | Ghost Label records | Spotify Playlist Curators | Artists' Database
Partituræ Immortales | Ghost Label records | Spotify Playlist Curators | Artists' Database
Re: Calculator for the zx81
So let's see..
In visual basic when you press a button, let's say "3" for example, you can do this
on button "3" click
if textbox = 0 then textbox = 3
else
textbox +=3
And if there is already a string in our textbox, for example "321", our program will place the character "3" next to our string "321" and we will get a "3213" textbox on our screen.
I guess is not that simple with zx basic is it ?:)
In visual basic when you press a button, let's say "3" for example, you can do this
on button "3" click
if textbox = 0 then textbox = 3
else
textbox +=3
And if there is already a string in our textbox, for example "321", our program will place the character "3" next to our string "321" and we will get a "3213" textbox on our screen.
I guess is not that simple with zx basic is it ?:)
Our music sent up to God.
Partituræ Immortales | Ghost Label records | Spotify Playlist Curators | Artists' Database
Partituræ Immortales | Ghost Label records | Spotify Playlist Curators | Artists' Database
- 1024MAK
- Posts: 4545
- Joined: Mon Sep 26, 2011 10:56 am
- Location: Looking forward to summer in Somerset, UK...
Re: Calculator for the zx81
No. The ZX81 BASIC has absolutely no concept of such a thing.
Instead you may have to use IF THEN constructs.
Mark
ZX81 Variations
ZX81 Chip Pin-outs
ZX81 Video Transistor Buffer Amp
We have now entered the Spring system. Standby alert! Summer approaching
Step up to red alert. Sir, are you absolutely sure? It does mean changing the bulb.
ZX81 Chip Pin-outs
ZX81 Video Transistor Buffer Amp
We have now entered the Spring system. Standby alert! Summer approaching

Step up to red alert. Sir, are you absolutely sure? It does mean changing the bulb.
Re: Calculator for the zx81
Yes, just use a string, add the key pressed and display the string.
Re: Calculator for the zx81
Doctor Beep I was hoping that we will co-operate on this one, after checking out your enormous BASIC experience.
But anyway, if you are more concerned building games, as it seems, perhaps write down how the "add to string" function works and I will continue from there.

But anyway, if you are more concerned building games, as it seems, perhaps write down how the "add to string" function works and I will continue from there.

Our music sent up to God.
Partituræ Immortales | Ghost Label records | Spotify Playlist Curators | Artists' Database
Partituræ Immortales | Ghost Label records | Spotify Playlist Curators | Artists' Database
Re: Calculator for the zx81
I am more than willing to help, but don't make assumptions that are not true.xubuntu wrote: ↑Thu Mar 23, 2023 7:15 am Doctor Beep I was hoping that we will co-operate on this one, after checking out your enormous BASIC experience.
But anyway, if you are more concerned building games, as it seems, perhaps write down how the "add to string" function works and I will continue from there.
![]()
as for my goodwill:
Code: Select all
10 let d$=""
20 let k$=inkey$
30 if k$="" then goto 20
40 let d$=d$+k$
50 print at 10,10;d$
60 goto 20
Re: Calculator for the zx81
I made progress and thus I am obligated to upload my superior code on this obsolete and god-forsaken forum, because what if my computer suddenly explodes and humanity suffers the loss of the most futuristic calculator ever made for zx81? That of course can't be tolerated.
At that point I would like to thank my mom and my dad for making me so incredibly clever, and point out that nobody helped me making this calculator, and especially not mister beep!
You are all free and welcome to suggest parts for improvement, although that would be nearly impossible considering how clever I am, so I can take all the credit, mention no one and state with bold letters that this was entirely my own idea/creation.
For the moment only addition and subtraction work.
Why are the keys not responding very well? Sometimes I have to press them 2 or 3 times.
At that point I would like to thank my mom and my dad for making me so incredibly clever, and point out that nobody helped me making this calculator, and especially not mister beep!
You are all free and welcome to suggest parts for improvement, although that would be nearly impossible considering how clever I am, so I can take all the credit, mention no one and state with bold letters that this was entirely my own idea/creation.
For the moment only addition and subtraction work.
Why are the keys not responding very well? Sometimes I have to press them 2 or 3 times.

- Attachments
-
- calculator.bas
- (6.07 KiB) Downloaded 19 times
Our music sent up to God.
Partituræ Immortales | Ghost Label records | Spotify Playlist Curators | Artists' Database
Partituræ Immortales | Ghost Label records | Spotify Playlist Curators | Artists' Database