Topics

BBC BASIC for SDL 2.0 v1.00a released

R.E.
 

  Yes that's what I meant to say.   I compile the prog in apk on windows.
But the Mac must be done on a Mac.
-Steve

Richard Russell
 

On Wed, Feb 6, 2019 at 05:02 AM, R.E. wrote:
Basically ill need to cpmpile on the Mac platform but i can move the apks to the android. 
Windows, not Mac.  BBC2APK is a 'compiled' BB4W program, it runs only on Windows.

R.E.
 

I get it now.  Basically ill need to cpmpile on the Mac platform but i can move the apks to the android.  So i wlll get a used Mac
   That is the simplest way in the long run

Thanks again
Ido uunderstand what i need to do.
Steve Hatch

Richard Russell
 

On Tue, Feb 5, 2019 at 05:09 AM, R.E. wrote:
I can simply put the file I download from your site
into my Android and have it install then compile my program there
Mobile platforms are an exception to the rule: whilst you will need an Android device to test your program, building your 'application bundle' (APK file) must be done on a Windows PC.  It remains to be seen if it will be possible to implement a similar process for iOS, but if it is then building for that platform will need to be done on a Mac.  Otherwise (that is, for desktop platforms) you need to create the application on the target platform.

R.E.
 

  Thank you very much for the info on moving to a Mac.
  I will find a Mac somewhere.  I think as you said that is the simplest solution for me.
 I have an Android phone so I can proceed with that path for now.   I can simply put the file I download from your site
into my Android and have it install then compile my program there.  I managed to get the code changed enough
that it runs in the apk on my windows so I'll try moving it.
   Once more Mr Russell I want to thank you for your great program.   It has me coding again after a 30 year layoff.
I'm writing all the little programs I want as I want them.  Nice.
-Stephen Hatch
Dewey Arizona

Richard Russell
 

On Mon, Feb 4, 2019 at 09:26 PM, DaveinSpain wrote:
Take your finger off and it should be there, where your finger was!
Draw it yourself then: job done!  You don't need OS support for that.

I think I've become quite simple minded and it is frustrating.
Since I'm also suffering that way - probably worse than you - I can't help!

DaveinSpain
 

Take your finger off and it should be there, where your finger was!
This was to help me build a sliding block puzzle.
See: http://www.squarerootgames.com/pictures/DirtyDozenPuzzle_StartingPositions.jpg

I've been examining your excellent jigsaw puzzle but can't get the hang of using structures and how to move the blocks. I think I've become quite simple minded and it is frustrating.
Dave N

On Feb 4, 2019 19:15, Richard Russell <news@...> wrote:

>
> On Mon, Feb 4, 2019 at 05:56 PM, DaveinSpain wrote:

>>
>> I wanted it to see exactly where on a picture I am pointing.


>
> I'm not sure that I understand.  Using a touch screen 'conventionally' you wouldn't be able to see a pointer because it would always be underneath your finger or stylus.  Even if you have a transparent stylus (I've never seen one) the usual reason for wanting a mouse pointer - to make sure you are in the right place before 'clicking' - doesn't apply because you must already be touching the screen by then.

Richard Russell
 

On Mon, Feb 4, 2019 at 05:56 PM, DaveinSpain wrote:
I wanted it to see exactly where on a picture I am pointing.
I'm not sure that I understand.  Using a touch screen 'conventionally' you wouldn't be able to see a pointer because it would always be underneath your finger or stylus.  Even if you have a transparent stylus (I've never seen one) the usual reason for wanting a mouse pointer - to make sure you are in the right place before 'clicking' - doesn't apply because you must already be touching the screen by then.

DaveinSpain
 

Thanks Richard,
Yes, you are so right! I don't get any sort of pointer at all (not on any screen). I wanted it to see exactly where on a picture I am pointing.
Dave N

On Feb 4, 2019 18:21, Richard Russell <news@...> wrote:
>
> On Mon, Feb 4, 2019 at 01:37 PM, DaveinSpain wrote:
>>
>> Is MOUSE ON 3 implemented?
>
> MOUSE ON 3 is certainly implemented in BBCSDL, yes, but you mention Android and presumably the entire concept of 'mouse pointer' only has a meaning if you use an actual mouse rather than the touchscreen!  Considering how unusual it is to use a mouse with a 'mobile' device I wouldn't be at all surprised if you only get a 'generic' pointer, but I've not tried it myself.

Richard Russell
 

On Mon, Feb 4, 2019 at 01:37 PM, DaveinSpain wrote:
Is MOUSE ON 3 implemented?
MOUSE ON 3 is certainly implemented in BBCSDL, yes, but you mention Android and presumably the entire concept of 'mouse pointer' only has a meaning if you use an actual mouse rather than the touchscreen!  Considering how unusual it is to use a mouse with a 'mobile' device I wouldn't be at all surprised if you only get a 'generic' pointer, but I've not tried it myself.

DaveinSpain
 

V1.00a, I like it.
One query (not confined to this version): Is MOUSE ON 3 implemented? I can't get it to work on this Android tablet.
I DID wonder if it was the same colour as the background but I've now tried it without any success.
Dave N

Richard Russell
 

On Sun, Feb 3, 2019 at 05:38 PM, Martin wrote:
This enables me to easily move files from my machine to the Mac, and then to use the Mac remotely to install BBCBASIC SDL and use it to Compile and test my program, all from my Windows machine.
Yes, that is indeed a workable approach if somebody with a Mac is prepared to make it available for remote access.

Martin
 

On 03/02/2019 10:28, Richard Russell wrote:
On Sat, Feb 2, 2019 at 10:20 PM, R.E. wrote:

Or do I need to load BBC basic on a Mac (I don't have one) and
compile it there?
Yes. There are several reasons why you must 'compile' (that is,
create an application bundle) on the target platform. Firstly the
process must, of course, have access to the correct edition of the
run-time engine. Secondly, it is highly likely that the process will
rely on tools that are only available on the target platform (that is
certainly true of MacOS, on which the 'hdiutil' utility must be used
to create the .dmg file).
Last, but not least, it is essential that you test your program on
every platform that you target.
[snip]

I agree with all that. However, there is a way to achieve it without owning a Mac, which I use to develop a program on Windows, then make it available to a friend on a Mac.

I have installed TeamViewer on my machine, and on the (remote) Mac. It is free for personal use - and secure! This enables me to easily move files from my machine to the Mac, and then to use the Mac remotely to install BBCBASIC SDL and use it to Compile and test my program, all from my Windows machine.

In your case, you just need one of your friends who is willing to install TeamViewer and allow you to use it, and to give you any help with the very different ways to use a Mac if you are not familiar. Note that they will always have to authorise your use. The 'Compilation' results in a single file which can be installed in the Mac applications directory. That file can then be simply used by other Mac users to install on their machines.

Richard Russell
 

On Sat, Feb 2, 2019 at 10:20 PM, R.E. wrote:
Or do I need to load BBC basic on a Mac (I  don't have one) and compile it there?
Yes.  There are several reasons why you must 'compile' (that is, create an application bundle) on the target platform.  Firstly the process must, of course, have access to the correct edition of the run-time engine.  Secondly, it is highly likely that the process will rely on tools that are only available on the target platform (that is certainly true of MacOS, on which the 'hdiutil' utility must be used to create the .dmg file).

Last, but not least, it is essential that you test your program on every platform that you target.  Whilst BBCSDL is a cross-platform language, and every effort has been made to maximise compatibility across the range of supported platforms, that does not mean that every program which runs on (say) Windows will run on every other platform without modification.

For example, Linux uses case-sensitive filenames, and if you don't test your program it is easy to have a mismatch between a filename that your program uses and the actual name of the file.  MacOS has thread-dependencies that other platforms don't have, which can mean some API calls (even basic ones like SDL_ShowSimpleMessageBox) need to be written with this is mind.  Android doesn't have the concept of Current Directory, and so on.

So since you will always need to test your program on every platform you target, it should not be a major inconvenience to have to build the application on that platform too.  That may well involve purchasing a suitable machine if you don't have one, but it needn't imply a huge expense if you get it second-hand from (say) eBay.  Sadly, but inevitably, distributing software these days often involves expenditure, e.g. for things like Code Signing Certificates which are increasingly necessary in this malware-infested world.

But when it comes down to it a Mac is probably the only major investment that most cross-platform software developers will have to make.  If they have a Windows PC they can dual-boot it into Linux for no expense, a Raspberry Pi costs less than £35, and they or a family member or friend are likely to have Android and iOS devices.

R.E.
 

Thank you Richard.you have produced a great program.
     I successfully completed a little program to create train orders on my windows machine.
 I'd like to put it on MacOS  for some of my friends who like the program but have a Mac.

   Is there a way to compile this source code to create a Mac version?
Or do I need to load BBC basic on a Mac (I  don't have one) and compile it there?
 not sure how to continue.  Thanks for any help
-Stephen Hatch

John Alfred
 

Thanks Richard,

That's amazing !

I now have BASIC on my iPhone, and an old Android-SAMSUNG.

I'm still getting to grips with the Android version, and might have a few questions yet. I'm really looking forward to getting the 'Cross-compiler' version going !

John A

On Saturday, 2 February 2019, 14:54:50 GMT, Richard Russell <news@...> wrote:


I have today released version 1.00a of BBC BASIC for SDL 2.0, the cross-platform programming language for Windows, Linux, MacOS, Raspberry Pi, Android and iOS (I recently canvassed opinion on whether it was appropriate to allocate this version number, and the consensus was to do so).  The changes in this version are as follows:

IDEs / Compiler:
  1. SDLIDE can now load Acorn-format programs (however no ARM BASIC 5 token substitution takes place).
  2. SDLIDE supports the Cross Reference add-in utility, which is very similar to that provided with BB4W.
BASIC Interpreter / Run Time Engine:
  1. The MODE statement in the ARM and 64-bit interpreters now ignores the high bit (so MODE 135 is the same as MODE 7), as it always has in the 32-bit x86 editions.
  2. The ARM (32-bit) assembler's ALIGN directive can take a numeric parameter, causing it to emit (if necessary) NOP instructions to achieve the specified alignment.  It has been found that aligning a small time-critical loop on an 8-byte boundary (ALIGN 8) can significantly improve performance.
Libraries: The following libraries have been added:
  1. ellipse.bbc: This is functionally equivalent to the BB4W library of the same name.
  2. treeview.bbc: This implements a Tree View control similar to that available in Windows (with thanks to Svein).
Example Programs: The following example programs have been added:
  1. seascape.bbc: A demonstration of the power of GPU shaders; it needs a fast GPU for good performance and may not work on all machines.
  2. ellipses.bbc: The 'angled ellipses' demonstration as supplied with BB4W.
This new version may be downloaded, for all the supported platforms, from the usual location.  The GitHub repository (used to build the MacOS, Raspberry Pi, iOS and 64-bit Linux editions, currently) has been updated.

bobfburns@...
 

Thank you Richard.

Regards

Bob

Bob F Burns
C Eng, FIET, MSE. G3OOU, @BobFBurns
Retired Electronics and Software Consultant
http://www.g3oou.co.uk/myexperience.html
On 02/02/2019 14:54, Richard Russell wrote:

I have today released version 1.00a of BBC BASIC for SDL 2.0, the cross-platform programming language for Windows, Linux, MacOS, Raspberry Pi, Android and iOS (I recently canvassed opinion on whether it was appropriate to allocate this version number, and the consensus was to do so).  The changes in this version are as follows:

IDEs / Compiler:
  1. SDLIDE can now load Acorn-format programs (however no ARM BASIC 5 token substitution takes place).
  2. SDLIDE supports the Cross Reference add-in utility, which is very similar to that provided with BB4W.
BASIC Interpreter / Run Time Engine:
  1. The MODE statement in the ARM and 64-bit interpreters now ignores the high bit (so MODE 135 is the same as MODE 7), as it always has in the 32-bit x86 editions.
  2. The ARM (32-bit) assembler's ALIGN directive can take a numeric parameter, causing it to emit (if necessary) NOP instructions to achieve the specified alignment.  It has been found that aligning a small time-critical loop on an 8-byte boundary (ALIGN 8) can significantly improve performance.
Libraries: The following libraries have been added:
  1. ellipse.bbc: This is functionally equivalent to the BB4W library of the same name.
  2. treeview.bbc: This implements a Tree View control similar to that available in Windows (with thanks to Svein).
Example Programs: The following example programs have been added:
  1. seascape.bbc: A demonstration of the power of GPU shaders; it needs a fast GPU for good performance and may not work on all machines.
  2. ellipses.bbc: The 'angled ellipses' demonstration as supplied with BB4W.
This new version may be downloaded, for all the supported platforms, from the usual location.  The GitHub repository (used to build the MacOS, Raspberry Pi, iOS and 64-bit Linux editions, currently) has been updated.

Richard Russell
 

I have today released version 1.00a of BBC BASIC for SDL 2.0, the cross-platform programming language for Windows, Linux, MacOS, Raspberry Pi, Android and iOS (I recently canvassed opinion on whether it was appropriate to allocate this version number, and the consensus was to do so).  The changes in this version are as follows:

IDEs / Compiler:
  1. SDLIDE can now load Acorn-format programs (however no ARM BASIC 5 token substitution takes place).
  2. SDLIDE supports the Cross Reference add-in utility, which is very similar to that provided with BB4W.
BASIC Interpreter / Run Time Engine:
  1. The MODE statement in the ARM and 64-bit interpreters now ignores the high bit (so MODE 135 is the same as MODE 7), as it always has in the 32-bit x86 editions.
  2. The ARM (32-bit) assembler's ALIGN directive can take a numeric parameter, causing it to emit (if necessary) NOP instructions to achieve the specified alignment.  It has been found that aligning a small time-critical loop on an 8-byte boundary (ALIGN 8) can significantly improve performance.
Libraries: The following libraries have been added:
  1. ellipse.bbc: This is functionally equivalent to the BB4W library of the same name.
  2. treeview.bbc: This implements a Tree View control similar to that available in Windows (with thanks to Svein).
Example Programs: The following example programs have been added:
  1. seascape.bbc: A demonstration of the power of GPU shaders; it needs a fast GPU for good performance and may not work on all machines.
  2. ellipses.bbc: The 'angled ellipses' demonstration as supplied with BB4W.
This new version may be downloaded, for all the supported platforms, from the usual location.  The GitHub repository (used to build the MacOS, Raspberry Pi, iOS and 64-bit Linux editions, currently) has been updated.