Welcome Guest, you are in: Login

Fruit Of The Shed

Navigation (MMBasic)






Search the wiki

»


Search Engine

Here you can search through the pages of this Namespace, their attachments and the files uploaded to the system.
Note: the results will only display the items you have permissions to read.



Filter by Category

Select allNoneInvert









































This search, performed through 3.39 MB (230 documents, 12918 words), completed in 0.0 seconds and yielded 30 results.

MMBasic Source Compression Utility — 4.4%

This module is part of the original MMBasic library. It is reproduced here with kind permission of Hugh Buckle and Geoff Graham. Be aware it may reference functionality which has changed or is deprecated in the latest versions of MMBasic. Note : Any required file(s) are available in the attachments tab (top right). MMBasic Source Compression Utility CRUNCH.bas v2.4 Author: Hugh Buckle June 2013 Updated: Dec 2014 to v2.4 This suite of programs takes an MMBasic program, reduces its [...]

MMBasic Source Code Formatter — 2.8%

This module is part of the original MMBasic library. It is reproduced here with kind permission of Hugh Buckle and Geoff Graham. Be aware it may reference functionality which has changed or is deprecated in the latest versions of MMBasic. Note : Any required file(s) are available in the attachments tab (top right). MMBasic Source Formatter ver 2.3 20/4/2013 Format.bas is a program to indent lines of MMBasic source code in order to highlight the program structure. Four methods [...]

LCD Panels Summary — 2.2%

[...] page is an attempt to summarise and link to the various LCDPANEL drivers available for the various MMBasic platforms. These can be built in (OPTION LCDPANEL xxxx), Cfunction loadable drivers or MMBasic drivers implemented with the OPTION LCDPANEL USER method. The scope includes links to various TBS threads that discuss supporting PCB designs, drivers etc, where to purchase. In general this page will try to link to relevant threads on TBS rather than reproduce the information here. This page initially inspired by @panky's TBS post . TBS [...]

_MMBasic Code Library — 2.2%

Welcome to the {NAMESPACE} namespace (zone) of MMBasic is an interpreter for members of the PIC 32MX & 32MZ, STM H7 & L4 micro-controllers, the Raspberry Pi and a DOS version. Principally developed by Geoff Graham for PIC32MX and later Peter Mather's eXtreme version for the PIC32MZ and versions for the STM H7 and L4, you can get it and read all about it here:  http://mmbasic.com/ It provides a rich programming interface that harks back to the "feel" of the original (and widespread) MicroSoft Basic languages with definite influence from [...]

RENUM.BAS — 2.2%

This module is part of the original MMBasic library. It is reproduced here with kind permission of Hugh Buckle and Geoff Graham. Be aware it may reference functionality which has changed or is deprecated in the latest versions of MMBasic. Note : Any required file(s) are available in the attachments tab (top right). RENUM.BAS RENUM.BAS is written in MMBasic and requires at least version 4.3a. Renum.bas renumbers basic files, the same way the RENUMBER command used to work in version of MMBasic [...]

Some Hints & Tips for writing efficient code. — 2.0%

[...] aimed at the MicroMite range of micro-controllers but the ideas are fully migrate-able across all the MMBasic platforms and beyond. On the smaller micromites, some tasks can be a big ask for an interpreter at 48MHz (or slower). Some of the following tips got an RC4 encryption algorithm usable - it was struggling to do un-encrypt >> process >> encrypt in under 1.5 seconds. It's still tight for long strings but it's usable now. So these tips can help and even have proved vital in some instances - do not dismiss as mere pedantry too lightly. This isn't an exhaustive list; [...]

UnixTime or Epoch Time — 2.0%

[...] local time, it will only be UTC if the time on the relevant system is UTC. The following function for MMBasic returns the number of seconds since midnight on 1st January 1970 as an integer. UnixTime correctly takes account of leap years in its calculations but leap seconds are ignored - this conforms with the established method of calculating UnixTime as leap seconds are arbitrary and not generally predictable. Because of this, very small errors may exist when the output is compared to astronomical clocks. There is little sanity checking performed on the strings you provide. [...]

Polar and Rectangular Co-ordinate Conversion Functions — 1.6%

[...] whether the angles are expressed in Radians (0) or Degrees (non-zero). Syntax: Polar (X,Y[,opt]) - the output will be in the two global variables Th and R Rect (Theta,radius[,opt]) - the output will be in the two global variables X and Y Examples: Polar 10,27,1 : Print Th,R > 20.3231 28.7924 Rect 20.3,28.7,1 : Print X,Y > 9.95705 26.9174 'Preamble CONST Deg2Rad=360/(2*Pi) Dim Float Th,R,X,Y Sub Polar(x As Float,y As Float,opt As Integer) ' opt [...]

ARMMite H7 Pin Aliases — 1.6%

The ARMMite H7 is a new MicroMite running MMBasic on the powerful STM32H743ZI and STM32H753ZI MicroController. You can grab the complete firmware and join the discussion here: backshed forums . The previous discussion is 18 pages(!) but worth reading to get the full story, but bear in mind it has been superseded by the former and is no longer updated: old thread It seems a popular way of utilizing this processor for small production/hobbyist is ST's Nucleo evaluation board. There are several suppliers but Farnell/Element14 seem to be well priced with good availability. [...]

IsNumeric Function (VB Work-A-Like) — 1.6%

[...] in scope in that only simple numeric notation is supported. It will test validity for both integer (opt=0 or absent) and decimal number strings (opt 0). It is intended for use where an arbitrary input must be forced into numeric compliance. It does not sanitize the string (out of scope for a small building block), rather providing an indication if the argument is/not compliant. Usage: =IsNumeric(MyString,Option) Examples: x=IsNumeric("345") If Not IsNumeric(a$,1) Then Print "Not a Number" Caveats: The string cannot be blank "" No support [...]

BIN8.BAS — 1.6%

This module is part of the original MMBasic library. It is reproduced here with kind permission of Hugh Buckle and Geoff Graham. Be aware it may reference functionality which has changed or is deprecated in the latest versions of MMBasic. Although MMBasic contains a function to return a binary string of any length from an argument, this module is interesting because it contains a number of useful function beyond simple conversion. BIN8.BAS ReadMe - crackerjack, March 2012 The BIN8.BAS "library" of byte-wide [...]

MMSudoku — 1.6%

This module is part of the original MMBasic library. It is reproduced here with kind permission of Hugh Buckle and Geoff Graham. Be aware it may reference functionality which has changed or is deprecated in the latest versions of MMBasic. Note : Any required file(s) are available in the attachments tab (top right). Hello all. Here's SUDOKU for Maximite version 1.0 (final?). Features: Requires MMbasic v3.1. Three types of difficulty: Easy, Medium and Hard. In the empty grid you can enter numbers and key lock. [...]

command to print text files on screen — 1.4%

This module is part of the original MMBasic library. It is reproduced here with kind permission of Hugh Buckle and Geoff Graham. Be aware it may reference functionality which has changed or is deprecated in the latest versions of MMBasic. Note : Any required file(s) are available in the attachments tab (top right). SHOW.BAS ' * Show command v1.1 by Juri Fossaroli * a$=MM.CmdLine$ If a$="" Then Input "input filename to show";a$ If a$="/?" Or a$="/i" Or a$="/I" Then ? "Show command v1.1 by Juri Fossaroli" ? "Use this command [...]

Shape drawing for Complex Lines and Polygons — 1.4%

The MMX and ST variants of MMBasic implement a Polygon command that takes a set of points in two integer arrays and draws an outline of the area with the option to fill the interior. The following is inspired by this command but includes an option to draw the data as either a line or a polygon. There is no option to fill the enclosed area. As written below, the routines use the Cartesian drawing commands (see dependencies) to provide co-ordinate 0,0 in the bottom left of the display. It is an easy enough job to replace the relevant drawing commands with the native ones [...]

SHIFT or ROTATE an array of integers — 1.4%

[...] confessed below. As written below, the routines will allow a shift or rotate (depending on the value of the opt[ion] flag passed in). For now, they are supremely lazy, simply performing a 1 bit shift the number of times you request. i.e. if you shift the array 10 bits, it goes round the loop ten times. In that respect, I suppose they are faithful to the inspiration in that the Z80 didn't possess the barrel shifter of more modern CPUs that can shift any number of bits in a single cycle. I wanted to be clever and calculate a "cookie cut" on each array member but then [...]

Driving LCD from MMBasic — 1.4%

This module is part of the original MMBasic library. It is reproduced here with kind permission of Hugh Buckle and Geoff Graham. Be aware it may reference functionality which has changed or is deprecated in the latest versions of MMBasic. Note : Any required file(s) are available in the attachments tab (top right). Demonstrates how to talk to a "standard" LCD display based on the Hitachi HD44780 controller and compatibles. Later versions of MMBasic have inbuilt commands which are simple and faster. If you have [...]

Small Strings — 1.4%

This module is part of the original MMBasic library. It is reproduced here with kind permission of Hugh Buckle and Geoff Graham. Be aware it may reference functionality which has changed or is deprecated in the latest versions of MMBasic. Note : Any required file(s) are available in the attachments tab (top right). This code is intended for early versions of MMBasic where strings were fixed at 255 characters in length (but after PEEK and POKE were implemented). This is no longer the case but this code is included [...]

MM_Event — 1.4%

This module is part of the original MMBasic library. It is reproduced here with kind permission of Hugh Buckle and Geoff Graham. Be aware it may reference functionality which has changed or is deprecated in the latest versions of MMBasic. Note : Any required file(s) are available in the attachments tab (top right). SE02.BAS : 'File....: SE02.Bas ' 'Author..: Simon Whittam ' 'Email...: s.whittam(at)xnet.co.nz ' 'Date....: 8th September 2013 ' 'Language: Maximite BASIC, v4.4 ' 'Purpose.: To provide an [...]

HumanTime() Function to return a human readable date and time from a unixtime number — 1.2%

[...] Unixtime() translate each-others outputs. A format option formats the date part as follows: DD-MM-YYYY when opt=0 or omitted (this matches DATE$) YYYY-MM-DD when opt 0 The option can be omitted if required Syntax: HumanTime(ut[,option]) Example Usage: Print HumanTime(ut_from_log,1) or Print HumanTime(ut_my_birthday) Dependencies: The following functions must be included in your program for HumanTime() to work correctly... IsLeapYear Function ZPad$ Function HumanTime(UUT As Integer,opt As Integer) [...]

Maxifont.bas — 1.2%

This module is part of the original MMBasic library. It is reproduced here with kind permission of Hugh Buckle and Geoff Graham. Be aware it may reference functionality which has changed or is deprecated in the latest versions of MMBasic. Note : Any required file(s) are available in the attachments tab (top right). Maxifont is a small program written by Dennis Wyatt for the Maximite Computer by Geoff Graham 2011/2012. It will create a font, based on your input and save the font to a filename of your choice, appended with the .fnt descriptor. [...]

Quick and Dirty Daylight Indicator — 1.2%

[...] This version includes an optional parameter to return the start and finish times of daylight also: Opt=1 returns the start of daylight in minutes since midnight on the given date. Opt=2 returns the end of daylight. Requires a single string which is a concatenation of the standard DATE$ and TIME$ strings as argument - see the Now() Function for an easy interface. NOTE does not support the international date sort form (yyyy-mm-dd...) - yet. Syntax : x=IsDayLight(strDateTime,opt) Do not use Daylight saving datetime [...]

AFTER, EVERY, AT, REMAIN Flexible State Machine Timers using Semaphores. — 1.2%

[...] Locomotive Basic commands of the same names and make executing sections of code asynchronously a breeze. MMBasic provides four timers but they expect a sub program to be called each time and they have to be handled (i.e. if they are one-shot) by the called sub. The following code uses a single MMBasic timer but then expands this to practically unlimited timers and really easy to set one running. The main loop simply checks for the relevant flag and takes action (calls a Sub, changes the state of an output pin etc...) if it is set. After Set [...]

Compatibility between Micromite MkII MMBasic and MicroMite Extreme (MMX) MMBasic — 1.2%

[...] and CFunctions encapsulate blocks of hex machine code to augment the functionality and capability of MMBasic on that platform The MicroMiteXtreme uses the PIC32MZ range of microcontrollers and although the MMBasic [...]

Now() Function (VB work-a-like) — 1.0%

[...] converted into DD/MM/YYYY HH:MM:SS which is arguably the most useful format to default to. Although MMBasic can't hope to support the different datatypes of modern languages, the Now() function is really useful instead of having to construct it each time. This function does that - OK, it isn't rocket science to concatenate the DATE$ and TIME$ but it reduces program size and, I think, makes program flow easier to read. Now() supports an optional date-format parameter. The default is zero which results in the date following the system format of DD-MM-YYYY. If opt [...]

Colour Demos — 1.0%

This module is part of the original MMBasic library. It is reproduced here with kind permission of Hugh Buckle and Geoff Graham. Be aware it may reference functionality which has changed or is deprecated in the latest versions of MMBasic. Note : Any required file(s) are available in the attachments tab (top right). Demonstration programs for the Colour Maximite: CMM4_TST.BAS A test program that demonstrates various graphics on the Colour Maximite running in MODE 4. These include coloured lines, boxes, circles and moving images on the screen [...]

Battery Management for 12V System — 1.0%

This module is part of the original MMBasic library. It is reproduced here with kind permission of Hugh Buckle and Geoff Graham. Be aware it may reference functionality which has changed or is deprecated in the latest versions of MMBasic. Note : The required file(s) are available in the attachments tab (top right). ' ' Battery Management Program for Caravan 12V System ' Copyright Doug Pankhurst May 2013 ' Written for MMBasic V4.3a, copyright Geoff Graham 2012 ' ' ' File Version: 2.04 May 2013 ' This is an updated [...]

A Simple GUI pack — 1.0%

A purely MMBasic GUI pack to provide a WindowsCE/95 look-a-like LCD panel interface for your projects. This is a work in progress in my spare time. This document has lots of improvements required - and I'll do them... just need a bit more time. Still to come: Lists, Drop-down Lists, tab strips, pop-up windows (if I can work out a way to do it). As it is now, it provides a lot of functionality and is usable. If you only need the simpler end of the GUI - buttons, checkboxes, radio buttons and text boxes etc, it is good to go. Let's face it; they probably cover 100% of [...]

Measuring RMS (algorythm) using MMBasic — 1.0%

[...] is a method of implementing RMS measurements on a mains AC signal, with minimal external circuit, in MMBasic on a small micromite. The name RMS (Root Mean Square) explains exactly what is involved: Take the square root of the mean value of all the measured value to the power two. 1/ take samples from an ADC 2/ calculate the square root of each sample and sum them all up. 3/ divide by the number of samples (summing and divide by number is essentially the mean value) 4/ take the square root of the mean value. In essence there is no start and end to this process. But if [...]

Backpack Tracker curve tracer — 0.9%

[...] measure the current and convert the measurements to an impedance graph. The software is written in MMBasic, the native language of the Micromite Backpack. Since the PIC32 processor can only output voltages in the range of 0V..3.3V, an additional amplifier is needed to achieve the +/- 15V. This amplifier, and it's power supply, are located on a third printed circuit board. The amplifier schematics are shown here: A short explanation of the circuit: The PIC32 processor does not have a DAC output that can be used to generate different voltages, therefore a PWM output [...]

DCF77 DigiClock — 0.8%

This module is part of the original MMBasic library. It is reproduced here with kind permission of Hugh Buckle and Geoff Graham. Be aware it may reference functionality which has changed or is deprecated in the latest versions of MMBasic. Note : The required file(s) are available in the attachments tab (top right). ' -------------------------------------------------------------------------- ' ' [...]