Thursday, September 23, 2010

Gandhi quotes

If I want to deprive you of your watch, I shall certainly have to fight for it; if I want to buy your watch, I shall have to pay for it; and if I want a gift, I shall have to plead for it; and, according to the means I employ, the watch is stolen property, my own property, or a donation.

I do believe that, where there is only a choice between cowardice and violence, I would advise violence..

I believe that nonviolence is infinitely superior to violence, forgiveness is more manly than punishment.

Wednesday, September 22, 2010

Chinese words for vegetarian

Chinese words for vegetarian

symbol for veg. food in taiwan

If you don't speak or read Chinese, there are two common symbols that mark vegetarian food. One is the lotus flower, and the other is the swastika. The characters for vegetarian food (su4 shi2) look like this: 素食

Monday, September 20, 2010

Jains

Jains not only strictly prohibit their members from eating any animal meat, but they go a step further. They don't allow root vegetables, such as onions and potatoes, lest some germs be attached to them.

Principles for Satyagrahis

Principles for Satyagrahis

Gandhi envisioned satyagraha as not only a tactic to be used in acute political struggle, but as a universal solvent for injustice and harm. He felt that it was equally applicable to large-scale political struggle and to one-on-one interpersonal conflicts and that it should be taught to everyone.[17]

He founded the Sabarmati Ashram to teach satyagraha. He asked satyagrahis to follow the following principles (Yamas described in Yoga Sutra):[18]

  1. Nonviolence (ahimsa)
  2. Truth — this includes honesty, but goes beyond it to mean living fully in accord with and in devotion to that which is true
  3. Non-stealing
  4. Chastity (brahmacharya) — this includes sexual chastity, but also the subordination of other sensual desires to the primary devotion to truth
  5. Non-possession (not the same as poverty)
  6. Body-labor or bread-labor
  7. Control of the palate
  8. Fearlessness
  9. Equal respect for all religions
  10. Economic strategy such as boycotts (swadeshi)
  11. Freedom from untouchability

On another occasion, he listed seven rules as "essential for every Satyagrahi in India":[19]

  1. must have a living faith in God
  2. must believe in truth and non-violence and have faith in the inherent goodness of human nature which he expects to evoke by suffering in the satyagraha effort
  3. must be leading a chaste life, and be willing to die or lose all his possessions
  4. must be a habitual khadi wearer and spinner
  5. must abstain from alcohol and other intoxicants
  6. must willingly carry out all the rules of discipline that are issued
  7. must obey the jail rules unless they are specially devised to hurt his self respect

Rules for satyagraha campaigns

Gandhi proposed a series of rules for satyagrahis to follow in a resistance campaign:[12]

  1. harbour no anger
  2. suffer the anger of the opponent
  3. never retaliate to assaults or punishment; but do not submit, out of fear of punishment or assault, to an order given in anger
  4. voluntarily submit to arrest or confiscation of your own property
  5. if you are a trustee of property, defend that property (non-violently) from confiscation with your life
  6. do not curse or swear
  7. do not insult the opponent
  8. neither salute nor insult the flag of your opponent or your opponent's leaders
  9. if anyone attempts to insult or assault your opponent, defend your opponent (non-violently) with your life
  10. as a prisoner, behave courteously and obey prison regulations (except any that are contrary to self-respect)
  11. as a prisoner, do not ask for special favourable treatment
  12. as a prisoner, do not fast in an attempt to gain conveniences whose deprivation does not involve any injury to your self-respect
  13. joyfully obey the orders of the leaders of the civil disobedience action
  14. do not pick and choose amongst the orders you obey; if you find the action as a whole improper or immoral, sever your connection with the action entirely
  15. do not make your participation conditional on your comrades taking care of your dependents while you are engaging in the campaign or are in prison; do not expect them to provide such support
  16. do not become a cause of communal quarrels
  17. do not take sides in such quarrels, but assist only that party which is demonstrably in the right; in the case of inter-religious conflict, give your life to protect (non-violently) those in danger on either side
  18. avoid occasions that may give rise to communal quarrels
  19. do not take part in processions that would wound the religious sensibilities of any community

Tuesday, August 31, 2010

எது எதுக்கோ ட்ரையல் பார்க்கிறீர்களே , பாடையில் ஏறி படுத்து பார்த்திருக்கிறீர்களா?

எது எதுக்கோ ட்ரையல் பார்க்கிறீர்களே , பாடையில் ஏறி படுத்து பார்த்திருக்கிறீர்களா?

Thursday, August 05, 2010

Japanese

Japanese Saying :- If one can do it, U too can do it!
If none can do it, U must do it!


Wednesday, July 14, 2010

Tamil books

அகத்தியர் பனிரெண்டாயிரம்
போகர் ஏழாயிரம்

Tuesday, June 29, 2010

Bash shell shortcuts

Bash shell shortcuts

Bash, which is the default shell in Linux contains a whole lot of key bindings which makes it really easy to use . The most commonly used shortcuts are listed below :

____________CTRL Key Bound_____________
Ctrl + a - Jump to the start of the line
Ctrl + b - Move back a char
Ctrl + c - Terminate the command
Ctrl + d - Delete from under the cursor
Ctrl + e - Jump to the end of the line
Ctrl + f - Move forward a char
Ctrl + k - Delete to EOL
Ctrl + l - Clear the screen
Ctrl + r - Search the history backwards
Ctrl + R - Search the history backwards with multi occurrence
Ctrl + u - Delete backward from cursor
Ctrl + xx - Move between EOL and current cursor position
Ctrl + x @ - Show possible hostname completions
Ctrl + z - Suspend/ Stop the command
____________ALT Key Bound___________
Alt + < - Move to the first line in the history
Alt + > - Move to the last line in the history
Alt + ? - Show current completion list
Alt + * - Insert all possible completions
Alt + / - Attempt to complete filename
Alt + . - Yank last argument to previous command
Alt + b - Move backward
Alt + c - Capitalize the word
Alt + d - Delete word
Alt + f - Move forward
Alt + l - Make word lowercase
Alt + n - Search the history forwards non-incremental
Alt + p - Search the history backwards non-incremental
Alt + r - Recall command
Alt + t - Move words around
Alt + u - Make word uppercase
Alt + back-space - Delete backward from cursor

----------------More Special Keybindings-------------------

Here "2T" means Press TAB twice

$ 2T - All available commands(common)
$ (string)2T - All available commands starting with (string)
$ /2T - Entire directory structure including Hidden one
$ 2T - Only Sub Dirs inside including Hidden one
$ *2T - Only Sub Dirs inside without Hidden one
$ ~2T - All Present Users on system from "/etc/passwd"
$ $2T - All Sys variables
$ @2T - Entries from "/etc/hosts"
$ =2T - Output like ls or dir

Friday, June 25, 2010

Present

Today is a gift, that is why it is called as 'The present'


Monday, June 21, 2010

How to make use of find to search files ??

find  ./ -name 'alsa*'

This will displays the filenames started with 'alsa' in a current directory


How to use grep command ??

To search for the given PATTERN in a current directory recursively :


grep -r PATTERN   DIR_PATH 

grep -r  init()  ./

it will displays the files which are having init() fn.


grep -r  init()  ./  -n

it will displays the files with init() fn and its occurence line number too...



 

How 2 Unpack/pack the android images:

How 2 Unpack the android images:
---------------------------------
1. ./unyaffs system.img  (unpack the yaffs file system.img) yaffs - file system
2.gunzip -c ramdisk.img |cpio -i
3../unpack-bootimg.pl boot.img

To Pack System.img:
---------------------
mkyaffs2image tool

./mkyaffs2image ./system (folder) system.img

will creates the system.img from system folder.

Tuesday, June 15, 2010

What good will they do you

However many holy words you read,

However many you speak,

What good will they do you

If you do not act upon them?

Are you a shepherd

Who counts another man's sheep,

Never sharing the way?

Read as few words as you like,

And speak fewer.

But act upon the dharma.

Give up the old ways -

Passion, enmity, folly.

Know the truth and find peace.

Share the way.

success

SUCCESS IS NOT TO BE EQUATED WITH GOODNESS.To believe in yourself and to follow your dreams, to have goals in life and a drive to succeed, and to surround yourself with the things and the people that make you happy----this is what we can call it as real success.

80/20 principle

 80/20 principle which  lays down that in an any organisation 80 percent of the work was done by 20 percent people and 20 percent work done by 80 percent people. "

Monday, June 07, 2010

what she is to me

what she is to me ? Words cannot express ...

Tuesday, June 01, 2010

hero

A hero never chooses his destiny. His destiny chooses him.

Tuesday, May 25, 2010

Register Node/Recognizer/OMX decoder component

Register Node/Recognizer/OMX decoder component:
----------------------------------------------------------------------------

//Add the dummy recognizer code in Recognizer folder;

1.#include the rec_factory.h in external\opencore\engines\player\config\core\pv_player_node_registry_populator.cpp
2.Create the instance in RegisterAllRecognizers() fn of the same file.


3.BUILD_MACRO defns available in \external\opencore\build_config\opencore_dynamic\pv_config.h file

4.We need to add our Node/register's library & android.mk in
\external\opencore\build_config\opencore_dynamic\Android_opencore_player.mk file

 

5.Configure Node/recognizer/decoder (pvyuvffrecognizer_lib=m) in \external\opencore\build_config\opencore_dynamic\pv_config_selected.mk

6.Configure the shared recognizer/node/decoder's library make path(/pvmi/recognizer/plugins/pvyuvffrecognizer/build/make)
in \external\opencore\build_config\opencore_dynamic\pv_config_derived.mk

 

Wednesday, May 19, 2010

red-faced gentleman

I know a planet where there is a certain red-faced gentleman. He had never smelled a flower. He has never looked at a star. He has never loved any one. He has never done anything in his life but add up figures.

essential things

The essential things in life are seen not with the eyes, but with the heart.

You are attempting with incorrect version of javac in Ubuntu while building android source code

Situation:

I have copied the JRE & JAVA SDK folder and set the environment variable . (without installing java, make it as
like an installed). with this one, I am able to compile android checkout.
I have checked the version of the java. its version is JDK_1.0.5_19;
Once I tried to install eclipse, then old version or updated version is installed in my laptop ,
so I couldnt be able to compile android source code and got the error as follows:


Error: You are attempting with incorrect version of javac in Ubuntu while building android source code


Solution:
We can get current java version by typing "java -version". I found that the java version is different from working version (android compiled code);
So we have to remove the recently installed version and reinstall the java .

We have to search the recently installed version by typing the command:

"aptitude search jdk"

it will lists out the JDK packages.

Remove all the JDK packages (Our JDK package doesnt need installation) by typing the following command:

aptitude purge $1 ($1 is the package listed in "aptitude search jdk")

install java_1_5_0_19 .bin file and then now try recompiling the code.Now it is working.

Environment variable was not set in Ubuntu

Error:

 if we are setting the environment variable PATH, its value is not reverted back to last value once the
terminal is closed.

Solution:
To overcome this problem, we need to set the environment variable in
.bashrc file in root folder.

Monday, May 17, 2010

Chetan Bhagat speech at symbiosis

Following is the speech by Chetan Bhagat given at the orientation programme for the new batch of MBA students at Symbiosis, Pune.

Good Morning everyone and thank you for giving me this chance to speak to you. This day is about you. You, who have come to this college, leaving the comfort of your homes (or in some cases discomfort), to become something in your life. I am sure you are excited. There are few days in human life when one is truly elated.  The first day in college is one of them.  When you were getting ready today, you felt a tingling in your stomach. What would the auditorium be like, what would the teachers be like, who are my new classmates – there is so much to be curious about. I call this excitement, the spark within you that makes you feel truly alive today. Today I am going to talk about keeping the spark shining. Or to put it another way, how to be happy most, if not all the time.

Where do these sparks start? I think we are born with them. My 3-year old twin boys have a million sparks. A little Spiderman toy can make them jump on the bed. They get thrills from creaky swings in the park. A story from daddy gets them excited. They do a daily countdown for birthday party – several months in advance – just for the day they will cut their own birthday cake.

I see students like you, and I still see some sparks. But when I see older people, the spark is difficult to find. That means as we age, the spark fades. People whose spark has faded too much are dull, dejected, aimless and bitter. Remember Kareena in the first half of Jab We Met vs the second half? That is what happens when the spark is lost.   So how to save the spark?

Imagine the spark to be a lamp's flame. The first aspect is nurturing – to give your spark the fuel, continuously. The second is to guard against storms.

To nurture, always have goals. It is human nature to strive, improve and achieve full potential. In fact, that is success. It is what is possible for you. It isn't any external measure – a certain cost to company pay package, a particular car or house.

Most of us are from middle class families. To us, having material landmarks is success and rightly so. When you have grown up where money constraints force everyday choices, financial freedom is a big achievement. But it isn't the purpose of life. If that was the case, Mr. Ambani would not show up for work. Shah Rukh Khan would stay at home and not dance anymore. Steve Jobs won't be working hard to make a better iPhone, as he sold Pixar for billions of dollars already. Why do they do it? What makes them come to work everyday? They do it because it makes them happy. They do it because it makes them feel alive Just getting better from current levels feels good. If you study hard, you can improve your rank. If you make an effort to interact with people, you will do better in interviews. If you practice, your cricket will get better. You may also know that you cannot become Tendulkar, yet. But you can get to the next level. Striving for that next level is important.

Nature designed with a random set of genes and circumstances in which we were born. To be happy, we have to accept it and make the most of nature's design. Are you? Goals will help you do that. I must add, don't just have career or academic goals. Set goals to give you a balanced, successful life. I use the word balanced before successful. Balanced means ensuring your health, relationships, mental peace are all in good order.

There is no point of getting a promotion on the day of your breakup. There is no fun in driving a car if your back hurts. Shopping is not enjoyable if your mind is full of tensions.

You must have read some quotes – Life is a tough race, it is a marathon or whatever. No, from what I have seen so far, life is one of those races in nursery school, where you have to run with a marble in a spoon kept in your mouth. If the marble falls, there is no point coming first. Same with life, where health and relationships are the marble. Your striving is only worth it if there is harmony in your life. Else, you may achieve the success, but this spark, this feeling of being excited and alive, will start to die.

One last thing about nurturing the spark – don't take life seriously. One of my yoga teachers used to make students laugh during classes. One student asked him if these jokes would take away something from the yoga practice. The teacher said – don't be serious, be sincere. This quote has defined my work ever since. Whether its my writing, my job, my relationships or any of my goals. I get thousands of opinions on my writing everyday. There is heaps of praise, there is intense criticism. If I take it all seriously, how will I write? Or rather, how will I live? Life is not to be taken seriously, as we are really temporary here. We are like a pre-paid card with limited validity. If we are lucky, we may last another 50 years. And 50 years is just 2,500 weekends. Do we really need to get so worked up? It's ok, bunk a few classes, goof up a few interviews, fall in love. We are people, not programmed devices.

I've told you three things – reasonable goals, balance and not taking it too seriously that will nurture the spark. However, there are four storms in life that will threaten to completely put out the flame. These must be guarded against. These are disappointment, frustration, unfairness and loneliness of purpose.

Disappointment will come when your effort does not give you the expected return. If things don't go as planned or if you face failure. Failure is extremely difficult to handle, but those that do come out stronger. What did this failure teach me? is the question you will need to ask. You will feel miserable. You will want to quit, like I wanted to when nine publishers rejected my first book. Some IITians kill themselves over low grades – how silly is that? But that is how much failure can hurt you. But it's life. If challenges could always be overcome, they would cease to be a challenge. And remember – if you are failing at something, that means you are at your limit or potential. And that's where you want to be.

Disappointment' s cousin is  Frustration, the second storm.  Have you ever been frustrated? It happens when things are stuck. This is especially relevant in India. From traffic jams to getting that job you deserve, sometimes things take so long that you don't know if you chose the right goal. After books, I set the goal of writing for Bollywood, as I thought they needed writers. I am called extremely lucky, but it took me five years to get close to  a release. Frustration saps excitement, and turns your initial energy into something negative, making you a bitter person. How did I deal with it? A realistic assessment of the time involved – movies take a long time to make even though they are watched quickly, seeking a certain enjoyment in the process rather than the end result – at least I was learning how to write scripts, having a side plan – I had my third book to write and even something as simple as pleasurable distractions in your life – friends, food, travel can help you overcome it. Remember, nothing is to be taken seriously. Frustration is a sign somewhere, you took it too seriously.

Unfairness – this is hardest to deal with, but unfortunately that is how our country works. People with connections, rich dads, beautiful faces, pedigree find it easier to make it – not just in Bollywood, but everywhere. And sometimes it is just plain luck. There are so few opportunities in India, so many stars need to be aligned for you to make it happen. Merit and hard work is not always linked to achievement in the short term, but the long term correlation is high, and ultimately things do work out. But realize, there will be some people luckier than you. In fact, to have an opportunity to go to college and understand this speech in English means you are pretty damm lucky by Indian standards. Let's be grateful for what we have and get the strength to accept what we don't. I have so much love from my readers that other writers cannot even imagine it. However, I don't get literary praise. It's ok. I don't look like Aishwarya Rai, but I have two boys who I think are more beautiful than her. It's ok. Don't let unfairness kill your spark.

Finally, the last point that can kill your spark is Isolation. As you grow older you will realize you are unique. When you are little, all kids want Ice cream and Spiderman. As you grow older to college, you still are a lot like your friends. But ten years later and you realize you are unique. What you want, what you believe in, what makes you feel, may be different from even the people closest to you. This can create conflict as your goals may not match with others. And you may drop some of them. Basketball captains in college invariably stop playing basketball by the time they have their second child. They give up something that meant so much to them. They do it for their family. But in doing that, the spark dies. Never, ever make that compromise. Love yourself first, and then others.

There you go. I've told you the four thunderstorms – disappointment, frustration, unfairness and isolation. You cannot avoid them, as like the monsoon they will come into your life at regular intervals. You just need to keep the raincoat handy to not let the spark die.

I welcome you again to the most wonderful  years of your life. If someone gave me the choice to go back in time, I will surely choose college. But I also hope that ten years later as well, your eyes will shine the same way as they do today. That you will Keep the Spark alive, not only through college, but through the next 2,500 weekends. And I hope not just you, but my whole country will keep that spark alive, as we really need it now more than any moment in history. And there is something cool about saying – I come from the land of a billion sparks.

Wednesday, May 12, 2010

Multiple Target patterns error with mak files in android/linux

Gnu make looks for tab space after the target line.
For ex:
$(TARGETDIR)/test.lib : $(TEST_SRC)
$(group_test)

The above line in.mak file would throw multiple target patterns error.

correct format would be

$(TARGETDIR)/test.lib : $(TEST_SRC)
<adding tab space here>$(group_test).
 
Solution:
By giving  some tabspace it will compile without any problem.

Android_Out of memory error

I got a wierd problem with android emulator, I have created a virtual device through Android AVD manager (newly created emulator with platform 2.1 and api level 7), I have tried with standard settings and with added hardware parameter for larger (256 mb) device ram size but nothing changed.

I need to come files to the system partition to test a project (called haggle), but for some reason the system partition has no space from start.

aa a@aaa /home/haggle-0.2-android $ adb -s emulator-5554 shell

# df df /dev: 47084K total, 0K used, 47084K available (block size 4096) /sqlite_stmt_journals: 4096K total, 0K used, 4096K available (block size 4096) /system: 73600K total, 73600K used, 0K available (block size 4096) /data: 65536K total, 18464K used, 47072K available (block size 4096) /cache: 65536K total, 1156K used, 64380K available (block size 4096)

As you can see the system partition has 0K space available. When a connect a non-rooted HTC Nexus One and do the same I get these values:

/dev: 108896K total, 0K used, 108896K available (block size 4096) /sqlite_stmt_journals: 4096K total, 0K used, 4096K available (block size 4096) /system: 148480K total, 116364K used, 32116K available (block size 4096) /data: 200960K total, 22296K used, 178664K available (block size 4096) /cache: 97280K total, 1852K used, 95428K available (block size 4096) /sdcard: 3864064K total, 118496K used, 3745568K available (block size 32768)
 
Solution:
 
 

When starting the emulator you can specify the partition size by -partition-size x emulator_name.

done through the terminal that is.

Example: emulator -partition-size 125 @b

What I am wondering is why the system partition on the emulator has 0K free space from beginning and what can I do to change that? Even if I make the partition write-able with mount/remount I get the same 0K values.

Becoming an artist does not merely mean learning something, acquiring professional

Becoming an artist does not merely mean learning something, acquiring professional

techniques and methods. Indeed, as someone has said, in order to

write well you have to forget about grammar. Though, of course, in order to forget it you have first to know it.
- Andrey tarkovsky

Thursday, April 29, 2010

கண் கலங்காதிருப்பாள்

இனி என் காதலி கண் கலங்காதிருப்பாள்
"இன்று முதல் இந்தியாவில் வெங்காயம் தடை செய்யப்படுகிறது "

Wednesday, April 28, 2010

Inspiring Quotes



Inspiring Quotes:

Do not go where the path may lead, go instead where there is no path and leave a trail.
- Ralph Waldo Emerson

I learned that it is the weak who are cruel, and that gentleness is to be expected only from the strong.
- Leo Rosten

Goal or Purpose

All successful people men and women are big dreamers. They imagine what their future could be, ideal in every respect, and then they work every day toward their distant vision, that goal or purpose.
- Brian Tracy

Monday, April 26, 2010

Be True To Yourself

Be True To Yourself

Never compromise your values and beliefs,
even it if means risking ridicule and rejection.

Be true to yourself. Live your own life.
And don't allow others to decide what is best for you.

If you do, you will be unhappy,
because, you're untrue to yourself.

fly

Flying high in the blue sky
Flying high just you and I
Let us fly with love

Oh my loved one

All the time
when I think of you
my thoughts are always
warm and true
Every time
when you pass my way
I feel that
you are here to stay
If I must say dont go
that you stay for more

For day by day
my love will
grow and grow and grow

You belong to me
Oh my loved one
You are in my heart
all day long

dreams

you are in my dreams
All day all Night
In my heart I feel only you

Wednesday, April 21, 2010

liberty

 I wrote about liberty in

social occasions--the problem of having to fake and lie in order to be polite, and does this perpetual game of faking in social situations lead to the

"destruction of the moral fiber of society."

faker

People often think I'm a faker, but I'm usually honest, in a certain way--in such a way that often nobody believes me!
 
People often think I'm a faker, but I'm usually honest, in a certain way--in such a way that often nobody believes me!
 
People often think I'm a faker, but I'm usually honest, in a certain way--in such a way that often nobody believes me!

Life

Life is not a rehearsal... Each day is a real show... No repetition, No rewinding... So, give the best performance in all your roles

Clear thinking and clear presentation

 Clear thinking and clear presentation were fundamental prerequisites for his attention. It could be perilous even to approach him when unprepared, and he did not forget the fools or pretenders

freshman lecture

 if a topic could not be explained in a freshman lecture, it was not yet fully understood. -Richard feynman

why we r studying science ?

The view is that science, good science, is at it's heart simply the satiation of our own curiosity. It is not a means to an end, we are
not trying to learn about the universe because we are trying to build faster computers or a better toaster. We are studying science because we want to know how the universe arranges itself, and appreciate its beauty.

 

Why we are studying science ?

We are studying science because we want to know how the universe arranges itself, and appreciate its beauty. -Richard feynman

Tuesday, April 20, 2010

Richard Feynman

You can know the name of a bird in all the languages of the world, but when you're finished, you'll know absolutely nothing whatever about the bird... So let's look at the bird and see what it's doing -- that's what counts. I learned very early the difference between knowing the name of something and knowing something.

    Richard Feynman

Siege of Syracuse





During the Siege of Syracuse (c. 214–212 BC), Archimedes destroyed enemy ships with fire. Centuries later, Anthemius of Tralles mentions burning-glasses as Archimedes' weapon.] The device, sometimes called the "Archimedes heat ray", was used to focus sunlight onto approaching ships, causing them to catch fire.

This purported weapon has been the subject of ongoing debate about its credibility since the Renaissance. René Descartes rejected it as false, while modern researchers have attempted to recreate the effect using only the means that would have been available to Archimedes.[26] It has been suggested that a large array of highly polished bronze or copper shields acting as mirrors could have been employed to focus sunlight onto a ship. This would have used the principle of the parabolic reflector in a manner similar to a solar furnace.

A test of the Archimedes heat ray was carried out in 1973 by the Greek scientist Ioannis Sakkas. The experiment took place at the Skaramagas naval base outside Athens. On this occasion 70 mirrors were used, each with a copper coating and a size of around five by three feet (1.5 by 1 m). The mirrors were pointed at a plywood mock-up of a Roman warship at a distance of around 160 feet (50 m). When the mirrors were focused accurately, the ship burst into flames within a few seconds. The plywood ship had a coating of tar paint, which may have aided combustion.
 
 In October 2005 a group of students from the Massachusetts Institute of Technology carried out an experiment with 127 one-foot (30 cm) square mirror tiles, focused on a mock-up wooden ship at a range of around 100 feet (30 m). Flames broke out on a patch of the ship, but only after the sky had been cloudless and the ship had remained stationary for around ten minutes. It was concluded that the device was a feasible weapon under these conditions.

Siege of Syracuse

During the Siege of Syracuse (c. 214–212 BC), Archimedes destroyed enemy ships with fire. Centuries later, Anthemius of Tralles mentions burning-glasses as Archimedes' weapon.] The device, sometimes called the "Archimedes heat ray", was used to focus sunlight onto approaching ships, causing them to catch fire.

This purported weapon has been the subject of ongoing debate about its credibility since the Renaissance. René Descartes rejected it as false, while modern researchers have attempted to recreate the effect using only the means that would have been available to Archimedes.[26] It has been suggested that a large array of highly polished bronze or copper shields acting as mirrors could have been employed to focus sunlight onto a ship. This would have used the principle of the parabolic reflector in a manner similar to a solar furnace.

A test of the Archimedes heat ray was carried out in 1973 by the Greek scientist Ioannis Sakkas. The experiment took place at the Skaramagas naval base outside Athens. On this occasion 70 mirrors were used, each with a copper coating and a size of around five by three feet (1.5 by 1 m). The mirrors were pointed at a plywood mock-up of a Roman warship at a distance of around 160 feet (50 m). When the mirrors were focused accurately, the ship burst into flames within a few seconds. The plywood ship had a coating of tar paint, which may have aided combustion.
 
 

archimedes

archimedes tells of how he invented a method for determining the volume of an object with an irregular shape. According to Vitruvius, a new crown in the shape of a laurel wreath had been made for King Hiero II, and Archimedes was asked to determine whether it was of solid gold, or whether silver had been added by a dishonest goldsmith.[13] Archimedes had to solve the problem without damaging the crown, so he could not melt it down into a regularly shaped body in order to calculate its density. While taking a bath, he noticed that the level of the water in the tub rose as he got in, and realized that this effect could be used to determine the volume of the crown. For practical purposes water is incompressible,[14] so the submerged crown would displace an amount of water equal to its own volume. By dividing the weight of the crown by the volume of water displaced, the density of the crown could be obtained. This density would be lower than that of gold if cheaper and less dense metals had been added. Archimedes then took to the streets naked, so excited by his discovery that he had forgotten to dress, crying "Eureka!" (Greek: "εὕρηκα!," meaning "I have found it!")[15]

Monday, April 19, 2010

six honest serving man

I keep six honest serving-men (They taught me all I knew); Their names are What and Why and When And How and Where and Who.

Thursday, April 15, 2010

Stress Management

 

Stress Management

A lecturer was giving a lecture to his student on stress management.

He raises a glass of water and asks the audience
"How heavy do you think this glass of water is?"
"It depends on how long you hold it."
"If I hold it for a minute, it is Ok."
"If I hold it for an hour, I will have an ache in my right arm."
"If I hold it for a day, you will have to call an ambulance."
"It is the exact same weight, but the longer I hold it, the heavier it becomes"

If we carry our burdens all the time, sooner or later, we will not be able to carry on, the burden becoming increasingly heavier.

"What you have to do is to put the glass down, rest for a while before holding it up again."

We have to put down the burden periodically, so that we can be refreshed and are able to carry on. When you return home from work, put the burden of work down. Don't carry it into your home. You can pick it up tomorrow. So Rest and Relax.

I don't know

I don't know what's the matter with people: they don't learn by understanding, they learn by some other way — by rote or something. Their knowledge is so fragile! - Richard Feynman

Monday, April 12, 2010

Your task is not to seek for love

Your task is not to seek for love, but merely to seek and find all the barriers within yourself that you have built against it - Rumi

Sunday, April 11, 2010

Remember to appreciate all the different people in your life.

A water bearer in China had two large pots, each hung on the ends of a pole which he carried across his neck. One of the pots
had a crack in it, while the other pot was perfect and always delivered a full portion of water. At the end of the long walk from the stream to the House, the cracked pot arrived only half full. For a full two years this went on daily, with the bearer delivering only one and a half pots full of water to his house.

 

Of course, the perfect pot was proud of its accomplishments, perfect for which it was made. But the poor cracked pot was ashamed of it's own imperfection and miserable that it was able to accomplish only half of what it had been made to do.

After two years of what it perceived to be a bitter failure, it spoke to the water bearer one day by the stream. "I am ashamed
of myself, and I want to apologize to you. I have been able to deliver only half my load because this crack in my side causes
water to leak out all the way back to your house. Because of my flaws, you have to do all of this work, and you don't get full
value from your efforts," the pot said.

The bearer said to the pot, "Did you notice that there were flowers only on your side of the path, but not on the other pot's
side? That's because I have always known about your flaw. So I planted flower seeds on your side of the path, and every day
while we walk back, you've watered them. For two years I have been able to pick these beautiful flowers to decorate the table.
Without you being just the way you are, there would not be this beauty to grace the house?

 


Lessons to Learn from This Story:

 

Each of us has our own unique flaws. We're all cracked pots. But it's the cracks and flaws we each have that make our lives together so very interesting and rewarding. You've just got to take each person for what they are, and look for the good in them. Blessed are the flexible, for they shall not be bent out of shape.


Remember to appreciate all the different people in your life.

Look at each day

Look at each day as a new opportunity to be your very best. Set high goals, be honest, never say no, and work with people who share your passion for doing their best.

Friday, April 09, 2010

Be yourself

 
 
"It takes a man to suffer ignorance and smile.
  Be yourself, no matter what they say."

Tuesday, April 06, 2010

Freedom

"Freedom's just another word for not caring about the quality of your work"
-Dilbert

My best code is written with the delete key.

My best code is written with the delete key.

Perception








 



 



Washington, DC Metro Station on a cold January morning in 2007.  The man with a violin played six Bach pieces for about 45 minutes.  During that time approximately two thousand people went through the station, most of them on their way to work.  After 3 minutes a middle aged man noticed there was a musician playing.  He slowed his pace and stopped for a few seconds and then hurried to meet his schedule.

4 minutes later:  
The violinist received his first dollar: a woman threw the money in the hat and, without stopping, continued to  walk.

6 minutes:  
A young man leaned against the wall to listen to him, then looked at his watch and started to walk again.   

10 minutes:  
A 3-year old boy stopped but his mother tugged him along hurriedly.  The kid stopped to look at the violinist again, but the mother pushed hard and the child continued to walk, turning his head all the time.  This action was repeated by several other children..  Every parent, without exception, forced their children to move on quickly.  

45 minutes:
The musician played continuously.  Only 6 people stopped and listened for a short while.  About 20 gave money but continued to walk at their normal pace.  The man collected a total of $32.  

1 hour:  
He finished playing and silence took over.  No one noticed.  No one applauded, nor was there any recognition.   

No one knew this, but the violinist was Joshua Bell, one of the greatest musicians in the world.  He played one of the most intricate pieces ever written, with a violin worth $3.5 million dollars.  Two days before, Joshua Bell sold out a theater in Boston where the seats averaged $100.  
This is a true story.  Joshua Bell playing incognito in the metro station was organized by the Washington Post as part of a social experiment about perception, taste and people's priorities.  The questions raised: in a commonplace environment at an inappropriate hour, do we perceive beauty?  Do we stop to appreciate it?  Do we recognize talent in an unexpected context?  

One possible conclusion reached from this experiment could be this: If we do not have a moment to stop and listen to one of the best musicians in the world, playing some of the finest music ever written, with one of the most beautiful instruments ever made..... How many other things are we missing?





 

Monday, April 05, 2010

Books to be studied

 விநாயகர் அகவல், திருமந்திரம், ஞான வாசிட்டம், தாயுமானவர் பாடல்கள், சித்தர் பாடல்கள், ஔவை குறள், கைவல்ய நவநீதம், ஒழிவில் ஒடுக்கம், குணங்குடி மஸ்தான் சாஹேப் பாடல்கள்

Thursday, April 01, 2010

Householder life in Jainism

Householder life



Lay Followers Vows

Ascetics follows five great vows absolutely in mind, speech and word. But, for those who want to live in family life and have a keen desire to lead a spiritual life, Jain ethics specify the following small vows (Anuvratas). These vows help to lay out a rational course of life and tend to lead to liberation. Those lay followers who practices anuvrats are known as anuvrati. Anuvratas are twelve in number:

1.Ahimsa Anuvrata: It means abstinence from gross injury or intentional or purposeless violence in word, thought, and deed towards himself or through others or by approving such actions committed by somebody else. In this vow they abstain from engaging in anything that is not strictly required for them.
2. Satya Anuvrata: In this vow, they abstain from gross telling of lies to fulfill their own vested interests, giving false evidence, or denying, or giving back the property of others. They also avoid speaking such truth as would be the cause of killing innocent being.

3 Achaurya Anuvrat: This means abstaining from stealing robbing, looting , thieving, plundering, misappropriating, other's property, and using dishonest and illegal means in acquiring worldly things.

4 Savadara santish: It means abstinence from sexual intercourse with anybody else but ones own wife. They avoid adultery and excessive sexual indulgence totally, and practise continence in regard to intercourse with one's own wife or husband.

5 Aparihraha Anuvrata: This means abstain from hoarding land, gold, house, cattle etc., in large scale and try to make voluntary limits on one's own needs, possessions and acquisitions such as land, real estate, gold, silver, money, other valuable goods, cattle and furniture. In this vow, they vow not to possess accumulations beyond a limited extent.

For strengthening and cultivating the effect of anuvratas, three Gunavratas and four sikshavratas have been pescribed. These seven vratas are supplementary vows. The following Gunavratas are to practiced for the whole lifelike the above five vratas to keep life on the right track.

6 Digvarta parimana: Dig means direction, vrata means a vow. It is a vow to carry out once own movement only within a restricted area. In this vow, they limit the distance up to which he will do in different spatial directions.

7 Upabhoga paribhoga parimana: This means to limit the sensual enjoyment of material things. Upabhoga means consumption of food, drink etc., which can only be used once, the paribhoga means semi-permanent articles like cloth, furniture, ornaments, buildings, etc., which can be used several times. They restricts fifteen types of sinful professions which are known as karmadana like manufacturing and supplying arms, selling meat, cutting forests, etc., twenty six articles such as food, ornaments etc. In this vow, householders limit the everyday usage of the quantity or number of food items, articles, etc.

8. Anarthadanda virati: In this vow householders abstain from all kind of purposeless violence, thinking ill of others, manufacturing or supplying of arms. This prevents themselves from indulging in those acts which are not required.
Among the seven vratas the four are called disciplinary vows or practical vows (sikshavrats). All four vrats are to be practiced repeatedly. Of the four, samayika and deshavakasika are to be observed daily while pushadhopavasa and atithisamvibhaga are observed occasionally.

9.Samayaka: This means abstinence from all sinful activities for a fixed intended period of 48 minutes known as muhurat. While sitting motionless, they perform samayaka meditation and contemplating upon there own soul with equanimity of mind.

10. Deshavakasika It means further lessening in the respect of the sphere of digvrata in certain areas and bhogopbhoga parinama for particular days and limited times. In the foregoing vows renunciation is made for the whole life, but the renunciation for a fixed time or shorter period comes under deshavakasika vrata.

11. Paushadhopavasa: In this vow, they accepts all the restrictions of the monk and pass time in meditation or religious study like a monk for one or more days by retiring household activities and keeping the fast by giving up all kind of food, drink, etc., on the eighth, fourteenth, or fifteenth day of each fortnight or month as per will.

12. Atithisamvibhaga: It means to offer food, drink, medicine and other articles to monk sand nuns with great reverence and with avoidance of all blemishes. It amounts to a sin to prepare food or other things intentionally for their sake. Before taking breakfast or lunch, householders think, wish and feel that it would be better for me if I had the chance to provide some portion of my food to the monk. This is called atithisamvibhaga. If the monk and nuns are not available, even they think about monks and nuns.

All the vows are to be observed in true spirit. By performing and practicing all these vows, and lay follower leads a righteous, spiritual, and pious life.

The Scarecrow

The Scarecrow

Once I said to a scarecrow, "You must be tired of standing in this lonely field."

And he said, "The joy of scaring is a deep and lasting one, and I never tire of it."

Said I, after a minute of thought, "It is true; for I too have known that joy."

Said he, "Only those who are stuffed with straw can know it."

Then I left him, not knowing whether he had complimented or belittled me.

A year passed, during which the scarecrow turned philosopher.

And when I passed by him again I saw two crows building a nest under his hat.

Wednesday, March 31, 2010

I searched for God

I searched for God among the Christians and on the Cross and therein I found Him not.
I went into the ancient temples of idolatry; no trace of Him was there.
I entered the mountain cave of Hira and then went as far as Qandhar but God I found not.
With set purpose I fared to the summit of Mount Caucasus and found there only 'anqa's habitation.
Then I directed my search to the Kaaba, the resort of old and young; God was not there even.
Turning to philosophy I inquired about him from ibn Sina but found Him not within his range.
I fared then to the scene of the Prophet's experience of a great divine manifestation only a "two bow-lengths' distance from him" but God was not there even in that exalted court.
Finally, I looked into my own heart and there I saw Him; He was nowhere else.

Don't worry be happy

Here is a little song I wrote
You might want to sing it note for note
Don't worry be happy
In every life we have some trouble
When you worry you make it double
Don't worry, be happy......

Ain't got no place to lay your head
Somebody came and took your bed
Don't worry, be happy
The land lord say your rent is late
He may have to litigate
Don't worry, be happy
Lood at me I am happy
Don't worry, be happy
Here I give you my phone number
When you worry call me
I make you happy
Don't worry, be happy
Ain't got no cash, ain't got no style
Ain't got not girl to make you smile
But don't worry be happy
Cause when you worry
Your face will frown
And that will bring everybody down
So don't worry, be happy (now).....

There is this little song I wrote
I hope you learn it note for note
Like good little children
Don't worry, be happy
Listen to what I say
In your life expect some trouble
But when you worry
You make it double
Don't worry, be happy......
Don't worry don't do it, be happy
Put a smile on your face
Don't bring everybody down like this
Don't worry, it will soon past
Whatever it is
Don't worry, be happy

lover

Lover's nationality is separate from all other religions,
The lover's religion and nationality is the Beloved (God).

Friday, March 26, 2010

Practice

"Practice doesn't make perfect - perfect practice makes perfect."

"My dad brought me up with a quote - 'Only those who attempt the absurd achieve the impossible.'"

"You can't practice all the time. If you do, you'll eventually burn out!"

"Just practicing isn't always enough. You have to be involved in what you are doing. You have to learn from the heart."

Wednesday, March 17, 2010

புலிகள்

புலிகள் கொஞ்சம் பதுங்கும் போது
ந‌ரிகள் போடும் ஆட்டமே
ந‌ரிகள் வேஷம் கலையும் போது
புலிகள் வென்று காட்டுமே

புல்லை கண்டு நடுங்கும் மனிதன்
இருக்கும் போதே சாகிறான்
புல்லை கத்தி ஆக்கும் மனிதன்
இறந்த பிறகும் வாழ்கிறான்

உண்ணும் உணவில் இல்லை வீரம்
வீரம் உள்ளது நெஞ்சிலே
வெற்றிச் சங்கை ஊதும் வரையில்
ூக்கம் இல்லை கண்ணிலே...

அறிவும், கல்வியும்

படித்தால் மட்டும் போதுமா?

* உடலை அடக்கி, நாவை அடக்கி, மனதையும் அடக்கியுள்ள ஞானிகளே உண்மையில் அடக்கம் உடையவர்கள் ஆவர். 


* தன்னிடம் இருக்கும் அதிகாரத்தை தவறுதலான வழியில் பயன்படுத்தி தீங்கு செய்பவன் நிச்சயம் வாழ மாட்டான்.
* பகைமையைப் பகைமையினால் தணிக்க முடியாது. அன்பின் மூலமாக மட்டுமே பகையை வெல்ல முடியும்.
* அறிவும், கல்வியும் மட்டுமே பாராட்டத்தக்கது என்று கருதுபவன் எந்நாளும் தனித்தே தான் வாழ நேரிடும்.
* அநீதி செய்து மற்றவர்களுக்கு துன்பம் இழைப்பவர்கள் வென்றாக சரித்திரம் இல்லை. அவர்கள் தோல்வியைத் தழுவுவது உறுதி.
* நல்லவழியில் செம்மையாக நிர்வகிக்கப்பட்ட மனமே நமக்கு என்றென்றும் உதவி செய்ய தகுதி உடையதாக இருக்கும்.
* நாம் எண்ணும் எண்ணங்கள் நமக்கு நன்மையையும், ஆறுதலையும் தருவதாக அமையவேண்டும். ஆனால், மாறாக துன்பத்தை அல்லவா நமக்குத் தருகின்றன.
* ஒருவரின் சொல்லும், செயலும் ஒன்றாக இருக்குமானால் அவர் அழகும், சுகந்தமும் நிறைந்த வண்ண மலரைப் போல எல்லோருக்கும் பயன்உடைய மனிதராக இருப்பார்.
-புத்தர்

அன்பான ஒரு வார்த்தை போதும்!

அன்பான ஒரு வார்த்தை போதும்!

* ஆயிரம் வீண்வார்த்தைகளைப் பேசுவதைக் காட்டிலும், இதம் தரும் அன்பான ஒரு வார்த்தை மேலானது. பேசும் வார்த்தைகள் ஒவ்வொன்றும் பிறருக்கு பயன்தரும் நல்லவையாக இருக்க வேண்டும்.
* நன்மை ஏற்பட்டாலும் சரி, கெடுதல் ஏற்பட்டாலும் சரி உனது செயல்களின் பலன்களை நீ அடைந்தே ஆகவேண்டும். இதற்கு யாரும் விதிவிலக்கு இல்லை.
* எவனும் தனக்குத் தானே தலைவனாக இருக்க கற்றுக் கொள்ள வேண்டும். தன்னைத் தானே அடக்கப் பழகிக் கொண்டவன், தலைமை ஏற்கத் தகுதி உடையவனாகிறான். தலைமைப் பண்புகளுக்கு எல்லாம் அடக்கமே அடிப்படைப் பண்பாகும்.
* மூடர்களுடன் சேர்ந்து வாழ்வதைக் காட்டிலும், தனியே வாழ்வது சிறந்தது. துஷ்டர்களுடன் நட்புக் கொள்வதும் இதே போன்றதே. மூடர்களுடன் சேர்ந்தால் கவலையும், துஷ்டர்களுடன் சேர்ந்தால் பாவமும் நமக்கு உண்டாகும்.
* அறிவோடும், விழிப்போடும் வாழ்க்கை நடத்துபவர்கள் ஞானம் என்னும் மேலான நிலையை அடைவர். அவர்கள் செல்லும் வழியை எமனால் கூட அறிய முடியாது.
*புயல் காற்றுக்கு அசையாமல் பாறை இருப்பது போல, மெய்யுணர்வு பெற்ற ஞானிகள் புகழ்ச்சியையும், இகழ்ச்சியையும் ஒன்றாகவே கருதுவர்.
-புத்தர்

Tuesday, March 16, 2010

எப்போதும் நிதானமாக இருங்கள்

எப்போதும் நிதானமாக இருங்கள்

* சத்தியத்தையே தீபமாகப் பற்றிக் கொள்ளுங்கள். சுயநலத்தை ஒழித்து எல்லா உயிர்களையும் நேசியுங்கள். ஒழுக்கம் என்னும் அடித்தளத்தில் வாழ்க்கையை அமைத்துக் கொள்ளுங்கள்.
* ஆயிரம் பேர் கொண்ட படையை வெற்றி கொள்வதைக் காட்டிலும், தன்னைத் தானே வென்றவனே வெற்றிவீரன்.
* மனிதன் நல்ல எண்ணங்களுடன் செயல்புரிந்தால் அவனைப் பின்தொடர்ந்து இன்பம் நிழல்போல வரும்.
* தூங்க முடியாமல் விழித்திருப்பவனுக்கு இரவு கொடியதாகும். களைத்துப் போனவனுக்கு செல்லும் வழி மலைப்பைத் தரும். அதுபோல தர்மத்தை பின்பற்றாதவனுக்கு வாழ்க்கை துன்பத்தைத் தரும்.
* வெறுப்பு, கடுஞ்சொல் இவற்றிலிருந்து விலகி நில்லுங்கள். எதிர்பார்ப்பு இல்லாமல் அனைவரையும் நேசித்து மகிழுங்கள். எந்த நிலையிலும் நிதானத்தைக் கடைபிடியுங்கள்.
* நாவின் ருசிக்காக உயிர்க்கொலை செய்பவன் வாழும்போது மட்டுமில்லாமல் மரணத்திற்குப் பின்னும் துன்பத்தை அடைவான்.
-புத்தர்

வெற்றிவீரன்

ஆயிரம் பேர் கொண்ட படையை வெற்றி கொள்வதைக் காட்டிலும், தன்னைத் தானே வென்றவனே வெற்றிவீரன்.

எவ்ளோ சுகம்

ஆத்தி!  நம்ம வீட்டு மொட்டை மாடில மல்லாக்கப் படுத்துக்கிட்டு வானத்திலே நிலவையும், நட்சத்திரத்தையும் பாத்துக்கிட்டே தூங்கிறது எவ்ளோ சுகம் !...

Sunday, March 14, 2010

கடமை


 கடமையில் இருக்கும் போர்வீரனும், காதலில்   இருக்கிறவனும் எதுக்கும் பயப்படக் கூடாது .

மனம்

வாழ்க்கை என்ற தேரில் நம்மைக் குதிரையாகப் பூட்டி கடிவாளத்தைத் தன் கையில் பிடித்துக் கொண்டு மனம் தான் ஜம்மென்று சவாரி செய்கிறது நிஜத்தில் . ஆனால் நாம் மனதிடம் அடிமைப் பட்டு இருக்கிறோம் என்பதைக் கூட நம்மால் உணர முடிவதில்லை

சூபி ஞானம்

சூபி ஞானம் வாழ்வை பகுப்பதில்லை.தரம் பிரித்து வகைப்படுத்துவதில்லை .முழுவதுமாக அதனை ஏற்கிறது .தான் அதில் மூழ்கி விடுவதில்லை.தன்னுள் அதனை ஏற்றுக் கொண்டு அதற்கப்பாலும் தான் நிற்கிறது

விருப்பம்

விருப்பம் ஏற்படுவதற்கு மூல காரணமாக இருப்பது ஒருவர் மனதில் தோன்றும் எண்ணங்கள் தான்

மிகப் பெரிய யுத்தம்

யுத்தத்திலே மிகப்  பெரிய யுத்தம் ஒரு மனிதன் தன் மனதுடன் நடத்தும் யுத்தம் மட்டுமே .

உயிர் அசையும்

அன்பே! உந்தன் விழியசைவில் எந்தன் உயிர் அசையும்

தூங்கிறது எவ்ளோ சுகம்

ஆத்தி!  நம்ம வீட்டு மொட்டை மாடில மல்லாக்கப் படுத்துக்கிட்டு வானத்திலே நிலவையும், நட்சத்திரத்தையும் பாத்துக்கிட்டே தூங்கிறது எவ்ளோ சுகம் !...

Friday, March 12, 2010

Life is like a mountain

Life is like a mountain. Reaching its peak is my aim.
However trails are difficult to go through.

But what's important are -
The lessons I've learned,
Challenges I've experienced,
and the people I'm with in my journey.

Wednesday, March 03, 2010

Walk up behind your lover

Walk up behind your lover and point fingers shaped like gun into her back
"You're under arrest!"
For what?
"For stealing my heart."

Pick up a flower

Pick up a flower and walk over to your lover and say
"I was just showing this flower how beautiful you are."

Monday, February 22, 2010

Windows Mobile application Error:

Windows Mobile application Error:
-----------------------------------------------------


For some applications, I am getting the following error :

Error in VS2005:
--------------------------
---------------------------
Microsoft Visual Studio
---------------------------
Unable to start program '\My Documents\TestApp\TestApp.exe'.

An error occurred that usually indicates a corrupt installation (code 0x8007007e). If the problem persists, repair your Visual Studio installation via 'Add or Remove Programs' in Control Panel.
---------------------------
OK  
---------------------------


Result:

This is due to missing of any dependency files.

Solution:
   You can copy the dependency files and then check once again.

Sometimes, if msvcr80.dll or msvcr80d.dll is referenced as a dependency in our exe/dependency files,
then this error might occurs.


To resolve this error, Project->Properties->Deployment->Additional files->

add the following lines:

msvcr80.dll|$(BINDIR)\$(INSTRUCTIONSET)\|%CSIDL_WINDOWS%|0;

 

Additional Files property is to copy the dependency files at the time of deployment.
The above code will copy the msvcr80.dll from our system to the target device(Windows Mobile device)'s windows folder.

 

 


 

Friday, February 19, 2010

Words of Kalidasa

Dasaratha saw many beasts as he was hunting. Although he saw a peacock fly very close to his chariot, he did not shoot his arrow. For, as the peacock spread its tail feathers before him, it reminded him of his wife's hair adorned with flowers of different kinds and how it would become disarranged during their lovemaking.

Wednesday, February 10, 2010

Alcohol

"Alcohol is the human beings worst enemy,But Bible Says Love your enemy"

Sunday, February 07, 2010

difficult to control

"it is easy to control an elephant, catch hold of the tiger's tail, grab the snake and dance, dictate the angels, transmigrate into another body, walk on water or sit on the sea; but it is more difficult to control the mind and remain quiet". - Thaayumaanavar

Tuesday, February 02, 2010

Follow your instincts. That's where true wisdom manifests itself

Follow your instincts. That's where true wisdom manifests itself

safe

Ship's in harbor are safe, but that's not what ships are built for..!!

Wednesday, November 11, 2009

Some times I feel like...

Sometimes I feel like
a motherless child
A longway from my home.
oh... My Brothers
A longway from my home

Thursday, June 25, 2009

Learnings


Today I learnt two things:

1.How to load the WMP with local file ?
2.FourCC codes in AVI file format

How to load WMP with local file:
VS2005 debugger :
File path : wmPlayer
command line arguments : file://My documents//incredibles.avi






FourCC codes in AVI file:

FOURCC('0','0','d','c') - video
FOURCC('0','1','w','b') - audio

dc - indicates video stream
wb - indicates audio stream

00 - indicates the Stream number
01 - '' ''

Usually video will be the first stream and audio will be the second stream.
But For Some avi files, (Problematic avi file)

we found the audio as first stream and video as second stream.
So we need to check only the dc or wb to identify the stream type ( video or audio).

Monday, May 11, 2009

waiting for the right chance

உயிர்களைக் கொல்வது பாவம் என என் மனது சொல்லியதால் நான் உயிருடன் இருக்கிறேன்.
I am waiting for the right chance to die.

Friday, April 10, 2009

How to handle seek operation in Splitter or Source Filter ?

How to handle seek operation in Splitter /Source Filter:
-----------------------------------------------------------
1.SetPositions () called multiple times for a Single Seek operation.
2.we have to Set m_bSeeked variable in SetPositions() and Start Seek position
3.We have to store the Previous Seek value.within FillBuffer(), if m_bSeeked set,check for the seeked position and Previous seek position. if they are different, then send a seek request tostack or file parser.
So even Multiple SetPositions () ( 3 times) called for a single seek, operation from our filter we will send a seek request onceby having seeked Flag and Checking the Previous seek position with current seek position.
During Seeking, FillBuffer must not wait for any event... it must be unblocked ... ( Set Positions () fn will call flushing in all the output pins. Flushing will wait for the FillBuffer to complete its operation.

Tuesday, March 31, 2009

How to Assert the thread was closed (dead) or Not ?

How to Assert the thread was closed (dead) or Not ?:

WaitForSingleObject( hThread, INFINITE) ; // This statement will blocks until the thread dies.
if the Thread comes out of the loop, then hThread handle is like signalled.
The Next statement to WaitForSingleObject () will be executed.

How to modify the 3gp streaming filter to read Only rtp data?

How to modify the 3gp streaming filter to read Only rtp data?
================================================
( 3gp streaming stack it will receives the rtsp and rtp data)

Solution:Quick and dirty way to do this:
===============================
Use Some SDP file to create the dummy audio and video output pin. ( We can create it with rtsp:// URL itself);
Hard code the media type, File duration (instead of the file duration configure duration as much as we need to receive data for RTP),config data in a filter .

How to get SDP file for any RTSP file?

How to get SDP file for any RTSP file?
RTSP response will have the SDP description
if we are having rtsp URL, we can open it with Quick time Player and at the same time, we can open the Ethereal to capture the net logs.
RTSP response RTSP/1.1 200 OK will have a SDP description.
Even with this SDP description and save it into SDP file and open it in Quick time, we are able to play it in Quick time

Sunday, March 29, 2009

Audio goes off after seeking several times

Audio goes off after seeking several times :

When I seek several times, the audio goes off.

Reason:

After seeking, negative timestamps are set to video and audio media samples.

In case of video even though it was negative, it was rendered.But In case of audio,

it was not rendered fine because the audio is the reference clock for both video and audio.

Moreover audio and video are synchronized with this audio timestamp.

So the audio timestamp must not be negavtive, after seeking. if it is so, we cant predict the

rendering ( Sometimes it might render and sometimes it may not render)

Solution:

I modified Source filter in such a way to output positive timestamp for video and audio after seeking. Now the issue was resolved.

Wednesday, March 04, 2009

RegSvr32 error

 


I am able to compile the filter ; while registering I  got the following error:

---------------------------
RegSvr32
---------------------------
DllRegisterServer in D:\PushSource\Debug_Unicode\PushSource.dll failed.
Return code was: 0xc0000005
---------------------------
OK  
---------------------------


Solution:
============

 This error will come if any dependency has been removed
The problem is it doesnt have any dependency. I have checked it with depends.exe.

 

CFactoryTemplate g_Templates[3] =
{
    {
      g_wszPushDesktop,               // Name
      &CLSID_RxVideoReceiver,       // CLSID
      CRxReceiver::CreateInstance, // Method to create an instance of MyComponent
      NULL,                           // Initialization function
      &sudPushSourceDesktop           // Set-up information (for filters)
    }
};

 

I modified the above code as


CFactoryTemplate g_Templates[] =
{
    {
      g_wszPushDesktop,               // Name
      &CLSID_RxVideoReceiver,       // CLSID
      CRxReceiver::CreateInstance, // Method to create an instance of MyComponent
      NULL,                           // Initialization function
      &sudPushSourceDesktop           // Set-up information (for filters)
    }
};


Now I am not getting any errors.

 if I g_Templates[3] means, the regsvr32.exe expects the another 2 GUIDs and informations. Since it doesnt have the values,

it gives read violation error.

Tuesday, February 24, 2009

WindowsMobile Microsoft video renderer crashes for Odd resolution width

 
 
WindowsMobile Microsoft video renderer crashes with the following error for RGB565 data with 179x99 video resolution:
 
Data Abort: Thread=8a66da00 Proc=88a8b8b0 'wmplayer'
AKY=00080001 PC=03fa0060(coredll.dll+0x00054060) RA=0305798c(quartz.dll+0x0007398c) BVA=29b9a01c FSR=00000007
Unhandled exception at 0x03fa0060 in wmplayer.exe: 0xC0000005: Access violation reading location 0x01b9a01c.

Unhandled exception at 0x03fa0060 in wmplayer.exe: 0xC0000005: Access violation reading location 0x01b9a01c.
 
Odd Resolution Clip: 179x99 resolution
DecideBufferSize () size as 179x99*2
SetActualDatalength() as 179x99 * 2

Solution :
--------------
if I modified the DecideBufferSize to 180x99*2 then it is working fine.
renderer is doing some alignment for odd resolution clip is it so ?

Before giving the output to the renderer from our decoder, we need to align width and height to multiple's 0f 4 or 2;
 
Alignment to 4 :
----------------
  if( nFrameWidth & 0x03)
  {
   nFrameWidth = nFrameWidth  - ( nFrameWidth & 0x03);
  }
Alignment to 2 :
-----------------
  if(nFrameWidth & 0x01)
  {
   nFrameWidth = nFrameWidth - 1;   
  }
 
Note: I also got the above error if I do the following:
i) allocating memory size as 179x99 in DecideBufferSize()  and set the Width and height as 180x100 .

Monday, February 23, 2009

fatal error LNK1104: cannot open file 'x0__ar10.lib'

problem:

fatal error LNK1104: cannot open file 'x0__ar10.lib'

Solution:
-------------------

Search this library in Visual studio 8 installation folder.In the
following path it has that library.
D:\Program Files\Microsoft Visual Studio 8\VC\ce\bin\x86_arm

Thursday, February 19, 2009

Regarding the how to set the relative path:

Regarding the how to set the relative path:
==================================================

D:\tech\code\fileformats\3gpp\reader

..\..\..\..\inc


it refers the path as follows:
excape from the four directories:

D:\tech\inc


My Current directory is as follows:
D:\tech\code\Apps\Mp4Propertybag_Source\Mp4PropertyPag

common.h file's Current Directory D:\NokiaPCFilters\tech\inc

Relative path: ..\..\..\..\inc

Target directory:

D:\tech\code\fileformats\3gpp\reader\inc


Relative path:
..\..\..\fileformats\3gpp\reader\inc


Target Dir:
-------------
D:\tech\code\fileformats\3gpp\inc

Relative path:
--------------
..\..\..\fileformats\3gpp\inc

Target dir:
--------------
D:\tech\code\filters\inc

Relative path:
--------------
..\..\..\filters\inc

Integer division by error with Audio Decoder filter

while delivering audio data, I got a problem as follows:

i) if I deliver it then I got a crash in Decoder as "Integer division by zero".

So I modified the AvgBytesPerSec member of WAVEFORMATEX structure as follows:


wfx.nBlockAlign = 1 ;
wfx.nAvgBytesPerSec = MP3hdr->bitrate * 1000 / 8;

Solution:
--------------
Assign the proper values for WAVEFORMATEX header.

Modified value as follows Now the Filter is working fine.

wfx.nBlockAlign = 2 * nchannels ;
wfx.nAvgBytesPerSec = pwfxout->wfx.nSamplesPerSec * pwfxout->wfx.nBlockAlign ;

Wednesday, February 18, 2009

How to do dynamic format change from the Decoder Filter?...


 How to do dynamic format change from the Decoder Filter?...


Scenario:
-------------
 Assume that we reading video data from the RTP or from real media file.
we will receive the video with 320x240 resolution. In the middle of the stream, it might give you video data with 640x480

resolution. How will u handle the situation ? we can do it with Dynamic format change.

 


what needs to be done at decoder level:
---------------------------------------
   For getting width and height, we will refer the config data from the Source filter's VIDEOINFOHEADER config data or from
the video frame itself have the config information .

 We have the Create the Decoder with current width and height( 320x240) resolution.


DecodeFrame() fn itself must have the ability to detect new config. if some new config arrived, the DecodeFrame () returns

E_NEW_CONFIG;
 
 
 when the new width and height found, we have to delete/release the decoder ( Not a decoder filter) and we have to
create the new decoder with new resolution and then try to decode the frame.

 Here we need to change Decoder filter's output pin media type as well as the reallocate renderer's allocator with new

resolution.

 Logic is as follows:

 if( DecodeFrame() == E_NEW_CONFIG)
 {
  DeleteDecoder();
  hr =CreateDecoder(newWidth,newHeight);

  //Change the output pin's media type resolution
  //Rellocate the renderer's allocator with new resolution (640x480)

  //DecodeFrame() once again and give it out.

 }
 


 if we want the dynamic format change, we have to use upstream filter's(video renderer) allocator .

 

 

For Windows mobile:
-------------------
  Microsoft video renderer doesnt have the dynamic format change support.
So we can develop the new video renderer.


 if( DecodeFrame() == E_NEW_CONFIG)
 {
  DeleteDecoder();
  hr =CreateDecoder(newWidth,newHeight);

  //Change the output pin's media type resolution
  //Rellocate the renderer's allocator with new resolution (640x480)

  hr = m_pInput->ReceiveConnection(m_pOutput,mediatypeWithNewRes); // m_pInput is just a pointer to upstream

filter's                // input pin ( video renderer input pin


  DecodeFrame();
  Deliver(pSample);
  
 }

 
 In Video renderer:
 -------------------
  upstream filter input pin (Renderer input Pin):

  we have to override the ReceiveConnection() fn;

 HRESULT ReceiveConnection(IPin* m_Connected, AM_MEDIA_TYPE* mtWithNewRes)
 {

  if( m_Connected)
  {
                   // this condition will be satisfied if ReceiveConnection() called from the Decoder manually (while    // the graph was running
   int Width  = getWidth(mtwithNewRes);
   int height = getHeight(mtWithNewRes);

   if( CheckMediaType(mtWithNewRes) != S_OK)
   {
    return E_FAIL;
   }
   SetMediaType(mtWithNewRes);


   m_pAllocator->Decommit();
   m_pAllocator->SetProperties(Width,height);
   m_pAllocator->Commit();
    
   
  }
  else
  {
   return CBasePin::ReceiveConnection();
  }
  
 }

  
 

 
For PC:
----------
 For PC, Video renderer has the support for dynamic format change.
 

 we will do as follows:

within Decoder:
  
  if( DecodeFrame() == E_NEW_CONFIG)
 {
  DeleteDecoder();
  hr =CreateDecoder(newWidth,newHeight);

  //Change the output pin's media type resolution
  //Rellocate the renderer's allocator with new resolution (640x480)

  hr = m_pInput->ReceiveConnection(mediatypeWithNewRes);

  m_pInput->m_pAllocator->Decommit();
  m_pInput->m_pAllocator->SetProperties(new Resolution Size);
  m_pInput->m_pAllocator->Commit();

  DecodeFrame();
  Deliver(pSample);
  
 }
Renderer have the ability to change to new allocated buffer;;

 

Tuesday, February 17, 2009

Kavithai

அவள் கூந்தலில் வழிந்தோடும் மல்லிகைப் பூக்கள் அவள் நடக்கும் போது அவள் கன்னத்தை முத்தமிடத் துடிக்கின்றன.