1. Flying Probes

    Flying probes are used for testing printed circuit boards (PCBs) and the chips mounted on the PCBs. One or more probes touch various parts of the circuit board and send an electrical signal into the circuit and a different probe checks to see if the signal at some other part of the circuit successfully matches what is expected.

    I'd never seen them in action but then I discovered that there are several videos on Youtube. They are incredibly fast! The good stuff starts at 0:15, after the machine has done a computer-vision registration of the board. I don't quite understand what the blunt piston-looking thing is doing though.

    Sat 12 November 2016
  2. Opening putty from the command line

    I was pleased to discover that putty can actually be launched via the command line. Most of the guides online make use of this feature to make it easier to launch SSH sessions. However being able to launch putty on the command line is also incredibly helpful for opening serial port connections.

    putty is my go-to tool in Windows for connecting to embedded devices that communicate over UARTs, usually in the form of virtual COM ports exposed through serial to USB chips. Due to the somewhat convoluted way that the Windows USB subsystem works the COM port number a device gets when connected over USB can be somewhat unpredictable. If the port settings do not match a saved configuration, quite a bit of keyboard and mouse input is needed to adjust the settings.

    The putty documentation describes all of the options. However, the two that are relevant to serial ports are -serial and -sercfg, which control the port name and settings, respectively. Assuming the putty.exe executable is in your path, to open COM23 using speed 115200bps, 8 data bits, no parity, and 1 stop bit, (8-N-1) and no flow control the command line is:

    putty.exe -serial COM23 -sercfg 115200,8,n,1,N

    The above can be a handful to type, especially if your devices are running with the same port settings and the only thing changing is the port name. I have yet to encounter a device that does not use 8-N-1.

    The following powershell script takes in a port name and an optional speed, otherwise defaults to 115200bps.


    param([string]$port, [string]$speed = "115200")
    putty.exe -serial $port -sercfg $speed,8,n,1,N

    If this script is somewhere in your path then can type either Open-ComPort.ps1 -port COM23 for the default speed (115200bps) or Open-ComPort.ps1 -port COM23 -speed 9600 for a different speed (9600bps in this case).

    Sun 06 November 2016
  3. Linux fun: cowsay and lolcat

    While browsing the latest WSL release notes, I learned of the linux utilities cowsay and lolcat. You can see the effect below:


    These utilities will be great additions to anyone's toolbox of nerd party tricks.

    In UNIX spirit, these guys operate on standard i/o and can be piped and composed. Moreover, each of these utilities have tons of additional options to further tweak their behavior. For instance, cowsay can be a truly generic cow-speaking tool since it allows the user to specify the eye and tongue appearance (using the -e and -t switches, respectively)

    The lolcat utility only works on terminals that support 256 (or more) colors. The OSX/macOS Terminal, putty, and most Linux terminals do. Bash for Windows will also have support in the next update.

    If you are unsure about your terminal color settings, a useful tool for testing terminal color settings is the colortest package that comes with Ubuntu.

    Sat 05 November 2016