mermaid: Markdown Tool for Graphs

I needed to represent a Finite State Machine (FSM) for my Smoker Controller project. I could have gone with the pencil and paper route but what I learned in dot: command line utility for drawing graphs was that there are better tools. Since this project was documented in markdown from the start I looked for a way to do it all in markdown. It turns out there is a plugin called mermaid that does everything dot does without the compile step. But with a different syntax. πŸ™ Many markdown processors have this plugin pre-installed. πŸ™‚ I am using Joplin and it works just fine.

Continue reading “mermaid: Markdown Tool for Graphs”

dot: Command Line Drawing Tool

I wanted to represent a Finite State Machine (FSM) for my sump pump monitor. Grabbing my coding stick, I create the FSM on paper in my project journal. Then I take a photo of this and I’m done.

But not really done because the photo isΒ  3.3 MB. I download it from Google Photos and open it in my Macbook using Preview. I select the portion of the page with the selection tool and copy this part of the image to the clipboard and then I use Preview’s “New from Clipboard” command to create a PNG image file. This file is still 1.7MB.

Continue reading “dot: Command Line Drawing Tool”