Saving Programs Like Examples
The example programs are shown in a nice hierarchical list on the left hand of the screen. Can a user (such as myself) store a program such that it is in the list with the examples? I understand how to keep the program in my Journal but there are programs I would like to use frequently and accessing them from the list would really be usefull.
I second this. --DanielAjoy 17:36, 3 June 2008 (EDT)
In build 703 (current stable) the program text for an example is stored in a sub-directory of
for example ./math or ./sound, as a plain text file with no extension.
You can add plain text files to any of these sub-directories using the terminal activity, and they will appear in the example list and be usable in every way like the bundled examples. By adding a file you are, in fact, editing the bundle. No reboot is necessary.
You can also create additional directories here, for example ./home for your own programs. If the directory is empty, it will not have a triangle to its left in the list (the triangle toggles the display of the files within the directory). If there is a file in the directory, the triangle appears and works normally.
You can rearrange, copy, and delete example files at will among these sub-directories, including the pre-bundled examples, and the changes will show immediately.
You can not, however, nest the files in a sub-sub-directory. If you do, the sub-sub-directory will be visible, but there will be no triangle to display the contents, so the file itself will be inaccessible. This is a flaw that needs to be fixed. It would, of course, be nice to be able to save other programs without having to resort to the command line and the current journal save mechanisms. This is, of course, the thrust of the original question. What I've described is simply a work around, the necessity of which will be temporary, one may hope. Esemplectic 17:13, 1 July 2008 (UTC)
Is this in the build
Hey! Cool! Where did this come from? Is this in the build? If not, where can I get it?
Hi Homung pippy is in the last two builds but i recommend you that you try it in the last build (553) RafaelOrtiz 05:12, 22 August 2007 (EDT)
Compliments, and suggestion of comments in the code examples
I think this activity will be really cool for kids to play with python in a sandbox environment and create small python programs.
Also, from an educational point of view, would it be good if there where examples that showed/explained parts of python syntax/language? This could be done with commentaries and would be excellent so that kids didn't have to leave the screen to access to a mini-reference book to help them in their mini-programs (which the current examples are a sort of). It would surpass the old interpreters that you are trying to emulate (like in the spectrums, etc.).
On the other hand, you could say that it should belong to a separate "Python for Kids" ebook, or perhaps part of the more full-blown Develop activity.
Anyway, it's a great thing already in its state!
- A link to some tutorial programs has been added in the Beginning Programming section Alan Davies 17:32, 14 December 2007 (EST)
Origin of Pippy?
I've tried using Pippy a bit, although only via an XO emulator at present. It seems like a great environment for learning and experimenting.
Here are a few ideas for improvement, when I get hold of a laptop and create an XO development environment I will consider implementing them myself:
- The core 'pippy' library could use a getchar() function (similar to old 8-bit basic INKEY$ )
- It would be great for beginners to have tooltips or some form of autocomplete that them helps to remember the parameters of functions etc.
Alan Davies 17:32, 14 December 2007 (EST)
Start new file? Save?
Pippy is great, but there needs to be some ability to handle code files (start from scratch and save). --220.127.116.11 11:14, 27 December 2007 (EST)
Changes to code in Pippy can be saved with "Keep" and then "Resummed" from the journal. Yea!
Okay, but that's pretty unsatisfying. I still can't create a new file with my own program. If we expect kids to use the XO to learn to program, what environment are they going to use? --22:03, 26 January 2008 (EST)Risacher
There is no xo bundle link on the activities page. I want to play with this in my sugar-jhbuild but I guess I'll have to download it using git, totally undocumented...Homunq 23:53, 5 January 2008 (EST)
OK, what's the official word. Is it "Pie-pie", a lame name, or "Pippy" as in "Pippy Longstockings", a great name? Not that I'm biased. :) CharlesMerriam 16:35, 9 January 2008 (EST)
Logically, it should be "Pip-pie", i.e. little python. Of course linguistically, that would be clearer as "Pypip". Esemplectic 15:39, 1 July 2008 (UTC)
Availability on other distros
Wonderful intro to Python - captivated my daughter. Is anyone working it into Edubuntu?
Where she gets stuck is if she accidentally generates a syntax error. Some kind of fixup function would definitely help, even if it's pretty darned rudimentary.
pippy module attributes
I'm working my way through the tutorial mentioned at the bottom of the wiki page (the ones based on code from a Commodore 64 book) and one of the examples fails: Bouncing Ball. The first line is "import pippy", which imports the module. That works fine, but the next line is apparently calling for a non-existant attribute.
Does anyone know where I can find a list of the attributes? thx --AuntiMame 21 feb 2008 19:05
Re: Compute Pi
Travis Hall wrote the pi computation demo http://wiki.laptop.org/go/User:Odel
There he asked how to increase the precision available to his code. Python has two relevant numeric types, integers and floating-point values. The former numeric type is of infinite precision, whereas the floating-point is an IEEE "double" of 64 bits. Accumulate your result as an integer and infer the decimal position by some other means.
School server ideas and thoughts
Are there any general ideas for adding school server content features to Pippy?
It can be as simple as:
> School Server - Lesson 1: Hello - Lesson 2: Getting Started -- Example 1.1 -- Example 1.2 - Lesson 3: Numbers 1, 2, 3...
The content can be served via http, rsync, ftp, scp, or any URI. A local copy would permit homework when disconnected from the school server.
It may be that some security issues need to be considered given the raw power of python and that students would be clicking on Run.
One value is that the instructor could expose lessons as needed in a structured way for the next class.
Http is interesting because the server can be setup for multiple languages. See the Apache documentation for an example. Translations can cover more than just words. Mango can replace Apples if apples are unknown. A "British" boot might hold more than just feet. etc.
--Tom Mitchell Tuesday, May 20 2008
What types of variables and expressions are used in Bounce? What SSRMGIO constructs are used? Is the program well documented internally and externally? How do you change the size, colour and speed of items on screen? How can you document changes that you have made to Bounce?
can you answer as many as possible