Messing about with Ncurses

For a long time I've been aware of Ncurses, but I've never actually used it. So when I accidentally wandered across this tutorial for using Ncurses in Xcode, I decided that it would be worth checking out.

But, when I found myself with a few spare minutes... I was sitting in front of a machine running Debian Linux rather than Mac OS X. So I experimented there instead. To get the snakey program to run I had to do the following:

  1. First of all, I had to get the ncurses stuff:
    sudo apt-get install libncurses5-dev

  2. Then I had to compile the example code (I had renamed the program to box.c):
    gcc box.c -lncurses -o box

  3. Then finally, I could run it:
    ./box

So that was pretty easy. Ncurses is one of those things that I'd like to mess about with some more, because I still like running stuff in a console window.

More hudl notes

So, after fiddling with my Tesco hudl for a reasonable amount of time, here are some more of my thoughts... In fairness I should state that the other tablet I've used a lot is an iPad mini, so that tends to be what I'll naturally compare it to.

So here goes:

  • standby mode on the hudl uses much more battery than I'm used to with the iPad mini. You're much better off shutting down the hudl when you're not using it for a while. It will make a big difference if you shut your hudl down at night, for example.
  • the software feels a little more flaky than the iPad ... the hudl has frozen up a couple of times and needed a reboot.
  • it doesn't always reconnect to wifi automatically if you have been out of range. I've had to manually reconnect to my home wifi a few times.
  • you can hide most of the Tesco stuff quite easily, so you don't need to have Tesco in your face if you don't want it (which is what I've done).
  • some people say the touchscreen is not as responsive as an iPad ... but I've not noticed too much. Although gestures, like swiping across the screen seem slightly more difficult to achieve than on an iOS device. But it hasn't caused me any problems.
  • the on-screen keyboard / predictive text can be annoying sometimes. But maybe I just need to get used to it.
  • the hudl always seems to make a startup sound... even when you've silenced everything else. If you boot up your hudl then be prepared to advertise it :-(
  • overall, I have no major complaints considering the price, I think the hudl is a good value little tablet.

When I have a choice I tend to revert back to the iPad mini, but I am much happier dragging the hudl around Cambridge in my bag. So far, the hudl is doing exactly what I wanted... so I'm generally impressed.

Bluetooth Speaker: Minx Go

A while back (probably towards the end of 2012 in fact) I saw one of those Bose SoundLink bluetooth speakers being demonstrated. I was pretty impressed and made a mental note that it would be a cool thing to buy. Since my phone/tablet/laptop all have bluetooth, it makes sense to be able to beam out some nice quality sounds from them. If nothing else, it's a bit like having a hi-fi in every room of your house, you can just carry the speaker round with you.

Anyway, now I've finally decided to get one there seems to be a lot more choice, and there are some cheaper alternatives that still give good sound quality.

So I've bought a Minx Go made by Cambridge Audio. It's quite an impressive thing and has worked with every bluetooth device I've got. It also means that if we're watching BBC iPlayer on my MacBook, then I can enjoy nicer sound quality.

The Minx Go is a bit bigger than the Bose one, but that doesn't matter to me... It was quite a lot cheaper though.

But despite the cheaper price, the sound quality still seems excellent as evidenced by the review in What Hi-Fi found here where it receives top marks. It especially gives nice bass for a relatively small unit I reckon.

Of course, other bluetooth speakers are available, but I have to say I'm quite happy with my choice.

Running 'nweb' on Mac OS X

For some time I've admired the simple web server code called nweb, which can be found here. It's written in C and shows how you can build a nice simple little HTTP server without scary amounts of code. The code even runs on the Raspberry Pi.

It's written for Unix and Linux systems, but I wanted to see if it would work on my MacBook (which runs Mac OS X, obviously). Since Mac OS X has a Unix heritage, I hoped it would work without too much trouble...

So I fired up Xcode and created a blank "Command Line" application in C, then I just pasted in the nweb source code. It gave just one compilation error.

All I needed to do was replace SIGCLD with SIGCHLD in one line of code. Then it worked! Nice.

So that's awesome, a very handy little command line web server for Mac OS X.

I'm sure I will find a use for that. The old brain cogs are whirring as I type this in fact.