Jump to content

Search the Community

Showing results for tags 'language'.



More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Commander X16 Forums
    • Introductions
    • X16 Discussion Lounge
    • X16 Help & Support Lounge
    • Off-topic Lounge

Categories

  • Official Software
  • Official Docs
  • Community Downloads
    • Games
    • Productivity Apps
    • Graphics Apps
    • Audio Apps
    • Demos
    • Networking Apps
    • Dev Tools
    • Tutorial Apps
    • Misc Apps

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


About Me

Found 1 result

  1. So after piecing together the memory map of the Commander X16 and getting the emulator working I set out to make the necessary changes in my programming language Prog8 compiler to support a second target machine architecture beside the C64. Prog8 is a cross-compiler that works on any modern machine and compiles into a machine code binary for 6502 8-bit machine targets such as the Commodore-64. I've just released an updated version that supports CommanderX16 as a second compilation target! Prog8 documentation: https://prog8.readthedocs.io Prog8 project website: https://github.com/irmen/prog8 you can download it from there as well. Some micro-benchmarks (not by me) to compare it to other languages and compilers such as cc65 can be seen here. Here is one of the simple programs that I made in Prog8 for the Cx16, it renders the well-known Mandelbrot fractal (using floating point calculations): For those interested this is the source code of the above program: %import textio %import floats %zeropage basicsafe main { const uword width = 60 const uword height = 50 const ubyte max_iter = 16 sub start() { txt.print("calculating mandelbrot fractal...\n\n") ubyte pixelx ubyte pixely for pixely in 0 to height-1 { float yy = (pixely as float)/0.40/height - 1.3 for pixelx in 0 to width-1 { float xx = (pixelx as float)/0.32/width - 2.2 float xsquared = 0.0 float ysquared = 0.0 float x = 0.0 float y = 0.0 ubyte iter = 0 while iter<max_iter and xsquared+ysquared<4.0 { y = x*y*2.0 + yy x = xsquared - ysquared + xx xsquared = x*x ysquared = y*y iter++ } txt.color2(1, max_iter-iter) txt.chrout(' ') } txt.chrout('\n') } } }
×
×
  • Create New...

Important Information

Please review our Terms of Use