The general pattern of 68K mnemonics is:
action.length object[, destination]
Where “action” is the mnemonic, typically an English verb describing the action being performed, with an occasional cryptic abbreviation standing for a whole phrase.
“Length” denotes the amount of bits we’re dealing with. 68K can work with bytes (8 bit), words (16 bit) and long words (32 bit), and so “length” is one of the three letters:
b for “byte”,
w for “word”, or
l for “long word”.
“Object” is the stuff we are manipulating. It can be raw literal data (denoted by
# sign), a memory address (denoted by…
I have tried spaced repetition couple of times when I was learning Japanese. I used Mnemosine and Anki apps — for those of you who don’t know, they are basically software implementations of flashcards (and both are really great apps if that’s what you’re after — I can highly recommend either). I actually used actual flashcards too — back in the day when I was a university student and preparing for my exams.
This method didn’t work for me. I mean, it did work for the exam preparation. In fact, this was arguably one of the most effective methods to…
Assembly language is probably the closest you can get to hardware without loosing your mind. There are little to no high-level abstractions — you tell the processor what to do in a very literal way, so a basic understanding of how it works is required. This post is all about 68K, but really most processors work in the same or very similar way.
Processors typically have registers — small amounts of fast storage to store the data being worked on at the moment. The processor would typically load data from RAM into the registers. 68K has two units: an integer…
In these series I will blog about my experience learning an assembly language — or maybe even several assembly languages, if I like it enough! Today I set up my development environment.
When I was a CS student, we had an assembly language class. Of course, I don’t even remember what kind of processor were we writing for or what kind of programs we built — all I remember about it is it went in all caps 😆
I am into watercolor a lot, and I am a big sucker for pigments (my palette includes 7 different blues). I am currently reading this book on the art history that discusses the history of color blue (happens to be my favorite color to paint with). In the book, where it tells about medieval treatises on dyeing, I find this passage:
[The medieval dyeing manuals] stress the importance of letting time to do its slow work — the desire to accelerate things is always seen as ineffective and dishonest.
That is so different from us today! That passage got me…
How long does it take you to write four lines of code? What is your sad record?
Mine is a week. These are the lines:
const crypto = require('crypto');const verifier = crypto.createVerify('sha256');
verifier.update(document.toString());verifier.verify(pubKey.toString(), signature.toString(), 'base64');
You might be wondering why it took me so long to copy-paste this from Node.js documentation. You might also be wondering where are
signature defined. Let me tell you about the latter.
“How do I write unit tests, and where do I even start?”, “How do I make sure I don’t miss anything?”, “I saw some examples of test suites in your other code bases, but I’m not sure how to set up my own tests, how do I do it?” — those are familiar questions, aren’t they? You either had them yourself or heard them (or both). I myself definitely was asking these questions at a certain point, so I spent a bit of time studying software testing. …
At the time of writing this, the book contained 12 chapters, all of which I had studied. “Studied” means I read them, took notes, quizzed myself, and solved the problems…
This weekend I attended my first PyCon! This year it was held in Toronto, where it was so cold as if it’s November or something; it was even snowing on Saturday morning. Incidentally, the conference swag included pom tuques — quite handy.
I spent most of my time doing the hallway track — something way outside my comfort zone, so I’m very happy to report that I managed to have lots of interesting conversations and a wonderful Saturday dinner with the folks I met. The latter was a self-organized 6-people event because the conference didn’t organize anything officially. …
This may be a weird article in a developer’s blog, but I think good quality sleep is fundamental when it comes to work that requires a lot of thinking and creativity.
I used to struggle with insomnia for quite a while. Besides that, I am a “night owl” — somebody who likes stay up late at night. I don’t think there is such thing as “night owls” and “early birds” though. I am convinced it’s a matter of habit, and modern life just calls for a “night owl” way. I know that because I have changed my sleeping habits numerous…