Extending Tiny BASIC on the Arduino

I was intrigued by @monsonite’s challenge to extend Tiny BASIC for the Nanode. I don’t have a Nanode, but I do have some Arduinos, and extending Mike Field’s Tiny BASIC port to include some additional Arduino functionality seemed pretty straightforward. An hour or so staring at the code told me pretty much all I need to do, so I went ahead and added a DELAY statement to duplicate the Arduino delay() call, a MODE keyword (duplicating pinMode()) and WR (duplicating digitalWrite()).

If you put all these together, you can write simple LED blinking programs entirely in BASIC. Check it out:

I might see how far I can take this idea during my vacation.

Addendum: Why does YouTube always choose a frame where my eyes are closed as the default marquee image?

Tiny Basic running on Nanode – Christmas Challenge

As a followup to my post yesterday regarding Arduino BASIC, here’s a contest challenge to extend the Arduino basic to drive the Nanode, an Arduino compatible microcontroller board that extends the conventional Arduino with Ethernet and other cool features. The challenge is to make a good hack using Tiny BASIC: perhaps by extending the BASIC interpreter to include commands for accessing all the additional peripheral devices that the Nanode has. Neat!

Sustainable Suburbia: Tiny Basic running on Nanode – Christmas Challenge

Addendum: It only took me a few minutes of staring at the code to figure out how to add a “DELAY” command that can pause execution. It wouldn’t be hard to add equivalents to the digitalRead, digitalWrite, analogRead and analogWrite. Maybe I’ll give this a try myself over the next few days.