Author Topic: X11 to Droid  (Read 8456 times)

B+

  • Guest
X11 to Droid
« on: October 04, 2018, 02:51:14 PM »

B+

  • Guest
Re: X11 to Droid
« Reply #1 on: October 05, 2018, 03:57:17 PM »
I downloaded this to check it out and dang! the shortcut icon has me on the command line.

Has anyone used X11?

B+

  • Guest
Re: X11 to Droid
« Reply #2 on: October 07, 2018, 01:33:24 PM »
Things are not working out so well for me with X11, I can drag and drop a simple Hello World onto xbasic (using Windows laptop) the interpreter and the one sample program but using anscicon with shortcut icon or xbasic from command prompt, files are not found.
True I am rusty with primitive ways of loading and running programs but I don't know if X11 even works in Windows 10 environment.

Too bad, there are some nice features in X11, complex number type, arbitrary long integers, Word$() function, GLOB... it has both interpreter for developing code and compiler for faster runs.

The 710 page pdf manual takes allot of scrolling and paging around because nothing is hyper-linked.

So maybe some very nice features if you can ever get this thing to fly.

Oh the Android version supposedly does have an IDE, so there is hope there.




jj2007

  • Guest
Re: X11 to Droid
« Reply #3 on: October 09, 2018, 03:24:02 AM »
Quote
The syntax is most similar to GFA-Basic for ATARI-ST. It is a structured dialect with no line numbers. A full manual and command reference is available. GFA-programs should run with only a few changes. Also DOS/QBASIC programmers will feel comfortable.
I still have a hundred GFA programs hanging around, the biggest one at 365 kBytes - a full-scale editor with graphics capability, and a heavy dosis of embedded 68000 assembly. It still runs fine on this Win7 machine, using the Steem emulator. A screenshot, produced right now:

Here is a short sample of the syntax:
Code: [Select]
Procedure Calc(Y$)
  Local Ti%,Is%
  Clr R_err%
  Sub C.max%,Instr(Y$," e")=0
  Do
    Is%=Instr(Y$," ")
    Exit If Is%=0
    Dec C.max%
    Y$=Left$(Y$,Is%-1)+Mid$(Y$,Is%+1)
  Loop
  Repeat
    Is%=Instr(Y$,")")
    Exit If Is%<2
    @R.ins("(",Left$(Y$,Is%-1))
    Sub R_err%,Ris%=0
    If Ris%
      Yl$=Left$(Y$,Ris%-1)
      Yr$=Mid$(Y$,Is%+1)
      Y$=R.i$
      @Calc0
      Clr Ogs%
      If Len(Yl$)>=3
        Ogs%=(Instr("SINCOSTANLOGLGEMAXMIN",Upper$(Mid$(Yl$,Ris%-3,3)))+3)/Tgv%
      Endif
      If Ogs%
        W=Val(Y$)
        Wl=W*Pi/180
        On Ogs% Gosub C1si,C1co,C1ta,C1lo,C1lg,C1max,C1max
        Y$=Left$(Yl$,Ris%-Tgv%)+Str$(W)+Yr$
      Else
        Y$=Yl$+Y$+Yr$
      Endif
    Endif
  Until R_err%
  Sub R_err%,Instr(Y$,"(")>0
  @Calc0
  X0=Val(Y$)
  Add C.max%,Len(Str$(X0))-Len(Y$)
  If R_err%
    Clr Play!
    @Melde(H44%,Str$(R_err%)+" Syntaxfehler")
  Endif
Return
That was February 1986 btw. How QBASIC programmers should feel "comfortable" here, though, seems a mystery to me  ;D
« Last Edit: October 09, 2018, 04:01:00 AM by jj2007 »

B+

  • Guest
Re: X11 to Droid
« Reply #4 on: October 09, 2018, 12:52:54 PM »
Yes scoping of variables is different but same as SmallBASIC, all is global unless declared LOCAL.

Calling procedures with @ is yucky specially for functions but I think QB had CALL for subs, JB still does.

EXIT IF is weird too.

Have yet to figure out what Clr is for, clear a variable value?

jj2007

  • Guest
Re: X11 to Droid
« Reply #5 on: October 09, 2018, 02:52:41 PM »
Calling procedures with @ is yucky specially for functions but I think QB had CALL for subs, JB still does.

The @ calls a sub; functions are declared with DEFFN and used with somevar=FN myfunction(x, y, z)

Quote
EXIT IF is weird too.

Almost the same as in assembly:
.Repeat
  ... do stuff ...
  .Break .if eax==edx
  ... do stuff ...
.Until eax>somevar

Quote
Have yet to figure out what Clr is for, clear a variable value?

Exactly.

Cybermonkey

  • Administrator
  • *****
  • Posts: 0
Re: X11 to Droid
« Reply #6 on: October 09, 2018, 06:21:02 PM »
Maybe you want to have a look into the GFA-BASIC 32 for Winddows (also runs in 64 bit): http://gfabasic32.blogspot.com/
It comes with an editor and comprehensive help files/user manuals.

B+

  • Guest
Re: X11 to Droid
« Reply #7 on: October 09, 2018, 08:21:35 PM »
Sounds good!

Get me some of JJ's background before I attempt MASMBASIC ;-))

jj2007

  • Guest
Re: X11 to Droid
« Reply #8 on: October 09, 2018, 08:46:54 PM »
Maybe you want to have a look into the GFA-BASIC 32 for Windows

I have programmed for over a decade with the 16-bit Windows version, a great dialect - unfortunately its author was not interested in porting it to 32-bit. I vaguely remember that Hamstra's product is horribly bloated and slow, and not at all compatible with the 16-bit version. That's why I develop MasmBasic ;)

P.S.: I've given Gfa32 a chance. The interpreter runs fine, the compiler compiles, but the exe complains that it can't find GfaWin23.Ocx, a one MByte runtime which happens to be hidden away in gb32\Bin\GfaWin23.Ocx. And no, the name is not a typo of mine, it's really GfaWin23 8)

253 sample files, and none of them contains the term string array. GfaBasic 16's most useful command, Recall, is implemented but no example available; ok, the manual has one, and it works if you know beforehand how many strings the text file has. MasmBasic Recall has dynamic arrays, and is over a factor 7 faster than Gfa32.
« Last Edit: October 09, 2018, 10:43:20 PM by jj2007 »

Tomaaz

  • Guest
Re: X11 to Droid
« Reply #9 on: October 10, 2018, 07:44:36 PM »
Maybe you want to have a look into the GFA-BASIC 32 for Winddows...

B+, maybe you want to have a look at Commodore 64... I'm only joking. ;) I can clearly see that you love language hopping, so here is a little advice. It's time to move to other languages - real fun starts there. Try Processing, Ruby with Shoes, Lua with LOVE, NewLisp, Euphoria... But this time try to forget this "it doesn't come with editor and doesn't have a build-in command to draw a circle, so it's not beginner friendly" nonsense and force yourself to stay with something for more than one hour.  ;)

B+

  • Guest
Re: X11 to Droid
« Reply #10 on: October 10, 2018, 07:49:49 PM »
Oh not same Gfa as JJ's experience. OK understood.

I already have it downloaded so I will see how it compares to getting started with X11.

Apparently I have a "moral obligation" to donate to the author, well maybe I will if I like it and use it.

Is this the way to get around being a commercial product?

Tomaaz posts just as I was going to post this. I have checked Ruby, Java, Java Script and Python a couple of times. I need my circles dang it!

Tomaaz

  • Guest
Re: X11 to Droid
« Reply #11 on: October 11, 2018, 07:01:04 AM »
I have checked Ruby, Java, Java Script and Python a couple of times.

But did you give them more than 15 min. each?  ;)


B+

  • Guest
Re: X11 to Droid
« Reply #12 on: October 11, 2018, 01:23:47 PM »
I have checked Ruby, Java, Java Script and Python a couple of times.

But did you give them more than 15 min. each?  ;)

Do you think I would not pursue with passion something that I found fun? I assure you it wouldn't matter if BASIC were in the name or not. Something with BASIC in it's name does suggest a graphics based pl unless it is preceded by the word Script. Even there I suspect a proper plug-in extension and or library and all would be well with the familiar language.

Wasn't it you who wrote a tutorial for a graphics based pl, surely you know or once did what I am liking.

I confess abstract lectures on object heredity bore me to tears. I think my projects are never big enough to benefit from advantages of objects.

Tomaaz

  • Guest
Re: X11 to Droid
« Reply #13 on: October 13, 2018, 05:58:55 PM »
Something with BASIC in it's name does suggest a graphics based pl unless it is preceded by the word Script.

Does it? My first BASIC was BASIC V2 on C64 and it didn't have any graphics commands.

Wasn't it you who wrote a tutorial for a graphics based pl...

Yes. It was about Lua.

I confess abstract lectures on object heredity bore me to tears. I think my projects are never big enough to benefit from advantages of objects.

Then have a look at Processing (I wonder what will be not beginner friendly this time - my guess is curly braces). Or at LOVE - this time dots and clear (but long) function names will make it beyond beginner's capabilities.

Peter

  • Guest
Re: X11 to Droid
« Reply #14 on: October 14, 2018, 09:31:28 AM »
It's pretty cool that Xbasic is available for Android devices. I know programming on a small device can be fun. Once, on a boring holiday long time ago, I programmed the game of Tetris on my Psion 3mx. This device comes with a BASIC like language called OPL containing some graphical commands.

I remember it was great fun, however, the Psion had a real keyboard, a relatively bigger screen, and the OPL itself was tightly integrated with the capacities of the device.

However, generally, I notice that programming on an Android phone is still very cumbersome. The soft keyboard is way to clumsy to enter code and the screen usually too small for real debugging. I guess programming languages need a better integration in Android to be real fun...  ???