Guides/JAndroid

From J Wiki
Jump to navigation Jump to search

Install and Upgrade

Before installation, enable Unknown Sources if not yet done.

To access the Unknown Sources setting directly, press the menu icon or button from the Home screen and tap Settings. Select Security (Android OS 4.0+) or Applications (Android OS 3.0 and earlier).

You may need to scroll down to see the Unknown Sources setting.

Open a web browser to download and install jandroid.apk on your Android device. A blue J icon labeled jandroid will appear in launcher screen if installed successfully. The first run will take about 1 minute to decompress files. After installation process has completed, tap on Back Button to finish install.

JKeyboard

This is the JKeyboard from Michael Dykman. Go to Settings >> Language & Input to activate JKeyboard. We do not collect your data. Finally scroll up and select JKeyboard in the default box.

SystemFolders

~install  /storage/emulated/0/Android/data/com.jsoftware.j.android/files
~bin      /data/user/0/com.jsoftware.j.android/app_jandroid/bin
~system   ~install/system
~addons   ~install/addons
~user     ~install/j-user
~home     ~install

other folders will be under ~user

~break
~config
~projects
~snap
~temp

~break is empty and will not be used.

Upon uninstall, all files under ~install will be removed by Android.

Location of Shared Libraries

Startup Files

~install/bin/profile.ijs
~install/bin/profilex.ijs         NB. if present
~home/.jprofile.ijs               NB. if present
~install/bin/startup_android.ijs  NB. if present

profilex.ijs is typically used for setting up system folders. Other customization can be put in either .jprofile.ijs .

Async Mode

By default jandroid runs in sync mode but it can also run in async mode where J engine runs in separate thread. The following features requires async mode

  • console keyboard input of 1!:1[1 and explicit definition
  • debug and suspension (GUI debug not supported)

Use wd command to switch between sync and async mode,

wd 'setj asyncj 0'   NB. sync
wd 'setj asyncj 1'   NB. async

and restart J to take effect.

Force Update

The Android APK file contains system base library and some addons. Whenever jandroid starts, it will check the version number stored in

~install/assets_version.txt

to determine if it needs to decompress and overwriting files. If you want to decompress files again, type

dver ''

and restart J, and then quit again to finish install.

jandroid will switch back to the default sync mode.

Limitation

  • printing not yet supported
  • keyboard shortcut is not supported
  • some addons such as FFTW do not work because of missing shared libraries.

Known issues

  • when jandroid has been killed by Android after a long in-activity period, jandroid can not restart and will crash.

Contributed by Bill Lam