A while back I decided to try to write a Game Boy emulator in Common Lisp based on this series of articles. I made some good progress but eventually got bogged down because I was trying to learn a bunch of complex new things at once.
[…]
Instead of dragging on, I decided to take a break and try something simpler: a CHIP-8 emulator/interpreter. The CHIP-8 is much simpler than the Game Boy, which made it easier to experiment with the rest of the infrastructure.
In this post and a couple of future ones I’ll walk through all of my CHIP-8 emulator implementation.
I always wondered why Lisp hasn’t became *THE* language instead of basic, since it can perform absolutely everything, unlike many more domain specific programming languages.
because of parentheses!
You mean….
parenthetheth?
The same could be argued about almost any general purpose language. What matters is not just what the language can do, but how easy it is to do it. That’s part of why Python is so popular, it’s powerful and it’s insanely easy compared to many other languages.
In the case of Lisp though (and most of it’s derivatives), I think the issue most people have is RPN and s-expressions (I understand why some people prefer RPN (it is after all how most human languages are organized when discussing math), but I’ve never been fond of it myself).
Slight correction: LISP does not use RPN but rather Polish Notation (pn), since the operators prefix their data rather than being postfixes.
ahferroin7,
Generally speaking yes, but there are still exceptions. I opted for python in a recent project and I didn’t realize quite how bad it’s SMP multithreading support was until I really started using it. There were caveats I didn’t expect coming from different languages.
One reason may be that LISP was heavily fragmented soon after its inception, whereas BASIC at least appeared to be consistent across vendors and versions.
And while LISP can do everything, it’s not always done the best way, taking ideology to the extreme. Like Scheme’s obsession with call/cc, which I recently learned has had its critics, both as a general language feature and as a target for ideological extremes.
Basic was anything BUT consistent across vendors. Everyone had their own custom version, even disagreeing on things as basic (no pun intended) as line numbers or not. The only “consistent” Basic was Microsoft Basic, which was virtually the same on every supported computer, but was buggy as all hell get out. I never used MS Basic if I could help it, preferring to rewrite my program for different Basics rather than try to work around all the MS bugs.
I assume you’re referring to BASIC being THE language during the 8-bit days.
The answer is pretty simple: LISP required a lot more resources. Also BASIC is imperative and translated, with little overhead, to the programming model of the 8-bit CPUs targeted.
I wrote a CHIP-8 emulator for the PC-Engine a few years ago and was amazed that while it’s a pretty commonly emulated platform the documentation isn’t all that great.
I aggregated a bunch of docs and zines and started writing up a more comprehensive description of it but haven’t finished. Perhaps it’d be of use to others.
https://github.com/trapexit/chip-8_documentation