Search This Blog

Monday, 24 October 2011

Getting Comfortable with Eclipse

I started using Eclipse recently. I'd tried and given up twice before, because the learning curve is quite steep and my heart wasn't really in it. This time I persevered, and now definitely see its advantages.

I'm been a Visual Studio user for over a decade, and most of my problems with Eclipse were to do with the dissimilarities between the two. It was quite tempting to change all the key settings to make Eclipse look like Visual Studio, but decided to forbear and take the hit of learning a new set of commands. With a bit of searching around under Windows > Preferences > General > Keys I managed to find equivalents for most of the functionality I was used to in VS2010. One command escaped me though: typing Ctrl + C to copy the current line onto the clipboard. There is no native Eclipse equivalent for this; the best you can do is move to the start of the line, highlight the line, then copy. However, someone else had also found this a problem, but unlike me, they came up with a solution.

You need to visit this page and follow the instructions. (On Windows, the 'dropins' folder is in the 'eclipse' folder; presumably something similar for Mac and Linux.) Restart Eclipse and Ctrl + C will work as it used to.

My thanks to the author of this drop-in. I have to point out that, for my setup at least, it's not working for HTML and CSS files. Python and JavaScript are perfect though.

Sunday, 23 October 2011

Listening at the Double

The excellent Lifehacker sent me to the somewhat bizarre Buddha Machine Wall. This web site lets you blend short loops of "Buddhist temple music" together, making an ambient soundscape to cut out surrounding distractions. Although you'd think it would get repetitive and annoying, I've managed to play it for hours: it does shut out the surroundings, and in addition I don't even notice it after a few minutes. This is a lot better than my usual technique of listening to music, which does affect my concentration (though not as much as some of the noise going on in my office).

However, it does feel like a waste. When I listen to Spotify, getting to know new albums, I feel as if I'm doing something productive. Ironic, as all I'm doing is consuming, but there you are. Just listening to a wall of sound doesn't cut it.

It would have once, but I think my problem now is a continual feeling that I'm not processing information as fast as I should.

To help with this, I've started listening to podcasts and audio books at higher speeds. Both BeyondPod, my podcast app, and Audible both let you play at a variety of faster (or lower) speeds. I tend to stick between 1.25 and 1.5 times normal speed. Any faster than that and it's too easy to lose the thread. It doesn't work for music, unsurprisingly, and it's not very good for comedy,where timing is all important, but otherwise it works really well. Now the challenge is to train myself up to be able to listen at x2.

How We Know that Precognition Doesn't Exist

Although in my youth I was quite sympathetic towards the possibility of ESP, the continued lack of consistent evidence turned me away from it. That, plus the realisation that, if phenomena such as telepathy were possible, they would confer a huge survival advantage on any creature possessing, so natural selection would ensure that they were as widespread as, say, the sense of smell.

In the case of precognition, the ability to see the future, there is an even better argument against its existence. Many countries around the world hold lotteries, in which the participants have to guess which numbers are going to turn up in a draw. If precognition was a real power, even one that was only held by a small percentage of humanity, and then not even very reliably, still the effect would be visible in lottery results.

The lottery organisations would be the first to notice that more people were winning than chance would allow. Rollovers would be almost unheard of, and jackpots would routinely be shared between many winners. In the UK, guessing just three numbers out of six gets you a £10 prize.Even someone whose precognitive powers were only right half the time should be able to scoop up prizes week after week.

None of this happens. Unless it goes hand in hand with a profound aversion to gambling, I think it's reasonable to conclude that precognition does not exist.

Friday, 21 October 2011

Sometimes You Already Know the Answer

Funny how I sometimes manage to install really useful stuff on my PC and then forget all about it.

Months ago I downloaded Dropbox onto my PCs at home and work, and on my Nexus S. I got them going, but couldn't think of anything much I needed to transfer or share just then, and time did the rest. Dropbox became just an icon on my desktop.

A few months ago I was reflecting on how annoying it was that I had to remember to take my portable disc drive home every Friday so that I could run SuperMemo at home over the weekend. A penny faintly dropped in the background: what if I put the SuperMemo files into Dropbox? Then I wouldn't need the portable drive at all. Five minutes later I was set up; the hardest bit was remembering the Dropbox password.

Another example. I have AutoHotkey running on my PC. A really useful program, though a complete b*gg*r to configure, thanks to its highly cryptic scripting language. I used it to set up keyboard shortcuts in Firefox, Explorer, et al. so that, for instance, typing Ctrl + Alt + F in Explorer will convert it to Folders view. It can also correct typing errors on the fly (in any program), which is useful if you make consistent mistakes. For instance, I very often type my first name as 'CHarles'. AutoHotkey corrects that. (In fact it did it just now; I had to edit the 'h' manually.) I was very enthusiastic about AutoHotkey for a few weeks, but once I'd put in all the obvious shortcuts, it went out of my mind.

Last month it stopped working, after I'd rearranged some folders. (I noticed when I signed an e-mail wrongly.) Easy enough to get it going again, but having been drawn to my attention again, I thought of some more useful shortcuts I could add to it. So now, instead of entering my full e-mail address, I can just type 'c@' and AutoHotkey fills in the rest (as indeed it just did). Other user names I frequently use are also now shortcutted, and when I'm writing JavaScript programs, I can type 'jq' instead of 'jQuery', which saves more time than you might think.

I did these new shortcuts at work, then realised it would be nice to have them at home as well. If only there was some way of sharing the two AutoHotKey config files. Oh, wait...

Thursday, 20 October 2011

50% Increase in My foursquare Friends

Okay, so there are now three of them.

I have a fairly tentative approach to social applications. I'm not on Facebook, and my Twitter account remains untweeted. But I thought I'd give foursquare a go, and I've been on it for a few weeks now, dutifully checking in whenever I remember, so that my two friends (who incidentally live miles from York) will know where I am (usually a long way away). Not very useful yet, though I can see how it could be if I could just reach that critical mass of friends. It's not helped that so few of my non-virtual friends have smartphones.

However, the price of smartphones will continue to drop, and in no great time they will presumably be the norm. Meanwhile I look forward to the time when I can't count all my foursquare friends on the fingers of one hand. Maybe when that happens foursquare will give me a badge?

Wednesday, 19 October 2011

Do it Yourself Internet Radio

I rarely listen to the radio unless I'm in the car, or cooking. In the kitchen we have a DAB radio, which I usually tune to Jazz FM or, on the suspiciously large number of times when Jazz FM isn't actually playing jazz, Planet Rock. A few days ago I happened to notice that the DAB radio had a USB port on the side. I still don't know why it needs this, but it got me thinking again about getting an Internet radio. Trouble is, they start at around the £100 mark, which seems a bit steep, particularly as, a recent All About Android podcast informed me, I could listen to internet radio for free on my mobile phone with the TuneIn Radio app.

A lightbulb came on inside my head (and not one of the longlife ones, which take a few minutes to warm up) What if I plugged my mobile's earphone socket into something with a speaker? I'd have my own internet radio.

(Or I could listen to my mobile through earphones. However, for some reason listening to music in a world of my own without disturbing anyone else is deemed more anti-social than playing it out loud for everyone to hear.)

My first attempt was the Sound Traveller universal USB speaker. Not very expensive, but unfortunately not very loud either, and the sound was a bit tinny. I had much more success with E-volve MP3 Vibe-Dock Home portable speaker system. This runs off the mains, and has an excellent sound for £25. It has a USB outlet, so it can charge my phone up even as the phone streams music at it. I've tried this once, and the speaker system started to give off a faint smell of overheating electronics, so I'll probably use that feature sparingly. Bizarrely, the system also has an earphone socket, though why I should ever need that I can't begin to imagine.

So now I can listen to radio stations from around the world in the kitchen, and the question comes down to choosing which station to listen to. Or whether to listen at all. I have Spotify on my mobile, which lets me listen to millions of songs. I could build the playlist of my choice and listen to that instead. (Or not, because it seems that the Spotify app now bombs out a few seconds after logging in. Tried reinstalling it, but no luck. Haven't used it for months, so no idea when this behaviour started, and may have to wait until it just as mysteriously stops. Anyway, I reckon my argument still stands.)

Radio listening has the advantage of serendipity, plus I always find that music I know sounds much better when someone else chooses to play it. However, the amount of access we now have to music creates a new variation of the old question, "What do you give to someone who has everything?"

Thursday, 13 October 2011

What a Difference a Gym Makes

I got into gyms comparatively late in life, in my mid-forties. At school gym was about the last place I wanted to find myself. No, on second thoughts it was totally the last place I wanted to find myself. I said goodbye to PE at age 18 and never regretted it. Then I read Fantastic Voyage: Live Long Enough to Live Forever, by Ray Kurzweil and Terry Grossman. 'Forever' sounded a bit optimistic, but I was enthused enough to alter my lifestyle in several ways, including putting a bit more exercise into it. I joined the gym near my place of work.

Last month my employer moved location, and the formerly local gym is now remote. Swallowing my tears as I discovered its mandatory three month cancellation period (bast**ds!), I said goodbye and joined the gym nearest our new site.

It's smaller, and several pieces of equipment I'd grown used to are no longer available, and there's a wall with a notice telling me not to use it as a support "for my own safety" (and to prevent me dislodging any more of its loose plaster), but I can ignore all that. Even the fact that they have communal showers (shades of school again).

No, what's bugging me is the average age of my fellow gymnasts (is that the right word?). At the last one, many of the clients were well into their retirement. I could comfortingly reflect on how I was still the Right Side of 60. In the new place I seem to be one of the oldest people there. It's early days, and maybe I'm just having a wrong first impression, but it seems that, rather than being surrounded by people trying to get fit, I now find myself among the already perfectly fit, annoyingly attempting to get even fitter.