Author Topic: Lua on the PRIZM soon?  (Read 3153 times)

0 Members and 1 Guest are viewing this topic.

Offline DJ Omnimaga

  • Clacualters are teh gr33t
  • CoT Emeritus
  • LV15 Omnimagician (Next: --)
  • *
  • Posts: 55943
  • Rating: +3154/-232
  • CodeWalrus founder & retired Omnimaga founder
    • View Profile
    • Dream of Omnimaga Music
Lua on the PRIZM soon?
« on: August 21, 2012, 02:02:36 pm »
After arriving on the ClassPad years ago, then as LuaFX on the Casio AFX and years later the FX-9860G calculator models, it seems that Lua is finally making its ways to the FX-cg10 and cg20 models as well: A few days ago, KermMartian has started working on LuaZM, his own implementation of Lua for the PRIZM! Hopefully this should attract new PRIZM programmers, noticing the high success that TI's version of Lua saw on the TI-Nspire in the past year that spawned dozens of releases.

The Casio Prizm is a powerful calculator, great for both math and playing games. It is particularly great for programming, and for months thoroughly bested the TI-Nspire calculator in offering ASM, BASIC, and C programming. In an attempt to reduce criticism of their apparently anti-student stance, Texas Instruments improved the TI-Nspire to run Lua programs. Lua is a "fast, lightweight, embeddable scripting language," an interpreted procedural language. The language has allowed budding Nspire programmers to quickly write games and programs without needing to use a computer.

I am happy to announce that I am now bringing Lua to the Casio Prizm graphing calculator, in the form of a full-featured Lua interpreter. After days of porting, rewriting parts of libc (including the longjmp/setjmp system), and learning some SH4 assembly, I am proud to present the first screenshot of the interpreter successfully running on a Prizm. Special kudos to Juju for the PrizmIO library, a port of an Nspire I/O library for C programmers. As you can see from the screenshots, this is just the raw interpreter; although it understands Lua syntax and can parse/lex the language, load libraries, and recognize incorrect code, it is almost entirely lacking in functioning libraries. From here, I will be porting over each of the standard libraries, starting with numbers, strings, and I/O. Please feel free to share thoughts and suggestions here or in the original Cemetech thread. Bonus features: Planned transparent support for Nspire and Lua FX programs.



Nonetheless, this looks promising and this will give much more options to PRIZM programmers, some of which may find C and ASM too hard, but BASIC too slow or limited. Maybe this will also make it easier for TI-Nspire programmers to port their programs to the other platform or vice-versa too.

As said in the quote above, feel free to discuss the project here or in the main Cemetech thread.
« Last Edit: August 21, 2012, 02:03:36 pm by DJ_O »

Offline Stefan Bauwens

  • Creator of Myst 89 - סטיבן
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1799
  • Rating: +162/-24
  • 68k programmer
    • View Profile
    • Portfolio
Re: Lua on the PRIZM soon?
« Reply #1 on: August 22, 2012, 04:25:30 am »
Hmm, interesting. I wonder how much slower, if it is, it will be than on the Nspire. ;)


Very proud Ticalc.org POTY winner (2011 68k) with Myst 89!
Very proud TI-Planet.org DBZ winner(2013)

Interview with me

Offline apcalc

  • The Game
  • CoT Emeritus
  • LV10 31337 u53r (Next: 2000)
  • *
  • Posts: 1393
  • Rating: +120/-2
  • VGhlIEdhbWUh (Base 64 :))
    • View Profile
Re: Lua on the PRIZM soon?
« Reply #2 on: August 22, 2012, 07:30:45 pm »
Good news! :)