top | item 32592550

Build Android apps without an Android SDK using PicoLisp

126 points| ducktective | 3 years ago |picolisp.com | reply

37 comments

order
[+] victornomad|3 years ago|reply
I took a similar approach with PHONK https://phonk.app

The differences are:

- It uses a Javascript interpreter

- It includes an on-device-hosted WebEditor, so you can code also from your computer

- Simplified API

- API that allows to do cool stuff such connect to Arduinos, BT BLE, MQTT, sensors, etc

After some time on hold I picked up dev again and I'm about to release a pretty nice release soon. I invite you to join the Discord channel as I will start posting updates there :)

https://discord.com/invite/Rt2mkWp

(EDIT: formatting)

[+] flas9sd|3 years ago|reply
thanks for the pointer! As ten-thousands before me I just had the epiphany that phones need to be more like Apple-IIs or a web-inspector, where you drop to a development environment / shell to edit and create your own apps
[+] Reitet00|3 years ago|reply
The play store link seems to be broken or is it just me?
[+] melony|3 years ago|reply
Does this support npm?
[+] prosaic-hacker|3 years ago|reply
I would not be surprised if other constrained interpreter environments could be created like this one. From the descriptions I believe a Hypercard, Logo, python or (forgive me from saying this) Basic scripting could be created.

We could turn lots of older phones into portable toy dev platforms for the next gen of programmers.

10 minutes searching: https://play.google.com/store/apps/details?id=com.krazeapps....

https://play.google.com/store/apps/details?id=and.bas&gl=US

[+] never_inline|3 years ago|reply
> portable toy dev envs

There's also termux and it's predecessors, running debian rootfs with or without root. (Most of them based on proot).

Before proot, there were some manually ported GCC and friends.

Some years ago, I had an android 5 phone and hacked up a fakechroot'ed debian rootfs on a terminal emulator without root. Basically unpacking some debian .debs with statically linked busybox binary, then using a chain of LD_PRELOAD hacks to call a shell with a shim.

But proot is better solution (ptrace instead of shim), and termux is very well done.

On the other hand, if you're thinking about scripting without all the hassle of Unix, I saw an app for experimenting with Android APIs using beanshell [1], I made an attempt to create a modern clone for my Android course project this year, but couldn't take it much far due to shortage of time.

[1] https://f-droid.org/en/packages/org.ligi.ajsha/

[+] 0xdeadbeefbabe|3 years ago|reply
> or (forgive me from saying this) Basic scripting could be created.

It's worth pointing out that no CPUs took offense.

[+] edf13|3 years ago|reply
So just a Lisp interpreter for Android?

>The PilBox App itself (called the "PilBox kernel") is written in Java, the normal Android way. It displays a WebView GUI, and starts a PicoLisp binary compiled for Arm64 CPUs. This binary may now run any PicoLisp program, by setting up a local web server where the WebView component connects to, possibly opening a database, and doing whatever is desired.

[+] dmitrybrant|3 years ago|reply
> So just a Lisp interpreter for Android?

A Lisp interpreter for a single specific ABI of Android, with which you communicate through a local web server. That's... one way to build an app!

[+] paskozdilar|3 years ago|reply
So we have a Java Virtual Machine that runs a PicoLisp Virtual Machine which runs PicoLisp programs.

The circle of life?

Perhaps the next step would be to implement a Java Virtual Machine in PicoLisp.

[+] YourGrace|3 years ago|reply
It's nice to see new tools and SDKs being built to try and simplify development. However, I'm always against frameworks/SDKs which try to abstract away the native coding experience and move developers away from using the SDKs Apple/Google provide.

These types of solutions will always lag behind the official SDKs, and require ongoing maintenance from the authors as new features are added. This also requires individuals to learn something else in addition to the core SDK (I believe you will ultimately need to learn about the core SDK regardless of what you want to do).

In my opinion, working with the native SDKs is the best solution. You are as close to the SDK as possible and are able to do what you want. For Android in particular, it's important to minimize the layers between your code and drawing the UI.

With that said, kudos on building this as it's no easy feat to accomplish.

[+] haolez|3 years ago|reply
I assume the same approach wouldn't be possible on iOS, since it seems very dynamic in nature.
[+] andyjohnson0|3 years ago|reply
I can't find the details right now, but iirc Apple has strict rules about apps that contain interpreters and other execution environments.
[+] DecoPerson|3 years ago|reply
You may be able to run the program on your own iOS devices, but publishing to the App Store is a different story.
[+] anta40|3 years ago|reply
Being able to code in your phone is fun... although as a native Android developer this won't replace Android Studio for me (yes bloated/resource hungry bla bla bla... I know).

Anyway, let's give it a try:

Typing "$ ls -l" on the REPL input box gave: "-> NIL"

And repeated back press won't close PilBox. Seems like it's intentional (or just a bug?). Will take a look at the source code later...

[+] yewenjie|3 years ago|reply
Yes, please. The recommended Android development environment is huge bloat and overwhelming for quickly starting a project.
[+] adamius|3 years ago|reply
This would be great on iOS but I sense it would be blocked by Apple. Ipad/iphone versions would be an excellent addition.
[+] rathereasy|3 years ago|reply
Is this React Native with Lisp instead of JavaScript?