Showing posts with label electronics. Show all posts
Showing posts with label electronics. Show all posts

Thursday, December 5

Complete Guide to Cheer Up a Little When Your Laptop is Infested by Ants.

I woke up this morning only to get a miny heart attack when I saw tiny ants crawling out of my keyboard. Like most of us, my laptop is my most precious asset and I am not going to let any critter call it as its home. Damnit, its not my hostel room, in which till recently we were amicably in agreement with the spiders about their property and ours. They mind their business and we mind ours. Such peace. I am sure foreign diplomats could learn from us. But that changed a few days back. More about it later.

So yes, you don't mess with my Laptop. I was pretty pissed. So started firing away Google searches on 'Ants crawling out of my laptop' and that kind. To my surprise I came across some pretty funny answers, a creepy BBC documentary which talks about why ants love electronics but bees hate electronics and an ingenious solution to the problem!

Instead of being panicky, why not cheer up a little?


Monday, September 2

How college students took group study to a whole new level !

Students of Dhirubhai Ambani Institute of Information and Communication Technology (DAIICT) took group study to an entire new level during one of their recent in semester examinations.

Students were given a random set of questions by the professor and were supposed to find their answers and treat them as the syllabus of the upcoming examination. Everyone was completely clueless. It was all messed up and last minute panic had already kicked in for those who gave a damn.

But necessity is the mother of Jugaad. 

One of the students made a document on Google Doc and make it public and editable by everyone. He put all the questions on it and wrote a tiny foreword telling people to fill in answers and links. All questions which were in more probability of being asked in the examination were asked to be +1'ed.



Initially the doc wasn't filled up completely but as the night before the exam began, the doc was being viewed by as many as 70 people and most of them were editing and adding answers.

It was really wonderful seeing such massive collaboration. The document was the single source of information for many of the clueless students.

There were at times when 50 people were editing at the same time and Google didn't allow any further editors on the document. But all of us could read it anyway.

But it was not that smooth and simple. There were many cases of people writing complete bull shit and going completely off topic taking advantage of their anonymity. But any crap written was removed very quickly by other more serious editors. A sense of community.

There were also instances in which people selected the whole text and deleted it and thereby sending many students in panic and giving them tiny heart attacks. These instances increased as soon dawn was breaking, and so were people's hopes about the exam. But thank god for revision history, peace was instilled quickly.

In all, its an wonderful example of who technology can be used for mass collaboration.
Everyone has the same technology, its just about how you use it and make the most of it.

A video about massive collaboration which really amused me in my freshmen year. Its an must watch for everybody. Creativity is endless.





Tuesday, August 6

Madonna's 4 minutes and Arduino Board.

Note: Non senti post. Just a bit technical. Yes, I am not crying and brooding all the time.

An assembled serial Arduino. (Photo by Nicholas Zambetti)

“Tick tock, tick tock, tick tock
Yeah, uh huh
Tick tock, tick tock, tick tock
I only got 4 minutes to save the world”




Don’t judge me. Don't go away. This post is not about that song. Play it for added effect while reading.
World ends in 4 minutes 15 seconds.
Yes, it is the end. Everything gets over. Reset. You have to start from scratch every 4 minutes 15 seconds.
At least in Arduino world. This happened in the EHD ( Embedded Hardware Design ) lab. We were supposed to work on Arduino boards and implement a clock which displays the time. We also had to add an alarm.

The method we followed was to have a variable called seconds, which stores duh seconds. We added a delay of 1 seconds before incrementing it.

seconds = 0
delay(1000)
seconds = seconds + 1
We had to write the time every time into EEPROM so that the clock can continue even after a reset.
EEPROM.write(address, seconds)
In the start of each loop we read the seconds from the EEPROM, displayed it, added a delay, incremented, wrote in the EEPROM and continued the same cycle all over again.

The clock was working was properly our at least it seemed to. But stumbled upon something really weird though.

When the clock was running,
4 : 11
4 : 12
4 : 13
4 : 14
4 : 15
0 :  0
0 :  1
0 :  2

WHAT?! The world came crashing. Nothing made sense. Well, okay. Nothing that melodramatic.
But me and Zubin ( lab partner) were confused. There was nothing in the code that could reset the seconds to zero. Why only after 4:15? The code was simple enough to have any such hidden errors.
We tried again, and the same thing happened. We were reset to the beginning of time as soon as we hit 4:15.
But we were a little confused and then it finally hit us.

Each address on the EEPROM is byte sized and hence can only save numbers from 0 to 255. As our design solely relied on one variable (seconds) we were facing the problem.

4 : 15 means 4* 60 + 15 seconds, ie 255.

As soon as the time reached 4 : 16, it meant 256 seconds. But we couldn’t write 256 into the EEPROM, hence 0 was getting written.  Which meant the next read only fetched 0 seconds.
It was such an eureka moment for us. We were literally excited and beaming. 

We engineers, little byte sized things make us so happy.









Ps. Subscribe if you like :)
Twitter: @NisarHogaya