128k Programming basics using Z88DK and the SCCZ80 compiler Lesson 11

Vortex Tracker and Player

This is the eleventh lesson of programming the 128k ZX Spectrum. Today, I’m going to write about adding music to your program. I’m not going to be writing about making the song itself but integrating the Vortex player into Z88dk.

Continue reading “128k Programming basics using Z88DK and the SCCZ80 compiler Lesson 11”

128k Programming basics using Z88DK and the SCCZ80 compiler Lesson 6

Loading uncompressed Assets

This is the sixth lesson of programming the 128k ZX Spectrum. Today, I’m going to write about loading assets into your compiler. In this particular case, I’m going to be loading images. Please note, what I am about to explain is a simple test case only. The images are going to be uncompressed for this lesson, so this would never be used in real life. My coverage of compression will happen in the next lesson, so be on the lookout for that.

Continue reading “128k Programming basics using Z88DK and the SCCZ80 compiler Lesson 6”

128k Programming basics using Z88DK and the SCCZ80 compiler Lesson 5-1 : IM2 revisited and corrections

This follow up article is to point out some mistakes I made in my last article for Lesson 5.

The article is found at https://zxspectrumcoding.wordpress.com/2021/09/10/128k-programming-basics-using-z88dk-and-the-sccz80-compiler-lesson-5/

The first thing I want to point out is that IM2 stands for Interrupt Mode 2, this was pointed out to me and I since corrected the article with the updated name.

Continue reading “128k Programming basics using Z88DK and the SCCZ80 compiler Lesson 5-1 : IM2 revisited and corrections”

128k Programming basics using Z88DK and the SCCZ80 compiler Lesson 5

Interrupt Mode 2: Pardon the Interruption

This is the fifth lesson of programming the 128k ZX Spectrum. Today, I’m going to write about interrupt mode 2, rolling out our own routine and setup. We are making some changes from lesson 4, in which our focus was on placing C code in sections, today we are going into a bit of assembler not to worry, this should be pretty easy to layout in Z88dk.

Continue reading “128k Programming basics using Z88DK and the SCCZ80 compiler Lesson 5”

128k Programming basics using Z88DK and the SCCZ80 compiler Lesson 2 part 2

OBJECT files and linking to associate sections

This is our second lesson, part 2 of programming the 128k ZX Spectrum. I have split up this lesson into several parts as I have greatly expanded the source code. In my last part, I covered the many batch files that I am using to compile the separate files

Continue reading “128k Programming basics using Z88DK and the SCCZ80 compiler Lesson 2 part 2”

128k Programming basics using Z88DK and the SCCZ80 compiler lesson 2, part 1

Setting up BATCH files

This is our second lesson, part 1 of programming the 128k ZX Spectrum. I have split up this lesson into several parts as I have greatly expanded the source code. Even though the code is still simple, I have split up the code into three different areas. Our eventual goal for this lesson is to combine our 3 memory sections into one program. We are not, in this lesson, going for anything spectacular, this is going to be simple code. Even though we are combining 3 sections into one program, the ram-low section and Ram 0 section are going to be storing assembly variables. The nice thing is that assembly variables can be easily seen in C. The irritating thing is that you have to slightly alter the name making it difficult to trace at times. In the end, we are going to be able to place different routines in different memory sections.

Continue reading “128k Programming basics using Z88DK and the SCCZ80 compiler lesson 2, part 1”

128k Programming basics using Z88DK and the SCCZ80 compiler lesson 1

Unassociated Programming

This is the first part of a multipart series that will ease us into programming on the 128k Sinclair ZX Spectrum. Today, we are going to start by creating 3 unassociated programs that will compile to different sections of memory. Since the lower portion of memory in the ZX Spectrum is contended (meaning shared with the ULA), it is thus a bit slower and programs running in it are subject to being halted for a short while. We will still compile for contended as well as uncontended memory.

Today, we are going to start at some basics of 128k programming, this will be creating 3 simple programs all very similar with 1 exception, where the program is placed in memory.

Continue reading “128k Programming basics using Z88DK and the SCCZ80 compiler lesson 1”

128k Programming basics using Z88DK and the SCCZ80 compiler – Introduction

I have received a few private messages wanting to know some of the basics of programming on the 128k ZX Spectrum using Z88dk. My prior articles seem to jump the basics without some explanations. So the next few articles will attempt to fill in some of the basics.

Continue reading “128k Programming basics using Z88DK and the SCCZ80 compiler – Introduction”

Z88dk Bank Switching Part 6: Object files

This is the sixth part of a multi-part series of using Z88dk to create a 128k program with Bank Switching. The code is available from https://github.com/andydansby/zx-spectrum-128k-screen-paging-sccz80

Z88dk Bank Switching Part 6: Object file

An object file is the real output of the compiling phase which is mainly assembler but has symbols and information within it that a linker uses to build the final output. Building an object file is important to make a 128k TAP to output each section to a separate binary, which happens during the linking stage. The linking stage will be covered in another blog post, today I’m just covering the object file(s).
Continue reading “Z88dk Bank Switching Part 6: Object files”

Z88dk Bank Switching– Notes for the ZX Next machine

This blog usually only covers classic ZX Spectrums, the standard 48k, and 128k variety. However, due to the popularity of the upcoming ZX Spectrum Next machines, I want to place some notes from Allen Albright about Bank switching for the ZX Spectrum Next

These notes are posted with permission, to preserve them.
Continue reading “Z88dk Bank Switching– Notes for the ZX Next machine”