Zack Matthews

Raspberry-Pi: Motion light switch

My latest little side project has been utilizing a Raspberry-Pi to turn on lights via motion detection. Here’s a quick run down of how I got this working. What you’ll need: – Raspberry Pi w/ Raspbian – Webcam – Hue lights – Motion (https://github.com/Motion-Project/motion) First things first, head over to the motion github page to get that installed on your Pi. This will do all the heavy lifting (why re-invent the wheel here?) as far as motion detection goes. Motion will let you specify a script to execute if it recognizes motion in a specific area of the screen or...

Android: Retrieve JSON from service via DNS SRV lookup

Quick snippet of code for anyone in need of an SRV lookup example. If your apps retrieve data from a service and you’re hard coding a URL, DNS is a great way to make that more dynamic. DNS Java is the library being used here (http://www.dnsjava.org/doc/). private static class ConfigUpdater extends AsyncTask<Void, Void, JsonConfig> { private static final String SRV_RUE_CONFIG_PREFIX = “_rueconfig._tls.”; ConfigListener listener; String request_url; String query_url; String username, password; String errorMsg; public ConfigUpdater(String url, String username, String password, ConfigListener listener) { this.username = username; this.password = password; this.listener = listener; query_url = SRV_RUE_CONFIG_PREFIX + url; errorMsg = “Failed...

The iOS accessibility feature that should be dead simple for developers but isn’t

Android just knows what your system font setting is. If you have trouble seeing smaller text, it will automatically scale your TextViews according to what you’ve told it to do in settings. iOS developers need to give their views a little extra love. Short, simple, and to the point here at 1am just for you. No digging or stackoverflow required. Objective-C – How to scale labels according to iOS system settings: UIFont *CELL_FONT = [UIFont systemFontOfSize:[UIFont preferredFontForTextStyle:UIFontTextStyleBody].pointSize]; if (CELL_FONT) { self.labelView.font = CELL_FONT; }

PUC – Personal Universal Communicator

Once again, Christmas has come and gone. I’ve been working all year to deliver on the Universal communications app aimed at not just the accessibility community but to everyone. We want the PUC project to be the end all be all for communications. We have so much room to improve (who doesn’t?) but we want to share our work with the world. From being one of the first to implement the new FCC mandated real time text, to high quality video, HD voice, multi-media messaging and more, PUC is the ultimate communications platform. Having been the Sr. Software Engineer for...

Silent Planet – Everything Was Sound

To be honest, I have been working harder than I have ever worked in my life. I’m super exhausted, and have been trying to better partition work time and fun time. Not to say that work can’t be fun, or it isn’t rewarding, or I don’t love what I do, but your mental health can suffer when there isn’t any down time. All this to say, when things cool off I’ll probably start writing on the experience I’ve gained from work over the past year in novel length intervals. For now, I want to introduce you to one of the most beautiful albums / bands I have ever...

iOS Tools [5.0+]: FXKeychain – The stress-free, easy to use Keychain wrapper

FXKeychain, by nicklockwood just saved me about an hour of brushing up on the latest changes to Apple’s already slightly complicated password manager library, Keychain. What would otherwise be a bunch of convoluted C calls with ARC complications and a myriad of other caveats, FXKeychain provides a ridiculously easy to use wrapper that resembles something intuitive that we should all be somewhat familiar with: Dictionary syntax. To insert a value into Keychain: [FXKeychain defaultKeychain][@”password”] = sipAuthPassword; To retrieve a value: [FXKeychain defaultKeychain][@”password”]; That’s it! Somebody give nicklockwood some love!

Pi Zero Update and the future of computing

Just wanted to give everyone a quick update on my experience with the Pi Zero so far. I haven’t done any circuitry or wiring, but have been crushing up on my breadboards / circuits. However, I did set up a hole in my firewall to setup SSH, VNC, and a WeMo switch to power my Pi remotely. All in all, this was a really cool experience to learn more about networking, terminal, and how to maximize computations with limited memory / CPU power. Diving a little deeper, I wanted to see if I could whip up a quick IoT app last week. In...

Raspberry Pi’s, Photons, and the magical world of Computer Engineering

Very often we can find ourselves in a career rut no matter the industry. We do the same things, learn similar skills to what we know, and are far too frightened to branch out to try something new. As a means of fighting complacency I’ve wanted for a long time to jump into the world of microcontrollers / hardware, but there has always appeared to be such a high barrier to entry. This article is for the Software Engineer who has been unsure of the hardware world but has an interest in giving it a go. My goal though this...

Press: iD Tech Updated Success Story

So grateful to iD Tech (Programming Academy) for the kind words and update of my story with them. iD Tech has had one of the greatest impacts on my career and I would recommend them to anyone looking to spend a summer learning about or teaching others about Software Engineering. To learn more about iD and read about my experience with them check out the updated story over at iDTech‘s site.

Android Project: Fork of Google “Meter” live wallpaper

Though I’m still working full time I couldn’t help but get my hands dirty with some code over our Christmas break. I wanted to create something I would use on a daily basis as well as have that “cool factor.” Thus spawned the idea of modifying Google’s data centric live wallpaper “meter” for Android. My fork currently adds a settings page that can be configured to do a GET from two URL’s and display that information atop of your Android Desktop. My initial use case for this is to display system status from my office and home Macbooks such as...

A challenge to the insecure entrepreneur: You gave me my career

I get it. Being an entrepreneur can be discouraging. In fact, it can very often end up costing you everything you own. Family and friends may not understand the reasons you pursue the things you do. They don’t see the vision, the greater picture. People say you’re crazy. My word to anyone who is discouraged with where they are at, overwhelmed with finances, or any other worries that have come your way because you chose to pursue your dreams is this: You gave me a career. The reason I can work a salary based Software Engineering position today and provide...

Android + iOS Tool: Calaba.sh – Automated BDD UI Testing

When developing mobile applications with a large team, especially on open source projects, it is essential to ensure your UI is being automatically tested. Not only will this prevent commits that break UX, but will also save time and make things easier for your developers. Calabash does this by using Cucumber scripts (Plain text user stories) to automate button presses, text inputs, and will even tell you if a particular String appears on your screen. In fact, you don’t even need to be a developer to write a Calabash script. For example, a calabash script to test renaming a note:...

Android Tools: Simple HTTP RESTful requests using Volley

For as long as I can remember Android leveraged AsyncTask’s and HttpUrlConnection’s to perform network operations. The reason for this being is that any synchronous tasks performed on the UI thread would cause an application to hang until a response was returned. All of this extra code was a complete hassle and simply added unnecessary time to development. Google has made every Android developer’s life easier now by introducing the Volley maven library. Volley completely does away with all of Android’s woes, worries, and frustrations when performing HTTP requests. At a high level, http requests are wrapped in a Request...

Google Play: DropPin v1.5 out now!

What’s new? – Optimized location services (should remove any battery drain) – Added anonymous pin mode (classic) – Added popup window to save six pins – Context dialog to rename pins via long click – Context dialog to choose between navigation or deleting pins – Link to developer site (hire me!) Available on now Google Play.

Android-Tools: Butterknife (Maven Plugin for Android Studio)

As of this posting I have been developing on the Android platform for over three years and I cannot believe that I haven’t heard of Butterknife. Butterknife is similar to a dependency injection framework, but rather than injecting an interface Butterknife will bind an XML defined view id to a corresponding Java object or lamba callback without making petty calls to findViewById(). Butterknife accomplishes this in probably the most simple way possible. Below is an example of a bare bones Android Activity that demonstrates a simple binding on two EditText variables, a String resource, and an onClick listener.   As you can see,...

Tools: The Little Schemer

If you’re a CS student or Software Engineer candidate trying to master your data structures / algorithms I HIGHLY recommend checking out The Little Schemer on Amazon. If you struggle to think recursively this book will be one of your greatest resources. Digging into it now and it is definitely not for the faint of heart!

DropPin now available on Google Play!

Forget where you parked your car? What building your physics class was in? What about where you stored all of your money in the Albuquerque, New Mexico desert? DropPin is just what you need to alleviate last minute navigational headaches and frustrations. Next time you want to remember an important spot, simply open the DropPin app, and press the pin action button in the lower right hand corner. That’s it! Link to app on Google Play

Android: Merge Sort Visualizer – One Million Integers

After getting back from Stanford’s iD Tech Programming Academy yesterday I thought I might try improving some of my own projects instead on working on others for a change. I took to my old Merge Sort Visualizer for Android and decided to optimize rendering, threading, improve random seeding, and more. After all of my optimizations, sorting a million integers is no longer an exhaustive task for the renderer. To do this I made the following changes to my code: Cut off rendering for any objects off screen (duh!) Added boolean flags during generation and sorting to avoid null pointer exceptions Thread blocking that...

Why Programming is only 10% of a Software Engineering Position

Entering into college was probably one of the most humbling moments of my professional career. Before submitting a single college application I had worked on a number of paid programming projects, but I realized rather quickly that I had a lot to learn about life and my career. To get to the point, which really is the point of it all, is that I could be a Good Will Hunting programming prodigy (read: I’m not!), but without effective communication / valuable life skills I would be just another cocky, mediocre college kid who thinks he’s entitled to his dream job at Google. My epiphany came to me...

Android: Binary Search Tree Project v1.1

I’ve updated my Binary Visualization project with a searching function. Going forward I plan on creating a standard interface and library for each of my structure / algorithm projects and combining them into one application.