Skip to main content

Posts

Showing posts from 2013

YouTube Videos of some awesome IoT and M2M Products

The best way to introduce some one to a newly emerging technology is to show them short (about 2 minutes) but well shot videos of some new products and applications enabled by that technology. Here is a short compilation of awesome videos of awesome Internet of Things (IoT) and Machine to Machine (M2M) products.
IoT and M2M both make use of the same building blocks of technology, the only difference is that IoT products are developed within the context of home use where is M2M refers to products developed for industrial use.

Internet of Things Nest Thermostat - The learning thermostat - YouTube Video00:01:12 Nest Protect - Smoke and carbon monoxide alarm - YouTube Video00:01:37 Tile - The world's largest lost and found - YouTube Video00:02:00 Egg Minder - The smart egg tray - YouTube Video00:00:57 Electric IMP -The Egg Minder is based on this - YouTube Video00:02:00 WunderBar! - Starter kit for the Internet of Things - YouTube Video00:03:01M2M

Decreasing JPEG image file size

So friends/family have asked me time and again regarding this and it had become a major FAQ asked of me.
So here goes.

You can decrease the file size of a JPEG image in two ways: decreasing the image quality and decreasing the resolution. When you get a file whose size you want to decrease, try reducing the quality first, if that brings the file size under the threshold, you are looking for then you are done, if not, try decreasing the resolution.

Theory
The quality setting of JPEG image can vary from 0% (bad quality) to 100% (best quality) and refers to a parameter of the compression algorithm used by JPEG. Needless to say, digital cameras save images at quality setting of very near 100% and decreasing this to 80% will decrease the file size of the image by almost a third. The same process when applied to images that have come from scanners and mobile phone camera does not yield much reduction in file size - maybe those devices have already set the quality level to lower value.
In my…

Trouble installing VirtualBox extension pack on Windows 8

So, you have installed VirtualBox successfully on Windows 8 and now you are trying to install the corresponding Extension Pack but it won't install and you keep getting the error message "The installer failed with exit code 1". To fix that just enable Windows 7 compatibility mode for VBoxSVC.exe and VirtualBox.exe - both of these files would be present in C:\Program Files\Oracle\VirtualBox

(Note: The following has been tested with VirtualBox 4.3.6 on Windows 8.Thanks to Kiran Nevaskar for the solution and the screenshots)
Open Windows Explorer and browse to C:\Program Files\Oracle\VirtualBoxRight click VBoxSVC.exe and select Troubleshoot compatibilitySelect the options as per the screenshot below to enable compatibility mode for Windows 7Repeat process for VirtualBox.exeTry installing the extension pack again (http://download.virtualbox.org/virtualbox/4.3.6/Oracle_VM_VirtualBox_Extension_Pack-4.3.6-91406.vbox-extpack)






Video panning across your family tree chart (.jpg to .mp4)

Problem statement:
I have a large panoramic JPEG file (e.g. 8038 x 1145 or more) . How do I generate a video (.avi or preferably .mp4) to zoom in on a particular sub-section of the image (say 1920 x 1080 - size of my Full HD television screen) and slowly pan across the whole image?

I have been using MyHeritage's Family Tree Builder since 2008. I have their premium plus membership. Currently I have 401 individuals cataloged in my family tree. Beginning last year, we starting organizing an annual family get together of the descendants of Mr Mool Chand Kalra (My mother's father's father) . Genealogically, this basically comprised of 1/4 branch of my extended family, I have 3 other such branches each comprising of the siblings (and their descendants) of my other 3 grandparents. But this particular branch has more individuals (Mr. Mool Chand Kalra had a big family, and his children had equally big ones as well) than the other 3 branches. It is also the best catalog in my famil…

Why do we use 11.0592 MHz with 8051 variants?

Why do we use 11.0592 MHz with MCS-51 variants?
The original 8051 could be operated at a maximum frequency of 12 MHz (reference).
And 11.0592 MHz was the frequency very near the maximum operating frequency which was still a multiple of the standard baud rates.
By the way original 8051s executed a single machine cycle every 12 clocks, so at 12 MHz, the instruction execution frequency was 1 million instructions per second.What are the standard baud rates?
Baud rate refers to number of symbols sent through a channel in one second.
The standard baud rates are 2400, 4800, 9600, 19200, 38400, 57600, 115200 etc.
Baud rate is also known as symbol rate.
These are the symbol rates used in all kinds of serial communications.
The first serial communications were those that were carried over telephones lines.
(Reference: Bell 202 Modem, Acoustic Coupler)What is the relation between baud rate and bit rate?
Baud rate is number of symbols per seconds.
Bit rate is number of bits per seconds.
One symbol can repres…

Enlarging polygons (Logos saved as parts) in Cadsoft Eagle

This is for regular users of Cadsoft Eagle - a software package used for designing PCBs.
If you have been using Eagle for as long as I have been using, you most definitely know how to create part libraries, write ULPs and have come up with creative ways to spruce up your PCB's silkscreen (and schematic drawings) with nice artwork - logos, line art, figures etc.

One way you can add artwork to your PCB is by drawing a monochrome figure in paint or some other graphics program and then using the import_bmp.ulp as described in this instructable

But this method imports your art work as a raster of small squares/traces which lacks fidelity - you can note the squares when zoomed in!



Usually you would have your company logo in some vector format (PS or CDR or SVG). This vector image of the logo is what you would use in your various branding artifacts and documentation. The reason one wants vector images is that they can be enlarged or shrink without loosing fidelity.

It is only reasonable…

HelloWorld on TP-LINK TL-WR740N

Here's how to:
Flash a TP-LINK TL-WR740N WiFi router with OpenWRT (Wikipedia)Install toolchain which will run on your x86 Ubuntu computer but compile for the MIPS processor (Atheros AR9330) present inside the TP-LINK TL-WR740N.Cross-compile a hello world C program on x86.Transfer the executable to the router and run it.
Flashing the router with OpenWRT


Look on the back side of the router and figure out your model numberMine was V4.23. I looked up the corresponding entry for that model on the OpenWRT's Wiki Page for TL-WR740N here http://wiki.openwrt.org/toh/tp-link/tl-wr740n under the "Specific Install Notes" section and read:
"Hardware version 4.23 works perfectly with the unmodified Attitude Adjustment (12.09-beta) generic WR740N v4 image. The best installation method is flashing it through the stock TP-Link web interface."So I clicked on the image link in that line and downloaded the .bin file:
openwrt-ar71xx-generic-tl-wr740n-v4-squashfs-factory.binNext I co…

Measuring the hot resistance and cold resistance of Incandescent Bulbs

The Bulbs So I took 3 bulbs of 40 Watts, 60 Watts and 100 Watts respectively and measured the hot and cold resistances

I used the Philips softtone frosted lamp series.

Price:
40 Watts : Rs 20
60 Watts : Rs 20
100 Watts  : Rs 21


Cold Resistances The cold resistance readings were as follows:

40 Watts : around 97.6 Ohms
60 Watts : around 71.4 Ohms
100 Watts : around 39.5 Ohms



Hot Resistances (Calculated) Calculated values of hot resistance can be obtained using the formula: Resistance = (Voltage^2) / Power
In India the AC voltage RMS value is 230 Volts.

So we get the hot resistances as:

40W Bulb : (230*230) / 40 = 1322.5 Ohms
60W Bulb : (230*230) / 60 = 881.67 Ohms
100W Bulb : (230*230) / 100 = 529 Ohms

Hot Resistances (Measured)
To get the actual values of the hot resistance, you have to measure the current flowing through the bulb. In case of AC supply, this can be done using a clamp meter. It measures the current flowing through a wire by sensing the amount of magnetic flux induced a…

Irfanview : Auto adjust colors

I refuse to use any computer without first installing a copy of IrfanView on it. This light weight multi-format image viewer and converter has become ubiquitous amongst my circle of tech geeks - we can no longer imagine life without it. One of the specific features that I love is "Auto adjust colors".

Consider the following images. The images in the left windows are the originals and the images in the right windows are obtained by applying the "Auto adjust colors".



As you can see, "Auto adjust colors" tweaks the various parameters of the image and brings out the details which remained unseen earlier. One of the major operation that "Auto adjust colors" does is Histogram stretching. Look at the screenshot below to get a better idea of what that is all about:


Here are the original images for reference.




All in all, using this nifty feature of IrfanView makes me feel like I am performing some macho image forensics - like they show on crime series o…

Integrating FlashMagic with Keil uVision4 for P89V51RD2

If you are using P89V51RD2 microcontroller with Keil uVision4 for your project, then you might find it convenient to add FlashMagic as a Tools Menu Option within Keil.
What this will do is allow you to download the program onto P89V51RD2 using a single click from within Keil.
Prerequisites:Keil uVision4 (with the hex output option enabled for your current project)FlashMagic from http://www.flashmagictool.com/A target board wired properly to allow DTR to control RESET. If you are using FT232 (USB <> UART) then refer the connection diagram below on how to design your circuit board appropriately.

Adding FlashMagic to Tools menu:Click on "Customize Tools" option from the Tools menu.
Add a new tool by clicking on the New button. Type the tool name as "Flash Magic".Type the following lines in the "Command" and "Arguments" textboxes and click ok.
Command:
C:\Program Files (x86)\Flash Magic\fm.exe

Arguments:
DEVICE(89V51RD2, 11.0592, 0) ERASE(DEVICE, …