weekends are for leisure

Android Text Message Backup

I’ve wanted to “factory reset” my old Android phones for years but hadn’t found a good way of exporting text messages including the embedded images and videos. Some solutions involve rooting your phone, and I didn’t want to do that. Nor did I want to use an app that copied to Gmail or the cloud. And I wanted to know exactly what the app’s code was doing. So I found the MessageBackup repo on GitHub and used it as a starting point.

Continue reading

Flashing a Dell BIOS using FreeDOS and a USB stick

I recently purchased a Dell Mini 1012 on Ebay and wanted to ensure it had the latest BIOS update from 2011. Dell’s website provides an exe, but I rarely boot into Windows. I managed to find a Linux-only workaround.

What I Tried

It was a bit of a journey. If you want the TL;DR, go to the next section.

  1. According to Ubuntu’s Dell BIOS page you can flash the BIOS using FreeDOS and a USB stick. Sounds promising.
  2. On a Linux machine I downloaded the “Lite USB” version of FreeDOS
  3. Flashed it to a USB stick with a command like this: dd if=./FD12LITE.img of=/dev/sde bs=4M conv=fsync status=progress
  4. Mounted the filesystem with a command like this: mount /dev/sde1 /mnt/other
  5. Tried to copy the BIOS exe into /mnt/other but there was no space on the filesystem. The FreeDOS image makes a very small FAT16 filesystem on the device
  6. I then tried to resize the filesystem (to give me enough free space for the BIOS exe) using gparted but gparted wasn’t able to resize
  7. I considered doing the same with the CDROM image, but really didn’t want to resize any partitions at all …
  8. Then I realized I could likely gain free space by deleting files from the FULL version of FreeDOS
  9. So I downloaded the “Full USB” version of FreeDOS instead
  10. Wrote it to the USB stick (same as above)
  11. Mounted the filesystem
  12. Explored the contents and ultimately decided to delete the packages/games folder since it was large
  13. Copied the BIOS exe to /mnt/other
  14. Unmounted the filesystem
  15. Booted with it
  16. Skipped FreeDOS installation to go back to DOS. Believe it was second menu option
  17. Tried to run the BIOS exe. Grr, it said it can only be run from within Windows.
  18. Uhhhhh
  19. I checked the notes associated with the BIOS exe on Dell’s website and saw this: “This file contains a compressed (or zipped) set of files. Download the file to a folder on your hard drive, and then run (double-click) it to unzip the set of files”.
  20. I thought to my self: Ok, it’s a self-extracting exe. That must be a pretty standard format. I wonder if the unzip command on Linux can extract it?
  21. Turns out unzip CAN extract a self-extracting exe. Yes!
  22. I remounted the USB filesystem to /mnt/other, navigated to it within a terminal
  23. Ran: unzip ./R30BLABLA.exe
  24. It extracted the contents within the USB stick
  25. Woo!
  26. umount /mnt/other
  27. Reboot laptop
  28. Skip FreeDOS install, menu option 2
  29. Run exe that isn’t prefixed with “win”
  30. Watch while the BIOS is flashed

What Actually Worked

Condensed steps from my journey above.

Continue reading

HD Motion Detection, Streaming, Encoding on a single Raspberry Pi

This post is about how and why I pieced together my own motion-detection and encoding system. I wanted to produce smooth HD videos whenever motion was detected. Find the code here.

Note: I plan to add videos and stills to make this more than a wall of text, but wanted to get it out before the holidays.

Raspberry Pi computers are powerful despite being small. Did you know the raspivid program can capture 1080p at 30fps without breaking a sweat? Given that, I figured it should be possible to layer on motion detection without impacting the HD video quality too greatly. But like many things, it’s harder than you might think.

Continue reading

Effective Horns

Queued up some Koufax on my morning walk. It had been a while. Sometimes I forget how effective horns can be. Move Out, Move On.

Continue reading

Amanda Nguyen, Rise Justice Labs and effective legislation

Amanda Nguyen is truly inspiring. That’s not something I say lightly.

  • She formulated an effective strategy for getting important bills passed unanimously.
  • She passed legislation by “taking our egos and shoving [them] somewhere”. Oh and compromise and respect. Yes!
  • She fought to fix the broken criminal justice system as it pertains to sexual assault, and rolled that experience into Rise Justice Labs.
  • Oh, and she’s training to become an astronaut.
  • The ZeroUSA campaign wants to ensure that politicians will be safe in voting for gun violence prevention legislation. Founded by someone who doesn’t want to lose his second sister to gun violence. Damn, that’s heart-breaking.
  • “This is a time of frustration, of political tribalism, and of waning faith in our democracy. And I don’t think there’s ever been a more vital moment in our history for people to understand that they hold the power.”
  • “I needed to work with people from all walks of life and people I didn’t agree with in order to pass laws.”
  • “In order for a healthy democracy to function, it’s citizens need to be able to hash things out. And we, I think, in this moment of extreme toxic political tribalism, have lost that.”

Listen to Amanda in the Chaos is a Ladder episode of Pod Save Amerca. Fast forward to 57:10 in the player below. Well worth 17 minutes of your time.

Continue reading

Who Sang It Better

Fatherhood has exposed me to some new music. The themes are similar, so who sang it better?

Continue reading

The Mask

Came across this poem while reading Nonviolent Communication for a book club at work. Great book, by the way.

Continue reading

AFK with Suz Hinton

Given that I have a lot less time these days, and that my brain is being taxed by a recent job change, I’ve been on the lookout for shorter, less attention-demanding podcasts. Enter AFK from Changelog. Episodes are less than 30 minutes, and showcase “the human side of creative work”.

Especially check out AFK with Suz Hinton. They touch on burnout, and the importance of asking for help. It’s not a sign of failure.

Continue reading

Pull request reviews as an async pair-coding session

I started a new job recently and my on-boarding mentor told me I was bringing lots of value to pull request reviews despite being the new guy. This caused me to pause and reflect on how I approach code reviews, what I might be doing differently from others, why I do it and where my habits came from.

Perhaps the best way to describe my approach is that I think of code reviews as an asynchronous pair coding session:

Continue reading

Peter Gabriel - Shaking the Tree

Love this song and sentiment. Getting close to this being reality, but not quite there yet.

Also, I can’t wait until more Americans begin to value and demand good character in their leaders again. That’d be nice.

Continue reading