Tuesday, April 03, 2018

Toastmaster P5 speech : Fraudalert

Opening : 1M

    Have you ever had your wallet stolen ? Where ?

    I had my wallet stolen was around 4-5 years back, when I was in the metro heading to the railway station. I still remember that I felt the hand slip into my pocket and take out my wallet in the crowded metro and when I looked around, there were a lot of people and I could not figure out who took my wallet.

    Fellow toastmasters, today, I will tell you how to save yourself from fraud.

Body : 4M

    That day, when my wallet was stolen, I had everything in my wallet - id, all my money, credit and debit cards and even my metro card. And that made me realize that you should never keep all your eggs in the same basket. It is better to have multiple baskets. So, since that day, my wallet only has a small amount. Bank cards and id cards go into my backpack. I was so paranoid after that incident, that for some time, I had started keeping some money in my socks as well.

    Another type of fraud that is very rampant now is the paytm fraud. You get a call from an unknown number and the call would go like this.

    Caller : hello beta, this is sharmaji.

    You : (thinking) which sharma ji? Why is he calling from an unknown number?

    You : (Aloud) yes sharmaji, why are you calling from unknown number ?

    Caller : Beta, I am in mathura. My wallet and phone has been stolen, and i need money urgently. I am calling from the mobile of my hotel owner where I am staying. I have to make some payment here. Can you paytm me money on this number?

    Now, you are in doubt, whether you should paytm money or not? This can be a genuine case or can be a fraud. The best way to handle this is to call up the sharmaji that you know and verify.

    Have anyone of you ever fallen for credit card or debit card fraud by sharing your otp ? I was almost duped. Around an year back, I got a call from an unknown number asking me about an insurance policy for which i had recently paid the premium. I was told that there was some problem with the payment and it is not reflecting properly. And to verify the same, I would need to share the credit card no through which I had made the payment. So, I shared the credit card no. Next, they asked me to share the OTP. That got me thinking. Why would they need the OTP to verify. So, I told them that I have not received the OTP yet and asked them to call me back in 5 minutes. In those 5 minutes, I called up the insurance company and verified whether the call was from them or not. The learning is that never share your OTP or your PIN with anyone - no matter what.


Conclusion : 1M

    Recently, there has been a drive to link your adhaar card with almost everything - your bank account, your credit cards, mobile no. The question that you have to ask yourself is how secure is the adhaar system. Can someone who has your adhaar number extract all the details linked to it ? What happens when an unknown person has all your information ? I will leave you now with this thought. Thanks

Monday, March 19, 2018

Toastmaster P4 Speech : Ijen Crater

Opening : 1M

    Have you ever smelled burnt sulphur ? It has this sharp choking smell that hits your nose and scratches your throat and makes you want to stop breathing. Imagine breathing that smell for a long time. Dear toastmasters, I visited a volcanic sulphur mine at ijen crater during my trip to indonesia. It was a trek which I will never forget.

Body : 4M

    We got up at 12 in the night to start our drive to the base of the volcanic crater. It was a steep drive and I could feel my ears popping due to loss of air pressure. The temperature dropped drastically and it was very cold by 1pm, when we reached the base. We had a round of hot tea and started to climb the 4 km long route at 2 am. It was a very steep climb and we were soon out of breath. We were huffing and puffing like the wolf in the 3 pigs story. There were no lights and we could see only upto 2-3 steps before us.

    After climbing for almost 2 hours, suddenly I could smell the sharp acidic smell of sulphur. On looking around, i could see that I was at the peak and the path now led down into the mountain that we were climbing. The path was made of  steps cut into the mountain and was broken. And in spite of the darkness, I could see the sharp drop to my right. It was scary and smelly. My throat was raw and scratchy. I had a gas mask, but putting it on the face made me feel suffocated and clouded my spectacles.

    After climbing down, we reached the base of the crater. Where we saw the main attraction. We could see electric blue fire coming out of the mine at certain places. We were told that it happens due to sulphur gas catching fire at high temperatures. I tried a lot, but could not get a clear photo of the fire.

    We climbed back the scary path holding and helping each other. All this time, we could see miners going to and fro carrying heavy buckets full of sulphur. We trekked further on the rim of the crater and came to the sunrise point. As the sun came up, I saw the beauty of the crater. I was at the edge of the crater with the sun in front of me and the beautiful sulphur lake behind me. I stood staring at the lake, mesmerised by the view.  The lake is in the form of a huge circle 1 km wide. I could see the complete lake inside the crater. The lake is turquoise in colour. Some part of the lake was covered in yellow smoke of burning sulphur and another small part was covered in floating white fog. As the sun rose, the fog started clearing and we could see thick yellow smoke coming out of the mine.

Conclusion : 1M

    The lake is said to be very toxic. We also saw the path we took to visit the mine. It was then we realized why we were taken in the dark. The way was so twisted and dangerous, that we would not have dared to climbed down to the mine, if we had seen the complete picture. Overall the view was worth the effort. It is rightly said that the best view comes after the hardest climb.

Wednesday, March 14, 2018

Toastmaster P3 : Why travel ?

Do you think it is a pain to travel ? First getting bus, train or plane tickets to your desired destination. Then packing your bags and moving from one location to another. All this to see the same earth, sky and water which you can see anywhere. Let me explain the benefits of travelling, which should persuade and inspire you to travel more.

Travelling improves your social and communication skills. When we travel, we meet different types of people, who speak different languages and have different cultural background. Their way to greet can vary from a handshake to namaste to something else. Interesting "conversations" happen when you are in a foreign country where you do not understand the language and are forced to use sign language for as simple as asking directions. When i went to indonesia recently it was very difficult for me to understand their food menu. So, i pointed out a dish labelled "nasi goreng" and the waiter explained to me via sign language that it has something to do with rice. I generally do not have any reservations with food, but uncooked or partially cooked food is not something that I can have. I ordered "nasi goreng" and was surprised to find that it was simple (pause) "fried rice". It became my favourite dish through out my stay and travel. The excitement and joy of communicating with someone without using speech(pause) is something that cannot be explained in words.

Travelling also enhances your tolerance for uncertainty. Have you ever been in a situation where you have missed a bus or a train or a flight? During my trip to leh laddakh, our group was stuck at the second highest motorable pass in the world called TAGLANGLA at the height of 17582 feet. It was extremely cold outside and we did not have any food or water. All we had was a bottle of (pause) old monk . That night we saw truck drivers cooking within their trucks. It was so cold at night, that we did not have the courage to go out, even to ask for food. We survived on the single bottle of old monk. I learned that I should always carry some chips and peanuts to go along with the bottle. When we face uncertain situations, our mind is forced to think differently to find the way out.  That joy of finding your way out of uncertain situations(pause) is something that cannot be explained in words.

And finally, you get lifelong memories. That night(pause) at TAGLANGLA is something that all of us will remember. On our way to leh, we travelled on a road with a wall of ice on both sides. I can never forget that drive. And I still cannot figure out the effort it took to dig that road from under so much ice. Nor can I forget the thrill of watching a live volcano from its crater. Or the time spent with my kids building a sand castle on the beach. These memories get imprinted in your brain and come back sharp and clear. The joy of remembering and recalling those moments(pause) is something that cannot be explained in words.

Inspite of the trouble that we go through in making arrangements and moving ourselves from one location to another, the experiences that we gain far outweight the trouble that we take. We can not only improve our communication and social skills, but also improve our capacity to overcome uncertain situations. And the memories that we get last for eternity. To conclude, the joy of travelling(pause) is something that cannot be explained in words.

Monday, March 05, 2018

Toastmaster P2 : E-commerce vs Brick & Mortar Stores

    Can I have a show of hands on how many of us prefer to shop online?
    And how many of us prefer to go out to a store to shop?
    Would huge brands like amazon or flipkart let the brick & mortar shops survive ?
    Or would these huge brands eventually run out of investor funds and shut down ?
Good morning fellow toastmasters, let us try to foresee who would survive in a war of E-commerce vs Brick and Mortar stores.
Let me tell you a story   

        During my wedding, my better half wanted to get a lehenga of my choice. I was surprised because for me there are only 6 colors - red, yellow, orange, pink, blue and green, whereas her eyes can see multiple colors in each of these color.) For example she could see multiple shades of red - light red, dark red, blood red, maroon. Similarly for green there is light green, grass green, dark green, lime green, etc. I think i spent at least 2 weekends roaming with her in chandani bazaar and karol bagh. I cannot even count the number of shops we visited. And i know that i was of little or no help to her. Now, if we had flipkart or amazon in those days, it would have been a lot easier for me.
    There are people who want to see, touch and feel a product before purchasing. Also there are people who want to take the product home immediately. These are the two downfalls of shopping online. You cannot know how the cloth will feel. So online shopping for electronics and electricals is easier. Because you do not need to touch and feel the product. You know that all products that belong to a model will be similar. Shopping online for footwear is a bit dicey. You know the size you wear, but different brands may have different sizes and there are cases in which for one brand you would be wearing a size 7 whereas for another brand it would be size 8.
    What prompts us to shop online is the large amount of inventory and the discounts that are available online. And the luxury of having a product delivered home without stepping out of the house. Now-a-days, returns are also easier. It takes time, but then there are some benefits as well.
    The question that comes to our mind is what is required to run these online or offline stores?
    Both require rent and electricity. Offline store would pay rent and electricity for their shop where they put their products on display. Whereas e-commerce sites pay rent where they have their offices. They also pay a lot of rent on warehouses where they hold their inventory, whereas offline stores do not require such large warehouses. But then they have limited variety, whereas online sites have huge variety. Offline stores pay small salaries to the sales team they have, whereas online stores have to maintain a highly paid technical team and computers - servers. Offline stores do marketing locally so the marketing expenses are low  as compared to online stores which have to do marketing at a countrywide scale which is very expensive.
    If we look at the sales figures, online stores have a conversion rate of 2-3%. That is out of 100 people visiting the site only 2 make a purchase. This can go up to 8% with proper marketing, discounts and intelligent listing of products. On the other hand,  offline stores have a conversion rate of 15-30% which depends mainly on the season and discounts. So out of 100 people walking into the store, at least 15 make a purchase.
    If we look at both of them, ecommerce stores have made it easier for people to shop. But if you have time and want to feel the product before you buy, you can still walk into a store and purchase it. Which tells us that both online and offline stores would co-exist. E-commerce sites have realized that it takes huge effort to maintain a huge inventory. And in order to cut costs, they are moving to marketplace model. Where they would compliment the sales of offline stores. In a marketplace model, the online stores will eventually get product from an offline store and deliver it to the customer. Nobody can predict the future. We can only speculate it.

Toastmaster PI Speech : Story of love

I still remember the day when I was small boy and I saw it for the first time. It was love at first sight. It had blinking eyes and all 10 numbers. Yes it was the casio calculator watch which did addition, subtraction, multiplication and division on your wrist. I wanted it so badly. But it was very expensive and also not allowed in school. The casio calculator watch was my first love. And also my first heart break after my parents did not allow it to be a part of my life.

Good morning fellow toast masters. Today I will be telling you the story of my love.

Some time during my childhood, i realized that I understood machines better than I understand humans.

I remember my first interaction with computers during my 8th standard in my School in Baroda, Gujarat. Our lab had the latest intel 286 machines. Now these machines came without hard drives. To boot the machines, we used to insert a 5 inch floppy into their floppy drive. And on booting, we used to get a black screen with the DOS prompt. There was no windows in those days. My favourite games were paratrooper and chess. I remember that in chess, for each move I made the computer used to take 15-30 minutes to calculate its next move. And since the computer period was of 1 hour only, I never completed a game of chess in school.

I got my first computer when I joined Engineering in Computer Science branch. It was the latest 166 MHz intel pentium processor with 2 MB of RAM and 1 GB of hard drive. Almost 1000 times slower than what we have on our mobiles these days. But then those were the days when Bill Gates had said that 640 kb should be enough for any one. And, having such a machine, I was on cloud 9. So, during college days, I spent my nights playing Age of empires instead of studying. And as a result, when I passed out in 2001, I was one of the very few graduates, who were not placed during campus placements. Thanks to my seniors, I was able to join as a software engineer in a small company in Delhi. Here I was exposed to the world of online gaming. I used to spend a lot of time in office - around 10-12 hours daily. Working a lot during the first 8 hours and spending time playing online games after my manager went home. I was very happy.

But then, the greatest tragedy of my life happened - I got married in 2007. It was difficult for me to grasp that talking to my wife is more important than playing video games. One year later, i could not take it any more and got my first custom built desktop with a very expensive graphics card to play high end games. But all good times come to an end. My first kid was born in 2010 and I had to spend time feeding her, changing diapers and with multiple trips to doctor for vaccinations. I did not learn from my mistake and got my second kid in 2012. They are 7 and 4 years old now. My passion for games came alive last year when my 2nd kid started going to school. I had to rebuild my computer last year to play the latest games. Imagine falling in love again.

In addition to computer games, I love travelling. I hope to travel to all the different corners of this world some day.

To conclude, I am a very passionate computer gamer and a traveller. In addition to this, I am a father, a husband and currently a toast master.

Saturday, August 19, 2017

A rant on Uber and Ola

Uber and ola have been in India for a long time now. Why do I want to rant about them now ? Read on. I promise it is interesting.

What happened with Uber ?

Uber keeps on sending me promo codes, but whenever I try to use them, i am told that the code is not valid for me. I used to ignore it in the past. But last week, when I was planning my ride, i thought of asking uber - why do they send me promo codes which are useless to me. Maybe they have a bug and I since I point it out to them, I may get some goodies from them. On asking about the same, I was told that promos have been deactivated on my account due to suspicious activities. Now, if i had done some "suspicious activities", i would have been ok with this response. But, being flagged without doing anything is not something I would look forward to.

After multiple to and fro, I realized, that it is some customer support typing the same message with different word combinations - as he is not capable of doing anything else. Here is a the complete dialogue - with jumbled words conveying the same meaning repeatedly.


We understand the disappointment this may have caused. Unfortunately, since the promotions on your account have been disabled by the system, we would not be able to honor any promotions on your account going forward.

Though you may receive notifications regarding the on-going promotions, please know that will not be able to apply them on your account.

Rest assured, you will still be able to request for rides from your account as usual.

Hope this clarifies.

Sent by SB on Saturday, August 12, 2017 at 2:34:36 PM
Continue this conversation by replying to this email or going to help in your Uber app.
My earlier query still remains unanswered
Sent by XXXX K. on Saturday, August 12, 2017 at 2:30:58 PM

Happy to explain. Uber reserves the right to adjudge and verify the eligibility criteria of any rider receiving a promotion discount.

Unfortunately, since your account has been flagged for violation of Uber's Terms of Service we will not be able to honor any promotions on your account.

Though you might have received a notification regarding the on-going promotion, it would only apply on the account when the usage is within these Terms and Conditions.

Appreciate your understanding!
Sent by madapana a. on Saturday, August 12, 2017 at 2:27:44 PM
My query still remains unresolved
Sent by XXXX K. on Saturday, August 12, 2017 at 2:16:53 PM

I am afraid I do not have further info as this is a system generated flag with no manual intervention in the process.

Our system is the same across the 300+ cities that we operate in. It flags suspicious accounts and disables the application of promotions on these accounts and in some cases even cuts off access to these accounts.

You will appreciate that these security features need to be built in to prevent misuse of our services and to prevent users from creating accounts for the sole purpose of taking free rides. You might not have had that intention, however, the system cannot differentiate between the two situations and frankly, there really is no way for anyone else to distinguish the two either.

I am afraid I really cannot be of any more help with this than I already have.
Sent by PS on Saturday, August 12, 2017 at 2:15:19 PM
So, what can I do so that your highly advanced system can allow me to use promos that your another advanced system is sending across? I have been using uber regularly. But this irritating attitude will force me to use other better services which will not have such advanced systems creating chaos with the end user.
Sent by XXXX K. on Saturday, August 12, 2017 at 2:13:53 PM

Thanks for letting us know. Happy to help.

I am afraid I do not have further information, as this is a system generated flag with no manual intervention in the process.

Our system is the same across the 300+ cities that we operate in. It flags suspicious accounts and disables the application of promotions on these accounts and in some cases even cuts off access to these accounts.

You will appreciate that these security features need to be built to prevent misuse of our services and to prevent users from creating accounts for the sole purpose of taking free rides. You might not have had that intention, however, the system cannot differentiate between the two situations and frankly, there really is no way for anyone else to distinguish the two either.

I am afraid I really cannot be any more help with this than I already have.
Sent by Bhavana S. on Saturday, August 12, 2017 at 11:45:40 AM
Can you elaborate on this? If the system has disabled promotions, why do I still get offers? Why has the system disabled promotions on my account?
Sent by XXXX K. on Saturday, August 12, 2017 at 11:44:00 AM

I sincerely apologize for the inconvenience caused. I checked your account and it appears that the use of promotions on your account does not comply with Uber's terms and condition. Consequently, the system has disabled promotions on your account.

However, please note that only the use of promotions has been disabled and your account continues to remain in good standing. This means you will be able to request rides as usual.

Appreciate your understanding in this regard.
Sent by Ajaj K. on Saturday, August 12, 2017 at 11:21:30 AM
Share Details : I am unable to use this promo code sent to me. Dear Rider, use code: OCCASIONS if you haven't already & get Rs. 50 off 10 rides on uberGO. Valid only for you, in NCR till Sun, 13 Aug. I get an error that the promo code is invalid.

What happened with ola ?

The above incident got me thinking. Maybe i should give ola a fair chance. So, after being with uber for a long time, I installed ola. And since, i wanted to use the cashless riding promo, I loaded some cash in my ola money. I still don't understand why Ola uses ola money. Why cant they simply integrate with already available wallets like Paytm or Mobikwik or something else.

Upon getting down at the airport, I booked an ola share. Surprisingly, at airport surcharge is always applicable, so you would get uber/ola at 2-3 times the original fare. And I was waiting at the specified pillar hoping that the car will arrive. After 5 minutes, when, i saw that the car is still not moving, I called up the driver and he told me that he is waiting in departures dropoff while I am downstairs at the arrival pickup. And since it may take him a lot of time and money (re-issue of entry ticket) I should come up to him.

So, I climbed up a very long flight for stairs and reached the departure. And sat inside the car. He requested OTP from me and I gave it to him. And he started the ride. Since my majority of my payment was via olamoney, only a very small amount (Rs 70) was coming as cash payment. Here is how the dialogue went.

Driver : You will pay me only 70 for a ride to indirapuram (my destination)
Me : Yes, rest of the payment is cashless via ola money
Driver : I cannot go to indirapuram in only 70 rs
Me : But, I am not paying you. I am paying ola and they have already deducted 700 from my ola money.
Driver : Please get down, I will not go in 70 rs.
Me : Ok.

I got down and called up ola customer care and narrated the incident.

Me : (Narrating the incident)
Customer care : Sir, we are really sorry for the incident. We will talk to the driver partner.
Me : But, why my ola money was deducted at the beginning of the ride ?
Customer care : Sir, I am sending a link via sms. Please click on the link and the money will be credited back instantly.
Me : Ok

I waited for the SMS for 5 minutes and called again. Again repeating the above conversation.

Me : But the last person i spoke to told me that the sms has been sent. I have not received it. Can you resend it ?
Customer care : Sir, i have just resent the SMS. You will receive it shortly.
Me : Ok

Now, I started cursing myself for using cashless mode. And thought of trying airport metro. Always try to avoid metro as it is very crowded. And carrying a backpack into a crowded metro is not very easy. Did not get any SMS, so called again after 10 minutes.

Me : SMS has been sent to me twice, but i have not received it.
Customer care : Sir, i can see that there is a problem with your account which is why the SMS has not gone from our system.
Me (thinking) : Today is a bad day. Even my newly created account is getting flagged. Maybe there is some problem with my name.
Customer care : sir, you will have to wait for 48 hours for the amount to be credited back to your ola money.
Me : Ok. What should I do for 48 hours ? Should I use uber ?
customer care : Sir, you can again load money into your ola money account
Me (thinking) : Do I look like a fool ? What if you do not refund my money even after 48 hours ?
Me : But I do not have any more money to give to ola.
Customer care : Sir, as per the terms and conditions, your money will be credited back in 48 hours ?
Me : Ok

After being stranded for 30 minutes, I am left without any cab or any money. And i am being shown the terms and conditions - which no-one ever reads. To hell with ola. I get out of the airport metro, book an uber and go home. Wrote a strong mail to ola to refund me the money from olamoney to my original account.

But, uber is not perfect

I have had many rides with Uber, and there are 2 instances where I faced major issues. One of which was handled well by Uber.

In the first incident, I was to travel to Gurgaon from Noida. It was raining and the uber driver simply refused to go to such a distant place. Also, he refused to cancel the ride and asked me to do the same. When I cancelled the ride, I was shown a cancellation charge. On talking with Uber, the same was refunded.

Second incident happened when I was in Indonesia. Indonesia has another uber competitor - grab - which surprisingly is a lot better than uber. Prices are extremely low and grab taxis are very easily available. Since, I have been using Uber in India, I thought of using the same in Indonesia. Some driver accepted the ride and called me up. Due to language issues, we were not able to talk and asked the hotel valet to convey our location to the person. After waiting for 10 minutes, the driver cancelled the ride. And i was charged the cancellation fare. Which I came to know a long time later. Though Uber waived off the fare later.

Another issue with Uber is the outstanding fare. Uber would prompt you to pay your previous due when you are at the final stage of booking. This is very inconvenient. An alert about outstanding fares and an easier way to pay it is something I would look forward to.

  • Use uber for cashless integration with paytm. If you are unable to use your promo code, Uber thinks you can misuse their system and has flagged you for suspicious activity.
  • Use ola but only via cash. Do not try cashless with ola.
  • Haggle with auto and taxi drivers, if you do not find uber or ola nearby.

Tuesday, January 26, 2016

Build your own in house weather station

We all use a smartphone and most of the smart phones generally have a weather app. Which shows the weather for your city. But do you wonder what would be the weather like inside your house or inside your room? The "in house weather station" monitors the weather inside your house. With its help, you can get a report of what the weather is outside and compare it with the weather inside. Here we are monitoring only two parameters - temerature and humidity. After all the hard work, you would get an output similar to this

Tools :
  • Raspberry pi 2 with raspbian installed
  • DHT22 sensor
  • 10k resistor
  • Male to female jumper wires
  • Breadboard
  • Wires for making breadboard connections
I would not go in depth on how to setup the DHT22 sensor. Here are the instructions that I followed.


I was stuck with the resistor piece as I did not have a 10K resistor. So I added two 6k resistors in series, taking the total resistance to 12k (6k+6k).

Here is how my setup looks

W.r.t the software, I tried using the Adafruit code, but it felt more comfortable using the pigpio code after running the pigpiod daemon. I am still getting some errors when i call the s.cancel() and pi.stop() functions. But the rest of the code works.

To get the external temperature and humidity, I signed up with openweather and got their api. There is a python library pyowm which provides an implementation for openweather. So, I got the humidity and temperature of my city from openweather. And i pushed the data - external humidity & temperature and internal humidity & temperature into elasticsearch which I was running on my raspberry pi.

Looking at the limited resources available on the pi, both in terms of disk and memory, I did some tweaking in elasticsearch, so that It did not hog down my raspberry pi.

I restricted the heap size of elasticsearch to 256MB by adding the following options in the ./bin/elasticsearch script.


Since, I had to access my elasicsearch via the raspberry pi's ip address, i changed the host to bind to the ip address instead of localhost. Also, looking at the disk constraints, I limited the number of shards & replicas to 1. Here are the configuration lines in ./config/elasticsearch.yml

index.number_of_shards: 1
index.number_of_replicas: 1

Here is the script which pulls data from openweather and gets data from my DHT22 sensor and pushes it into elasticsearch.

The interesting thing to note in the graph is that though there is change in the external temperature and humidity, the internal temperature and humidity does not change much.

Saturday, November 28, 2015

Use your smartphone as a GUI display for your pi

With a very simple hack, we can use our smartphone as a GUI display for your raspberry pi. This can work over remotely and there is not HDMI or any other connector required to connect your smartphone to your pi.

There are a few apps that you would require on your smartphone. Download and install

Xserver XSDL

Xserver XSDL is a xserver which can be run on your smartphone. Whereas connectbot is a simple ssh client for connecting to your raspberry pi via ssh. The trick here is to run the Xserver on your smartphone. Ssh to your pi and tell your pi to forward the display to the Xserver running on your smartphone.

Let us see the configurations that need to be verified on the pi. Ssh to your raspberry pi over the network and check the following configuration options in these files.


AllowTcpForwarding yes
X11Forwarding yes
X11DisplayOffset 10


ForwardX11 yes
ForwardX11Trusted yes

If these configuration options are commented out, simply uncomment them. Else add them and restart your ssh server on your pi.

$ sudo service ssh restart

Now start the app Xserver XSDL on your smart phone. It may download a set of fonts and will then ask you to run some commands on your linux PC. The Xserver starts running on port 6000. Now, we need to forward the display of pi to our smartphone.

Go back to the ssh connection on your smartphone and run these commands.

$ export DISPLAY=           
$ export PULSE_SERVER=tcp:

My smartphone is running on the ip And i am forwarding the display directly to the Xserver running on port 6000.
This is insecure as the port forwarding is not happening over ssh but directly from the pi to the smartphone. But if you are on a local network, it should not matter.

Now simply start your lxde desktop environment on the ssh connection. Execute the following command on the ssh connection.

$ startlxde

And bingo...

It is not very comfortable for working as the mouse pointer is difficult to catch and click. But if you have an old smartphone or tablet lying around, you can use it as a display - running a smart photo frame or a hanging smart calendar.

Monday, November 09, 2015

Script to update godaddy dns A record

Recently, I have setup my raspberry pi as a download machine. The aim was to be able to access the machine from anywhere and be able to add files to download. Now, since the machine is connected via airtel broadband, it is bound to go down and come up as and when the electricity in my location does.

Everytime, when the machine came up, i would be having a different public ip address to access the machine as my ADSL modem+router would also go down.

At first, i setup a cron to be run at boot time which would give me the public ip address.

The corresponding cron entry is
@reboot /home/pi/progs/godaddy.py

I also created a dns entry to access the machine. And then wrote a script to update the dns record in godaddy whenever the machine reboots. Here is the script.

Now whenever my pi reboots, it checks and updates the corresponding DNS record at godaddy. And i can ssh my machine from anywhere.

Tuesday, January 20, 2015

Ecommerce review : Amazon.in shopping experience

I use ecommerce extensively. All my stuff - from clothes to shoes to electronics to groceries are delivered to my doorstep. The good point about ecommerce is that it saves you from the headache of driving down to the store, parking, standing in a queue to pay for your purchase, and hauling the stuff back to your place. And I use multiple shopping sites for getting my stuff:
Flipkart for books & electronics
Firstcry for diapers & other stuff for kids
Zovi, jabong, myntra in order of preference for clothes and shoes
Peopleeasy for groceries.

I try to avoid shopping on amazon. Reason being that the delivery times are too long. Also there is no quality control from amazon. My last order from amazon was a pair of school shoes for my kid which were defective. Since it was not "fulfilled by amazon" the only option I had was to send it back by a courier and wait for 15-30 days for a refund or go to a nearby cobbler and get the defect fixed. I chose the later. It costed me an additional amount, but saved me from the hassles of refund and re-order.

After that experience, I decided that the only option why I would order from amazon was when the product will be "amazon fulfilled".

I was looking for a coffee maker and found one on flipkart. But flipkart will not deliver it to my pin code. I have never tried snapdeal or paytm but have heard first hand horror stories from people who have used it. The only option was amazon which had the exact model that I was looking for and that too with the "amazon fulfilled" label. The delivery time was 10 days, but still I went ahead and ordered. I still cannot figure out why it takes 10 days for amazon to deliver while flipkart delivers in 3-4 days. And zovi & jabong deliver in 1-2 days. Zovi delivers from bangalore and that too in 2 days max.

When I got a mail that my package has been dispatched by india post, I was a bit astonished. What role does india post play in amazon fulfilled orders. I believe it is the cheapest option. But has service and reliability issues. I kept a track of the package on india post web site as amazon did not update the tracking details on its website frequently.

Finally after 7 days the package arrived in the post office nearest to me. I was hoping that I will get the order the next day. But what happened the next day shook my perception of e-commerce.

I got a call from the post office asking me to pick up the package from there. I was like - what??? And the person on the other end said that it is too big for him to deliver and cut off the phone. I connected up with amazon customer support and was given the assurance that I will get the package on my doorstep next day. Here is the actual conversation:

10:00 AM IST Amazon(Amazon): Thanks for contacting Amazon.in customer service. 
My name is Vijay. 
10:00 AM IST Jayant kumar : hi Vijay, 
10:00 AM IST Amazon(Amazon): Hi! Jayant 
10:01 AM IST Jayant kumar : i got a call from india post telling me that my package is at their facility and i have to pick it up ...
If i have to go out pick up a package, then why order online, wait for 15 days and then pick it up
i can simply go out and buy it from a store
10:02 AM IST Jayant kumar : is this what you call e-shopping ?
10:02 AM IST Amazon(Amazon): I really do apologize for the inconvenience this may have caused you.
10:02 AM IST Jayant kumar : Also, please let me know why this order is being delivered by india post, instead of amazon ?
10:02 AM IST Amazon(Amazon): Let me check what best I can do for you.
10:03 AM IST Amazon(Amazon): I will surely let you know about the same.
10:03 AM IST Jayant kumar : i ordered it because it said that this will be fulfilled by amazon
10:04 AM IST Amazon(Amazon): Jayant, I really appreciate for doing business with us.
10:04 AM IST Jayant kumar : and not india post - the worst courier service in the country
10:05 AM IST Amazon(Amazon): I have contacted the courier partner and have instructed them to deliver to your door step.
10:05 AM IST Jayant kumar : I was told that since the package is "big" it may be broken if delivered to my door step
in case the package is broken, i hope amazon will take it back...
10:06 AM IST Amazon(Amazon): And regarding the courier partner, it is automatically selected by the system and we do not have the option to select the same. 
But we try to dispatch through Amazon service as much as we can.
10:07 AM IST Jayant kumar : Since this package is fulfilled by amazon, please explain how?
10:07 AM IST Amazon(Amazon): Related to broken item, we assure you it will be taken back in such scenarios and will issue a full refund.
10:08 AM IST Jayant kumar : so, fulfilled by amazon does not mean amazon delivery service ?
10:09 AM IST Amazon(Amazon): Amazon Fulfilled guarantees the product to be in a perfect condition and also assures if any defects found customer can return it back within the return window and we will issue a full refund.
10:10 AM IST Amazon(Amazon): But, as I have stated earlier the courier does get selected automatically by the system.
10:10 AM IST Jayant kumar : ok
so, will this be delivered today ?
10:11 AM IST Jayant kumar : since it is at the hub nearest to my place?
10:11 AM IST Amazon(Amazon): I have contacted the courier for the delivery as soon as possible.
10:12 AM IST Jayant kumar : thanks
10:12 AM IST Amazon(Amazon): You are most welcome Jayant.
Is there anything else I may assist you with?
10:13 AM IST Jayant kumar : no
10:13 AM IST Amazon(Amazon): It was a pleasure assisting a valued customer as you.
Hope to see you soon.
10:13 AM IST Jayant kumar : looking forward to ordering more with confidence from amazon
10:13 AM IST Amazon(Amazon): Thank you for contacting Amazon Customer Service.
Have a Wonderful time and day ahead.
10:14 AM IST Amazon(Amazon): I assure, you will not face any such issue in the future. 

Note the final line - I was hoping that this problem is now resolved and was looking forward to the package.

What happened the next day is that in the morning, I got a call from the postman. Again asking me to come and collect the package. It seems that amazon customer service did not take any action on the issue raised by me and has given me false assurance. The two options available to me were to either cancel the order and wait for refund and go out and purchase from the market or go ahead and pick the package from india post. I chose the later - being the easier option of the two. The reason given by the postman was genuine that he cannot deliver a big package on his cycle to which I could not come up with a counter argument.

I was told that the post office opens from 10 am to 5 pm and knowing how government officials work - allowing them their tea, lunch and other breaks, I planned to visit the post office around 3 pm. When they would be done with their lunch and after lunch chit chat. When I reached there, I had to enquire around 4-5 people but was not able to trace where my package was. Everyone was busy doing their own work. So, I called up the postman and told him to connect me to the person who can locate and hand over the package to me. Finally after asking everyone's name and making the person talk with the postman, I was able to take delivery of the package.

So, there is me now carrying 2 big boxes in front of me from the post office to the car and from the car to my flat. All the while people staring at the amazon.in label on the boxes I am carrying and trying to figure if I am the guy who delivers for amazon. They must be figuring the ad of amazon where the delivery guy delivers the package with a smile. I, on the other hand was only concerned if I would encounter anyone who has faced similar fate by amazon and try to engage my as an amazon employee.

By luck the products were ok. I have no idea what will happen if I had to opt for an exchange or refund. If delivery is suoh a hassle, refund / exchange can be non existent. Also I cannot figure out how amazon plans to compete with other sites. When even small sites like zovi outsmart amazon on delivery. I would not be ordering from amazon till I hear some positive reviews.