Apple-1 ACI Music Player: Also the Apple-1 has a sound card ;)

2 replies [Last post]
Offline
Joined: Dec 1 2014
Posts: 25

Hello to All,

I am doing experiments with my Apple-1 ARM Replica, and after a lot of work on the ACI driver, I can save and load programs and data into real tape cassette. While working on this driver I tried to generate some sound, as if the ACI was a sound card. It was so fun that I developed a tiny music player with a simple tone generator and a note sequencer. The first music I tried to compose is the theme of the movie "Back to the future" Smile

In attachment you can ear te sample taken directly from my emulator. I am pretty happy but I will be real happy if this worked also on a real hardware. So is there somebody who wants to try this for me? Smile
The program saved hopefully should load also on the real hardware by typing:

C100R
270.487R

and then launch the song typing:

300R

You should hear the music...

The main program starts at 300, even if there are parameters and variables starting at 277. Music data starts from 400, and every note is a group of 5 bytes. Pauses are treated as notes as well but without toggling the output line. If this works also on the real hardware I will put the assembly source code online of course. Who knows maybe this gives a new life to Apple-1 Wink

Laughing out loud Thank you all!

AttachmentSize
AudioPlayer_Demo_010.zip1.43 MB

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
Offline
Joined: Oct 9 2011
Posts: 1063
Re: Apple-1 ACI Music Player: Also the Apple-1 has a sound ...

Yep you can use the ACI on the real hardware to make sounds. I posted a few years back the code for twinkle twinkle little star. I also use it for my ascii graphics lunar lander basic program to make sound effects.

Cheers,
Corey

Offline
Joined: Dec 1 2014
Posts: 25
Re: Apple-1 ACI Music Player: Also the Apple-1 has a sound ...

Cool, I didn't see that. Smile

I just saw your post, so the audio engine is called from the BASIC by setting the note and the duration, is it correct? In my engine there is a main "loop" that continuously update the tone oscillator according to the current period of the frequency to play. There is also the counter of the duration of the note that is decremented for each iteration. When this counter reaches zero the next note is loaded and the loop goes on.

I worked also on a white noise generator with a LFSR register divided into two bytes. My original idea was to create a super simplified version of a module tracker like the AMIGA ones, but with one channel only and two instruments(a tone and a Noise).
The Noise works, but in the whole loop everything becomes slow Sad

Currently my emulator may be not so accurate in timings because of the ISR routine that generates the video signal. I am porting the emulator on a faster board, and converting the scanline renderer to use a DMA channel to free the CPU. So I will see if I can come up with something interesting Smile