Hack \etal http://hacketal.com The blog of Nirmal Patel posterous.com Thu, 05 Jan 2012 10:47:00 -0800 Bash script to monitor and email when a application stops http://hacketal.com/bash-script-to-monitor-and-email-when-a-appli http://hacketal.com/bash-script-to-monitor-and-email-when-a-appli

Usage: monitor.sh PID MESSAGE EMAIL_ADDRESS

#!/bin/bash

while [ -e /proc/$1 ]
do
  sleep 1
done
mail -s "$2" $3 < /dev/null

Permalink | Leave a comment  »

]]>
http://files.posterous.com/user_profile_pics/837639/nirmal_mii.png http://posterous.com/users/332nJ58U Nirmal Patel Nirmal Nirmal Patel
Fri, 07 Oct 2011 14:37:00 -0700 My Grandfathers http://hacketal.com/my-grandfathers http://hacketal.com/my-grandfathers

A short note on what my grandfathers were to me.

Dada, my father's father. He was a farmer in India and a businessman in America. No matter where his family moved, he always carved out a little garden that produced a disproportionately large amount of vegetables. Even when the family no longer depended on his efforts he put the same amount of work into his small garden as he did with all of his acres in India. Always provide for your family. He was also a very social man. His wit and impeccable memory allowed him to carry on a conversation with anyone, anywhere. He had a gift for remembering everything about you so the next time you met everything just picked up right where it was left. My mother always said, "If he had practiced his English a little more he could easily become a mayor." Last he was a religious man. He spent many hours reading scriptures. He wanted to know as much as he could so that he could best determine his own path. For him, the best way to understand and be a member of our religion was not simple adherence and blind faith. His goal was to deeply understand every facet of our and others' beliefs. To dive deep and know everything. Work is important because it provides for your family. Thinking of others is important because it strengthens your community. Deeply understanding your beliefs is important because it strengthens you.

Dadaji, my mother's father. He was an intellectual through-and-through. He was a civil engineer in India. He had a completely positive outlook and it was a rare and confusing moment to ever see him upset. His focus was always laser sharp on understanding the world through science. Many of my mornings in India were spent discussing various scientific topics. Physics was the primary subject. We focused on the beginnings of everything from the elements to fundamental forces such as gravity. We discussed the evolution of scientific concepts such as Mass/Energy Conservation and Relativity. As concerns about the future on a human timescale became more important to him we often discussed topics in Biology and Chemistry. How can we support everyone on the planet when the gifts of nature are no longer sufficient? What can be done with technologies such as genetic engineering when we barely understand what we are modifying? What about limited water supplies? How can we reverse the effects of global warming while continuing to produce energy at a sufficient level? Not too far from all these questions was the place of religion in a world of science. Was there a happy medium between science and religion? While some around him thought that such resolution to such difficult questions and the mysteries of the universe should be left to God, he, and I, deeply believed that God has left it to us.

My Dada and my Dadaji taught me that life is about many things. To better know yourself, know the world. To better know yourself, know others. To better know yourself, question yourself. Their lessons were implicit in the way they lived. In the end you should be happy, not just with what you've earned, what you've created or how other's feel about you. In the end, you should be happy with the effort you have put forth.

Permalink | Leave a comment  »

]]>
http://files.posterous.com/user_profile_pics/837639/nirmal_mii.png http://posterous.com/users/332nJ58U Nirmal Patel Nirmal Nirmal Patel
Mon, 26 Sep 2011 21:31:00 -0700 Yosemite National Park http://hacketal.com/yosemite-national-park http://hacketal.com/yosemite-national-park

This weekend, Mansi and I got away to see Yosemite National Park. We were really astounded with the beauty of the park. We also found a really nice place to stay. If you can get a room there, we really recommend staying at the Poppy Hill Bed and Breakfast. We were hosted by a wonderful woman named Mary Ellen. Every morning, we had a hot, fresh breakfast and Mary Ellen may be the nicest person in the whole world.

Dsc02995

Day 1 - Yosemite Valley

Our first day was all about waterfalls. Drive in on 140E. Stop at Bridleveil Falls as you drive in. The walk from the parking spot to the base of the fall is only 1000 feet so it is a nice start to the morning. Then head on further and park at the Visitor Parking. From here you can use the free shuttle to get all over the valley. We planned on seeing both the Lower Yosemite Falls and Vernal Falls on this day. However, due to a freak thunderstorm we pushed the Vernal Falls to Day 2. I include it here because both are doable on the same day if you get there early and push it. Both are beautiful although be prepared for a bit of a uphill hike to get to Vernal Falls. Climbing on the rocks around the waterfalls can be a lot of fun and great for getting some really nice photos. We did this a lot for Yosemite Falls but didn't for Vernal because the water was pretty fast and just getting there was pretty exhausting. We ended the day by driving up to Tunnel View and watching the sunset from Glacier Point.

Day 2 - Mariposa Grove

Wow! Mansi and I have seen lots of various Redwood forests but nothing prepared us for just how large the sequoias were. We spent a long time hiking all over Mariposa Grove. We were lucky to find a parking spot but you can always take the free shuttle from Wawona. We checked out every tree on the map and more. The one thing we didn't catch on camera was a beautiful deer crossing the trail and not remotely caring about our presence.

Permalink | Leave a comment  »

]]>
http://files.posterous.com/user_profile_pics/837639/nirmal_mii.png http://posterous.com/users/332nJ58U Nirmal Patel Nirmal Nirmal Patel
Fri, 09 Sep 2011 09:42:00 -0700 Mobile HCI 2011 Lightning Write-up http://hacketal.com/mobile-hci-2011-lightning-write-up http://hacketal.com/mobile-hci-2011-lightning-write-up

Mobile HCI 2011 was held in Stockholm, Sweden. This was the 13th Mobile HCI. This year there were 63 papers and notes for an acceptance rate of 23%. The attendance was the highest ever with 400 registrations.

The first paper that caught my attention was "Intimate Mobiles: Grasping, Kissing and Whispering as a Means of Telecommunication in Mobile Phones". This paper explores how physical cues of nearness could be transmitted by our mobile devices. Imagine a phone that slipped around your hand like a glove and when your conversational partner tensed up the glove tightened around your hand. Or maybe you're away on travel and your spouse wants to give you a goodnight kiss. She kisses her phone and your phone kisses you. While the technology may be years off, there is lesson to be learned here on how we can close the gap between the conversational experience on both sides of what is just now a auditory connection.

Then there was "Unpacking Social Interaction that Make us Adore – On the Aesthetics of Mobile Phones as Fashion Items". Among my colleagues, there was a lot of discussions as to the relevant importance of this paper. On one hand, the authors attempt to show how understanding how mobile technology fits into the trend setting world of fashion is crucial to helping design products. On the other hand, the practicalities of producing hardware at large scale make it seem like our own only option is the custom phone covers market. My take away from this is that there is a powerful market force to be considered in the fashion magazine/blog world but it is probably drowned out by more tangible issues such as carrier plan and base device costs.

With the more touchy-feely things out of the way I strapped in for a session called "Text and Keyboards". Feel free to skip this paragraph if the session name made you yawn. The winner of this session was definitely "Design and Evaluation of Devanagari Virtual Keyboards for Touch Screen Mobile Phones". The paper focused on coming up with techniques for entering Devanagari script on mobile devices. The key insight of this paper is that there is a false jump to optimize for speed of entry. However, in almost all cases, there users were rarely familiar with the mobile technology much less ready to learn an entirely new layout for their language. So while the overall entry rates of their methods were slow at least some text was being entered. I seriously hope they continue down this work and try to create some techniques for non-touchscreen phones as that is still a prominent form factor in India. Other papers of note in this session, "A Versatile Dataset for Text Entry Evaluations Based on Genuine Mobile Emails" and "Script-Agnostic Reflow of Text in Document Images".

Back to something a little more light-hearted, the next session was "Projections and Visualizations". As the session chair stated, a few years ago it would be odd to hear about a session on projection at Mobile HCI but with the arrival of pico projectors the output space of mobile phones is expanding. The first paper, "PoCoMo: Projected Collaboration using Mobile Devices" may have had the best hack I've seen during the entire conference. Multiple users point their phones at a wall to project small cartoon characters that live on their devices. The phones have a sleeve over them that allow the camera to see the projection. By encoding information into the projection itself, both devices can communicate to keep the cartoon characters at the right scale and rotation. Additionally, as the characters get closer, the projection+vision system is used to sync up animations. The projection surface is the network medium. Great hack. The other paper in this session that really struck a chord with me was "Content Splitting & Space Sharing: Collaboratively Reading & Sharing Children’s Stories on Mobile Devices". The authors explore how giving a group of children multiple devices and having them engage in a story reading exercise with multiple configurations of the story pages effects interpersonal engagement. The paper goes into a lot of depth on the various effects of how devices were oriented to each other as well as the effects of activity (creation or consumption) on the engagement.

Then there was "Ubiquitous Sketching for Social Media". The technology is simple. You have an Anoto pen, augmented paper and a smart phone client that will upload an image of what you sketch to your social network. Simple but powerful. From the paper, "Despite its portability, sketching as a social medium has been largely left behind. Given sketching’s unique affordances for visual communication this absence is a real loss. Sketches convey visuo-spatial ideas directly, require minimal detail to render concepts, and show the peculiarities of handwriting." The paper shows how by combining the unique affordances of pen and paper, the expressiveness of a hand drawn sketch and the connecting power of digital communication, users were able to engage in a richer communication with their friends and family.

My final notes are on "The Phone Rings But the User Doesn’t Answer: Unavailability in Mobile Communication". The researchers goal was to better understand the context around unavailability. I really liked the methodology in this paper. The authors installed some simple logging software on participants phones to record instances where phone calls and text messages didn't connect. Then each night, the logging software uploaded this information to a web server and sent the user an email with a web form which solicited contextual information regarding the lapses in communication. Then at the end of the study, the researchers sat down with the participants and went through the data to fill in more gaps in the contextual information. This gave the researchers a very rich representation of otherwise banal log data. The results were interesting with an almost even split between Unavoidable (couldn't hear the phone), Enforced (in a meeting, would be inappropriate to answer) and Intentional (I'm sleeping or at a movie) unavailability. Another interesting outcome of this study was the amount of cross-modal communication, someone misses an incoming phone call but instead of calling back they reply with a SMS or IM. I would really like to see this methodology taken up a notch by logging all notifications that arrive on a device and monitoring how and when a user interacts with them.

So that does it for me and Mobile HCI 2011. The conference was two simultaneous tracks so I'm sure I missed a lot of good work. I encourage everyone to check out the proceedings as soon as they pop up on the ACM Digital Library. Next year the conference will make its jump across the Atlantic to San Francisco, CA. I hope to see everyone there again!

Permalink | Leave a comment  »

]]>
http://files.posterous.com/user_profile_pics/837639/nirmal_mii.png http://posterous.com/users/332nJ58U Nirmal Patel Nirmal Nirmal Patel
Mon, 05 Sep 2011 13:24:00 -0700 Photos from Stockholm http://hacketal.com/photos-from-stockholm http://hacketal.com/photos-from-stockholm

I'll write up my thoughts on Mobile HCI 2011 later but until then, here are a few photos I took while out and about in Stockholm. Due to all of the flight troubles I ended up having a free day before and after the conference. I checked out the Vasa Museum, Sergels Torg, City Hall and Moderna Museet amongst other places. We also so some pretty weird things, including a wall climber statue, a couple of guys hanging off the side of NK playing a vertical tennis game and some interesting views up and down the canals.

Permalink | Leave a comment  »

]]>
http://files.posterous.com/user_profile_pics/837639/nirmal_mii.png http://posterous.com/users/332nJ58U Nirmal Patel Nirmal Nirmal Patel
Sat, 20 Aug 2011 19:50:00 -0700 Big Sur and Highway 1 http://hacketal.com/big-sur-and-highway-1 http://hacketal.com/big-sur-and-highway-1

Mansi and I went out to Big Sur today for some light hiking (2 miles). We checked out Pfeiffer Falls and Valley View while at Big Sur. We also stopped at a few scenic points on Highway 1. Here's a few photos.

MOV02794.MPG Watch on Posterous

Permalink | Leave a comment  »

]]>
http://files.posterous.com/user_profile_pics/837639/nirmal_mii.png http://posterous.com/users/332nJ58U Nirmal Patel Nirmal Nirmal Patel
Sun, 14 Aug 2011 12:59:00 -0700 Photos and videos from Mount Hermon http://hacketal.com/photos-and-videos-from-mount-hermon http://hacketal.com/photos-and-videos-from-mount-hermon

Mount Hermon is this great park in the Santa Cruz hills. Here are a few photos and videos of Mansi and I enjoying the Redwood tree canopy zipline tour. Big thanks to Thad and Tavenner for taking some great photos.

00010.mov Watch on Posterous
00005.mov Watch on Posterous
00008.mov Watch on Posterous

 

Permalink | Leave a comment  »

]]>
http://files.posterous.com/user_profile_pics/837639/nirmal_mii.png http://posterous.com/users/332nJ58U Nirmal Patel Nirmal Nirmal Patel
Sun, 31 Jul 2011 10:58:00 -0700 Keywurl and Safari 5.1: A better solution http://hacketal.com/keywurl-and-safari-51-a-better-solution http://hacketal.com/keywurl-and-safari-51-a-better-solution

Eric Ridvan Üner pointed me to Safari Keyword Search, a Safari extension that behaves similarly to Keywurl and works with Safari 5.1.

Pros:

  • It's an extension so you don't have to fuss around with SIMBL.
  • Allows for easy customization of all of your keyword searches by right clicking on any input text field and choosing "Keyword Search Settings...".

Cons:

  • To add a new custom search you have to look up the URL endpoint you want. Right clicking and choosing the settings brings up all of your custom searches but it does not pre-populate a new one with the search you may be adding.
  • You can only specify using the entire query after the keyword. Keywurl allows breaking it up by individual words and rest of query.

Also, it does not work side-by-side with the SafariOmnibar Plugin which allows you to get rid of the Google search box. Not a big deal for me, I just shrunk down the Google box as much as possible because my Default query using any keyword searcher is Google.

Permalink | Leave a comment  »

]]>
http://files.posterous.com/user_profile_pics/837639/nirmal_mii.png http://posterous.com/users/332nJ58U Nirmal Patel Nirmal Nirmal Patel
Sat, 23 Jul 2011 20:12:00 -0700 Keywurl and Safari 5.1: A Temporary Solution http://hacketal.com/keywurl-and-safari-51 http://hacketal.com/keywurl-and-safari-51

I've received a few emails about this so I thought it would be best to just make a quick post about it. 

Back in June 2010 when Safari 5 came out it was pretty easy to make Keywurl work by just editing the Info.plist file. Details on that hack are here. However, this same hack doesn't really work with Safari 5.1. While it prevents Keywurl from causing an error when Safari 5.1 starts, it does not allow Keywurl to actually fulfill its purpose.

In the meantime, I am using Safari Omnibar which currently just uses non-URL text as input to Google search but aspires to go further and make the Safari location bar functionally identical to the Chrome location bar. To perform keyword searches from anywhere I switched to Alfred (an app similar to Quicksilver or Launchbar), which has custom keyword searches, and wrote a little script to take all of my Keywurl customizations and add them to Alfred.

Permalink | Leave a comment  »

]]>
http://files.posterous.com/user_profile_pics/837639/nirmal_mii.png http://posterous.com/users/332nJ58U Nirmal Patel Nirmal Nirmal Patel
Thu, 30 Jun 2011 12:49:16 -0700 Two ideas for tea bags http://hacketal.com/two-ideas-for-tea-bags http://hacketal.com/two-ideas-for-tea-bags 1) A bag that is lined with a shape memory alloy. The ring is small when cool allowing tea to move freely. As it warms up in the water, it expands thus squeezing the tea and extracting the water left. I think I've seen this somewhere before but haven't been able to find it.

2) A tag that changes color with exposure to air. The tag can start normal and go clear in the same amount of time as the recommended brew time.

Permalink | Leave a comment  »

]]>
http://files.posterous.com/user_profile_pics/837639/nirmal_mii.png http://posterous.com/users/332nJ58U Nirmal Patel Nirmal Nirmal Patel
Sun, 03 Apr 2011 16:11:00 -0700 Reddit Pics Screensaver http://hacketal.com/reddit-pics-screensaver http://hacketal.com/reddit-pics-screensaver

Have you ever wanted a screensaver that just cycled through the top pics on the /r/pics sub-Reddit? I did too, but who has time to learn how to make screensavers? Then I found out about WebSaver for OS X, a simple screen saver that shows any given url when your screen saver timeout activates.

Installation

  1. Install WebSaver, you can get it here.
  2. Download this HTML file to ~/Library/Screen Savers. Don't bother trying to view it in the browser, it won't work due to cross domain restrictions.
  3. Open up the Screen Savers preferences panel and select the WebSaver.
  4. Click on "Options" and set the URL to the local file. For me this is: file:///Users/nirmal/Library/Screen%20Savers/redditPicsScreensaver.html. As the page requeries the /r/pics frontpage, I disabled the automatic reload.
  5. Start the screensaver and enjoy! The first image load may take some time but it should be pretty smooth afterwards.

 

Permalink | Leave a comment  »

]]>
http://files.posterous.com/user_profile_pics/837639/nirmal_mii.png http://posterous.com/users/332nJ58U Nirmal Patel Nirmal Nirmal Patel
Wed, 23 Mar 2011 22:09:06 -0700 Netflix credit for recent disrupted service http://hacketal.com/netflix-credit-for-recent-disrupted-service http://hacketal.com/netflix-credit-for-recent-disrupted-service
Photo

Permalink | Leave a comment  »

]]>
http://files.posterous.com/user_profile_pics/837639/nirmal_mii.png http://posterous.com/users/332nJ58U Nirmal Patel Nirmal Nirmal Patel
Sat, 19 Feb 2011 11:51:00 -0800 Pizza California http://hacketal.com/pizza-california http://hacketal.com/pizza-california

Pizza California was the first place we had dinner when we came to California. We recently went back for Valentine's Day. Our standard order is a half order of Garlic Breadsticks and a medium Santa Cruzer (sub jalapenos for zucchini).

(★★★★/5) and they have an awesome logo on their box.

Dsc02154

Permalink | Leave a comment  »

]]>
http://files.posterous.com/user_profile_pics/837639/nirmal_mii.png http://posterous.com/users/332nJ58U Nirmal Patel Nirmal Nirmal Patel
Wed, 16 Feb 2011 21:46:00 -0800 Embedding LargeType in Webpages http://hacketal.com/embedding-largetype-in-webpages http://hacketal.com/embedding-largetype-in-webpages

Added a little feature to LargeType that I've been wanting for awhile. Now you can click on the embed (< / >) link in the top-left corner and you get some HTML code to embed the message in your page. You can adjust the area taken up by LargeType by just changing the width and height attributes in the markup. And it still works fine in Mobile Safari, even if you're offline.

Example:

Permalink | Leave a comment  »

]]>
http://files.posterous.com/user_profile_pics/837639/nirmal_mii.png http://posterous.com/users/332nJ58U Nirmal Patel Nirmal Nirmal Patel
Sun, 13 Feb 2011 12:36:00 -0800 Photos From Mom & Dad's Visit http://hacketal.com/photos-from-mom-dads-visit http://hacketal.com/photos-from-mom-dads-visit

San Francisco: Chinatown, Gott's Roadside @ Ferry Building, Lombard St., Golden Gate Bridge

Muir Woods: Very chilly day in the woods.

Monterey Bay: We saw dolphins and whales, but no good pics of them. In their place I present my dad looking cool and a dog on a surfboard.

Santa Cruz: Later half of Monterey Bay day was spent in Santa Cruz.

Note: While these only represent the time spent with them outside of the house doing "fun" things, nothing compares to the happiness of just hanging out with them in a day-to-day setting. Most importantly, morning tea.

Permalink | Leave a comment  »

]]>
http://files.posterous.com/user_profile_pics/837639/nirmal_mii.png http://posterous.com/users/332nJ58U Nirmal Patel Nirmal Nirmal Patel
Sun, 16 Jan 2011 14:38:00 -0800 Showing common short messages on your iOS device http://hacketal.com/displaying-common-short-messages-fullscreen-o http://hacketal.com/displaying-common-short-messages-fullscreen-o
  1. Go to http://nirmalpatel.com/largetype/offline/index.html
  2. Type in your message and press enter
  3. Use the "Add to Homescreen" feature of Mobile Safari and save the page to your home screen
  4. Anytime you want to show the message again just tap the icon and the page will load with that message

The page works offline and to save space you can group a bunch of common statements into a single folder. Let me know if it works for you.

Permalink | Leave a comment  »

]]>
http://files.posterous.com/user_profile_pics/837639/nirmal_mii.png http://posterous.com/users/332nJ58U Nirmal Patel Nirmal Nirmal Patel
Sat, 01 Jan 2011 21:34:00 -0800 San Francisco New Year's Eve 2010-2011 http://hacketal.com/san-francisco-new-years-eve-2010-2011 http://hacketal.com/san-francisco-new-years-eve-2010-2011

A short one night trip to San Francisco. Went up on Friday and toured SFMOMA. Dinner at Osha Thai (✭✭✭/5) and relaxed before heading down to Pier 14 for fireworks which were great. The rain thankfully waited until the fireworks were over. Next day we just made the checkout time and went back to the Ferry Building to have lunch at Gott's Roadside (✭✭✭✭/5). Followed up with a leisurely drive up along the coast starting at the Ferry Building and going around until we hit the beach along the Great Hwy.

Permalink | Leave a comment  »

]]>
http://files.posterous.com/user_profile_pics/837639/nirmal_mii.png http://posterous.com/users/332nJ58U Nirmal Patel Nirmal Nirmal Patel
Wed, 29 Dec 2010 15:39:00 -0800 Lesser The Flow More The Temperature http://hacketal.com/lesser-the-flow-more-the-temperature http://hacketal.com/lesser-the-flow-more-the-temperature

Lesser_the_flow_more_the_temperature

This little plaque is attached to a water heater in Mansi's family home. Given the lack of safety features the first four instructions are unsurprisingly all about not killing yourself. It is an electric heater so make sure it is grounded (1). Due to an erratic power supply there should be a good fuse (4). The device does not have an automatic pressure relief valve so it is important to make sure pressure can not build up (2 and 3) which could lead to an explosion.

The last instruction however is interesting and is there because the heater does not have a storage tank. There is only a single faucet which controls the rate of water flowing through the pipe. Water flows directly from the holding tank on the roof, around the heating elements and out of the faucet. Therefore, the temperature is inversely proportional to the flow, hence "Lesser the flow, more the temperature." Once, as I was waiting for a bucket to slowly fill with hot water, I started to think about how odd it was to see this relationship explained in text rather than some sort of graphic. 

Inspired by more standard patterns such as:

Standard_gradient

Why not something like:

Lesser_gradient

Due to the generally warm temperatures in Mumbai, I use purple to represent the higher flow end as even without heating the water is room temperature. The question then, is the graphical depiction more, less or equally likely to get the point across than the text version?

 

Permalink | Leave a comment  »

]]>
http://files.posterous.com/user_profile_pics/837639/nirmal_mii.png http://posterous.com/users/332nJ58U Nirmal Patel Nirmal Nirmal Patel
Tue, 28 Dec 2010 19:49:00 -0800 Sit here. Stare there. http://hacketal.com/sit-here-stare-there http://hacketal.com/sit-here-stare-there

We're finally settled into our new place. My old morning routine involved having chai on our balcony while staring out over the Trader Joe's plaza in Midtown Atlanta. A few things have changed but the chai is still there.

Permalink | Leave a comment  »

]]>
http://files.posterous.com/user_profile_pics/837639/nirmal_mii.png http://posterous.com/users/332nJ58U Nirmal Patel Nirmal Nirmal Patel
Thu, 09 Dec 2010 19:07:00 -0800 Experience the impact! http://hacketal.com/experience-the-impact http://hacketal.com/experience-the-impact

Today we stopped to "Experience the Impact!" at a meteor crater spot in Arizona. See the website for all the details. One really interesting factoid is that the crater was used as a testing ground for Apollo astronauts. The scale of this meteoric divot is hard to imagine without being there but here are a few photos and a video to try and capture it.

09-cratervideo.mov Watch on Posterous

 

Permalink | Leave a comment  »

]]>
http://files.posterous.com/user_profile_pics/837639/nirmal_mii.png http://posterous.com/users/332nJ58U Nirmal Patel Nirmal Nirmal Patel