Sugar Instructions (Build 303)
 Different Builds of Sugar
The Sugar software is evolving rapidly, so there are different instructions, depending which version you have. The OLPC software comes in "builds", which are loaded into the laptop's firmware (or booted from a CD image, USB key, or SD card). This page documents Sugar for "Build 303", which was shipped on the initial B2 XO laptops. The current stable build is documented at Sugar Instructions. You can find all versions of this documentation in [Category:Sugar].
If you have an OLPC laptop, Sugar is already installed. Otherwise you can either use an emulated laptop, which will have Sugar built in, or you can install Python on your desktop PC and run the Sugar application directly on your PC. If you are running Sugar from Python then you can skip most of the stuff in the next section, up to choosing your user name.
 First Booting on an Emulated OLPC Laptop
When you first open an OLPC image using an emulator, you will see this screen. Just press enter, or wait a few seconds.
This screen will appear. Again, just press enter if you are using an emulator.
Then several screens of text will fly past as Linux begins to load. Just wait until you see the Sugar desktop shown later.
Then it will go to a login prompt. You don't have to type anything. Just wait and it will start the GUI. If you don't want to wait for the GUI to load, you can log in with username "root" and no password.
If you wait, the GUI will start. If the GUI fails to start, you may have forgotten to choose emulated when you booted, or you may have encountered the "GUI won't start" bug. The "GUI won't start" bug is fixed by reinstalling the hard disk image. In QEMU, delete the .img file (it has become corrupted), and extract the original .img file from the bz2 file, or download the image file again. Upgrading to a later version isn't necessary.
 Choosing a Picture and a Name
The first time Sugar starts it will show a screen where you have choose a picture and type in an username. To choose a picture, click on the moving image from the camera. Type in any name; gibberish will suffice. (The name doesn't get used much yet, but it will appear in a pop-up in the network view -- on your own laptop and on other XO's.) You cannot continue without choosing a name and picture. Two colors have been automatically chosen for the XO icon that represents your laptop, but you can change them by clicking in the XO icon. Keep clicking until, at random, you get a color combination you can stand. You need not be satisfied with your name, photo or color, but you must satisfy the GUI designers. Press Enter or click in the > button below to get past this impediment.
 Getting Started with the Sugar Desktop
 Home Mode
The Sugar desktop starts up in Home mode. This shows a picture of you in the centre of the screen.
Later on we will see many people, but at the moment we can only see you. Each person is a different colour.
 Opening an Activity
Sugar uses "activities" rather than "applications".
For example a web browser is a type of activity in Sugar. The ring around you shows which activities are running. At the moment there are no activities running, so the ring is empty.
So let's open an activity. To open an activity, move your mouse to the edge of the screen. The "Frame" will appear.
At the bottom of the frame there are some icons.
These are the activities that you can open.
For example, AbiWord (a word processsor) is shaped like a triangle.
To open an activity, click on it.
After a few seconds a new screen will appear - this is AbiWord (see right for example).
You can open several activities at the same time, by going to the bottom of the frame, and clicking on another icon.
 Switching View Modes
To see which activities are open, go to the frame, and in the top left corner, you will see four "Zoom Icons".
There are three different levels of "zoom", so you can see not just yourself and your activities, but also your friends, or everyone on the local network.
- Neighborhood Shows everyone in the "Neighborhood", and what activities they are sharing.
- Friends Shows only you and your friends, and their activities.
- Home Shows only you and your activities
- Bulletin Board Toggles an extra transparent layer on top of the view, where you can add comments and stick items, like an old-fashioned bulletin board, that you want to share with everyone in that view.
Click on the "Home" view (The circle with a single dot inside) or press F3 on the keyboard.
If you have a real OLPC laptop, you can change zoom mode by pressing the appropriate button on the top of your keyboard, shown here.
Now you will see your icon in the centre, and the AbiWord icon in the surrounding circle.
 Switching Between Activities
If you have more than one activity running, you can switch to it by clicking on the appropriate icon in the ring.
The size of the ring segment that an activity occupies represents its overall memory usage; when the ring fills up, no additional activities may be launched until some resources are freed up.
There are currently 8 activities on the frame, but not all of them work yet.
|Squeak Etoys (dynamic media authoring system)||chat activity||Web Browser||AbiWord (word processor)||[PenguinTV] RSS Newsreader||Camera Test A basic camera test activity||Memory (musical memory game)||TamTam (musical sequencing activity)|
 Closing or Sharing Activities
To close an activity, select it (for example AbiWord). The activity will open.
Then go to the top of the frame. You will see the AbiWord icon at the top of the frame.
Move your mouse on the icon but don't click.
A box will appear with two more icons.
Click on the "X" icon to close the activity.
To share an activity with other people, go to the frame at the top, and move your mouse on to the activity icon.
A box will drop down, then click on the circle with many dots inside.
You are now sharing your activity. To find out more about sharing activities with others, read about Neighborhood View Mode.
 Shutting Down the System
To shut down the whole system, simply push the power button on the bezel. There is no longer (as of recent builds) any need for a separate on-screen button for shutdown.
 Neighborhood View Mode
Neighborhood mode shows you other people connected on the network. It also shows you which activities they are running, and which activities are being shared. Each person is represented by a different colour.
The activities are colour coded with the colours of whoever started the activity. In this case the painting activity was started by the orange and purple girl, who you can see surrounding the orange and purple activity in the Neighborhood view in the middle of that screen.
The left frame is the clipboard. You can copy multiple items to the clipboard.
The right frame is your buddy list. It shows your friends that are online.
The bottom frame is like the windows start menu that you use for launching applications. The icons represent different activities that you can start. In the above screen shot, the activities are from left-to-right: painting, word processor, chat, and web browser. You will also have other activities on your laptop. A shooting star icon will represent Squeak e-toys, which is a fun visual programming and drawing application.
When you receive an invitation from your friend to join an activity, it will appear in the bottom frame in colour. A pop-up menu lets you accept or reject the invitation. Notifications may also appear in the bottom frame.
The top of the frame has the icons for "neighborhood", "friends", "home", and "bulletin board", just like on the keyboard. It also has something like the Windows "task bar" with the icons for the currently running activities.
In recent builds (> 300), internet access points (infrastructure mode) appear as triangles on the mesh view. You select an access point by clicking on it in this view. Your status appears on the homepage, also in the form of a triangle. In future builds (>330), a mesh status will also be shown in both views. We are considering adding functionality to the friends view to allow one to collect "favorite" access points.
 Shortcut Keys
You can use the following shortcut keys in Sugar:
- F1 : Zoom to Neighborhood view
- F2 : Zoom to Friends view
- F3 : Zoom to Home view
- F4 : Zoom to Activity view
The following key combinations use modifier keys. For example "Alt+f" means "Hold down the 'Alt' key, then press the 'f' key, then release both keys."
- Alt+f : Toggle the frame
- Alt+= or Alt+0 : Open the Developer Console (includes terminal (linux prompt) as user "olpc", you won't be able to log in as "root"; and the sugar-log-viewer window)
- Alt+r : Rotate the screen
- Alt+q : Quit Sugar when running within a development environment (i.e. not when running an emulator image or on an OLPC laptop)
The following Linux key combinations can be used when running Sugar in an emulator image or on an OLPC laptop:
- Ctrl+Alt+F1 (hold down) : Leave the Sugar screen, and go to the Linux prompt, so you can log in as "root" with no password.
- Ctrl+Alt+F7 (hold down) : Return to the Sugar screen
- Ctrl+Alt+Backspace : Terminate Sugar immediately without closing down properly. It will restart automatically in the background (use Ctrl+Alt+F7 to see it restarted).
 Terminal (linux prompt)
You can access the linux prompt in two ways... Either hold down Ctrl+Alt+F1 to leave the Sugar screen and return to the login prompt, or open the Developer Console activity within Sugar and select the terminal tab.
If you use Ctrl+Alt+F1 to leave Sugar, you can return to Sugar with Ctrl+Alt+F7.
If you use the terminal in the Developer Console you won't be logged in as "root" but as "olpc". You need to be logged in as "root" to edit some of the setup files, such as "/boot/grub/grub.conf". You can gain root access by typing "su -". The prompt suffix will change to # which denotes that you are root. You will not be able to start any graphical programs as root using this method.
For example, if you want to edit "/boot/grub/grub.conf" with AbiWord in Sugar, hold down Ctrl+Alt+F1 to leave Sugar, and type "root" for the log in. Type "chmod a+rw /boot/grub/grub.conf". Then return to Sugar by holding down Ctrl+Alt+F7. Now you can open and save that file in AbiWord.
Some basic linux commands you can use at the prompt are:
- ls -al (get a list of the files)
- cd dirname (change to directory dirname)
- cat filename (show the contents of filename)
 Web browser
The browser is based on Mozilla Firefox.
It has a simple interface. By default it has one toolbar across the top, with back, forward, and reload buttons, followed by a box with the page title or URL, and a "+" button which adds an extra browser tab. If you click the "+" button then it adds a new tab, and a new toolbar appears on the left side of the screen which displays all the tabs. I couldn't work out how to close tabs.
When you click on the title box, it will change to showing the URL, and you can type in a new address and press Enter to make it go there. The title box also shows the loading progress as a bar in the background.
Don't confuse the tool bars with the similar looking frame. You can still move the cursor to the corner of the screen to pop in the frame over the top. You can then click on the coloured wire-frame globe icon in the top frame and choose close from the drop down menu.
NOTE: Currently, when a link opens in a new window, you will be stuck in that window until you close it from the top frame, at which point you will see the previous window until you close all the browser windows.
If you cannot get an internet connection in the sugar browser, look here.
 Detailed description of the Sugar Interface
For more info on the Sugar interface, have a look at the Human User Interface Guidelines.