Re: [Pharo-users] Want to run C code in Pharo using UFFI

2020-06-18 Thread Rob van Lopik
You may want to have a look at:
https://fuhrmanator.github.io/2019/03/16/LibC-Pharo-experiments.html

hth
rob van lopik

>
> ***
>


[Pharo-users] SerialPort hangs image in combination with Raspberry Pico (Windows)

2021-06-29 Thread Rob van Lopik
I have the following strange situation, where SerialPort>>nextPutAll: hangs
when sending to a COM port that is (USB) connected to a Raspberry Pico
(RP2040). The Pico contains a simple program (sketch) that echoes all input
on it USB-serial port. This is written with the Arduino IDE. The echo
function works OK with the Arduino Serial monitor, PuTTY and a simple
Python progran. When I put the same echo program on another Arduino board
(e.g. Uno or Adafruit Feather) Pharo's SerialPort does work fine. I have
tested with 32 and 64 bits versions of Pharo 5, 7 and 8. All on Windows; on
Raspbian there is no problem.

So, there is something peculiar with the combination of the SerialPlugin
and the USBserial implementation on the Pico (which uses TinyUSB), but I am
at a loss as to where to search. Maybe somebody has a hint. I have seen
problems with the Serial Plugin in the past.

I ran into this when developing a driver for the Raspberry Pico, where the
Pico runs the  picod daemon (http://abyz.me.uk/picod/index.html). This code
is in https://github.com/robvanlopik/picod-pharo and does not work on
Windows.

Rob van Lopik


[Pharo-users] Pharo on Raspberry Pi in 2024

2024-01-19 Thread Rob van Lopik
With the new Raspberry Pi 5 (8Gb) I finally got hold of, and the new
Raspberry OS (Bookworm 12), I thought it was time to try Pharo again (see
Pharo issue #11841 by @astares). I used zero-config with version
specification, like 'get.pharo.org/100+vm'. (On pharo.org there are no OBS
packages for Bookworm).

Using Raspberry Imager I put 64-bits Bookworm on the Pi5. The installs for
Pharo 9, 10 and 11 worked OK. Pharo12 does not work because
files.pharo.org/get-files/120 does not contain an aarch64-vm. The P12
image does work with the VM downloaded for P11. UI performance is excellent.

Next I tried 32-bits Bookworm (Raspberry OS 12) on the Pi5. As there are no
recent 32-bits Pharo images (issue #12769) I only tried P9 and P10.
Directly using zero-config loads 64-bit Pharo and even explicitly
specifying 32-bit (through 'get.pharo.org/32/90+vm') results in a
64-bit download. The reason is, that the Pi loads a 64-bit kernel even when
the OS itself is 32-bits. This means the command 'uname -m' that is used by
zero-config, returns 'aarch64' instead of 'armv7l'. I will report this on
the zero config repo. So I downloaded and unzipped manually.. Pharo 9 works
fine. The Pharo 10 image misses Playground in the menu, but ctrl+O+W works.

On a Pi 4 (8Gb RAM)  with 64-bits Bookworm Pharo 10 is OK. Pharo 11 (with
VM 10.0.5 2023-05-05) gives an error: '[ERROR] 2024-01-16 21:37:55.000
sqAllocateMemory (src/memoryUnix.c:160):I cannot find a good memory address
starting from: 0x100'. With 32-bits Bookworms it behaves the same
as the Pi (i.e. it also loads a 64 bits kernel)

Next I tried the same on a Raspberry Pi 3B+ (1Gb memory).
For 64-bits the Raspberry Imager default to the Bullseye version (11) .
Pharo 10 and 11 complain about a wrong libc.so version and don't work.
Using Bookworm ( 64-bit) Pharo 10 runs OK . Pharo 11 does not work, with
the same error as on the Pi4

Last I tried the Raspberry Pi Zero 2W (512 Mb RAM, but only €20!).
First 32-bits Bookworm. Pharo9 works. Pharo10 also with the incomplete
latest image. 64-bits Bookworm seems a bit heavy for this  board, but it
works.  Pharo10  runs, more or less. Maybe headless would be quite useful.
Pharo11 gives the same memory allocation error as on the Pi 4 and 3B+

Summary:
- On the Pi 5 all Pharo 64 bits versions work
- On other Pi's only version 9 and 10 work. Pharo11 has a memory allocation
error.
- Recent 32-bits Pharo images are lacking; especially for the cheap Pi Zero
I would really like to see whether 32-bits is more usable.