On Sun, 03 Jan 2021 21:16:36 +0000, Joe wrote:
> On Sun, 3 Jan 2021 19:36:54 -0000 (UTC)
> Martin Gregorie wrote:
>
>> A fairly rapid web search failed to discover whether unsigned
>> arithmetic is a feature of the BASIC
>
> There is no feature list of BASIC.
>
I know that all so-called BASICs differ, some radically from the original
Dartmouth BASIC. I thought that the context would make it plain that I
was talking about PICAXE BASIC, which differs enough from traditional
BASICs to be given another name (labels not numbers for branch
destinations and subroutines, long names for variables, named constants,
unsigned arithmetic and comparisons, conditional statement inclusion).
> No. All the arithmetic operators are signed,
>
Not according to the current PICAXE BASIC manual, which gives numeric
ranges for 8 and 16 bit variables capable of containing byte values in
the range 0-255 and explicitly says that byte values are unsigned. It alao
says that 16 bit variable can hold 0-65535, which implies, though it
doesn't state, that these are unsigned.
See https://picaxe.com/docs/picaxe_manual2.pdf
If this is a mistake, they get a down vote for not correcting their
manual, despite having three years to have made the correction - I bought
the PICAXE and downloaded to manual 2.5 years ago and then got distracted
from that project, but the online manual's wording (section 2, page 13)
remains the same - I just checked.
BTW I'm using the PICAXE-14M because I need at least 3 PWM outputs. and,
to put this on topic for the RPi group, am running the BASIC compiler/
uploader on a headless Pi 2B. This setup successfully uploads compiled
code to the PICAXE and displays messages from it on the RPi's
console.
--
--
Martin | martin at
Gregorie | gregorie dot org
--- SoupGate-Win32 v1.05
* Origin: Agency HUB, Dunedin - New Zealand | FidoUsenet Gateway (3:770/3)
|