I've been trying forever to get a mobile IPSec connection up between my OS X laptop and pfsense. Finally, thanks to this outstanding blog post, it works. I'm especially excited that it works with the default OS X and Android VPN clients.

I have a number of disks in my FreeBSD box which exist only as backups of data. I prefer that they not be mounted all the time, but instead mounted on use. They are 2x internal SATA disks and an external USB3 disk. This blog post explains how they are set up to auto-mount.

Some printers, like the one I have (HP 8600 Pro), have "Print-to-Folder" capability. Unfortunately, I have no Windows server, only a FreeBSD box to print to. I can mount folders from the FreeBSD box on my MacBook.. if I can get files to scan there. So, to do that, I need a Samba on my FreeBSD box. To install SMB on FreeBSD:

pkg install samba36

Then, I need a smb.conf in /usr/local/etc, that exports a folder, like this:

I recently had a reason to parse a large data set, for another project. I decided that an ideal "large data set" would be my Outlook mail saved archives. Sadly, Outlook for Mac doesn't output PST files, it outputs OLM archives, which are, essentially, giant zip files full of XML. I was coding this all in Java, so I needed a Java library to parse OLM files.

Every IT geek is, to some degree, fascinated with the Apollo program which put a human on the moon for the first time. Naturally, there is also curiosity about the computers on the Apollo moon lander, and the software that ran on them. The source code that went to the moon is available now, and you can take a look at it here.

I'm interested in the Apollo program, but I'm also interested in formal grammars, and a committer to the Antlr project. So, I spent some time building an Antlr4 grammar for the Apollo source code. You can take a look at it here. The grammar can parse a number of files from the Solarium55 source code, which is the source code that flew Apollo4. If you're keen you could try it on the Apollo13 source code, called Artemis072, but you'd have to key in the source from jpg images of the form-feed printouts (here).

It's natural to ask why a Antlr4 grammar for AGC source code would be useful. In addition to the obvious "because that goalwill serve to organize and measure the best of our energies and skills", it's the first step in building a simulator. There is already an excellent C simulator here, and there are numerous JS ones on the web, but I thought it might be helpful to have an Antlr4 grammar that can output parser-lexers for new simulators in other languages. Also, it was very interesting to learn about the AGC computer and to see how software development has progressed since the 1960's.

Recently I had reason to get interested in process modelling. Ultimately I ended up writing an Antlr4 grammar for Modelica (here), but in the mean time I came up with SML (Simple Modeling Language). The Antlr4 grammar is sml.g4.

The characteristics I wanted in my own modeling languages were:

Ability to define models as text files

Models should be as Object Oriented as possible

Ability to compose models. That is; ability to have models that include models.

Ability to define variables that are internal to models and variables that are exposed by models (i.e. "ports")

Ability to put models in namespaces

Ability to define equations in models that related the variables. The equations should be expressed in standard form.

Support for differential equations is essential

SML accomplishes these goals. An example SML model is a standard spring from 1st year Engineering, here. The model file is:

This model is in the namespace "tge.string". It exposes three public variables "k", "df" and "x". The relationship b/t the variables is "df=k*x". There is a simple example, of a standard pendulumhere.

More complex examples are here. One such example is a classic RC circuit. This model defines the structure of the circuit itself, and references the resistor, capacitor and source via includes of those models from their own SML model files

Ultimately, with Antlr4 it should be possible to generate model parsers in Java, C# and potentially C++, that can consume SML files, ensure that the model composition is reasonable, and generate input files for mathematical solvers. The work of producing solver input files from SML models is essentially the work of collapsing an object tree to a flat model.

Unix version 0 was written in 1963 by Ken Thompson, on a PDP-7. Recently, the source code code Unix V0 has been discovered, and you can read it here, as pdf scans of printouts. You can read about the discovery, and the effort to boot Unix V0 on a real PDP-7 here. The project home page is here.

I got interested in PDP-7 unix, and then in PDP-7 assembler. Eventually, I wrote an Antlr4 grammar to parse PDP-7 assembler files in the original as format that Thompson wrote them here. The resulting grammar is here.