User:Tdang/XO Setup: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
|||
(44 intermediate revisions by 3 users not shown) | |||
Line 1: | Line 1: | ||
== Old Setup == |
|||
I'm just starting on the 767 setup. I never got completely up on the 708 setup. |
|||
For historical curiousity, I still have the info on my old [[User:Tdang/XO Setup 656|656 setup]]. |
|||
== My XO Setup == |
== My XO Setup == |
||
XO Name: Abiyoyo |
XO Name: Abiyoyo |
||
Primary User Age: 39 (but same setup for 5-year-old's computer) |
|||
Operating System: OLPC Fedora / Sugar |
Operating System: OLPC Fedora / Sugar |
||
Build: |
Build: 708 (currently updating) |
||
SD Card: None |
SD Card: None |
||
Line 10: | Line 17: | ||
Hardware Mods: None |
Hardware Mods: None |
||
Peripherals: little USB mouse, |
Peripherals: little USB mouse, 4G USB stick |
||
Flash Player: ??? |
|||
Pre-installed Activities Removed: None |
|||
Favorite Activities Added: ??? |
|||
Flash Player: LNX 9.0.115.0 |
|||
Essential Non-Sugar Software: ??? |
|||
Favorite Activities Added: [[Speak]], [http://gcompris.net/incoming/xo/sudoku.activity.xo GCompris Sudoku] |
|||
Essential Non-Sugar Software: |
|||
* Firefox |
|||
Modifications: |
Modifications: |
||
* Installed Firefox |
|||
* Sugarized Firefox |
|||
* Made gamepad keys zoom in Read |
|||
* Created homepage for Browse |
|||
* Prevent re-starting X |
|||
* Changed Home View background color |
|||
* Removed "Register" from Shutdown menu |
|||
* Disabled hot corners |
|||
* Added clock to Home View frame |
|||
== What I like about this setup == |
|||
I'm trying to stay very close to the standard installation. That's partly for my curiosity, and partly so that any contributions I make will be applicable to the standard installation. |
|||
[[Browse]] is simply not good enough as a browser. I'll use it sometimes, particularly to install new activities. But its inability to search within a web page, and inability to handle useful pop-ups (required for attaching a file in gmail, for instance) make it not good enough. |
|||
Firefox seems a possibly good alternative. I just started using Firefox instead of [[Opera]], and so far the main appeal of Firefox is that I have it fully Sugarized. |
|||
The XO as a book-reader is fantastic. I read a lot of academic papers in PDF. With the slight modification to [[Read]] allowing me to zoom with the game keys as well as navigate, I can really use the XO in eBook mode. |
|||
== What I dislike about this setup == |
|||
I suspect that I'll buy into the [[Journal]] philosophy in time, but I'm not used to it yet, and so I miss directory trees. |
|||
[[Write]] is OK, but not good enough to make me want to work on it instead of NeoOffice on my iBook. |
|||
I don't yet have LaTeX. |
|||
I don't have any satisfactory spreadsheet capability. |
|||
== How to duplicate my XO Setup == |
|||
<center>incomplete</center> |
|||
If there are any mistakes you find in these instructions, please let me know. |
|||
=== Update the OS === |
|||
Update the OS as soon as you reasonably can. This is because when you update the OS, you'll lose pretty much anything you've done with your XO. |
|||
Hopefully, the standard instructions on this will work for you... |
|||
If you're networked, you can use [[olpc-update]]. |
|||
If you're not networked, or you're having trouble with olpc-update, you can do an [[activated upgrade]]. |
|||
=== Get Familiar with Command Line === |
|||
You need to be comfortable acting on the command line and editing files to do most of what's here. |
|||
If you need, I hope my [[User:Tdang/XO_Command_Line_Tips|command line tips]] are helpful. |
|||
=== Pick an Editor === |
|||
I won't walk you through all the choices of text editor. Many like [[vi]], and there's other options like [[emacs]]. In principle it's possible to use the [[Write]] activity. |
|||
I use [[nano]]. It's not very powerful, but it's very intuitive. |
|||
To edit a file, type (for instance): |
|||
nano /usr/share/sugar/shell/view/frame/frameclock.py |
|||
==== nano Hints ==== |
|||
Here's a couple of hints for using nano: |
|||
* To find out what line of a file you're on, hit Ctrl-C. That can be useful for following editing directions. |
|||
* To save a file without exiting, the command is Ctrl-O. But that doesn't work on the XO, since Ctrl-O brings you to the Journal. You can cheat by instead hitting (Esc, Esc)-O. That is, hit Esc twice, followed by O. If this istoo awkward, just use Ctrl-X to save and exit, and then go back into the file again. |
|||
=== Install Firefox === |
|||
([http://olpcnews.com/forum/index.php?topic=2395.msg19221#msg19221 Instructions] from samphilomath at OLPCNews forum) |
|||
Here's what you type: |
|||
su |
|||
nano /etc/yum.repos.d/olpc-koji-ship2.repo |
|||
Now you're editing an "exclude" file. Go down and erase firefox from the list. (and make sure to delete the comma which goes with it so that there aren't two commas in a row.) |
|||
Ctrl-X exits nano and saves. |
|||
At this point, you should exit all programs except Terminal. yum install can be memory-intensive, and it's annoying to have it quit midway on you. |
|||
Type: |
|||
yum install firefox |
|||
Follow the directions. When completed, type "exit" to stop being superuser. |
|||
==== Sugarize Firefox ==== |
|||
([http://olpcnews.com/forum/index.php?topic=1555.msg12203#msg12203 Instructions] and helpful files from CatMoran at OLPCNews forum) |
|||
Type: |
|||
su |
|||
wget http://www.catmoran.com/olpc/libsugarize.so |
|||
chmod 755 libsugarize.so |
|||
wget http://www.catmoran.com/olpc/sug |
|||
chmod 755 sug |
|||
wget http://www.catmoran.com/olpc/ff.svg |
|||
./sug |
|||
If the above doesn't work because the catmoran.org domain is down, you may have luck by looking [http://olpcnews.com/forum/index.php?topic=1555.msg19217#msg19217 here]. |
|||
* You'll be prompted for an activity name. Enter "Firefox" |
|||
* You'll be prompted for an icon file. Enter "ff.svg" |
|||
* You'll be prompted for the command to start the program. Enter "firefox". (This is case-sensitive, so enter it in all lowercase.) |
|||
* You'll be prompted for an organization path. Enter "org.mozilla ". |
|||
Now, reboot Sugar. (Hit Ctrl-Alt-Erase). There should be an activity icon which is "FF" in a circle. |
|||
==== Flash ==== |
|||
=== Modifying Activities === |
|||
==== Give Browse a Home Page ==== |
|||
==== Gamepad Zoom in Read ==== |
|||
=== Tweaking Sugar === |
|||
Some of the changes I've made are changes to the Sugar UI itself. |
|||
==== Pre-Tweaking Precaution ==== |
|||
<b>Prevent X Restarting</b> |
|||
First, however, I strongly recommend a precautionary change. By default, X (the graphical environment Sugar runs in) restarts itself automatically. That means if something goes wrong as Sugar is starting, it quits and dumps out to the console, and then restarts and so on loops and loops and it's very hard to fix. |
|||
[[Michael Stone]] gave me good advice to prevent this from happening [http://en.forum.laptop.org/viewtopic.php?f=2&t=2570#p8960 at the forum]. Before making any (even minor) tweaks to Sugar, I follow that advice. |
|||
==== Practice Tweak--Background Color ==== |
|||
Just to get familiar with making changes to Sugar, and because it's fun to personalize, how about changing the background color of the Home view? |
|||
==== Turn Off Register ==== |
|||
Since we're never going to to register our XO's with a school server, we don't need to be reminded regularly. So we might as well take that out. It's a minor point, but it's also a minor edit. |
|||
---- |
|||
in /usr/share/sugar/shell/view/frame/HomeBox.py |
|||
Simply comment out the following lines: |
|||
# if not self._profile.is_registered(): |
|||
# item = gtk.MenuItem(_('Register')) |
|||
# item.connect('activate', self._register_activate_cb) |
|||
# palette.menu.append(item) |
|||
# item.show() |
|||
---- |
|||
==== Turn Off Hot Corners ==== |
|||
There's at least one thing about the standard Sugar interface which most users want to change. (I think it might change by default in future updates.) The [[OLPC Human Interface Guidelines/The Laptop Experience/The Frame#Hot_Corners|hot corners]] are very annoying for me, and many others. They also feel unnecessary since you can accomplish the same thing(s) by pressing the special navigation buttons. |
|||
---- |
|||
This requires just commenting out two lines in /usr/share/sugar/shell/view/frame/eventarea.py: |
|||
def _create_invisible(self, x, y, width, height): |
|||
invisible = gtk.Invisible() |
|||
# invisible.connect('enter-notify-event', self._enter_notify_cb) |
|||
# invisible.connect('leave-notify-event', self._leave_notify_cb) |
|||
That's all that's needed. |
|||
---- |
|||
==== Add a Clock to Home View ==== |
|||
It's very unusual these days to have any electronic device which doesn't tell you what time it is. There are a couple full-fledged clock activities ([[Clock activity|clock]] and [[Alarm Clock, Randomizing WAV/MP3|random tune alarm clock]]), but they're overkill for a constant clock. |
|||
---- |
|||
To add a clock, I create one new file and modify one existing file. Both files are in /usr/share/sugar/shell/view/frame |
|||
The existing file which gets modified is zoomtoolbar.py. First, up top in the imports it needs: |
|||
from frameclock import FrameClock |
|||
Down actually in the code of zoomtoolbar.py: |
|||
palette = Palette(_('Activity')) |
|||
palette.props.invoker = FrameWidgetInvoker(button) |
|||
palette.set_group_id('frame') |
|||
button.set_palette(palette) |
|||
# new clock code here |
|||
clock = FrameClock("%a %b %d %I:%M %p") # Show day month date HH:MM AM/PM |
|||
# clock = FrameClock("%D %H:%M:%S") # show date & time through seconds |
|||
# self.insert(clock,0) # Put clock to left of navigation buttons |
|||
self.insert(clock,-1) # Put clock to right of navigation buttons |
|||
clock.show() |
|||
clock.start() |
|||
You see above that there are format choices. You can use [http://docs.python.org/lib/module-time.html time format] codes in the call to FrameClock() to get the format you like. And you can decide when you do insert(clock...) whether you want the clock on the left or the right of the navigation buttons. |
|||
This requires a definition of FrameClock, which happens in the new file, frameclock.py: |
|||
# frameclock -- a little digital clock widget for the Home frame |
|||
# Actually, there's nothing about this specific to that use, could |
|||
# be used as a widget anywhere. |
|||
# March 28, 2008 Timothy Dang |
|||
from gettext import gettext as _ |
|||
import gtk |
|||
import time |
|||
import gobject |
|||
import string |
|||
import pango |
|||
class FrameClock(gtk.ToolItem): |
|||
def __init__(self,new_format="%D %H:%M:%S"): |
|||
gtk.ToolItem.__init__(self) |
|||
self.set_expand(True) |
|||
self.format=new_format |
|||
self.update_interval = 1000 # update every second (recommended) |
|||
def start(self): |
|||
self.label = gtk.Label(time.strftime(self.format)) |
|||
self.add(self.label) |
|||
self.label.show() |
|||
self.update_timer = gobject.timeout_add(self.update_interval,self.update) |
|||
def update(self): |
|||
time_string = time.strftime(self.format) |
|||
self.label.set_markup("<big>"+time_string+"</big>") |
|||
self.label.show() |
|||
return 1 # This seems to be needed to continue the update_timer |
|||
That should give you something which looks like: |
|||
[[Image:FrameClockMiddle.png|screenshot of Home View with clock on top frame bar]] |
|||
---- |
Latest revision as of 14:54, 22 December 2008
Old Setup
I'm just starting on the 767 setup. I never got completely up on the 708 setup.
For historical curiousity, I still have the info on my old 656 setup.
My XO Setup
XO Name: Abiyoyo
Primary User Age: 39 (but same setup for 5-year-old's computer)
Operating System: OLPC Fedora / Sugar
Build: 708 (currently updating)
SD Card: None
Hardware Mods: None
Peripherals: little USB mouse, 4G USB stick
Flash Player: ???
Favorite Activities Added: ???
Essential Non-Sugar Software: ???
Modifications: