WJD

Software Developer, BBQ Enthusiast, Soldier, Parent.

Page 2


Teensy Duino - Auto Login

Teensy 3.1 auto login sketch

I recently got a Teensy 3.1 and have been looking for little projects to do.

This is a quick one that I wrote that, when plugged in, automatically logs me into my computer.

It uses the basic keyboard emulation to send keys to the computer, typing in my password.

It uses 3 char arrays, with the letters/numbers properly offset so that its easy to send the proper int to the usb_keyboard_press function

char keysLower[31] = "0000abcdefghijklmnopqrstuvwxyz";

char keysUpper[31] = "0000ABCDEFGHIJKLMNOPQRSTUVWXYZ";

char nums[68] = "pppppppppppppppppppppppppppppp1234567890";

You call


  writeWord("Mywordtowrite");

here is the function - it just loops through each char and calls the proper write method

void writeWord(char sWord[])
{
  int i;
  char *p;
  p = sWord;
  for(i = 0;p[ i ];i++)
  {
    if(isNumber(p[ i ]))
      writeNumber(p[ i ]);
    else
...

Continue reading →


Bacon 2.0

 Bacon

Who doesn't love bacon

I mean seriously, its one thing that most everyone (sorry-not-sorry vegans / veggies) can enjoy. But how do you make bacon better than you get in the store? Well you make it yourself of course!

I was first exposed to this idea when my neighbor, Matt, smoked a pork belly about a year ago. It was incredible, Thanks Matt! About a month ago I decided to take my first crack at the fatty smoky goodness. I found a whole Pork Belly at Earth Fare up the road from the neighborhood. I’ve always been a big fan of their meats. I went ahead and purchased the whole belly, it was pretty entertaining watching the cashier trying to ring it up. Later that weekend I smoked that bad boy and we had bacon for a couple of weeks.

Naturally I wanted to up my game a bit more the 2nd time around. So last Thursday I bought a whole belly like last time. Only instead of just...

Continue reading →


Lets Encrypt Beta

I’m currently working on how this page is delivered to you. If you want to see the LetsEncrypt certificate in action please visit:
https://www.wjd.io/status

9289019.png

Working with the Let’s Encrypt python client

 Things to check before you begin:

Make sure nothing is listening on port 80 on the machine you are trying to run the client

Ensure that the domain names you are attempting to register are able to be resolved

Dont enter domains that are not explicitly whitelisted in the beta program email you received.

So to get started was pretty easy, there are directions in the email that give you the gist of it. But we want to get as secure as possible right?

Here are the included directions:

 git clone https://github.com/letsencrypt/letsencrypt
  cd letsencrypt
  ./letsencrypt-auto --agree-dev-preview --server \
      https://acme-v01.api.letsencrypt.org/directory auth

Now, that being...

Continue reading →


UDP Server Study Part 3 - Erlang

So its been much longer than I originally anticipated between the 2nd and 3rd installments of my Udp Server investigation. I had already done the majority of the ‘investigating’ into the performance differences between 4 different languages when I started this whole thing. But I’m just now getting around to writing about what I found with Erlang.

I’ve been pretty busy here the last week or so with a new job, a BBQ competition in Chicago and then military this weekend. But enough belly aching, lets get down to the Erlangs.

Spoiler alert, the results ending up being pretty similar to the first two tests, NodeJs and Mono. But it wasn’t that way initially.

At first Erlang had the worst performance out of any of them. I was interested in Erlang after reading a little about it, and of course after watching the very munctional video on YouTube:

When I first started working with Erlang...

Continue reading →


UDP Server Study Part 2 - NodeJs

In Part One of this series we tested a .NET (Mono) Udp Server.

The test has changed a little, and I’ll have to go back and update part one with the new results. The first test we ran was pretty simple. A client running on my machine at home sent 1000 udp packets to an Ubuntu instance running in AWS.

I decided that wasnt enough….. So now the client will generate and send as many packets as it can in a 30 second time frame. The client and the server will both display the number of packets they interact with and I do some fancy math to report on a percentage of success (received / sent).

The NodeJs server performed very similar to the Mono server, with around ~95% success rate.

The node server, and the entire project can be downloaded from here

Just like with the Mono example here is a Youtube video of the test, this time, with music.

Ok since writing this just a couple hours ago...

Continue reading →


UDP Server Study Part 1

Download Repo Here

So a few weeks ago I secured a new job with a technology company here in Indy. Part of my new role will be re-architecting the backend solution to help improve performance, and eventually migrate the solution to AWS.

I started doing some digging into the best practices for some of the various tasks I’ll be required to complete, one of which will be a UDP server. This server will be accepting ~45million requests a day. That averages out to 520 requests per second, though, I’m assuming the load isnt that evenly spread out. To be safe I wanted to be able to handle 1000 requests / second with the server I develop.

I started tinkering around on my local machine with .NET / C# and quickly realized I needed to make this a little more real worldish. So off to AWS.

I already had a T2.Micro Ubuntu 14.04 Server running so I got to work using that.

Luckily what I had...

Continue reading →


Success as measured by time

I recently read an article on HBR.ORG titled “Stop Working All Those Hours” and it has really made to stop and think about how people, myself included, measure success. The general premise here is that success in the workplace is often measured by the amount of time spent in the office. Stop and think about this for a moment; is it true?
Will spending 50+ hours a week in the office really make you a better employee? Or is it a perfect demonstration of not being as efficient as you could be? Metrics are an important factor in a business, I mean you have to have some empirical data by which you compare employees against each other. But is hours worked a valid metric? Does the employee that came in on Saturday deserve recognition if they could have completed the task on Friday? Is the employee that leaves early to watch their childrens’ little league game less dedicated to his or her job?

...

Continue reading →


Cisco E4200 Antenna Mod (no solder)

Cisco E4200 Antenna Mod (no solder)

I have an e4200 dualband a/b/g/n from Cisco (linksys).

Frankly, its reception in a medium/large home sucks. I have it on a bookshelf in my living room on the south side of the house, while my son’s Roku is on the north side of the home. I ended up buying a signal booster just so we could reach the bedroom. I also tried a PowerLine Adapter but I have an older model that was maxing out at 9mbps.

I went ahead an purchased this, that includes 2 7dbi high gain antennas with the proper connectors for the board.

It was really a snap to install, considering all of the antennas on this model have a connector (as opposed to being soldered on).

Here are some pics.
photo1.jpgphoto2.jpgphoto3.jpg

The end result? About a 10 dbi gain in the office when the antennas are aimed properly!
Screenshot_2014-07-15-20-32-56.png

Continue reading →