Home

Electronic Projects
  • The Micromite
  • GPS Tracker
  • Colour Maximite Computer
  • The Original Maximite
  • The mini Maximite
  • Intelligent Fan Controller
  • GPS Synchronised Clock
  • GPS Boat Computer
  • GPS Car Computer
  • Making the GPS Computer
  • Energy Meter Firmware
  • ISM Band Scanner
  • Utility Power Supply
  • Precise Voltage Reference
  • Game of Pong
  • Water Level Meter


  • General Articles
  • Problems in Open Source
  • The Maximite Story
  • MMBasic on the UBW32
  • The TFT Maximite
  • Surface Mount is Easy
  • Measuring Capacitor ESR
  • EM-408 GPS Module
  • SG12232A LCD Driver
  • Custom PC Boards
  • The Gerber Format


  • Reviews
  • Hantek DSO-2250 Scope
  • Rigol DS1000 Scope
  • PIC C Compilers
  • Brickbats


  • PC Software
  • Weather Station
  • Mazing


  • About

     

     

     

    This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Australia (CC BY-NC-SA 3.0)

    Colour MMBasic for the UBW32

     


    This page describes MMBasic running on the UBW32, a small experimenter's board based on the PIC32 microcontroller.

    The combination of a powerful BASIC language running on this low cost board makes it a complete and capable computer.  Writing your program is easy as the whole development environment is on the UBW32 and you can quickly run through the test/edit/run cycle.

    MMBasic itself is completely free - you cannot get much better value than that.

    Colour Maximite

    Using the UBW32 you can build your own Colour Maximite.  All you need to do is add the required connectors and a few passive components.  Colour MMBasic includes support for eight colour VGA video output, PS2 keyboard, SD card storage, stereo synthesised sound and many more features.

    Mick Gulovsen has designed a low cost PCB that holds the extra components required and this makes the task much easier.  Populating the board is easy and Mick has even written a comprehensive assembly manual  (see this link for a description and to purchase the board).

    A Maximite built around the UBW32 has exactly the same capabilities and runs the same firmware as the Colour Maximite.  For information on the Colour Maximite click on these links:

    The download section at the bottom of this page has full instructions for creating a Colour Maximite using a UBW32.

    MMBasic on the UBW32

    MMBasic is a Microsoft BASIC compatible implementation of the BASIC language with floating point and string variables, long variable names, arrays of floats or strings with multiple dimensions and powerful string handling.  From within the BASIC language you can control 40 I/O pins which can be independently configured as digital input or output, analog input, frequency or period measurement and counting.

    The focus of MMBasic is ease of use.  The BASIC language was designed to be simple to learn and this makes it easy to whip up a quick program to control a boiler, log data or whatever. MMBasic is also powerful, with a single command you can read a voltage or frequency, control a chip using the SPI protocol, drive a video display and more.

    For example:  
          Read the voltage on pin 5: vlt = PIN(5)
          Display it on USB or a VGA/Composite monitor: PRINT "The reading is" vlt " volts"
          And the resulting display might be:      The reading is 2.87 volts

     

    More examples:  
          Open a file on the internal virtual drive: OPEN "MYDATA.DAT" FOR OUTPUT AS #1
          Save the voltage to that file: PRINT #1, vlt
          Send three bytes via I2C to address 6F (hex): I2CSEND &H6F, 1, 3, s$
          Generate a 100 mSec pulse on pin 8: PIN(8) = 1: PAUSE 100: PIN(8) = 0

     

    The interpreter resides on the board and using it you can try out commands, enter programs and debug them using the USB interface.  You do not need a compiler or another development environment - it is all done on the UBW32.  Other features include a non volatile virtual drive (using the PIC32's flash memory) for storing programs/data, support for an externally connected SD memory card and communications via serial, I2C, SPI and CAN.

    MMBasic also supports a colour VGA monitor directly connected to the UBW32.  The colour video, sync pulses and everything else is generated by the firmware.  Multiple fonts and graphics commands are available so you can generate a rich display on the many low cost 6 to 8 inch monitors now becoming available.

    More Information

    The UBW32 can be purchased from sparkfun.com and dontronics-shop.com

    For the PC board (designed by Mick Gulovsen) to make the UBW32 into a Colour Maximite see this link.

    For support on the UBW32 go to the creator's web site (http://www.schmalzhaus.com/UBW32) or the SparkFun forums (http://forum.sparkfun.com/viewforum.php?f=23).

    There is a library of programs that run under MMBasic.  This includes games, utilities and demonstration snippets of code. You can download the latest MMBasic Library from the Maximite page.

    MMBasic Firmware for the UBW32

    The UBW32 runs exactly the same version of MMBasic as the Colour Maximite.  So, when you are looking for an updated version of the firmware, look for the Colour Maximite version.  That will load and run on the UBW32 exactly the same as on the Colour Maximite.

    Note that the Colour Maximite version uses different connections for the VGA, keyboard, etc compared to the previous monochrome firmware for the UBW32 (version 3.2C).  If you want to retain compatibility with the previous connections you should continue to use version 3.2C (which can be found in the archive).

    UBW32 and MMBasic Support

    The main Maximite web page lists the support options and resources for all Maximite versions including the UBW32.

    Source Code to MMBasic

    The source code for MMBasic is available from the main MMBasic website at http://mmbasic.com

    Downloads

    Instructions - Colour MMBasic for the UBW32 DOWNLOAD
    Colour Maximite MMBasic firmware (will run on the UBW32) DOWNLOAD
    Windows Serial Port Driver (for connection to a Windows PC via USB) DOWNLOAD

    For information on the Colour Maximite click on these links:

    Other useful pages: