scene.org File Archive

File download

<root>­/­parties­/­2025­/­vccc25­/­christmas_challenge/mattpilz_mattelaquarius_basic_189b_vc3-2025.zip

File size:
17 789 bytes (17.37K)
File date:
2025-12-30 23:34:07
Download count:
all-time: 1

Preview

  • file_id.diz 2.83K
  • result.png 12.22K
  • source.png 11.09K
  • xmas25.bin 189B
  • xmas25.caq 239B
  • xmas25.txt 217B
  • xmas25.wav 229.30K

file_id.diz

Christmas Snowflake

Author: Matt Pilz
Category: Christmas Challenge
System:   Mattel Aquarius
Language: BASIC
Len source code: 189
Len exe file:    239

Instructions:

	[EMULATION]
	
	1. Download the latest AquaLite emulator from https://aquarius.je/aqualite/ (e.g., v1.39).
	
	2. Extract the contents to your hard drive and launch the executable (e.g., AquaLite.exe).
	
	3. At the BASIC title screen, press <ENTER>.
	
	4. Type CLOAD and then press <ENTER> <ENTER> (twice).
	
	5. Select FILE > Load File and double-click xmas25.caq.
	
	6. Type RUN and then press <ENTER>.
	
	[ORIGINAL HARDWARE]
	
	1. Transfer "xmas25.wav" to a device for audio playback. This can be a cassette, laptop, phone etc.
	
	2. Power-up your Mattel Aquarius and at the BASIC title screen, press <ENTER>.
	
	3. Type CLOAD and then press <ENTER> <ENTER> (twice).
	
	4. Begin playback of the audio file while connected to the Aquarius audio interface (e.g., via 3.5mm EAR plug of the Aquarius cassette cable to your phone/laptop, or via a real cassette tape. You should see "FOUND: xmas25" and then "Ok" after the data has loaded. If not, try increasing the volume of playback.
	
	5. Once loaded, type RUN and then press <ENTER>.
	
Description:

For this challenge, I felt it would be fun and creative to embrace the system's internal random number generator (RNG) as part of producing the necessary output. I first determined which seed could generate the star pattern for each row of the top-left of the snowflake by brute force iterating through every seed until a match was found. This was done by generating a 0 or 1 randomly and comparing it to the necessary pattern. For example, row 3 equates to "  * *   **" so I searched for a seed that would generate its first 10 random numbers in the order of "0010100011" and then noted the seed value. This was done for 10 rows, 10 characters each, to encapsulate the full top-left of the design.

For the top-right, it is simply a reverse pattern from the base. Same for the bottom half of the snowflake, except for that we also iterate through the rows in reverse order. So from 10 statically set seeds we are able to produce the full 19x19 pattern snowflake. The foundational code can then remain largely the same when porting to other platforms, with the only difference being which seeds produce the desirable output as depicted within the DATA statement of the final code.

Comments:

The following files are included in this package.

	* xmas25.txt	Text format source code
	* xmas25.bin	Raw binary composed only of the tokenized BASIC code (189 bytes) 
	* xmas25.caq	Emulation-supported loadable BASIC program
	* xmas25.wav	Audio output of the program for playback on a real device
	* source.png	Complete program listing as seen on the Aquarius
	* result.png	Output of the program after running it on the Aquarius