PureBasic Forum

my two robots in a contest ...
Page 1 of 1

Author:  marc_256 [ Wed Aug 15, 2018 5:07 pm ]
Post subject:  my two robots in a contest ...


Me and my daughter want to do a contest with are robots.
We have two identical robots, except one with robot arm to catch some can's.

sorry, only in dutch ...

The robots are programmed for 100% in 68K assembler.
The contest rules, assignments and instructions are given in the morning,
and we have 6 hours to construct and write program for these assignments.
So, in asm it is very hard to write and debug in a short time.
And writing in basic is much easier.
I only need math, rs232, and do some text conversions to $hex and $bin.
I was thinking to port PB from amiga to this 68K SBC.

As I understand, the PB for amiga is open-source ...
as my robots are running on a 68K Single Board Computer an no amiga.

1) is this possible to port PB to my 68k SBC ?
2) where can I get the source in ascii code ?

the bobo's team
marc en elia

Author:  tinman [ Wed Aug 22, 2018 10:04 pm ]
Post subject:  Re: my two robots in a contest ...

marc_256 wrote:
1) is this possible to port PB to my 68k SBC ?

Probably not.

The compiler is written to run on AmigaOS and makes use of the OS libraries. It also calls other executables e.g. PhxAsm. So if you wanted to code in PB for your SBC you would need to port the compiler. However, the PBCompiler is not open source. For Fred's full announcement see here: https://www.purebasic.fr/english/viewtopic.php?f=14&t=24952&p=173691&hilit=opensource#p173691

If you get around the compiler problem the rest of it looks possible.

The PureBasic libraries are written in assembler, so you might only need to port the RS232 library for your SBC. Maybe the math library. Possibly also the string library as it no doubt uses memory allocation which you might not have on your SBC if you are running without an OS?

The output from PureBasic is designed to be run as an application running under the AmigaOS. I assume your SBC runs bare metal? If so you will need some changes to the output maybe for specifying linker addresses, handling interrupts, setting up stacks and so on.

marc_256 wrote:
2) where can I get the source in ascii code ?

At the bottom of this page:


You need to extract an LZX archive (search the web for unlzx for your OS). But it does not include the source for the compiler.

Page 1 of 1 All times are UTC + 1 hour
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group