Fire Fighting Robot

April 9, 2010

We’ve finally finished our fire fighting robot! If anyone is interested in seeing the robot in action, check out the video below. I know it’s kinda boring, we probably should’ve taken a longer video… but alas, we forgot.

This was taken while we were testing it’s sweeping functionality. It scans the 3×3 grid in front, then if and only if a candle is detected, the extinguishing mechanism (the sponge on the arm) is actuated and poof the flame is gone.

You’ll notice after it extinguishes the first two candles that it “bounces” against the black line before stopping. This is actually its self-aligning algorithm. One of the biggest problems we encountered during the course of the project was that the robot would be misaligned whenever it stopped. Essentially, the momentum would carry the robot in anunpredictable direction… Sometimes left, sometimes right. Obviously, as a result, the subsequent trajectory would be affected as well. So, in order to ensure that the robot is straight before proceeding, it is equipped with two photodiodes on the bottom that enables it to do a kind of a repeated “parallel parking” against the line that it’s perpendicular with (aka the line in front of it)… It does this backing up and driving forward motion repeatedly until it is perfectly aligned. Get it? If not, watch the video!

PS. If you’re wondering… here’s the code for the straightening algorithm =)

while( flag == 0) { 

   set_dc1_power(30);
   set_dc2_power(30);

   //not on black
   while( (sensor[2] > highBlack2) && (sensor[3] > highBlack3) ) {  }       

   set_dc1_power(0);
   set_dc2_power(0);

   sensor2 = sensor[2];
   sensor3 = sensor[3];

   //if both sensors are on black, we're straight
   if((sensor2 < highBlack2)  && (sensor3 < highBlack3)) {
      flag=1;
      break;
   }
   else {
      //right sensor is on black and left is on white
      if( (sensor2  highBlack3) ) {
         set_dc1_power(-35);            //back up
         while(sensor[2] < white2){}    //until white
         set_dc1_power(0);
      }
      //left sensor is on black and right is on white
      else if( (sensor3  highBlack2) ) {
         set_dc2_power(-35);             //back up
         while(sensor[3] < white3){}     //until white
         set_dc2_power(0);
      }
   }
}
Advertisements

Just in time for spring

March 28, 2010

It seems like whenever I get into the middle of a school term, I abandon my blog… but this time I’m not going to let that happen! I shall to take some time out of my busy schedule to write a quick update.

In my previous post, I wrote about an imaginary “Windows Zune phone”. Well just recently, Microsoft announced their newest OS for mobile devices, “Windows Phone 7”! They’ve completely revamped the whole design and approach they took to developing a mobile phone OS. From the early demos and screenshots, the user interface is much more “touch-friendly” and intuitive. Actually, it looks very similar to the ZuneHD interface which turned out to be quite well received amongst the tech crowd. And right now, the same looks to be true for the Windows Phone 7. I realize that it’s not an actual physical device, but they’re getting one step closer to challenging the Apple iPhone and Google Nexus One. The only two things I’m hoping that Microsoft will add to their new OS are: multi-tasking and copy/paste. Right now, it doesn’t seem to be included and I don’t understand why if you consider that those were two of the biggest areas of criticism that Apple got when they first released the iPhone… So I really hope it changes before its final release.

Spring is here, and while others are outside tossing around a frisbee, I’m either cooped up in a classroom or a lab. These past few weeks have been super hectic because we’re trying to finish our robot for a competition next Tuesday. The purpose of the robot is to navigate an obstacle course and extinguish lit candles. At first the problem didn’t seem too difficult. We had a mechanical design and algorithm worked out, but now we’re realizing how different real life is from theory.  We’re running into a lot of issues that are unpredictable and completely out of our control…!! Anyway, it’s slowly coming along and we’re learning a lot… Only two more days left!

Where do I even begin? The last month has been crazy hectic for me… in the best possible way. I finished up another successful work term with Sybase in Product Management (PM) and then took a two week break visiting Anaheim and Calgary.

I completed my fourth term at Sybase (fifth overall) and this was one of the busiest, but most rewarding terms. During one of my evaluations, my managers told me, “As the number of work terms you complete increase, so do the expectations.” Not only was this my second to last work term, but also my fourth at Sybase. I knew that the expectations were high and that the bar had been raised. I needed to work hard in order to get the most out of the term. That’s exactly what I did, I jumped into the PM experience, the team embraced my openness and allowed me to work on a wide range of tasks.

I truly believe that a unique experience that I gained from Sybase came as a result of my returning for a fourth term. With over a year of experience at Sybase under my belt, I had a clear understanding of the company’s vision and knew the product very well. Because of this, I was able to make responsible decisions and ones that were aligned with the company’s goal. It’s a great feeling to know that your opinions matter and that your work influences people. This kind of experience was invaluable and a big part of what I gained this term.

Almost immediately after the term completed, I flew down to sunny Anaheim, California. I spent a week there, flew North back to Canada and landed in the winter wonderland of Calgary, Alberta. It was the hardest thing packing for these two trips because most of the clothes that I wore in either places were mutually exclusive! Needless to say, I had to pack a lot of clothes and layers were an important part of my attire during those weeks. It was an fun-filled break and I needed it to clear my head before diving back into the books.

What are my plans for next term? Well, it’s up in the air for now… I’ll be going through the first round of interviews. I hope that I can build upon my current experiences and will update as soon as I know what I’ll be doing.

Need a break from exams?

August 6, 2009

I’m currently writing and studying for finals, so things have been quite hectic lately. I’m not really one for all-nighters, so I guess my schedule is a bit better than some of my classmates’.

After writing exams, I usually take a break to “recuperate”… don’t question whether that’s a good thing or not =P. And what better way to clear your mind than to hit the sand and play some beach volleyball!? (I say “sand” because it’s not really a beach… so I guess it can’t really be called “beach volleyball” either) There are these courts on campus beside FED hall which I’ve never been to. I like discovering these places on campus in my third year =P… just like that outdoor rink last winter. The courts are surprisingly really nice, soft sand with a strong firm net. The worst thing is playing with a flimsy net that droops down in the middle. Anyway, enough about the courts… myself and around a dozen of my classmates headed over after our ECE 325 (Microprocessor Systems and Interfacing) exam and played for about an hour. Though I hadn’t played volleyball in a long time, it was fun to get some fresh air and hit the ball around =). But now it’s time to hit the books again and study for the next exam… MTE 320.

I’ve had over a week now to test my MacBook’s new wireless card after being sending it in for repairs. For the record, this is actually the third time that I’ve had to get my MacBook fixed during the three years since I bought it. Boy, am I ever glad that I got the three-year extended Apple Care warranty! First, the LCD backlight started to flicker; next the keyboard chipped and most recently, the wireless card stopped working. Fortunately for me, I had an Apple-authorized repair shop right on campus. This definitely saved a lot of aggravation of having to find and get to an Apple store. Although, I am quite unhappy with the quality of their hardware, I am extremely happy with the service I received. I was never asked any questions and the turnaround time was really fast (two days in the case of my most recent incident). I cannot stress how convenient having a repair shop on campus was. If I had to drive to the local Apple Store, I think my sentiments would be completely different… so kudos to CHIP. Now, I’m just hoping that this wireless card will hold out for the remainder of my MacBook’s lifespan, and that nothing else breaks. I have just over a month left in my warranty >.<.

It was quite a long week. 5 exams in 5 days. Should that even be allowed? My week went as follows:

for(n=1; n<=5; n++)
{
     StudyForExam(n);
     TakeExam(n);
     if(n!=5)
          StudyForExam(n+1);
     Sleep();
}

Notice that there’s no time for a break? Well, that’s because the next one was less than 24 hours away! Okay, enough complaining. The point is, I’m done midterms for this term =).

In the midst of this crazy week, there were still some funny moments that arose. You know that time after every exam, when little groups form and everyone starts talking about how badly they did? (Unless your class talks about how well they all did… we usually don’t.) Although it was depressing, I found it somewhat funny hearing their comments and reactions. And it didn’t just stop there after the exam, a bunch of classmates echoed their sentiments on their Facebook status. Here are some of the best comments/replies that amused me:

After the first exam: “Round 1: Epic fail”

After the first 3 exams: “I wonder if the sum of my marks for the first three exams has exceeded 100% yet.”

“is invoking the mercy rule.”

Facebook status:
failed 325 harddddddddddddddd”
Replies:
– “Who didn’t?”
– “Who didn’t x2 ?”
– “x3.”
– “0x04”
– “0x0F … it was so weird”
– “0xFFFFFFFFFFFFFFFF”
[ECE 325 is a course on “Microprocessor Systems & Interfaces”… so we had to work with Hexadecimals =P. Geek failure at its best.]

And a completely random, but hilarious one: “today I realized the word bed looks like a bed”

My class cracks me up =P. It’s good to know that while we’re all suffering, I can get a couple of chuckles.

Although exams are done, I’m still stuck in exam mode and that translates to my exam sleeping pattern… That explains why I’m still up at this insane hour (2:50 am). But seriously, I really need to fix this schedule. Great, I just realized that there’s a lab report due on Monday which means I’ll be spending tomorrow (today) working on it. When will this end!?