Page 1 of 1

Scratch 3 Desktop Version for Raspberry Pi

Posted: Thu Jan 03, 2019 10:32 am
by penguintutor
Now that Scratch 3 has been released are there any plans for a Raspberry Pi (Linux) version of the Desktop version? Scratch 3 can be run through a browser today, but the desktop version is required for offline use and to support physical computing using the Raspberry Pi GPIO ports?

If so is there anything that members of the Raspberry Pi community can assist? Perhaps programming or testing?

I'm happy to help myself. I don't have the time to run the project myself (and wouldn't want to duplicate work if there is a project already in the pipeline), but I would be happy to help if I can.

Re: Scratch 3 Desktop Version for Raspberry Pi

Posted: Thu Jan 03, 2019 10:48 am
by jamesh
Currently Scratch3 does work in online mode in Chromium, if/when offline becomes available is up in the air. We do talk to MIT re: Scratch, and discussions are on going with regard to the offline version.

Sorry, that's all the information I have.

Re: Scratch 3 Desktop Version for Raspberry Pi

Posted: Thu Jan 03, 2019 11:06 am
by fruitoftheloom
penguintutor wrote:
Thu Jan 03, 2019 10:32 am
Now that Scratch 3 has been released are there any plans for a Raspberry Pi (Linux) version of the Desktop version? Scratch 3 can be run through a browser today, but the desktop version is required for offline use and to support physical computing using the Raspberry Pi GPIO ports?

If so is there anything that members of the Raspberry Pi community can assist? Perhaps programming or testing?

I'm happy to help myself. I don't have the time to run the project myself (and wouldn't want to duplicate work if there is a project already in the pipeline), but I would be happy to help if I can.

Scratch 3 Desktop has only been released for Windows 10 and MacOS 10.13 or later, no Linux:

https://scratch.mit.edu/download

Re: Scratch 3 Desktop Version for Raspberry Pi

Posted: Thu Jan 03, 2019 3:14 pm
by penguintutor
I have used the online version in Raspbian (I used that during the Beta testing). It's not just taking Scratch offline (although that is one thing), but having the ability to access the GPIO which we have on Scratch 1.4 and Scratch 2. That is the killer feature allowing it to be used with physical computing.

I have tried the desktop version on Windows which appears to have access to external modules using Scratch Link (eg. Lego mindstorms). The Scratch team have said they are working on a desktop version for Chromebooks. Perhaps that will provide a good starting point towards a Linux version?

Presumably there will need to be a port of Scratch Link - or something similar to allow hardware access?

@jamesh If there is anything in future working towards those goals and anyway I can help please let me know.

Re: Scratch 3 Desktop Version for Raspberry Pi

Posted: Thu Jan 03, 2019 5:35 pm
by jamesh
penguintutor wrote:
Thu Jan 03, 2019 3:14 pm
I have used the online version in Raspbian (I used that during the Beta testing). It's not just taking Scratch offline (although that is one thing), but having the ability to access the GPIO which we have on Scratch 1.4 and Scratch 2. That is the killer feature allowing it to be used with physical computing.

I have tried the desktop version on Windows which appears to have access to external modules using Scratch Link (eg. Lego mindstorms). The Scratch team have said they are working on a desktop version for Chromebooks. Perhaps that will provide a good starting point towards a Linux version?

Presumably there will need to be a port of Scratch Link - or something similar to allow hardware access?

@jamesh If there is anything in future working towards those goals and anyway I can help please let me know.
You'll have to check with MIT - they are the ones who need to do the offline development.

Re: Scratch 3 Desktop Version for Raspberry Pi

Posted: Thu Jan 03, 2019 6:48 pm
by hippy
fruitoftheloom wrote:
Thu Jan 03, 2019 11:06 am
Scratch 3 Desktop has only been released for Windows 10 and MacOS 10.13 or later, no Linux:

https://scratch.mit.edu/download
Just for information: Though it does say "Windows 10+" is required; I downloaded and installed Scratch Desktop 1.2.0 under Windows 7 64-bit and it appears to be working as expected. The installer itself also reports "Windows 7 or above required".

That doesn't help with a Linux version though, nor with using extensions which have not been ported yet - and cannot be because the implementation specification isn't available :cry:

The current Linux status is as reported on that download link : "Scratch Desktop on Linux is currently not supported. We are working with partners and the open-source community to determine if there is a way we can support Linux in the future".

Re: Scratch 3 Desktop Version for Raspberry Pi

Posted: Sun Jan 13, 2019 7:25 am
by code_exec
MIT should start developing Scratch Desktop for Linux again considering the Pi is one of the main platforms to run it on.

Re: Scratch 3 Desktop Version for Raspberry Pi

Posted: Wed Jan 23, 2019 10:48 pm
by jakes
Pretty disappointed this wasn't available from the get-go, but I guess time & $ is finite.

From a cursory look, I suspect it may be "simple" to build it from source: (or rather, documentation seems pretty straight-forward enough)

* https://github.com/LLK/scratch-vm
* https://github.com/LLK/scratch-gui
* https://github.com/LLK/scratch-www

I'm looking at this as an offline solution for our STEM class - either running it in a Docker on a lap/class server, and/or deployable to a RasPi image. Possibly integrating with the MakeCode stuff for micro:bit & Playground Express boards.

I won't have time to dig into this any time soon, but I suspect members of the community far smarter & time-rich than I may solve this particular problem "soon" enough, once they get wind of it.

Re: Scratch 3 Desktop Version for Raspberry Pi

Posted: Thu Jan 24, 2019 1:19 am
by hippy
jakes wrote:
Wed Jan 23, 2019 10:48 pm
Pretty disappointed this wasn't available from the get-go, but I guess time & $ is finite.

From a cursory look, I suspect it may be "simple" to build it from source: (or rather, documentation seems pretty straight-forward enough)
Those were my thoughts as well. No one seems to have explained why an off-line editor isn't available for Linux or what the difficulty is or would be.

I would try it myself but I'm not familiar with Scratch 3, its internals, or the tools used, so am not sure exactly what I would need to build or how all the parts mentioned fit together.

I did download nodejs, npm, and scratch-vm, followed the instructions, 'npm install' and immediately got an error, another circle of hell entered. I didn't try the rest.

If someone wants to take the lead then I'll be pleased to help out, at least confirm or not that I get the same results, but I'm not leading this adventure.

Re: Scratch 3 Desktop Version for Raspberry Pi

Posted: Fri Jan 25, 2019 3:37 pm
by Botspot
The constant CPU usage in Scratch 3 is WebGl rendering the stage. WebGl does not support graphics acceleration on the Pi yet, so it uses the CPU instead.
To edit a Scratch 3 project, simply kill WebGl from the task manager. The stage will freeze, but dragging blocks becomes buttery smooth. Once WebGl is disabled, Scratch 3 truly becomes event based; I've seen 0% CPU with 2 Scratch 3 websites running at the same time.

To re-enable WebGl, refresh the page.

Re: Scratch 3 Desktop Version for Raspberry Pi

Posted: Fri Jan 25, 2019 5:43 pm
by hippy
Botspot wrote:
Fri Jan 25, 2019 3:37 pm
The constant CPU usage in Scratch 3 is WebGl rendering the stage.
That would explain it. I have no idea why it's continually rendering something which is never changing though. That would be what I'd call a 'design flaw'.

Though in reality it's probably more a case of 'works for me', so considered good enough for everyone, and 'get a decent computer' if it doesn't work for you. They wouldn't be the first software team to have adopted that approach, intentionally, or otherwise.

Re: Scratch 3 Desktop Version for Raspberry Pi

Posted: Fri Jan 25, 2019 5:59 pm
by rpiMike
The Scratch 3 article on the Raspberry Pi Blog mentions an offline version is being worked on :
Another reason for ensuring we support both Scratch 2 and 3 is that, at the moment, there is no offline, installable version of Scratch 3 for Raspberry Pi. Rest assured that this is something we are working on!
https://www.raspberrypi.org/blog/scratc ... -upgrades/

Re: Scratch 3 Desktop Version for Raspberry Pi

Posted: Wed May 01, 2019 12:29 am
by johnson34
Take a look at this, they provide opensource linux binaries: https://scratux.github.io

Re: Scratch 3 Desktop Version for Raspberry Pi

Posted: Wed May 01, 2019 9:51 am
by hippy
johnson34 wrote:
Wed May 01, 2019 12:29 am
Take a look at this, they provide opensource linux binaries: https://scratux.github.io
They don't seem to provide ARM binaries. And building from source fails if one follows their instructions -

Code: Select all

[email protected]:~/scratux $ yarn
ERROR: There are no scenarios; must have at least one.

Code: Select all

[email protected]:~/scratux $ yarn run build
ERROR: [Errno 2] No such file or directory: 'run'
So it seems something has to be configured to get it to build which hasn't been described.

That's no great surprise to me; is par for the course in my experience. I have asked 'Why does nothing ever seem to work?' in the past, and it's just another case which proves the point.

Though I haven't built it so I can't check, I would suspect the biggest argument against using 'scratux' is that it's not actually Scratch 3.0, is something similar but not the same. That, I would further suspect, will probably manifest itself in some ways which people will consider important enough to not consider it an acceptable option.

But I could be wrong.

Has anyone managed to build it, knows what needs to be done to get it to build ?

Re: Scratch 3 Desktop Version for Raspberry Pi

Posted: Mon May 06, 2019 5:02 pm
by johnson34
It looks like they have just changed the base of the project and the build steps. It is now truly based on Scratch Desktop and they now provide a .deb binary for armv7l. I will test it later on my Rasp

Re: Scratch 3 Desktop Version for Raspberry Pi

Posted: Thu Jun 20, 2019 10:51 am
by hippy
johnson34 wrote:
Mon May 06, 2019 5:02 pm
It looks like they have just changed the base of the project and the build steps. It is now truly based on Scratch Desktop and they now provide a .deb binary for armv7l.
Unfortunately; "Scratux 1.1.0 - .deb (armv7l) - For Raspbian - Coming soon", so seems it's not available yet.

Attempting to build from source continues to fail.

Re: Scratch 3 Desktop Version for Raspberry Pi

Posted: Tue Jun 25, 2019 3:39 am
by MisterEd
They just released the Raspberry Pi 4 today. You can get it with 1, 2, or 4 GB of RAM. :D

I hope they will be able to release Scratch 3 Desktop for the Raspberry Pi now that the new Raspberry Pi is a lot more capable.

I just ordered the Raspberry Pi 4 with 4GB of RAM. Unfortunately the 4GB version won't ship until August 1st.

Re: Scratch 3 Desktop Version for Raspberry Pi

Posted: Tue Jun 25, 2019 3:50 am
by fruitoftheloom
MisterEd wrote:
Tue Jun 25, 2019 3:39 am
They just released the Raspberry Pi 4 today. You can get it with 1, 2, or 4 GB of RAM. :D

I hope they will be able to release Scratch 3 Desktop for the Raspberry Pi now that the new Raspberry Pi is a lot more capable.

I just ordered the Raspberry Pi 4 with 4GB of RAM. Unfortunately the 4GB version won't ship until August 1st.

https://www.raspberrypi.org/forums/view ... 9&t=243091

Re: Scratch 3 Desktop Version for Raspberry Pi

Posted: Tue Jun 25, 2019 1:49 pm
by hippy
MisterEd wrote:
Tue Jun 25, 2019 3:39 am
I hope they will be able to release Scratch 3 Desktop for the Raspberry Pi now that the new Raspberry Pi is a lot more capable.
The issue of there not being an off-line editor, "Scratch 3 Desktop", is not Pi specific. MIT don't currently have a "Scratch 3 Desktop" available for any version of Linux.