Code Reviews

April 6, 2012 at 12:05 AMRampidByter

Code reviews are a necessary evil for professional developers. Anytime we finish a task we’re stuck with the arduous task of enlisting another developer to take on the tedious and time consuming task of reviewing the code for future deployment.

On the flip side when other developers need code reviews we tend to avoid those people like they’re plagued. Any emails requesting help are treated like spam, but we know in the back of our minds that one of us will catch it eventually. Excuses about being too busy can only get you off the hook for so long before you just have to accept the code review.

The problem with code reviews is they’re just so boring. It’s all the hassle of writing code without writing any, and you’re putting your name to something you now have to guarantee works. There is a certain amount of liability that you’re taking on when you do a code review for someone else. The moment it breaks it all comes back to the last person who worked on the code. The code reviewer gets the questions like why didn’t you notice XYZ didn’t work right? Why didn’t you notice that closure or bla bla it goes on.

One day I had a code review that nobody seemed to take any interest in. It wasn’t a terribly big review just a few classes and I sent emails to the team looking for an available reviewer. Nobody replied. A day went by and nothing. No response and no acknowledgement that anyone had even read my request. This happened often, again we avoided them at all costs.

I started to think about what would make me want to open a code review request. Cats. Not just any cat. Funny cats. In particular the LOLCat variety always amuse me so why not combine the two? I went to Google and looked for the cutest cat I could find, opened up my photo editor, and added the text “Y U NO CODE REVIEW?” over the pitiful looking cat.

I crafted a new email, attached the image, and sent it to the development group. Not two minutes went by before I heard the first series of chuckles. A few developers had ousted themselves as having read my code review request. That’s typically the biggest step in enlisting someone. By knowing they know you need help it’s all downhill for their willpower to resist. I had offers almost immediately to take the code review.

What I didn’t expect was for it to catch on. Every developer in the company started adding funny cat pictures to their code review requests. It became fun to see the code review requests come through just to see what kind of funny pictures would be attached. There were cats with guns, adorable cats, ugly cats, and cats with bread on their heads. There was even a pony. I won’t touch on that one, but in short one of the co-ops tried a coupe on the cat trend with a brony attack.

To this day nearly seven months after the first code review cat was sent it’s become an official part of the code review process. In all the years I’ve been programming and of all the things I’ve built or done I can safely say the code review cat is one of the things I’m most proud of. It turned a otherwise hated task and made it fun, well, at least the first part of the process anyways. :)

cat_code_reviews

Posted in: Programming

Tags:

Arduino Hack Weekend

December 4, 2011 at 6:22 PMRampidByter

I did something a little unusual this weekend. A few friends and I decided to have a Arduino robot hacking event. The goal of the event was to use all the same hardware and sensors then put together a robot capable of performing basic line tracking. Since we all started with the same hardware we could put together robots of equivalent capability, and the challenge would be to build and program a robot that would outperform the others.

I took some pictures of the event and figured I would share what happened.

I started with a grab bag of wires and IR sensors with the Arduino Uno board. My first task was to put together the dual motor gearbox for the treaded drive system. Pictured is the assortment of parts/sensors/wires in bags, the gearbox, and the Arduino Uno.

WinMoPho'er_000155

My two friends were already hard at work piecing together their robots.

WinMoPho'er_000157

This is a post-build picture of the gearbox that is driven by dual 6V brushless motors that will power the treaded robot.

WinMoPho'er_000158

After mounting the gearbox and assembling the platform with the treads the structure of the robot is completed. At this point it all comes down to assembling the Arduino Motorshield, wiring the motors, soldering the IR sensors, running the connectors, and programming the robot.

WinMoPho'er_000159

The platform with the flip-up electronics base.

WinMoPho'er_000160

In order to power both the 6V brushless motors I first had to quickly solder together the Arduino Motorshield.

WinMoPho'er_000161

After soldering together the Arduino Motorshield I simply attached it to the Arduino Uno board.

WinMoPho'er_000164

Next came soldering the positive/negative terminals on both the 6V brushless motors, and inserting the motors into the gearbox while running the wires out to connect to the assembled Motorshield.

WinMoPho'er_000167

After getting both the platform and Arduino board configured next came soldering the connectors to the four IR sensors that would be responsible for sensing the line.

WinMoPho'er_000169

Once the IR sensors had the connectors soldered, wires connected, and were attached to the underside of the treaded robot platform.

WinMoPho'er_000178

The finished Arduino powered treaded robot!

WinMoPho'er_000179

At the end of the evening there were three equal, but very different Arduino powered treaded robots. The robot to the very right was the first prototype of the robot configuration, and has been much experimented upon with the addition of both bump sensors, speaker, and a multitude of other sensors.

WinMoPho'er_000184

The first robot to successfully complete the course and on the very first try!

WinMoPho'er_000173

Just watch it go!

WinMoPho'er_000174

 

It was simply awesome watching something built in a period of a few hours going from miscellaneous plastic parts to a robot functioning on its own performing actions that even we didn’t know what would happen. For little under $200, a few burned fingers, and a ton of cheering we had an amazing moment where it felt as if anything was possible. We’re already formulating the next challenge that will be built upon the framework we’ve developed for this first challenge. What an exciting night.

Posted in: Programming | Computer Hardware

Tags:

MacBook Air Development Failure

October 20, 2011 at 10:56 PMRampidByter

Lion released somewhat recently and I was, of course, waiting on the App store to download it immediately. Well, what a cluster that was. I had Parallels setup to dock my windows in a certain workspace, and when the new multi-desktop setup took effect I no longer was able to access my open and running Windows VM. It happened to be docked to a non-existent work space. Ended up fixing that problem, but many more performance related problems started plaguing me. Mainly in the amount of RAM that Lion requires.

At the same time Parallels 7 released and was hailed as incredibly fast and tuned specifically for Lion. What a lie that was. I am told the boot times of the Windows VM decreased significantly, and for a while I thought it was an incredible update. I again upgraded as soon as possible. My Windows Performance Index actually went up by .2 in 3D graphics. I was incredibly happy until Windows Aero started continually crashing. The result was sporadic black screens as the device driver failed and Windows recovered it only to stop Aero. Then the random streaks of odd colors started to appear on the screen that would last a minute or two.

Through out all these new troubles one thing positive happened as a result of the upgrades. I haven’t had a kernel panic in going on a month whereas on Snow Leopard with Parallels 6 I was crashing twice daily on average. So I’ve switched from system crashes to having a buggy graphics driver on a generally underpowered machine bogged down by the host OS.

I wish I could say that things settled down and smoothed out after Lion’s first update became available, or even after the Parallels 7 multi-monitor bug fix came out. Sadly things have hit the wall in terms of performance since the Parallels 7 update that released two+ weeks ago. If anything the system is performing so poorly that it takes upwards of 10 minutes to compile the .Net solution that used to take three. In addition to the poor performance my Windows Performance Index has actually dropped to 2.3 because of the flaky Parallels 7 video driver.

I’m left with no other options than conceding that Lion and Parallels 7 on a MacBook Air no longer leave the device as a satisfactory development machine. At present time I am considering other device options. I will miss the Air… but I won’t miss the horrendous performance.

Posted in: Mac | Hardware

Tags:

Missing Hunter

October 9, 2011 at 8:11 PMAdministrator

I had an experience this weekend that I don’t think I’ll soon forget. I woke up early Saturday (5am) morning and went about my routine of trying to sleep in. I ended up giving up around 7am. I went upstairs and figured I’d check to see what was going on in the world on my desktop since I still haven’t replaced my Windows Phone 7 (another story.)

I logged into the usual sites, Google+, Facebook, Yammer, and Twitter. I skim through all of them and then I noticed it. A buddy had posted a plea for help, that his dad was missing, and that he needed help searching for him at 7:30am. I looked at the clock, it was 7:15am. I sent a quick comment saying I was on my way. I didn’t even shower. I grabbed my gear, cargo jeans, carhart jacket, warm socks, ball cap, and bolted from the house after getting the OK from the wife.

I made it to the search operation meeting area, and pulled in behind a parked police cruiser. I walked over to join the last search party heading into the woods and waited while the chief explained where we were going into the woods in coordination with the other groups that were searching. It’s at this point Trent, the son of the missing hunter, walks over to join the group along with his wife. We all entered the woods together and split up into two groups. I went with Trent, his wife, and an EMT off into a sector close to where his father may have been hunting.

We covered a lot of ground, most of it uphill, and visibility was very poor heading up to the top of the hill. I got filled in that his father most likely was wearing cameo, no reflective material as he was bow hunting, and that we should look for blood or any tracks. His cell phone was on and that they knew that he was within two miles so he was most definitely somewhere in the 60+ acre of woods. By this point I was told that any blood would be black and hard to see but to stay vigilant.

I learned a few things during the search that still bother me. Mainly that the EMT and police rely on hard-copy printed aerial maps while Trent was using Google maps to pinpoint our position far better. The EMT we were with had a basic phone and was surprised of the availability of such technological capabilities. While I don’t doubt the capability of their on-foot searching experience I can’t imagine how much more effective they’d be with properly applied technology.

We kept heading towards clearings that showed signs of recent deer activity as the most likely locations where his father would have been staking out for a good shot. We’d heard some radio chatter that a single arrow was found with a few climbing spikes not far from where we were located. We were advised that it was highly likely we were in the area that he’d be found. I don’t really know how much area we covered after that announcement, but we were heading into another thicket when the EMT shouted ‘They found him!’ We all rushed back to the EMT (we were spread out 20+ feet canvasing the area barely able to see each other).

It was silent for a moment waiting for any additional information. Very silent. We heard the news he was deceased. I looked at the EMT, back at Trent, and then his wife started crying. Trent and his wife embraced. I still can’t describe the look on his face. Pain hidden behind a solemn expression. His eyes were tearing slightly but he held his composure. The EMT and I made eye contact and shared the same thought. He placed his hand out on Trent’s shoulder, who was still consoling his wife, and squeezed. I did the same to the other shoulder.

We were close to where they found him. The other side of the clearing where we’d gone right instead of left. It was a while later when we exited the woods to join with the returning search parties. I splintered off to head to the back where I met with another buddy who I’d not seen in quite some time. Neither one of us had words that adequately described what we were thinking or the situation. I felt my heart jumping into my throat at the pain this must have caused the family. I waited around a while so I could get the chance to again express how truly sorry I was for his loss. I left shortly after. On the way home I called my dad and told him how much I love him.

Posted in: Offbeat

Tags:

3D Printer Project

August 14, 2011 at 4:24 PMRampidByter

I successfully completed getting my MakerBot Cupcake built, and after doing a little calibration work I created my first real object. The total process took 2 hours and 10 minutes to complete and looked a little bit like this:

WP_000846WP_000848 

WP_000849 WP_000850 WP_000852 WP_000853 WP_000854 WP_000855 WP_000856 WP_000857

WP_000858 WP_000859

WP_000861 WP_000862

WP_000863

And finally…

WP_000864 

With a little cleanup, minor sanding, and we have the finished product!

WP_000865

Posted in: Hobby

Tags:

State of Mobile Development

August 7, 2011 at 1:30 AMRampidByter

After spending six weeks building a mobile site for my current employer I had the chance to really get a sense of where mobile development is and a bit where it’s headed. The project itself was built with ASP.Net MVC3 along with jQuery Mobile and was meant to provide an iPhone-less experience. During the development I touched on Sench Touch, PhoneGap, and collaborated with both the Android and iPhone developers on staff to mimic the available functionality.

Unfortunately for me I happened to pick the time to develop the site using jQuery Mobile Alpha 4 and three weeks after launch the Beta was launched. In hindsight I think it would have been a better effort to develop the site using media queries to style the pages. jQuery Mobile is nice but the Ajax handling of page requests can cause some undesired effects. It’s a wee bit cache happy. The experience either way was very enlightening.

The takeaway from the experience was this. Mobile sites are slow, unreliable, and are a giant cluster when it comes to developing a consistent experience across multiple mobile OS and device manufacturers. Android browsers for example on 2.0 to 2.2 experiences vary widely. Even using the same Android 2.2 OS on the Motorola Droid X and HTC Thunderbolt handle mobile sites differently. HTC Thunderbolt has a fixed large network request buffer much different than that of the Droid X causing page requests delays. HTC Desire has an interesting virtual keyboard quirk when typing secondary characters. The keyboard enters the standard key and upon selecting the secondary key deletes the original character and replaces it, but it doesn’t always happen resulting in two characters being entered. Don’t even get me started on Windows Phones or Blackberry OS 5 or less.

It’s also difficult to get a true sense of our user experiences across different networks regardless of device. This is the biggest complaint I have against mobile development. I keep seeing newer phones released with dual-core processors, bigger screens, but they’re all still neutered by the worse than dial-up bandwidth. If the mobile device is on WiFi the device may act relatively well, but if the user is out and about on the AT&T or Cricket network the experience could be drastically different. Ajax has helped web pages come a long way to feeling as responsive as desktop applications, but the moment a chatty site moves to the mobile realm the proverbial shit hits the fan. That gets into the biggest disadvantage a mobile site has versus native apps when dealing with suboptimal bandwidth. Local storage.

Local storage enables the iPhone or Android applications to retrieve data, store it, and then use it for whatever the application needs. For example maybe the application requires a list of financial transactions, and then to allow the users to sort/filter/and view individual line item transaction details. For Android and iOS the transactions can be requested, stored, and easy as pie used for their purpose. Mobile websites are not afforded this luxury. For mobile sites the list of transactions are requested and besides session, storage is limited. Even rendering a large amount of transactions in markup, regardless of latency in retrieving the data, can cause massive delays. For what could take the iOS/Android OS native applications 10 seconds to retrieve, display, and enable interaction could take upwards of a minute or more on a mobile site just to render.

Looking at it again with the new perspective, knowing full well that more smart phones are sold than PCs, it’s saddening where the state of mobile development remains. The landscape is rich with a bevy of powerful mobile devices and many promising mobile operating systems. Still, each and every single one of the devices rely on a communication structure that provides the same experiences that desktop PCs had ten years ago while using dial-up. Sure, there is 3G/4G but coverage is limited, devices capable of using those connections are not as wide spread, and even device configurations (screen size/ touch capability/ browsers) are as numerous as stars in the sky.

In the meantime mobile website development using media queries can be perfectly adept for displaying static content that mostly works on most modern mobile browsers. Native application development still makes the most sense until high-speed mobile bandwidth is provided and hopefully without bandwidth limitations. AT&T you suck by the way. PhoneGap goes a long way to help alleviate the pain of having to master Object-C, Java, and puts focus back on HTML/Javascript. Not every developer is a polyglot programmer, but most developers have at least a familiarity with HTML/Javascript so this makes natural sense to adopt.

Posted in: Programming

Tags:

Life Changes

June 14, 2011 at 9:10 PMRampidByter

First post in a while.

 

Here is a little catch up on where I’ve been.

 

Full-time Work Life

My contract ended after seven months of working for a celebrity owned financial services company. I liked the people so much, and the small office environment that it changed my heart on never working as a full-timer again. They extended an offer even though I had been very adamant about remaining a consultant, and I surprisingly accepted. I’ve been there for over nine months total now, and still enjoying what I’m doing.

 

MacBook Development Machine

MacBook Air as a development machine has been a lot of headaches. Only within the last two weeks have things stopped kernel panicing on a bi-weekly basis. I think the latest Parallels 6 update combined with continual Mac OS updates fixed the problem. Knocking on wood. Still absolutely love the hardware. To this day I still only use one monitor and no other external peripherals.

 

Windows Phone 7 Development

Windows Phone 7 development has been a headache. I frankly got fed up and bailed off the platform. Mango was just released recently. The only problem is Visual Studio Service Pack 1 will not install on my VM. No VS SP1, no mango.

 

Android Development

After getting fed up with Windows Phone 7 I started looking at Android. Another consultant with whom I work with on a daily basis happened to be a very big Android fan. Having become a moderately advanced developer on the platform over the past year he’s ended up showing me the ropes. I ended up catching the bug, and have recently purchased an Eee Transformer (as of last week) that has become my new learning project. Still think Java is outdated.

 

Mobile Development

Within the past six months or so I’ve become very versed in mobile development and platforms. In particular the ‘early’ adoption of the jQuery Mobile library. I plan to write a few ongoing blog posts about jQuery Mobile to help spare others the same ‘early’ adoption headaches.

 

 

I’m hoping to set aside some time each week to catch up more on my blogging. We’ll see. Till then just know MVC 3 rocks. For now I’m off to play Duke Nukem Forever.

 

-R

Posted in: Offbeat

Tags:

MacBook Air Development Headache

December 30, 2010 at 8:22 PMRampidByter

It’s been nearly two weeks since my MacBook Air arrived and I have used it almost exclusively. I bought and setup Parallels 6. I created several Windows 7 Ultimate templates with Visual Studio 2010 Ultimate, Office 2010 Business, and used all my remaining licenses in the process. The VM template was given 60GB of hard disk, 2GB ram, and two cores.

I took it to work and setup a cloned VM as my client development machine. Everything worked better than expected. The MacBook Air built the massive client solution in two minutes and 38 seconds. The previous HP i3 machine with 4GB ram built the solution in just over four minutes. A true testament to the power of the solid state disk if I ever do say so.

Then problems started. First the machine started to freeze. From freezing it went to displaying the power sign of death. Within the first week it crashed five times. It varied from power screens of death, freezing, and even one blue screen within my Windows VM with a “Memory Management” problem. Started to suspect bad RAM at this point, but being new to both the OSX and Parallels I couldn’t tell whether it was hardware or fake hardware causing the problem.

This past Sunday an upgrade was released to Parallels 6, and I’d hoped if it was Parallels maybe it’d be resolved by the update. Unfortunately the upgrade didn’t help resolve the crashing. The crashes were random without being reproducible unless you count when I was in the programming groove it seemed to pick those moments to die. Luckily the MacBook Air boots in no time flat, and I can get my VM to boot relatively fast for a Windows machine.

I ended up contacting Apple support’s fast lane to schedule a service call. Last night I spoke to Cody, the Apple support rep, and booted the Mac to the hardware test utility running off the reinstall thumb drive. The quick hardware test proved to have no known problems. The extended hardware test was run three times in a row. Unfortunately it showed no signs of problems either.

At this point it seems there is no hardware problem, which leads me to believe Parallels 6 is the protagonist in this hardware play. Several other developers at the client site are using MacBook Pro’s with Parallels 6 without any incident. As far as I can tell it seems Parallels 6 does not play well with the MacBook Air. I’ve been researching any known problems (Apple rumors I should say,) and came across several kernel panic threads. The threads were related to first generation Nvidia 320M drivers on the Air. Considering that the Air doesn’t have discrete graphics memory it’s possible the combination of no discrete graphics memory, first gen drivers, and the strain of running Parallels causes a triangle of disaster.

For now I just have to live with the looming crashes, interrupted workflows, and the lost trust in my $1,800 development machine.

Posted in: Hardware | Programming | Mac

Tags:

MacBook Air Development Machine

December 21, 2010 at 10:33 PMRampidByter

A few weeks ago I started the search for a new replacement laptop for the Sony I sold a few months ago. I started by going to the nearby Microcenter and testing the usability of each laptop in the store. I had several make or break criteria I would not budge on. The criteria is below for reference:

  • Trackpad centered horizontally
  • Trackpad doesn’t move cursor while I type when brushed
  • Laptop shell not blindingly glossy (looking at you Toshiba)
  • Vent ports on the bottom of the laptop don’t get blocked by resting on legs
  • Touching the bottom of the laptop doesn’t burn my hand
  • Power cable plug doesn’t wiggle inside the socket
  • Power cable must be longer than four feet (Sony power cables SUCK)
  • Must have a low profile case easily used on the couch

 

Shockingly enough only three machines passed this criteria. Asus, Acer, and Apple. Of the three A’s the Asus was by far my favorite. The G series Asus machine with the flat black case, and back vent ports with luke warm bottom set it apart from the rest. The Acer unfortunately had too small of a trackpad where the mouse buttons seemed half the size of the touch area. The only problem with the Asus was the backlit keyboard from an angle shined light from the sides of the keys, and it weighed roughly 12lbs. It was 17” and wasn’t available in the store in a size I felt I could use comfortably on the couch.

The MacBook Pro laptops were nice, but the edges around the laptop were sharp. It felt like it would be painful to use while resting on my lap. The MacBook Air ended up being the all-star of all the laptops I tested out. The trackpad was perfectly centered on the case, it didn’t move my cursor while typing even though it was nearly twice the size of any other trackpads, and the laptop was incredibly cool to the touch. The slim profile of the device made it seem perfect for couch based use, and it weighed 2lbs compared to the 11lb Asus.

I wasn’t totally sold on the specs of the MacBook Air. The low powered Core 2 Duo and lack of discrete graphics memory wasn’t exactly a strong point in my opinion. Still it was the ONLY laptop that matched the majority of my requirements. I ended up checking around StackOverflow for anyone else using the MacBook Air for development, just to make sure I wasn’t crazy, and found a few posts about people doing just that. It seemed for the most part to be a decent machine given it’s limited resources.

I ended up ordering a MacBook Air last week. I ordered the 13” with the 2.1ghz core 2 duo, 4GB Ram, and with it came the larger 256GB flash drive. I installed Parallels and setup a development template with Windows 7 running both cores and 2gb Ram. It rated a 4.4 in the Windows Experience Index. Not too shabby considering the HP I use at work is an i3 2.4ghz with 4GB Ram and 512MB discrete graphics memory only rated 4.9.

After running Visual Studio 2010, Office 2010, and an assortment of other development tools within the Windows VPC while listening to podcasts via iTunes running on the Mac I can safely say the system holds up. Compile times on the VM were even faster than the HP running the same large solution natively. I believe the SSD had a lot to do with that fact as the hard drive rated 7.6 out of 7.9 on the experience index on the MacBook Air.

There is one thing to note though. I had a Mac screen of death earlier today after leaving the Mac for 30 minutes to attend a meeting. On returning I went to send the alt-ctrl-del command to unlock the Windows VPC, and received a giant power dialog instructing me to shut down the system. It was a bit odd, and a little disconcerting.

As I type this post from the couch on a Windows VM I have to admit this laptop is quickly growing on me. I literally have the best of both worlds, and don’t seem to be sacrificing anything more than the arm and leg it took to purchase it. I’m definitely glad I had the sense to upgrade the laptop with the faster processor, maximum Ram, and larger hard drive space. I have already used more than 100gb of space after setting up XCode, iPhone/Mac SDKs, and three basic .Net development systems.

Posted in: Hardware | Mac | Programming

Tags:

Windows Phone 7 App Hub

December 5, 2010 at 5:10 PMRampidByter

Last week I ended up getting up at about 3:30am and couldn’t sleep. So I did what any self respecting nerd would do. I went upstairs, opened up Visual Studio, and started making my first Windows Phone 7 program. I really wanted to create a program to be able to read the Mac address and display it easily from the phone. I quickly realized that the Silverlight functionality available on the phone is incredibly limited. By incredibly it’s really very pathetic. I would say it’s the most closed ecosystem of any mobile phone on the market, with exception to BlackBerry, but even then I haven’t dived into BlackBerry programming since the 8000 series.

It was fine enough to be able to use the emulator for phone development, but since I have a real phone I wanted to dive right into using things I create directly on my device. That’s when I discovered the App Hub. It’s basically like Apple’s development program where you have to pay $99 plus tax to join their little programming community/marketplace. With that cost you you are entitled to exactly one year of membership, and access to using a development device. This is where Apple and Microsoft take a sharp turn away from each other. With Apple it’s a one time yearly fee for complete access to the marketplace, documentation, code development environments (Xcode), SDK’s, and ability use development profiles on your physical devices. Microsoft on the other hand requires a background check to even get started. Microsoft didn't mention this until AFTER I paid them.

I failed the immediate background check. This is the second time I've failed to prove that I am me. It was asking questions related to my mortgage bank, my student loan bank, and what my monthly mortgage rate is. Well, first the mortgage bank list didn’t display my bank, my student loans were paid off/bank not listed, and none of the listed monthly mortgage rate range were even close to mine. Instead of a quick check it’s turned into a week long wait, having to fax a copy of my drivers license, and just today was granted access to start using my device for programming.

Talk about a buzz kill. Nothing like waiting a week with NO status updates to kill my enthusiasm. First the device is incredibly limited in access to physical functionality, and then jumping through hoops even to use the device I paid hard-cash to own really just puts it over the top from being sad to pathetic. Still, I am happy to see they finally agreed I am me, and now from this day forward I actually feel the $100+ dollars I paid to get denied was at least worth _something_. I’m hoping to push out a few project ideas and at least get a bullet point on the resume that I’ve made Phone 7 applications.

Posted in: Microsoft | Programming | Windows Phone 7

Tags: