Hjalfi programs a ZX81

Поделиться
HTML-код
  • Опубликовано: 3 окт 2024

Комментарии • 79

  • @alistermunro7090
    @alistermunro7090 Год назад +2

    I loved my ZX-81. Had a green film over my spray painted B&W TV, 16K RAM pack, rubber addon keypad and of course the thermal printer.

  • @0bm31770
    @0bm31770 7 месяцев назад +1

    Watching this takes me back to 1982 when I got my TS1000. I'm glad it came with 2K RAM. I didn't have much trouble writing simple games. I also assembled a 16K module so I was able to write some long programs.

  • @NotMarkKnopfler
    @NotMarkKnopfler 2 года назад +6

    Yes. This was how it was done. Your mate would come round after school, you'd put on some music on the record player, and take over the family TV to write the next 'mega game' that you had been talking about at school all day instead of doing your school work!! That's literally how it was.

  • @mauromartyn7941
    @mauromartyn7941 Год назад +2

    My father say , in 1983; - "What do you want? Atari 2600 or a computer?"
    In my little tinny brain for a kid 8 years old, a computer was a faboulous machine with millions of games and oportunitys.....
    You need see my face, and the face of my sister, when my father start on this piece of WHAAAAAT!!!!
    But the old man , in this moment, would give me a big favor. Because, me and my sister , was take BASIC lessons in a new academy. That was my first contact with the world of computers. I study for be an ingenier, and I work as an IT in my job. Thanks dad!!

  • @j0hnf_uk
    @j0hnf_uk 2 года назад +2

    I spent the entire summer school holidays of 1981 learning to program this machine, and by the end of the 6 weeks, I was quite proficient and wrote many games which I saved on cassette. One C90 cassette, no less. Something I shouldn't have done, but didn't know better at the time. Needless to say, years later, when trying to load in some of them, I was sadly disappointed.

    • @hjalfi
      @hjalfi  2 года назад +1

      It's probably stretched. If you still have the cassette, then it may be possible to digitise the audio and fiddle with the frequency until it decodes properly.

  • @r0bhumm
    @r0bhumm 2 года назад +1

    I suffer from severe dyslexia to program on a ZX 81 I found the fact that it expanded the key presses out to the commands on the screen help me immensely as a child.

  • @Havanacuba1985
    @Havanacuba1985 3 года назад +2

    This was my first computer in 1984 from WH Smith £39.99 got you the zx81 and a memotech 16k ram pack
    I could not believe I owned an actual computer. The manual was great and full of short interesting programs and explained things like variables very simply. I had great fun typing in programs from magazines .im so sorry I sold it in 1985 . I have just bought another 48k spectrum and am so looking forward to it.

  • @richartrod
    @richartrod 2 года назад

    This is why I admire those who programmed these old-school machines. Clever coding and editing squeezed every last bit and byte out of the puny RAM and created impressive games and apps. This video demonstrates that cleverness in real time.

  • @mikafoxx2717
    @mikafoxx2717 Год назад +1

    I'm impressed with the editor, much better than the MS basics I've used..

  • @Plrang
    @Plrang 6 лет назад +5

    I love that data transfer sound.. it takes me back, like meeting an oooold friend

  • @gdutfulkbhh7537
    @gdutfulkbhh7537 11 месяцев назад +1

    The Good Old Days were the Bad Old Days. Sinclair awfulness brings back distinctly mixed emotions.

  • @banjobear1666
    @banjobear1666 4 года назад +3

    Ah, the good old days! This has inspired me to dig out my old ZX81 from the loft. Great programming !

  • @laser31415
    @laser31415 6 лет назад +5

    My first computer! I loved programming it but hated the keyboard. My wrists start to ache just looking at this video.

  • @lintuxvi
    @lintuxvi 6 лет назад +7

    Love this, live-coding on some very ancient hardware is surprisingly great fun.

    • @herrbonk3635
      @herrbonk3635 3 года назад

      I agree, but ancient computers were built in 1941, not 1981 :D

  • @MikePerigo
    @MikePerigo 3 года назад +5

    Before deleting the initialization lines, more space could have been saved by changing
    Line 30 (LET C=5) to line 9 and then changing lines 10 and 20 to LET A=C+C+C and LET B=A+C.
    Also, at the end, lines 140 and 201 still both contained the number 0 which could be replaced by Y.

  • @olavl8827
    @olavl8827 4 года назад +2

    I just happened on this video today. You explain programming very nicely, well done. I had a ZX Spectrum 48K in the day which was a bit better than this, especially in terms of memory of course. At 53:08 you wonder why you need to give a filename when saving. It's because when loading from tape you can either fast forward the tape using the counter on the player to find the desired program (you'd typically keep a handwritten list with the cassette). Then use LOAD "" to make the computer load the first file that it hears. Or you can use LOAD "filename" and play the entire tape from the start and the computer loads only the file you specified when eventually it comes along.
    Of course nothing stops you from having different files with the same name on the cassette. Again, the computer will pick up the first that matches and ignores the others.

  • @MarcoMugnatto
    @MarcoMugnatto 4 года назад +3

    Two things I didn't know about zx81 that I learnt here: you can use two ATs in one line, and it saves variable values to the cassette

  • @jinchoung
    @jinchoung 3 года назад +1

    very enjoyable indeed! watching you program "over your shoulder" with you explaining things as you went along was tremendously educational. geez, i wish i had you as a teacher when i had the zx81! and the fact that it is just soo limited makes every little optimization demonstrably important. teaches a lot of useful principles that may be harder to understand with our modern machines. thanks for the great vid!

  • @TheSudsy
    @TheSudsy 2 года назад +2

    This is why there was a generation of coders who could squeeze every last byte and frame out of a program. Once we got into the 16 bit + world then memory and performance were "unlimited" and coding got lazy. With a 16k and even 64k RAM pack - yes they existed i had one. You could let you imagination run riot. I used to code adventure games with (simple) graphics into 64 k.

  • @coldsilnc
    @coldsilnc 3 года назад

    This brought back memories from my childhood. The zx81 was my first computer and i spent 1000s of hours programming on that machine. thanks for the video. :)

  • @KennethSorling
    @KennethSorling Год назад +2

    Thank you for this, it had lots of info and cool memory-saving tricks.
    One thing to make it more like a game, and thus more addictive, is keeping a score. Either you increment the score by a point or a few each time you catch the ball with the bat, or, simpler, increment the score by one for each second, or each 'turn' you manage to keep the ball 'alive'.
    I realize, though, that this is a pipe dream unless you squeeze out even more free bytes to accomplish all this. Not only to implement the logic, but to reserve space to display the score continuously. Man, this little computer was so frustratingly limited!
    So here's a thought: How about a machine language version of this? That has got to be not only less memory, but also quite a bit faster. Plus, it's a chance to introduce new tools and tricks. What would you even use to develop it? How would you get the code into the computer?

    • @hjalfi
      @hjalfi  Год назад +1

      These days, for machine code ZX81 programs you'd do the coding on a PC in an emulator and then deploy it via an SD card interface like the ZXPand. It'd also be possible to output audio data via your soundcard which can be read in through the cassette jack. But developing on a PC is much less fun. Back in the day, to develop on a ZX81, you'd either have used an assembler on an upgraded machine (which was a pretty miserable experience) or else hand-assembled on paper and entered hex directly (which was also a pretty miserable experience). Changing anything in the program would have involved lots of re-keying bytes and lots of crashes, which would lose all your data.

  • @CelticSaint
    @CelticSaint 3 года назад +1

    Thank you for this. You did a great job. I got back into BASIC a few years ago and have had a lot of fun writing games and simulations. There are one or two fundamental things that I would like to be able to do, but for the life of me I cannot work out how to do them, so I have hit a bit of a wall at the moment. There seem to be very few videos on YT like yours where people explain how to code and solve problems. Thanks again.

  • @philchurch927
    @philchurch927 4 года назад

    Down memory lane, I had mine perched on the old upright piano keyboard cover with the portable tv on the top. boy did I get neck ache but you felt good when it worked.
    Thank you for this video.

  • @theR1ddle
    @theR1ddle 3 года назад +1

    2021 reporting in... Thank you, I enjoyed this video very much. Now I want to go out in the shed, drag out my old Timex Spectrum and follow along.

  • @pyhunter101
    @pyhunter101 4 года назад +1

    Well done. I was 10 when I got one of these and spent thousands of hours writing my own software/games (and a lot of time rewriting them when they didn’t save properly onto tape). I had a whole 16k of ram with mine though. Thanks for the memory’s.

  • @dollarsing
    @dollarsing 9 месяцев назад +2

    Amazing. Talking hands!

  • @shadowboxer47
    @shadowboxer47 4 года назад +1

    I appreciate this. I like collecting old computers. I have no experience with Sinclair and picked one up on ebay. This program might be the first one I try.

    • @hjalfi
      @hjalfi  4 года назад +2

      Hope you have fun! Also, you may want to print a copy of Commander le Clef's Secret Encoder Wheel for reference... www.retrobattlestations.com/Cmdr-le-Clef/Secret-Encoder-Wheel.pdf

  • @SpaceParanoidX
    @SpaceParanoidX 3 года назад +3

    Me talking at the screen: "...line 140....Line 140....LINE 140!!1!!" ;)

  • @maks_zbogar
    @maks_zbogar 3 года назад +1

    If only today's software would be so memmory optimized :))). Congratulations! I would never believe that such a nice game could be done with 1024 bytes...

  • @Daeve42
    @Daeve42 5 лет назад

    Really enjoyed this, learned more than could from a book in that time. Thanks.

  • @antonnym214
    @antonnym214 4 года назад +2

    Well done! I used to code in 8080 and Z-80 assembly. I presume there was an assembler for this? I could almost survive a 1K limit if I could use assembly language. Z-80 was a sophisticated CPU in those days! I have only one question: Will it run Crysis?

    • @hjalfi
      @hjalfi  4 года назад +3

      There were assemblers, but entering text on that keyboard was painful. For small programs most people hand-assembled and then entered hex. And while I don't think there's Crysis, here's Dragon's Lair... ruclips.net/video/CuF4g5CDZQA/видео.html

    • @antonnym214
      @antonnym214 4 года назад +1

      @@hjalfi I was just being funny, but Dragon's Lair is amazing!

  • @antonnym214
    @antonnym214 11 месяцев назад +1

    If this BASIC has peek and poke, I would write the game in Z80 assembly, poke the object code into RAM, and execute it with a Call command.

  • @bazza5699
    @bazza5699 3 года назад

    great video, really enjoyed it, thanks

  • @reinoud6377
    @reinoud6377 11 месяцев назад +1

    I thought the 16k expansion was kind of mandatory?

  • @andrewdavidloch360
    @andrewdavidloch360 4 года назад +1

    I got the KIT to make it.. it was £3 short if you built it yourself... it was the cheap option. I MADE my ZX81 I soldiered it together and put the chips in their carriers and each resister.

    • @hjalfi
      @hjalfi  11 месяцев назад

      But, did it work?

  • @karlbesser1696
    @karlbesser1696 4 года назад

    I remember me. There was a handle, called 'Spoke Grip'.

  • @dannejendinger1847
    @dannejendinger1847 3 года назад

    You are a Basic-Jedi!! 😃

  • @مقاطعمترجمة-ش8ث
    @مقاطعمترجمة-ش8ث 3 года назад

    Why YT didn't recommended this to me two years ago ?

  • @AllGamingStarred
    @AllGamingStarred Год назад

    24x32
    how do I map that on graph paper? I don't have a ruler on me. Anyone, Picture?

  • @Havanacuba1985
    @Havanacuba1985 3 года назад +1

    My new spectrum has had the composite mod, should I be able to use it with a small monitor like yours ? That would be ideal

    • @hjalfi
      @hjalfi  3 года назад

      Yup, should work fine provided it's a PAL monitor (and you have a PAL Spectrum). My monitor's just a cheapo car reversing monitor with composite input, nothing special. The ZX81 is a bit more problematic due to producing a terrible quality video signal, but the Spectrum's significantly better.

    • @martindejong3974
      @martindejong3974 Год назад +1

      @@hjalfi later ZX-81 produced a much better video signal that included the "front porch" signal, so the TV could figure out what the black level was. Without it most modern TV's will only produce a very faint picture. The ones with the improved signal (ULA chip) do much better.

  • @CelticSaint
    @CelticSaint 6 лет назад +2

    Good video but I could hardly hear it?

    • @hjalfi
      @hjalfi  6 лет назад +2

      Yeah, sorry, I forgot to normalise, and you can't change the audio in RUclips without deleting the video. All I can suggest is cranking the volume.

    • @CelticSaint
      @CelticSaint 6 лет назад +1

      Thanks I thought it might have been my laptop for a moment!

  • @dmitriyk2282
    @dmitriyk2282 4 года назад

    всегда хотел поюзать zx81!! ))лайк!

  • @gregskuza7166
    @gregskuza7166 3 года назад

    Timed Sinclair 1000 had 2kb of ram I think…

  • @toto123456ish
    @toto123456ish 6 лет назад +2

    Can you program the ZX81 in Z80 assembler? And if so, can you do it from the computer itself?

    • @hjalfi
      @hjalfi  6 лет назад +3

      Yes, and technically yes, but the 1kB model doesn't have enough space for an assembler and entering assembly on that keyboard is painful. What most people did back in the day was to hand assemble with pencil and paper and then enter hex.

    • @Matusalem1969
      @Matusalem1969 3 года назад +1

      @@hjalfi My frriend, You can entet an Assembly program in a REM line and POKE it, byte by byte.
      Tha game you made, in Assembly Z80 could take half of the memory in BASIC or less than that. And you could have the advantage of the Speed of the machine language. It would require a lot of work, but it would compansate.
      You have economy of Memory IN BASIC if you adapt some instructions, for example: LET X=0, can be written as LET X= NOT PI or LET X = VAL "0", LET M=1 can be written LET M = SGN PI.

  • @GregMcMahan
    @GregMcMahan 4 года назад +1

    Would changing line numbers to 1 or 2 digits save ram space?

    • @hjalfi
      @hjalfi  4 года назад +1

      No, they were all encoded as 16-bit binary values, so were all the same size.

    • @Matusalem1969
      @Matusalem1969 3 года назад +1

      You have economy of Memory IN BASIC if you adapt some instructions, for example: LET X=0, can be written as LET X= NOT PI or LET X = VAL "0", LET M=1 can be written LET M = SGN PI. There are other tricks to raise memory.

  • @DavoidJohnson
    @DavoidJohnson 4 года назад +1

    Damn, I just changed the likes from 81 to 82

  • @Xoferif
    @Xoferif 6 лет назад +2

    "tao" as in "Taos"...?

    • @hjalfi
      @hjalfi  6 лет назад +2

      Yup. I worked there before it went bust.

    • @Xoferif
      @Xoferif 6 лет назад +3

      Cool bananas! I was crazy about Taos when I was a student, and would read and re-read everything I could find. And that demo system they built with the processor cartridges - you could just plug in more cartridges and the programs would run faster! Amazing stuff.

    • @hjalfi
      @hjalfi  6 лет назад +2

      If I remember that demo machine correctly, it was actually a bit embarrassing --- it was based around an eight-way Transputer system plugged into a host PC, running as a nine-CPU machine; except the early Pentium PC was so much faster than the Transputers that when drawing a Mandelbrot, the Transputers would take so long to draw a single scan line each that the Pentium had done the entire rest of the image all by itself...

  • @arnolduk123
    @arnolduk123 5 лет назад +1

    Just needs a "nag" screen or a 30 day trial before you can release it to the masses :)
    The video was mind numbing to watch all that code re-arranging and number mangling just to get the program to run. I'm surprised that WHSmith C15 cassette tape is still usable.

    • @hjalfi
      @hjalfi  5 лет назад

      The ZX81 has so little memory that the only kind of transaction it can do is micro.

    • @arnolduk123
      @arnolduk123 5 лет назад

      @@hjalfi well if someone can manage to program a game of chess on that thing, then that's sure a micro achievement!

    • @hjalfi
      @hjalfi  11 месяцев назад

      @@arnolduk123 (Very delayed, but) good news! They did! It's called 1k chess and it plays a pretty good game, for a program that's 672 bytes long.

    • @arnolduk123
      @arnolduk123 11 месяцев назад

      @@hjalfi Yes, I knew that and that's why I said it was an acheivement. The ZX81 is a good example of how more complex and memory restricted coding was for programmers. You were less likely to find bugs in code that was consistently analyzed line by line, although not true when typing then in line by line from a printed magazine that was full of typing errors :)

  • @semibiotic
    @semibiotic 2 года назад

    It would better to take ZX-Spectrum, instead (or ZX81 with 16K). ZX80/81, PET, VIC20 BASIC memory limitations are so ridiculous

    • @hjalfi
      @hjalfi  11 месяцев назад

      There's no fun in writing programs for anything _good!_

    • @semibiotic
      @semibiotic 11 месяцев назад

      ​@@hjalfi Fighting to write 30 simple BASIC statements it is interesting experience, but it is no programming.

  • @edmund-osborne
    @edmund-osborne 5 лет назад +2

    How did you keep missing that glaringly obvious 0 in line 140 every time you tried to further reduce memory usage? Literally every time, it was like you were blind or something.

    • @hjalfi
      @hjalfi  5 лет назад +3

      Practice!

    • @ksportz66
      @ksportz66 4 года назад

      Edmund Osborne - did Football league program and had to poke some address to access lines under normal display for bottom teams

    • @ksportz66
      @ksportz66 4 года назад

      hjalfi - Still cant code a for next loop quicker than on this.

  • @BenevolentChum
    @BenevolentChum 2 года назад +1

    Thanks for some good fun. Converted your program to Micro Color BASIC: ruclips.net/video/nkBIDif9K0w/видео.html

  • @clyth41
    @clyth41 11 месяцев назад

    Presumably your English so why are you saying dollars? can't you do it in pounds, you know for your English watchers....