Jaslabs: High performance Software

High Performance Software

Commodore 64 emulator in PHP

By Justin Silverton

For those of you that still remember the early days of computing, there is a commodore 64 emulator written in PHP.

A live demo is available here: http://phpc64.extra.hu/c64/index.html
the sourcecode is available here: http://phpc64.extra.hu/php_c64_source.tar.gz (released under the GPL License)

Homepage is here: http://phpc64.extra.hu/

Some Commands

The following are supported: NEW, RUN, LIST, LIST N-M, SAVE “NAME”, LOAD “NAME”,

Programming examples

PRINT “HELLO WORLD”
IF 2″A” THEN XXX (Note: XXX being a line number.)
GOTO XXXGOSUB XXX (…)
RETURN

10 FOR I%=1 TO 1020
PRINT “C64″
30 NEXT I% (Note: variable after NEXT is optional, but recommended)

Known Bugs

—–* doesn’t check BASIC programs for syntax errors (because of size limitations)*
Internet Explorer crashes when loading programs longer then approximatly 700 bytes
* when the frame containing c.php is loaded before creation of frame named ’s’, it causes javascript error; you should reload the page when this bug shows

Tricks

in Opera the execution of the BASIC program stops when INPUT commands are being executed; it will continoue if you activate another tab, then return to the window of the Emulator (you should press RETURN)

Share and Enjoy: These icons link to social bookmarking sites where readers can share and discover new web pages.
  • Digg
  • del.icio.us
  • DZone
  • Slashdot
  • StumbleUpon
  • Technorati

2 Comments so far

  1. Gerry Shaw April 27th, 2006 5:47 am

    Hi Justin,

    This sounds really cool! Are you going to write in ROM support?

  2. justin silverton April 27th, 2006 8:54 am

    That is a great idea. I will have to look into it.

Leave a reply