DM42 and Plus42 Hat Program


hat.42 (convert to .raw using SwissMicros DM42 Programming tool)

Here is a program you can put on your DM42 or Plus42 to create a hat. The code is taken from a 1981 computer ad and modified so that number of slices and width of hat can be adjusted. There are a few steps:

  1. Put your calculator in radians mode. I should make this part of the program. (Alternatively, change the single instance of 3pi/2 in the program to 270 and it works in degrees mode.)

  2. Edit hat.42 and up top you will see three blocks of assignments for Plus42, DM42 medium resolution, and DM42 high resolution. Use '@' (at sign) to comment out the two blocks you will not use.

  3. Use the DM42 Programming Tool linked to above where you can paste the edited hat.42 to generate a hat.raw file. Import the .raw file to Plus42 or put it in the root directory of the DM42.

  4. After starting program you have option to change SLICE and HATX. 2xSLICE slices will be created and the hat will be HATX pixels wide.

  5. Push the 'R/S' button. On the DM42 it is very slow. High res on the DM 42 will take about an hour! Go get a cup of coffee...or two. :-)

Mike Markowski
mike.ab3ap@gmail.com

web counter