by david
12. January 2012 23:34
We've had our iRobot Roomba robot vacuum cleaner for over a year now, so I thought that I should post an update. We're using the iRobot Roomba 531.
We still think it's brilliant and use it virtually every day. One day it goes round downstairs and the following day it does the upstairs. So our house is fully vacuumed every two days.
Battery life still seems good after a year of use. Maintenance is easy (it's good to regularly do a little 'service' to remove hair and fluff from the mechanism). Things that come apart for cleaning only go back in the right way round, which makes it simple to do. Apart from changing the filter we've not had to replace any components in a year of use.
Occasionally it gets snagged on a cable or tangled by a rogue sock left lying around, but it stops before any harm is done.
So if you can afford one, why would you buy a vacuum cleaner that has to be pushed round? The price of the Roomba is pretty similar to top-end manual vacuum cleaners anyway.
We have bought a Dustbuster to do the stairs, which is something that the Roomba cannot do though.
We've just found a supplier in the US who sell HEPA filters for our model of Roomba, so we're going to try those out next.
... and I never did get round to hacking it, partially because it's become so important to us, we don't want to risk breaking it. So the wife says that if I really want to hack a Roomba then I'll have to buy another one :-)
by david
10. January 2012 21:39
I'm pleased to report that over the holidays I was able to find a shop that had a wi-fi enabled Kindle on display for customers to play with.
So of course I couldn't resist pointing it at my DALIS proof of concept... and I found that it worked perfectly! So that's one more platform experimented upon. But I didn't have the courage to take a photo, so you'll just have to trust me on that...
It means that the experimental cloud-based programming language has now been tried out on iPad, iPhone, PlayStation Portable, Kindle and various Windows browsers including IE, Firefox, Chrome and Safari. DALIS has worked on them all. There was just one caveat with Safari, where it didn't seem to handle user input very well, I need to look into that.
Encouraged by that success I'm now in the middle of implementing function calls which will be a big improvement to the language syntax and should allow much better programs.
by david
5. January 2012 23:31
For some reason, I've been making a weather forecasting device by connecting up a Fez Panda II, a Fez Connect Shield and a Fez Touch. So far I have it connecting to my network (using a static ip address) finding the current time (by talking to an NTP server) and then getting the weather forecast from the google api.
It's pretty nifty to be able to get the weather forecast with a simple http request like this:
http://www.google.co.uk/ig/api?weather=cambridge,england&hl=en-GB
I've even gotten the weather icons and popped them onto a microSD card, so when I render the forecast it looks pretty. This is a photo of what I have working so far:
All the code is in C# (.Net Micro Framework) and all the networking is done using plain old Sockets. So when I'm talking to the google api I'm creating a TCP socket and sending the GET request the old fashioned way. All good fun.
I'm actually thinking about building a network of oBIX compliant sensor devices and making this weather forecaster device double up as the central hub... what madness.
by david
18. December 2011 16:55
In the past few months several people have contacted me to ask if I could update my LED USB Message Board driver so that it works on 64 bit machines, especially Windows 7. So I have finally gotten round to that.
It actually took me longer to find the source code than to fix it for 64 bit machines :-) It was one of those seemingly counter-intuitive problems. I had to tell Visual Studio to target x86 machines when compiling to make it work on 64 bit computers. This is because the USB code that I'm using is 32 bit only, so changing the compiliation to target x86 means that a 64 bit machine will know to run the code in 32-bit mode. Easy when you know how.
It might mean this driver has a limited shelf life, I'm probably not going to re-write a specific 64 bit version. So if Microsoft stop allowing 64 bit machines to run 32 bit code then the driver will stop working. But for now it works. It even means that I can use my own LED display again, since I've been running Windows 7 64 bit for ages...
My LED driver page is here.
by david
7. December 2011 23:14
Carrying on my journey of running DALIS programs on the .Net Micro Framework, here is a photo showing some actual screen output:
...apart from having to upgrade the firmware on my Fez Panda to get the screen drivers working it was pretty painless. I have some more work to do yet, I have only written the absolute basics of writing to the screen, but I know it can all be done. I think that I'll probably try to get an IDE 40 pin male to female cable, which will allow me to connect the Fez Touch to the Fez Panda using a flexible cable. Performance of running DALIS programs is not great, so I may have to try and do some optimisation. Having said that, DALIS was never designed to be a high performance language anyway.
by david
6. December 2011 23:59
Now that I have DALIS running in the .Net Micro Framework, I decided that I should try it on some real hardware, so I bought a Fez Panda II to
try it out on. Currently this only supports .Net Micro Framework v4.1, so I had to tweak a few things, but not much.
So here is a screenshot of it running in the Visual Studio debugger:
That's running on the actual hardware, with the output set to come out on the debug console. I'm still testing with the same temperature converter DALIS program. But it works, which is the main thing. The next task is to get the output appearing on the Fez Touch colour screen that I also bought. The end result might be to run DALIS programs from the SD card... or to download them from the web and always run the latest code.
by david
3. December 2011 23:23
For some reason I decided to see if I can get my new DALIS programing language working on the .Net Micro Framework, so I went off and got myself the latest version (4.2) to give it a try. Since the DALIS proof-of-concept was already written in C# I didn't think it would be too hard to port it.
It wasn't a totally trivial excercise, but I thought it's better to try it now rather than do it later when I have implemented lots more features in the DALIS language. The biggest things I had to do was remove any use of Generics and Nullable Types, both of which aren't in the Micro Framework. Apart from that the changes were all minor things. So I've ended up with a single set of source files which can compile in both the full blown .Net Framework and the Micro Framework too. If nothing else, it will force me to write efficient code.
I also had to write some sort of Console Window, so that I could display some output on a screen. If there is some feature for writing text to a console type of output on an LCD screen in the Micro Framework, I didn't find it yet... But I had fun writing my own anyways.
So, here is another example program which shows temperature conversions between Centigrade and Farenheit (running in the emulator, since I haven't got any real hardware for that yet):

...and here is the DALIS source code that I'm running:
min = 30
max = 220
gap = (max-min) / 17
WRITE "deg F deg C"+RETURN
LOOP f=min
c=(5/9)*(f-32)
WRITE TEXT(f,1)+" "+TEXT(c,1)+RETURN
REPEAT f=f+gap IF f<(max+1)
Of course, I also tried running my classic ASCII Mandelbrot, but I promised I wouldn't post any more fractals for a while ;-)
by david
22. November 2011 20:39
I originally wrote DALIS as a cloud based programming language, but since I had abstracted out all the IO, it has been really easy to make a command line version as well. So I have thrown together a few simple scripts to play around with. Consider this, for example:
IF ISASSIGNED("arg1") AND ISASSIGNED("arg2")
min = NUMBER(arg1)
max = NUMBER(arg2)
gap = (max-min) / 10
WRITE "deg F deg C"+RETURN
LOOP f=min
c=(5/9)*(f-32)
WRITE TEXT(f,1)+" "+TEXT(c,1)+RETURN
REPEAT f=f+gap IF f<(max+1)
OTHERWISE
WRITE "You must pass two arguments, min and max."+RETURN
END
As you can see, DALIS programs can now accept parameters (the web based version allows you to pass the parameters in the query string of the url). In this example you specify a minimum and maximum temperature in degrees farenheight and the program makes a simple table converting them to celcius. Here is a screenshot:

You never know, this might even make for a useful little scripting language.
by david
20. November 2011 17:01
As I have mentioned before, I have been adding User Input to my new programming language, codenamed DALIS. Because the language is designed to work in a request / response environment I wanted the language to reflect that without getting over complicated. So this is what I have got at the moment:
WRITE "Welcome to another DALIS program."+RETURN
ASK "Type your name and press ENTER: "
name = ANSWER
IF name="Dave"
WRITE RETURN+"Good morning Dave."
OTHERWISE
WRITE RETURN+"Hello "+name+"."
END
The ASK ... ANSWER syntax looks pretty straightforward to me. If I run this program, this is what happens:

Then I put in a name:

Finally, this is the end result:

It seems to work fine. Simple code which even runs on my phone. I also have a plan to enable forms, so that you can submit several values at once. That is for another day though...
by david
19. November 2011 00:09
OK, so you're probably getting bored of mandelbrots by now. Sorry. But there have been more improvements to DALIS, mainly in the area of string handling; namely there is some. I can now assign string variables and do string comparisons and concatenations. This means that I can output some pretty html with colour and everything :-) Just take a look that this bad boy:

How very retro. But it is like DALIS has jumped from the world of the ASCII character terminals of the 70s to the microcomputers of the 80s. OK, in case you're interested I'm mapping a 9 bit colour palette to the equivalent html colour values. But I'll try not to post any more mandelbrot images for a while, honest.