4tH on Android 2.2 (Froyo)

60 views
Skip to first unread message

The Beez

unread,
Apr 12, 2013, 10:54:19 AM4/12/13
to 4th-co...@googlegroups.com
Hi 4tH-ers!

My wifes HTC Wildfire was in need of recharging all the time, so in short: she bought a new one. Needless to say I confiscated the old one ;-) I installed an SSH server, FTP server, HTML server and ATE and started hacking.

Not all my favorite apps ran as expected, but I found a few ones that did. Then it was time to start hacking. Those of you who got such a small phone will know that typing in ANYTHING is not very comfortable. Hence the SSH server ;-) Still, for some things I needed ATE, most importantly, the 4tH package.

HTC Wildfire has Froyo. I followed instructions (very strange experience from my part of the fence) and I got 4tH running. PP4tH took its time to convert TEONW,4PP, but for just a couple of seconds, which IMHO is acceptable. Running IVANTSOV.4tH took over a minute, much worse than e.g. a Raspberry Pi. TEONW didn't run noticeably slower.

But, bottom line: 4tH works on Android 2.2, confirmed.

Hans Bezemer

Ron K. Jeffries

unread,
Apr 12, 2013, 11:09:12 AM4/12/13
to 4th-co...@googlegroups.com
I (currently) own a Motorola Droid 3. I think it has Android 2.3 I am not sure it is worth your time or mine to try 4tH since I am a total newbie. On the other hand, if it works on 2.2 it may also work on Android 4.2.2 Jellybean, which runs on Google Nexus 7.

By the way, many (most) low-cost Chinese tablets run Android 2.x Not sure what SOC the HTC Wildfire uses. Many Chinese tablets use the Allwinner SOC, which is on balance an impressive processor.

Just stream of consciousness I guess. Nothing to see here people, move along.

Ron K Jeffries

---
Ron K. Jeffries







--
You received this message because you are subscribed to the Google Groups "4tH-compiler" group.
To unsubscribe from this group and stop receiving emails from it, send an email to 4th-compiler...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Hans Bezemer

unread,
Apr 12, 2013, 11:25:30 AM4/12/13
to 4th-co...@googlegroups.com
On Friday 12 April 2013, Ron K. Jeffries wrote:
For those interested in the performance:

Platform OS Forth Compiler Cell Time
-------- -- ----- -------- ------ ----
Spectrum 48K ZX-BASIC Artic Forth Z80 assembler 16 bit 53:50 mins
Sun Sp Ultra1 Solaris 4tH V3.2 GCC 32 bit 0:18 mins
RS/6000 250 AIX V3 4tH V3.2 XL C V1.3 32 bit 0:30 mins
P5/600 DOS V5 4tH V3.3 DJGPP V2.72 32 bit 0:05 mins
P5/600 Win 3.1 4tH V3.3 Turbo C++ V3.0 32 bit 0:06 mins
P5/166 DOS V5 4tH V3.2 DJGPP V2.72 32 bit 0:09 mins
P5/166 Win 3.1 4tH V3.2 Turbo C++ V3.0 32 bit 0:21 mins
486/33 DOS V5 4tH V3.2 Turbo C V2.0 32 bit 2:45 mins
486/33 DOS V5 4tH V3.2 DJGPP V2.72 32 bit 1:11 mins
486/33 DOS V5 FPC V3.55 8086 assembler 16 bit 0:29 mins
486/33 DOS V5 PFE V09.12 Unknown 32 bit 0:45 mins
486/33 DOS V5 CForth Turbo C V2.0 16 bit 11:26 mins
486/66 DOS V5 NIB Forth Unknown 16 bit 10:55 mins
486/66 Win V3.1 AtLast Turbo C++ V3.0 16 bit 5:08 mins
486/66 Win V3.1 4tH V3.2 Turbo C++ V3.0 32 bit 1:23 mins
486/66 DOS V5 CForth Turbo C V2.0 16 bit 5:45 mins
486/66 DOS V5 4tH V3.2 Turbo C V2.0 32 bit 1:22 mins
THIS COMPUTER Unknown 4tH V3.62 Unknown 32 bit 0:58 mins

BTW, it is confirmed to work on Android 4.x. I wouldn't be surprised if it ran
on Android 2.1, because that was the version AFAIK the HTC had before I
upgraded the firmware (Don't ask ;)).

Hans Bezemer
--
I have no Facebook account. Consequently, I have no friends and I don't like
anything. Deal with it.

Visit our website! http://thebeez.home.xs4all.nl/4tH/

*** Home of the 4tH compiler! ***

Ron K. Jeffries

unread,
Apr 12, 2013, 11:32:20 AM4/12/13
to 4th-co...@googlegroups.com
Results show Compiler (or assembler) as Unkown for your Android result. But I assume you used a cross compiler?
Or is the issue that you do not know what C compiler Google provides as part of their Android support kit?

Would be fun to have the your 4tH on RasPi result in that same table at some point. ;)


---
Ron K. Jeffries






Hans Bezemer

unread,
Apr 12, 2013, 11:47:20 AM4/12/13
to 4th-co...@googlegroups.com
On Friday 12 April 2013, Ron K. Jeffries wrote:
> Results show Compiler (or assembler) as Unkown for your Android result. But
> I assume you used a cross compiler?
> Or is the issue that you do not know what C compiler Google provides as
> part of their Android support kit?
The others are hard-coded. I have no way to determine the actual c-compiler
used. This compile was done on the Pi itself. Much easier. Nowadays I pull in
the current source with SVN.

> Would be fun to have the your 4tH on RasPi result in that same table at
> some point. ;)

Platform OS Forth Compiler Cell Time
-------- -- ----- -------- ------ ----
Spectrum 48K ZX-BASIC Artic Forth Z80 assembler 16 bit 53:50 mins
Sun Sp Ultra1 Solaris 4tH V3.2 GCC 32 bit 0:18 mins
RS/6000 250 AIX V3 4tH V3.2 XL C V1.3 32 bit 0:30 mins
P5/600 DOS V5 4tH V3.3 DJGPP V2.72 32 bit 0:05 mins
P5/600 Win 3.1 4tH V3.3 Turbo C++ V3.0 32 bit 0:06 mins
P5/166 DOS V5 4tH V3.2 DJGPP V2.72 32 bit 0:09 mins
P5/166 Win 3.1 4tH V3.2 Turbo C++ V3.0 32 bit 0:21 mins
486/33 DOS V5 4tH V3.2 Turbo C V2.0 32 bit 2:45 mins
486/33 DOS V5 4tH V3.2 DJGPP V2.72 32 bit 1:11 mins
486/33 DOS V5 FPC V3.55 8086 assembler 16 bit 0:29 mins
486/33 DOS V5 PFE V09.12 Unknown 32 bit 0:45 mins
486/33 DOS V5 CForth Turbo C V2.0 16 bit 11:26 mins
486/66 DOS V5 NIB Forth Unknown 16 bit 10:55 mins
486/66 Win V3.1 AtLast Turbo C++ V3.0 16 bit 5:08 mins
486/66 Win V3.1 4tH V3.2 Turbo C++ V3.0 32 bit 1:23 mins
486/66 DOS V5 CForth Turbo C V2.0 16 bit 5:45 mins
486/66 DOS V5 4tH V3.2 Turbo C V2.0 32 bit 1:22 mins
THIS COMPUTER Unknown 4tH V3.62 Unknown 32 bit 0:01 mins

I told you the HTC was slow..?

Ron K. Jeffries

unread,
Apr 12, 2013, 12:04:46 PM4/12/13
to 4th-co...@googlegroups.com
On Raspian (Debian) on Raspberry Pi the C compiler would be GCC.

---
Ron K. Jeffries






Hans Bezemer

unread,
Apr 12, 2013, 12:26:41 PM4/12/13
to 4th-co...@googlegroups.com
On Friday 12 April 2013, Ron K. Jeffries wrote:
> On Raspian (Debian) on Raspberry Pi the C compiler would be GCC.
I know, sorry. I just meant the script can't "know" with what the underlying
4th programs has been compiled.

TianMing

unread,
Apr 12, 2013, 9:49:28 PM4/12/13
to 4th-co...@googlegroups.com
static cell    *Hld;                   /* equivalent of forth HLD */
static cell    *Here;              

beez, can you teach me something about the two pointer,what are they used for?
if each forth compiler need the two pointer as pad or “hld”?

--
You received this message because you are subscribed to the Google Groups "4tH-compiler" group.
To unsubscribe from this group and stop receiving emails from it, send an email to 4th-compiler+u...@googlegroups.com.

Hans Bezemer

unread,
Apr 13, 2013, 11:18:51 AM4/13/13
to 4th-co...@googlegroups.com
On Saturday 13 April 2013, TianMing wrote:
> static cell *Hld; /* equivalent of forth HLD */
> static cell *Here;
>
> beez, can you teach me something about the two pointer,what are they used
> for? if each forth compiler need the two pointer as pad or “hld”?
Both are pointers within the PAD string buffer. PAD is actually split into two
parts: a "circular string buffer" and a "number composition buffer" where the
string picture of a number is composed.

E.g. when you issue ".", the integer on the stack has to be converted into a
series of digits. HLD is close to the variable name this pointer has in
Forth. It works from higher memory to lower memory, since the least
significant digit is rightmost. Each time a digit has been added, HLD is
decremented. (BTW, that is why it is hard to use ".S" to debug an <# #>
expression, since ".S" uses that buffer as well to print the stack
items ;) ).

HERE is part of the circular string buffer. It starts of at the beginning of
PAD. Then a temporary string has to be created e.g. "123456789". Including
the NULL character, that means that HERE is incremented with 10. When a
string threatens to spill into the number composition buffer, HERE is reset
to PAD, overwriting whatever old stuff is there and the cycle starts all over
again.

Theoretically, the number composition buffer MAY spill into the circular
buffer, but it is sized in such a way that that chance is quite remote -
especially when you're using a 32 bit version, since it is sized for a 64 bit
architecture.

Hans Bezemer

unread,
Apr 13, 2013, 11:26:40 AM4/13/13
to 4th-co...@googlegroups.com
On Saturday 13 April 2013, TianMing wrote:
> if each forth compiler need the two pointer as pad or “hld”?
BTW, "HLD" yes. Every Forth has a number composition buffer as the ANS
standard requires (even it's size is predetermined). "HERE", no. First,
ANS "HERE" is more like the "HERE" keyword in 4tH, second: the ANS standard
doesn't require that this works:

s" Hello" s" Hallo" compare

In 4tH and several other Forths it works as advertised, but it is not true ANS
(an environmental dependancy).

Tian Ming

unread,
Apr 13, 2013, 6:01:09 PM4/13/13
to 4th-co...@googlegroups.com
OK,I will continue checking the 4th source code ,thank you so much, best regards to you

发自我的 iPhone
> --
> You received this message because you are subscribed to the Google Groups "4tH-compiler" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to 4th-compiler...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages