Android Question B4A Interpreter

Discussion in 'Android Questions' started by Adie, Sep 21, 2017.

  1. Adie

    Adie Member Licensed User

    I am looking for an interpreter that I can use to execute a .BAS file at runtime.
    The B4A app must be able to post the variables to the interpreter and then call the code (maybe a SUB). On return from the sub the required variables must be 'read' back and local processing will continue.

    I am porting an industrial control program from Windows (C++) to Android things. We currently use a product 'FastScript' that can compile C++ code on the fly and execute it almost at main app speed. It is seen as an object by the host app. All variables in the script have read/write access from the main app.

    I looked at this:
    As I am new (seldom use) to B4A I've got no clue where to start.

    Any Ideas?

  2. Erel

    Erel Administrator Staff Member Licensed User

  3. Adie

    Adie Member Licensed User

    Ok, I found BeanShell, a full Java interpreter. Look Here:

    There is a downloadable .JAR file (bsh-core) which is all I need to 'get into B4A' :)

    1: how do I generate the .XML file from the JAR?
    2: before I spend too much time on this, will this work?

  4. Adie

    Adie Member Licensed User

    And then I found BasicLib 1.4 from agraham that will work for now so I can carry on with the development.

    I would prefer BeanShell. Still don't know how to access the subs in the BeanShell JAR file which I would like to use.

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice