There are so many apps that turn your iPhone into an expensive (but stylish!) flashlight, it was only a matter of time before someone figured out how to do the same thing with the freshly-minted Palm Pre. In fact, it took less than a week. Take THAT, iPhone!
The Pre flashlight hack (as found on the Pre Dev Wiki) basically involves typing in a bunch of command-line code, some of which might be familiar to old MS-DOS hands. Here's the code to turn flashlight mode on:
echo -n 1 >avin
echo -n 100mA >torch_current
echo -n torch >mode
And to turn it off:
echo -n shutdown >mode
echo -n 0mA >torch_current
echo -n 0 >avin
Adds PDW: "We don't know the impact both electrically and thermally of running the torch for extended periods of time, be careful or you may damage your Pre."
(Oh, and if you're not sure how or where to enter these commands, follow the links in the sidebar.)
[Via the Pre Dev Wiki]