User Tools

Site Tools


en:projects:gforth-android:start

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
en:projects:gforth-android:start [2015-06-12 03:20] – [Troubleshooting] bernden:projects:gforth-android:start [2018-07-01 20:03] (current) bernd
Line 4: Line 4:
 ===== Project Status ===== ===== Project Status =====
  
-  * There is [[https://play.google.com/store/apps/details?id=gnu.gforth&|Gforth in Play Store]], installable on Android 2.3 or later (native activity) +  * There is [[https://play.google.com/store/apps/details?id=gnu.gforth&|Gforth in Play Store]], installable on Android 4.0 (Android 2.3 support dropped on 2018-03-31) or later (native activity) 
-  * This has a OpenGL terminal emulation and allows remote telnet on port 4444 (depending on what you call in ''/sdcard/gforth/site-forth/starta.fs'')+  * This has a OpenGL terminal emulation and allows remote telnet on port 4444 after you type in ''t'' and return.
   * It recognizes touches, and the menu button/softkey toggles the software keyboard   * It recognizes touches, and the menu button/softkey toggles the software keyboard
 +  * If the font is too small/large, use ''gl-fscale'' ( r -- ) with a float number as scale factor (<1 makes the font smaller, >1 bigger).  Example: ''3e gl-fscale'' makes the font three times larger, ''0.5e gl-fscale'' smaller by a factor of two.
  
 Starting the app first time unpacks the Gforth sources to the SD card.  That's a few megabytes, and therefore it takes its time.  Gforth shows a spinning wheel while it's doing so, but can't respond to any input events.  If the spinner shows you "Done; restart Gforth" for a while, you should kill and restart Gforth - it got stuck.  If you still have problems, there's a gfortherr.log and a gforthout.log in /sdcard, which might provide more diagnosis. Starting the app first time unpacks the Gforth sources to the SD card.  That's a few megabytes, and therefore it takes its time.  Gforth shows a spinning wheel while it's doing so, but can't respond to any input events.  If the spinner shows you "Done; restart Gforth" for a while, you should kill and restart Gforth - it got stuck.  If you still have problems, there's a gfortherr.log and a gforthout.log in /sdcard, which might provide more diagnosis.
Line 17: Line 18:
   * [[https://play.google.com/store/apps/details?id=de.ubuntix.android.mygermankeyboard|Deutsche Tastatur]]   * [[https://play.google.com/store/apps/details?id=de.ubuntix.android.mygermankeyboard|Deutsche Tastatur]]
   * [[https://play.google.com/store/apps/details?id=com.jb.gokeyboard|Go Keyboard]]   * [[https://play.google.com/store/apps/details?id=com.jb.gokeyboard|Go Keyboard]]
 +
 +Since Android apps can't be started from the command line, you can enter options for starting Gforth in the file ''/sdcard/gforth/home/.options'' One line per option.  ''-d64k'' e.g. sets the stack to 64kB, ''-m16M'' the dictionary to 16MB, see [[http://www.complang.tuwien.ac.at/forth/gforth/Docs-html/Invoking-Gforth.html]]
 ===== Examples ===== ===== Examples =====
  
Line 33: Line 36:
   * ''>o'' ( addr o:old -- o:addr r:old ) makes addr the current object, and pushes the previous current object onto the return stack.   * ''>o'' ( addr o:old -- o:addr r:old ) makes addr the current object, and pushes the previous current object onto the return stack.
   * ''o>'' ( o:addr r:old -- o:old ) pops the previous object from the return stack.   * ''o>'' ( o:addr r:old -- o:old ) pops the previous object from the return stack.
-  * ''ref>'' ( o:addr r:old -- o:old ) same as o>, but includes releasing a local reference.  Unlike Java's heap and stack, JNI memory is not part of the garbage collector, and therefore uses reference counting.  If you get an object from a Java call, you should use ''ref>'' to pop it after use, this allows the garbage collector to release this object.  There is only a limited space for references, so release them soon. +  * ''xref>'' ( o:addr r:old -- o:old ) same as o>, but includes releasing a local reference.  Unlike Java's heap and stack, JNI memory is not part of the garbage collector, and therefore uses reference counting.  If you get an object from a Java call, you should use ''xref>'' to pop it after use, this allows the garbage collector to release this object.  There is only a limited space for references, so release them soon.  ''xref>'' determines, which sort of reference that is, and correctly handles global and temporary references.
-  ''gref>'' ( o:addr r:old -- o:old ) global references passed from one thread to another require a global release This applies to objects passed as part of messages+
  
 To define a method or a field, you use the following words: To define a method or a field, you use the following words:
en/projects/gforth-android/start.1434072031.txt.gz · Last modified: 2015-06-12 03:20 by bernd