![]() You can also use the Raspberry Pi Camera Module to create new sprites and backgrounds. The Scratch team kindly allowed us to include all the sprites, backdrops, and sounds from the online version of Scratch 2.0. This loads two new blocks, one to read and one to write the state of a GPIO pin. Simply click on ‘More Blocks’, choose ‘Add an Extension’, and select ‘Pi GPIO’. ![]() In our Scratch 2.0 application, therefore, there is a custom extension which allows the user to control the Pi’s GPIO pins without difficulty. We know that people want to use Scratch for physical computing, and it has always been a bit awkward to access GPIO pins from Scratch. We ended up with the Scratch 2.0 application that you can find in the Programming section of the main menu. We combined this with a program called Electron, which effectively wraps up a local web page into a standalone application. The Scratch team had created a website to enable developers to create hardware and software extensions for Scratch 2.0 this provided a version of the Flash code for the Scratch editor which could be modified to run locally rather than over the internet. We’ve been working with the Scratch team to get an offline version of Scratch 2.0 running on Pi. However, it still needed an internet connection to run, which wasn’t ideal in many circumstances. This addressed the first of these problems, so the Scratch 2.0 website has been available on Pi for a while. We worked with Adobe to include the Pepper Flash plugin in Raspbian, which enables Flash sites to run in the Chromium browser. While this made Scratch 2.0 a cross-platform application, which you could run without installing any Scratch software, it also meant that you had to be able to run Flash on your computer, and that you needed to be connected to the internet to program in Scratch. Scratch 2.0, however, was written in Flash, and was designed to run from a remote site in a web browser. The original version of Scratch was written in a language called Squeak, which could run on the Pi in a Squeak interpreter. A few years ago, though, the Scratch team at the MIT Media Lab introduced the new and improved Scratch version 2.0, and ever since we’ve had numerous requests to offer it on the Pi. Raspbian ships with the original version of Scratch, which is now at version 1.4. Scratch really does provide a great introduction to programming for all ages. This is largely due to the way it makes programming accessible – while it is simple to learn, it covers many of the concepts that are used in more advanced languages. ![]() ![]() Scratch is one of the most popular pieces of software on Raspberry Pi. We’ll look at all the changes in this post, but let’s start with the biggest… Scratch 2.0 for Raspbian In addition to the usual small tweaks and bug fixes, the big new changes are the inclusion of an offline version of Scratch 2.0, and of Thonny (a user-friendly IDE for Python which is excellent for beginners). Today we’ve released another update to the Raspbian desktop. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |