MPP tests

2008-06-16 Thread Giannis Galanis
On my last week at 1cc, I performed several tests on MeshPortalPoint(MPP)
configurations.

Perhaps it is good for all to have an insight on what is possible, and what
isnt with MPP.
(especially after tomorrows network presentation!)

For those who dont know yet,  an XO  acts as an MPP, when it manages to
share its private internet connectivity to other XOs in the mesh.

The MPPs tested managed to successfully share their connectivity through the
msh0 interface.
Their connectivity was via
1) a GSM/usb modem though a ppp0 interface(thanks to Ankur!!)
2) a simple Wifi AP
3) a School Wifi

The common cases of MPP regarded home scenarios, or "under-the-tree"
scenarios(where at least 1 XO had access to an internet connection)
Specifically in the GSM modem case, probably only one XO will have the
device due to cost.. etc

But, it was rarely discussed whether an MPP can be useful at the school(am i
wrong?)
Probably because Schools were initially configured with Meshes, and the MPP
is probably useless there
(if the MPP, XO, School are indeed in the same mesh, then the XO can reach
the School directly)

However, now that Schools are mostly connected with Access points, MPP can
be useful in School as well!

Other XOs in the neighborhood can join a School Wifi via an MPP,
combining the benefits of the AP in the dense environment, and the Mesh in
the scarce environment

***Michali*, I have a question for u:
In the case that some XOs are many hops away(>5 and <10) from the School,
can an XO at halfway act as an MPP to practically increase the ttl?
I can understand that it would probably work if the MPP had two mshX ifaces
on diff channels(the second to be an active antenna)..
Is this a good way to bridge two mesh clouds?


Results:

1) GSM modem / SimpleWifi

* All XOs (including the MPP) had access to the internet
* The client-XOs showed a DNS server(in resolv.conf) of the msh0 address of
the MPP-XO
* jabber:All XOs(including the MPP) could perfectly collaborate via a jabber
server(any publicly routable jabber should work.. i used
schoolserver.laptop.org)
* salut: I disabled gabble in all XOs with "sugar-control-panel -s jabber
foo"
   a) All XOs(including the MPP) shared *Presence information*.. i.e. New XO
arrivals, new activities, who joins the activity..etc
   b) Only the client-XOs could perform actual collaboration!!
why is this happening? I found it rather strange..
I was under the impression that Presence data were very similar to Activity
sharing data..
*Dafydd*, can you explain this? (or anyone from collabora)

2) School Wifi.. tested with media lab 802.11, which is also connected to
schoolserver.laptop.org

All the above facts were also true here.

What makes this case more special than simple Wifi, is that the client-XOs
would share the benefits of being at the school.
However,
* The client-XOs could *not* Register
* They also could *not* resolve "schoolserver"(it is the simplest way to
tell whether the School "services" are accessible)
(it could ping schoolserver.laptop.org, but this is publicly routable
anyway)
* They could ping 172.18.0.1

Basically, they could reach the school server machine, but didnt treat it as
a school!

*Wad*, can you explain this behavior?



yanni




___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


A (very) brief tour of the OLPC 802.11s device class in NM r3246

2008-06-16 Thread Michael Stone
Sjoerd and I started dissecting our NM-0.6 divergence so that we can
begin porting that necessary pieces of that divergence to NM-0.7.
Several highlights from our reading of two important files follow.
NM-specific terminology is /emphasized/.

nm-device-802-11-mesh-olpc.c [1] contains:

  * A nice description of the state machine currently used to decide
change network associations. 
http://tinyurl.com/5xnxgw

  * The flag-file MESH_STEP_FILE (/etc/NetworkManager/mesh-step)
which can be used to alter the initial state of the aforementioned
connectivity state machine.
http://tinyurl.com/4ltm2u

  * The callbacks and setup/teardown logic on lines 536-661 which sync
the 'scanning' flag between the /mesh device/ (a.k.a. the msh0
network interface) and its /companion (wireless) device/.
http://tinyurl.com/5ydns6

  * Hoary netlink socket code (perhaps duplicating functionality of
iwconfig?) in the second quarter of the file.
http://tinyurl.com/427fxg

  * Hoary /mpp/ (mesh portal point) - http://tinyurl.com/4yxbyr
  /aipd/ (avahi-autoipd)- http://tinyurl.com/43kygw   and
  device association logic  - http://tinyurl.com/4fstfh
in the second half of the file.

  * The init method of the Mesh Device gobject class, showing off all
the Device methods we have overriden.
http://tinyurl.com/537awj

nm-dbus-nm.c [2] contains:

  * The construction and implemenation of the D-Bus interface used by
Sugar for /device activation/ (associating with networks) radio
discipline.
   http://tinyurl.com/3fcabp, http://tinyurl.com/3ozy7n

More details to come,

Michael

[1]: 
http://dev.laptop.org/git?p=users/mstone/NetworkManager;a=blob;f=src/nm-device-802-11-mesh-olpc.c;h=7c0808a77513d8f8d2f3029b6bb6d390ee370027;hb=olpc-0.6
[2]: 
http://dev.laptop.org/git?p=users/mstone/NetworkManager;a=blob;f=src/nm-dbus-nm.c;h=06694d625949f316ef3b4bdec1a71bb2f1ffb3a2;hb=olpc-0.6
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Communicate the changing of some sugar keyboard shortcuts?

2008-06-16 Thread Martin Dengler
Hi and apologies for the wide distribution of this email...

Some Sugar keyboard shortcuts are changing due to trac ticket
#4646[1].  They're not in joyride yet but will get there soon (I
imagine).  You can view the changes and the discussion leading up to
them in the [EMAIL PROTECTED] email trail for more background.

Two questions:

1. What documentation needs to change?  For example, there are
keyboard shortcut mentions on lots of wiki pages[3,4], and even a talk
page[5] complaining docmentation is out-of-date, but I'm loath to
change them before the changes even hit joyride.

2. Any feedback on the changes themselves is welcome (ok, that's not
phrased as a question, but...).

In case it spurs anyone to answer my question #1, my OTTOMH plan is
to edit [3] when these changes go into joyride and create a table per
widely-deployed build (for values of "widely-deployed build" that I
can link to a sugar-git tag or guess from deployed distro packages)
and a "latest" section.

Thanks,
Martin

1. http://dev.laptop.org/ticket/4646
2. http://www.mail-archive.com/[EMAIL PROTECTED]/msg03739.html
3. http://wiki.laptop.org/go/Keyboard_Shortcuts
4. 
http://wiki.laptop.org/go/Support_FAQ#How_do_I_close_an_Activity_.28program.29.3F
5. http://wiki.laptop.org/go/Talk:Keyboard_Shortcuts


pgpFhaGDCAkbL.pgp
Description: PGP signature
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Journal, Clipboard and activity instances vs. files (was Re: Recent Updates to Sugar Almanac)

2008-06-16 Thread Wade Brainerd
Hey James,

It actually sounds a bit like we're talking about the same thing...

On Mon, Jun 16, 2008 at 3:26 PM, James Simmons
<[EMAIL PROTECTED]> wrote:
> What you propose sounds difficult for a kid to master.  For myself, I'd like
> external storage to be treated differently from Journal entries and to
> *look* like its being treated differently.  External storage could have
> files and directories, you could navigate through them with a Midnight
> Commander-like interface, and you could lauch Activities from files in them
> if they had the needed MIME type.  This interface would be for the grownups
> (teachers), who would be the main users of external storage.

Right, I was moving the external storage into the clipboard UI
(extending the clipboard to handle it basically) as an alternative to
introducing a third UI for managing data objects.  Since the clipboard
deals in MIME types already, it seemed natural to put external storage
there too, and to "route more data" to the clipboard by default, for
example downloaded files.

> The current Journal user interface would be left pretty much alone, because
> it *does* work for kids.  Meta data would be fixed so that it persisted
> across reboots.  Journal entries would *not* be made for Activities that
> don't really need them (Terminal, Log Viewer, etc.  The Activity would
> specify that it did not want to be resumeable).

Agreed completely, I just want to remove the "files" from the Journal
and put them somewhere else.

Also, I think Terminal could use a decent Journal implementation, that
would save the environment and scrollback buffer.

The problem is more that the current home UI encourages creation of
new blank activity instances over resuming old ones.  This is somewhat
addressed in the new UI design, at the cost of some clarity in the
separation between activities and activity instances.  I also wrote up
some ideas on how to deal with it at
[[User:Wade/Ideas/Activity_Management]].

Regards,

Wade
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Journal, Clipboard and activity instances vs. files (was Re: Recent Updates to Sugar Almanac)

2008-06-16 Thread James Simmons
Wade,

What you propose sounds difficult for a kid to master.  For myself, I'd 
like external storage to be treated differently from Journal entries and 
to *look* like its being treated differently.  External storage could 
have files and directories, you could navigate through them with a 
Midnight Commander-like interface, and you could lauch Activities from 
files in them if they had the needed MIME type.  This interface would be 
for the grownups (teachers), who would be the main users of external 
storage.

The current Journal user interface would be left pretty much alone, 
because it *does* work for kids.  Meta data would be fixed so that it 
persisted across reboots.  Journal entries would *not* be made for 
Activities that don't really need them (Terminal, Log Viewer, etc.  The 
Activity would specify that it did not want to be resumeable).

James Simmons


Wade Brainerd wrote:

>Hey,
>
>I've had this read_file and write_file confusion before too.
>
>I think it's an issue in the design of Sugar, where there has been an
>attempt to mix "files" and "activity instances".  This leads to
>problems like when you plug external storage into the XO and all these
>fake "activity instances" appear in the Journal and have to be
>filtered into the datastore, even though they are really just files,
>and the usability issues with the Journal spending time indexing,
>removing file extensions, flattening path hierarchy, etc.  Or the need
>to pop up the Journal Object chooser when we have a perfectly function
>clipboard on the frame.
>

___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Journal, Clipboard and activity instances vs. files (was Re: Recent Updates to Sugar Almanac)

2008-06-16 Thread Wade Brainerd
2008/6/16 Faisal Anwar <[EMAIL PROTECTED]>:
> Rather than keeping track of what
> state you are in, it seems more coherent and natural that the developer only
> worries about specific calls to write metadata when he wants to write
> metadata (like volume and playback settings) and only worries about
> file-specific calls when he wants to manipulate files.

Hey,

I've had this read_file and write_file confusion before too.

I think it's an issue in the design of Sugar, where there has been an
attempt to mix "files" and "activity instances".  This leads to
problems like when you plug external storage into the XO and all these
fake "activity instances" appear in the Journal and have to be
filtered into the datastore, even though they are really just files,
and the usability issues with the Journal spending time indexing,
removing file extensions, flattening path hierarchy, etc.  Or the need
to pop up the Journal Object chooser when we have a perfectly function
clipboard on the frame.

(If I were designing Sugar from scratch) I would consider linking the
concepts of "file" with "object on the clipboard".  That is, you
cannot start an activity from a file, you can only paste a file into a
running activity instance from the clipboard (or choose the Open With
item on the clipboard context menu).  This takes care of the "Start
with" issue quite nicely.  And Read would not be a special case
activity, you could either launch it and Paste, or launch it from the
Clipboard context menu.  The clipboard would become an arbitrary
"storage pool of mime objects".  It would persist across reboots, and
would provide the user interface to access external storage.  In fact,
it would really just be a simplified UI to a folder tree in
/home/olpc/ (and /media/).

This would leave the Journal as the collection of activity instances
only, while the clipboard would be the collection of plain mime
objects only.  When you download an item in Browse, rather than going
to the Journal, it would go to the clipboard.  Downloaded files could
be easily located in Terminal by checking /home/olpc/.sugar/clipboard/
or similar.  The issue with starting activities in Develop could be
reduced to the context menu of an activity having a Copy Bundle option
which would copy the .xo file to the clipboard, to be pasted into a
new Develop instance.

The effect of all this on the API would be that activities would not
have files to read and write at all, they would deal solely with
metadata, which should clear up the confusion.  The current APIs would
be left for backwards compatibility, but whatever was written would be
packaged up with the metadata and stored in the activity instance.

Hope all this blue sky brainstorming isn't annoying anyone too much :)

Best regards,
Wade
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Recent Updates to Sugar Almanac

2008-06-16 Thread James Simmons

Faisal,

/* You can download or save a file to a particular location and then 
change the self._jobject.file_path variable (as the Read activity does).


*/The Read activity only does the self.jobject.file_path variable when 
receiving a shared document.  I wish I had a really old version of Read 
Etexts to show you.  Unfortunately, by the time I got my git repository 
I already had the sharing code in there.  But basically you don't need 
to do anything special to do a write_file() that doesn't write a file.  
You just need a Journal entry that exists and has a MIME type.  Then you 
have an Activity that can resume any Journal entry with that MIME type.  
The core Read activity doesn't make PDFs.  It just reads them.  Then, 
when it closes down write_file() it saves the current page number as 
metadata.  No file is saved.


self._jobject has nothing to do with it.

Activities that only read Journal entries are a bit unusual.  I know a 
bit about them because I've written two (Read Etexts and View Slides).  
And there are occasions when you need to write a file.  You cannot 
create a Journmal entry without writing a file.  Even in the Read 
activity if you press the Save button on the Edit toolbar you'll get an 
error because Read is being asked to create a new Journal entry and it 
has no code to do this.


As for using a file to store meta data, I'm not pushing it as a best 
practice, but a practical expedient until metadata starts working 
better.  Several Activities already do this.  In your Music activity I 
would save an empty file and use metadata, as you suggest.  Eventually 
that file would be replaced with one that had music in it.  In an 
adventure game program I would save all the state information in a file, 
and could easily put other kinds of meta data in there too.


James Simmons
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Upgrade G1G1 using autoreinstallation method

2008-06-16 Thread Pia Waugh
Hi all,



> > If one pulls the cable out on the LAN side of the AP the XOs cease  to
> > share and quickly drop out and look for the mesh. So, this duplicated
> > the  problem I described.
> 
> More and more interesting.
> 
> Have you been able to follow up on what Pia Waugh found ?   Does it seem
> relevant ?

I am purchasing one of the exact same APs today to figure it out and will
post to the list what I find and whether the fix I found works. 

Cheers,
Pia

-- 
OLPC Australia   http://olpc.org.au/
Linux Australia http://linux.org.au/
Open Source Industry Australia   http://osia.net.au/
Software Freedom Day  http://softwarefreedomday.org/
 
"If more of us valued food and cheer and song above hoarded gold, it
   would be a merrier world." - J. R. R. Tolkien
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Supported media formats?

2008-06-16 Thread Bert Freudenberg
Which media formats are supported out-of-the box on the XO?

I found a partial list here

http://wiki.laptop.org/go/Data_File_Formats

but it does not mention audio and video formats.

In particular I'm interested in what GStreamer can handle as installed  
- only the "good" plugins are shipped, but the plugin file names were  
not too helpful. I know Ogg is supported, but what else?

Thanks,

- Bert -


___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Text To Speech in Read Etexts improved again

2008-06-16 Thread James Simmons
Hemant,

Does that mean you are making changes in the speech-dispatcher API 
itself?  That could complicate things, since I'd need your version to be 
on my test boxes.  Nothing I can't do, but that will make it more 
difficult for Ed to do his demos in Ubuntu.  It would have been nice to 
avoid threading when I wrote the TTS code to begin with, but now that 
the code is in there and working fine I don't see it as a problem so 
much.  I really need espeak to do a better job on the callbacks.  Or to 
replace espeak with Festival, which Hynek said worked better.

I already sent you my non-Sugarized version of Read Etexts.  That's what 
I would modify first to try out the new API, since that's much easier to 
test than the full version.  You could hack on that one yourself.  It 
might save you some time waiting on me.  Then I could modify the full 
Activity and test it.

Thanks,

James Simmons


Hemant Goyal wrote:

> Hi James,
>
> Absolutely not a problem at all. I am also working on finding a fix 
> for the problems that developers can have while using speechd api with 
> pyGTK as described here : 
> http://www.mail-archive.com/[EMAIL PROTECTED]/msg15868.html
>
> I discussed a solution to the problem with tomeu and erikos, and have 
> been making changes in the API implementation to make speechd support 
> asynchronous socket communication so that we can avoid  a thread to 
> perform network communication. We've figured out an approach to avoid 
> threads in the API, and hopefully I'll have the alternate solution 
> ready in 2-3 days. I'll be depending upon you to use the modified API 
> in your application for testing purposes :)
>
> Best,
> Hemant



___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Recent Updates to Sugar Almanac

2008-06-16 Thread Faisal Anwar
Hi James,

Based on your feedback, I've changed to wording for the write_file() entry
to the following:

*The following simple write_file() method shows how both metadata and files
are written. write_file() must point to a physical file. This file reference
can be created in several ways: *

   1. * Your program can explicitly create a file in write_file() and write
   to it. *
   2. * You can download or save a file to a particular location and then
   change the self._jobject.file_path variable (as the Read activity does).*

However, I still am hesitant about writing metadata to a physical file if
the activity doesn't use a physical file for anything else. At a conceptual
level, this approach (to me) seems like it would confuse what is metadata
and what is actual file data and puts unnecessary burden on a developer to
keep track. Ideally, I'm wondering if there should just be an abstraction to
an activity as having both metadata and file data and it is the prerogative
of the developer to put stuff where it is appropriate (without the two
necessarily interacting, as is now the case where you have to put metadata
about an activity in a physical file if none exists). If I were to write a
wrapper for datastore to build this abstraction, it would look something
like:

class ActivityInstanceInDatastore:
def write_metadata_entry(self, key, value)
def read_metadata_entry(self, key)
def write_file(self, file_path, stuff_to_write)
def read_file(self, file_path)

These exist already to some extent in datastore, but it seems from this
thread that the functional behavior doesn't yet follow a strict pattern of
behavior. Also, there is the issue of activities having multiple data files
(eg. for a file diff activity) which I believe is dealt with by setting
special metadata mappings to keep track of all the files (correct me if I'm
wrong).

Practically, I understand there will be many cases where the current setup
won't be a huge deal. However, it will be a big problem when people develop
activities that may or may not be associated with a data file at different
times. For example, I could envision a music activity that has specific
preset music settings (such as frequency settings, volume, etc.) as well as
optional files that are being manipulated by the activity. If the user
doesn't have a data file open, then you would just want to save metadata,
but then later if the user does open an audio file, then you will want to
have both metadata and physical data. Rather than keeping track of what
state you are in, it seems more coherent and natural that the developer only
worries about specific calls to write metadata when he wants to write
metadata (like volume and playback settings) and only worries about
file-specific calls when he wants to manipulate files.

Thanks


Faisal



On Mon, Jun 16, 2008 at 1:35 PM, James Simmons <[EMAIL PROTECTED]>
wrote:

> Faisal,
>
> Look at the code for the Read activity.  It never creates a Journal entry
> itself.  What it does is to resume from a directory entry created by
> downloading a PDF through the Browse activity or perhaps one copied from a
> USB key using the Journal activity.  So there *is* a file in the Journal
> entry, but there is no desire to update that file.  If you have that
> situation you can save metadata without writing a file, just like Read does.
>  No special code is needed.
>
> Metadata not being preserved across a reboot is a known bug.  Metadata not
> being preserved for entries on SD cards and USB keys is a *feature*.  These
> devices are not considered part of the Journal proper, although the current
> UI makes them *look* like they should be.  There are good reasons to treat
> files on USB devices differently from Journal entries.  I understand that
> the USB and SD parts of the Journal may be given a different look to avoid
> this kind of confusion.  I don't know when this will happen.  The developers
> who could do this have a lot on their plates.
> If you have no data file, it would be a good idea to use a file to store
> persistent information about options, etc.  The only time you wouldn't do
> that is when you have a file in the datastore that must not be modified, as
> in the Read activity.
>
> James Simmons
>
>
>
> Faisal Anwar wrote:
>
>  Hi James,
>>
>> Thanks for the feedback. I had two follow up questions for you or others
>> who are in the know with datastore:
>>
>> 1. You said: 'However, if your application is like Read, Read Etexts, or
>> View Slides, which are always resumed from existing Journal entries, there
>> is no need to write a file.  You can still save metadata, even if you don't
>> write a file.'
>>
>>
>
>
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Upgrade G1G1 using autoreinstallation method

2008-06-16 Thread John Watlington

On Jun 14, 2008, at 6:09 AM, David Leeming wrote:

> Hi John,
>
> To see if we could duplicate our problem, we tried with another AP:  
> We have
> a VSAT set up near the village where we are deploying a trial with 50
> children in PNG. It has a reliable wireless AP and you can  
> associate both
> "grown up" laptops and XOs no problems. The XOs will then see the  
> Internet
> and also other XOs and the activities will share OK. This AP has a  
> DHCP
> server on the wireless side. In fact, there is no other as the AP  
> connects
> straight to the VSAT modem, which does not have DHCP set up, via a  
> switch.
> If one pulls the cable out on the LAN side of the AP the XOs cease  
> to share
> and quickly drop out and look for the mesh. So, this duplicated the  
> problem
> I described.

More and more interesting.

Have you been able to follow up on what Pia Waugh found ?   Does it
seem relevant ?

> I am now told that a jabber service is needed to keep the XOs  
> interested and
> reliably collaborating, that maybe is the cause? Do you concur?

You absolutely don't need a jabber server for laptops to associate with
an access point.   Something else is wrong here.

>> Not knowing more about what you've done, I have
>> to ask a lot of v. simple questions.
>>
>> When you say "move on", you have manually associated each
>> laptop with the AP once, right ?   And the ESSID hasn't changed ?
>>
>> How realiable is the failure ?   Do all XOs "move on" to mesh
>> mode, or is this only a problem with a (random) few ?

?

>> How many XOs on each channel ?

?   As JG mentions, if you have too many laptops per AP, this is
a known problem.  How many are you trying ?

>> You could be seeing a failure of DHCP to actually occur.
>> Have you checked /var/log/messages on a failing laptop ?

John

___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Upgrade G1G1 using autoreinstallation method

2008-06-16 Thread John Watlington

I'm glad you found a solution.   Can you provide more information
(such as exactly what model of AP are you using ?  Which versions
of firmware worked/didn't work.)

I can't follow the link you provided, it returns:
"No Thread specified. If you followed a valid link, please notify the  
administrator"

Thanks,
John

On Jun 14, 2008, at 4:29 PM, Pia Waugh wrote:

> Hi,
>
> 
>
>> I just found this which might help. Similar problem with that AP.  
>> Might
>> help.
>>
>>   http://forums.speedguide.net/showthread.php?t=223860
>
> "t works!!! I took a risk and went backwards in the firmware.  
> First I
> tried 2.10, which appeared to be just about the same as the  
> mysterious
> shipping firmware (2.11) that is not on their website."
>
> It is a slightly different use case but sounds like something to try.
>
> Cheers,
> Pia
>
> -- 
> OLPC Australia   http:// 
> olpc.org.au/
> Linux Australia http:// 
> linux.org.au/
> Open Source Industry Australia   http:// 
> osia.net.au/
> Software Freedom Day  http:// 
> softwarefreedomday.org/
>
> "There is no darkness but ignorance." - William Shakespeare
> ___
> Devel mailing list
> Devel@lists.laptop.org
> http://lists.laptop.org/listinfo/devel

___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Gadget on the XS - upwards/downwards compat?

2008-06-16 Thread Martin Langhoff
Hi Daf & Collabra team,

Michael Stone gave me a brief run down of Gadget and plans to review
it for inclusion on future XO and XS builds. What he described sounded
pretty good, so I am keen on this.

Have you guys considered backwards / forwards compat? We have many
locations where XS and XO will be updated on separate schedules -- can
an old client talk to a Gadget-driven server? How about vice-versa?
Can old and new clients coexist?

chees,



m
-- 
 [EMAIL PROTECTED] -- School Server Architect
 - ask interesting questions
 - don't get distracted with shiny stuff - working code first
 - http://wiki.laptop.org/go/User:Martinlanghoff
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Koji Tags for 8.2.0

2008-06-16 Thread Dafydd Harries
Ar 13/06/2008 am 00:23, ysgrifennodd Michael Stone:
> Marco, Dennis, and I talked this afternoon and evening about how to
> arrange our Koji tags for the 8.2.0 release. Assuming no serious
> objections are raised by either you or the Fedora infrastructure and
> release-engineering teams, we will take the OLPC-3 [1] CVS branch,
> freeze the dist-olpc3 tag, and create dist-olpc3-{devel,testing,updates}
> and dist-olpc4 tags.

I like this scheme very much.

-- 
Dafydd
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Question about logging behavior

2008-06-16 Thread Tomeu Vizoso
2008/6/16 Faisal Anwar <[EMAIL PROTECTED]>:
>
> Now, when I start my activity up, I don't find any logs that are written to
> with the logging message. However, when I resume the activity from the
> journal, I do see the logging message that I have written in my code. Does
> anyone know why logging seems to only happen when you resume an activity
> from the journal and doesn't when you start an activity from scratch (I
> start the activity using the sugar-launch command in the terminal).

Do you have SUGAR_LOGGER_LEVEL=debug set?

http://wiki.laptop.org/go/Attaching_Sugar_Logs_to_Tickets

Regards,

Tomeu
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: [Server-devel] [PATCH] ds_backup - major rework

2008-06-16 Thread Tomeu Vizoso
On Mon, Jun 16, 2008 at 7:57 PM, Martin Langhoff <[EMAIL PROTECTED]> wrote:
> On Mon, Jun 16, 2008 at 1:53 PM, Tomeu Vizoso <[EMAIL PROTECTED]> wrote:
>> On Mon, Jun 16, 2008 at 7:46 PM,  <[EMAIL PROTECTED]> wrote:
>>> From: Martin Langhoff <[EMAIL PROTECTED]>
>>>
>>>  - Use json (part of the XO base install) instead of simplejson
>>
>> python-json looks unmaintained and lacks some features on which sugar
>> depends, so I think you are safe by depending on it. You won't need to
>> "sanitize" the metadata if you use simplejson.
>
> Is this where you guys are heading? Consolidating on simplejson?

Think so, from previous discussions in the sugar ml.

> Does
> it know how to write CJSON?

No idea :/

> If that's the case, I'll switch it back to simplejson. At the time it
> seemed like simplejson wasn't on either build (XO or XS) so I didn't
> want to have ds-backup be the only thing depending on it...

Yes, simplejson should be on recent builds.

Regards,

Tomeu
___
Server-devel mailing list
[EMAIL PROTECTED]
http://lists.laptop.org/listinfo/server-devel


Question about logging behavior

2008-06-16 Thread Faisal Anwar
Hi,

I'm trying to do simple logging for an activity, but am finding some strange
behavior with logging that I'm hoping someone can clarify for me. In
particular, I've written code similar to the following:

import logging
_logger = logging.getLogger('Annotate')

class MyActivity(activity.Activity):

def __init__(self, handle):
activity.Activity.__init__(self, handle)
_logger.debug('starting myactivity')


Now, when I start my activity up, I don't find any logs that are written to
with the logging message. However, when I resume the activity from the
journal, I do see the logging message that I have written in my code. Does
anyone know why logging seems to only happen when you resume an activity
from the journal and doesn't when you start an activity from scratch (I
start the activity using the sugar-launch command in the terminal).

Thanks


Faisal
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Text To Speech in Read Etexts improved again

2008-06-16 Thread Hemant Goyal
Hi James,

Absolutely not a problem at all. I am also working on finding a fix for the
problems that developers can have while using speechd api with pyGTK as
described here : http://www.mail-archive.com/[EMAIL PROTECTED]/msg15868.html

I discussed a solution to the problem with tomeu and erikos, and have been
making changes in the API implementation to make speechd support
asynchronous socket communication so that we can avoid  a thread to perform
network communication. We've figured out an approach to avoid threads in the
API, and hopefully I'll have the alternate solution ready in 2-3 days. I'll
be depending upon you to use the modified API in your application for
testing purposes :)

Best,
Hemant

On Mon, Jun 16, 2008 at 10:25 PM, James Simmons <[EMAIL PROTECTED]>
wrote:

>  Hemant,
>
> The RPM's and instructions you posted to the Wiki before *almost* worked.
> Can we assume that you'll do something similar with your debugged RPMs while
> awaiting sponsorship?  Having my activity do TTS on a real XO would make a
> big difference to my project.  Not to mention that I could finally show my
> wife why I've been spending so much time in the basement programming.
>
> Thanks,
>
> James Simmons
>
>
> Hemant Goyal wrote:
>
> Hi Michael,
>
> The basic package is ready to use, and a few more Q/A issues as described
> in the bug report need to be resolved.
>
> The major Q/A issues to be resolved at the moment are :
>
>1. Conversion of CS language info file to UTF-8 encodings. I am having
>trouble finding the encoding of the file and then converting it correctly
>using iconv.
> 2. Also I am working on an init script so that the speech-dispatcher
>daemon can be auto-started when the Operating System loads. The script is
>ready and has been included in the package. The init script has a few bugs
>in that it deletes the wrong pid file when the daemon has to be stopped. I
>will be fixing this bug in the next release.
>
> Hopefully, there wont be any more issues at the package review level after
> I resolve the above issues.
>
> Since this is my first package the next step for me is to get *sponsored*.
> I wrote 2 informal reviews for this purpose.
>
> The reviews I wrote can be found at :
> https://bugzilla.redhat.com/show_bug.cgi?id=448292 &
> https://bugzilla.redhat.com/show_bug.cgi?id=448458
>
> Best,
> Hemant
>
>
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Recent Updates to Sugar Almanac

2008-06-16 Thread James Simmons
Faisal,

Look at the code for the Read activity.  It never creates a Journal 
entry itself.  What it does is to resume from a directory entry created 
by downloading a PDF through the Browse activity or perhaps one copied 
from a USB key using the Journal activity.  So there *is* a file in the 
Journal entry, but there is no desire to update that file.  If you have 
that situation you can save metadata without writing a file, just like 
Read does.  No special code is needed.

Metadata not being preserved across a reboot is a known bug.  Metadata 
not being preserved for entries on SD cards and USB keys is a 
*feature*.  These devices are not considered part of the Journal proper, 
although the current UI makes them *look* like they should be.  There 
are good reasons to treat files on USB devices differently from Journal 
entries.  I understand that the USB and SD parts of the Journal may be 
given a different look to avoid this kind of confusion.  I don't know 
when this will happen.  The developers who could do this have a lot on 
their plates. 

If you have no data file, it would be a good idea to use a file to store 
persistent information about options, etc.  The only time you wouldn't 
do that is when you have a file in the datastore that must not be 
modified, as in the Read activity.

James Simmons


Faisal Anwar wrote:

> Hi James,
>
> Thanks for the feedback. I had two follow up questions for you or 
> others who are in the know with datastore:
>
> 1. You said: 'However, if your application is like Read, Read Etexts, 
> or View Slides, which are always resumed from existing Journal 
> entries, there is no need to write a file.  You can still save 
> metadata, even if you don't write a file.'
>


___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Switching to Kreyol ?

2008-06-16 Thread Sayamindu Dasgupta
Hi Bastien,
The locale code would be ht_HT.UTF-8. I need to figure out how much of
Kreyol translations are in the build yet, but I would suggest that you
use one of the newer joyride builds.
Another problem is that probably (again, I need to verify this), the
Kreyole locale is not yet defined in glibc yet. In that case, we will
need a locale definition file for Kreyole and put it in our glibc
builds.
Thanks,
Sayamindu


On Fri, Jun 13, 2008 at 8:31 AM, Bastien <[EMAIL PROTECTED]> wrote:
> Hal Murray <[EMAIL PROTECTED]> writes:
>
>>> Mhh..  I can't seem to find a good reference on this. I will try to
>>> ask to some haitian developers.
>>
>> http://en.wikipedia.org/wiki/Kreyol
>>   The word Kreyol may mean:
>> * Liberian Kreyol language
>> * Haitian Creole language (KreyĆ²l ayisyen)
>> * Kreyol Lwiziyen (Louisiana Creole)
>>
>> People in the US are probably familiar with Creole from the New Orleans
>> region.  (We bought Louisiana from France in 1803.)
>
> Thanks*.  The question is: where are the GNU/Linux users who configure
> their machine so that it speaks Kreyol?  What is the equivalent of the
> en_EN.UTF-8 code then?
>
> I expect many of these users to be from the haitian diaspora, thus using
> canadian or french locale...
>
> * Not for the deal about Louisiana, of course.
>
> --
> Bastien
> ___
> Devel mailing list
> Devel@lists.laptop.org
> http://lists.laptop.org/listinfo/devel
>



-- 
Sayamindu Dasgupta
[http://sayamindu.randomink.org/ramblings]
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Text To Speech in Read Etexts improved again

2008-06-16 Thread James Simmons

Hemant,

The RPM's and instructions you posted to the Wiki before *almost* 
worked.  Can we assume that you'll do something similar with your 
debugged RPMs while awaiting sponsorship?  Having my activity do TTS on 
a real XO would make a big difference to my project.  Not to mention 
that I could finally show my wife why I've been spending so much time in 
the basement programming.


Thanks,

James Simmons


Hemant Goyal wrote:


Hi Michael,

The basic package is ready to use, and a few more Q/A issues as 
described in the bug report need to be resolved.


The major Q/A issues to be resolved at the moment are :

   1. Conversion of CS language info file to UTF-8 encodings. I am
  having trouble finding the encoding of the file and then
  converting it correctly using iconv.
   2. Also I am working on an init script so that the
  speech-dispatcher daemon can be auto-started when the Operating
  System loads. The script is ready and has been included in the
  package. The init script has a few bugs in that it deletes the
  wrong pid file when the daemon has to be stopped. I will be
  fixing this bug in the next release.

Hopefully, there wont be any more issues at the package review level 
after I resolve the above issues.


Since this is my first package the next step for me is to get 
/*sponsored*/. I wrote 2 informal reviews for this purpose.


The reviews I wrote can be found at :  
https://bugzilla.redhat.com/show_bug.cgi?id=448292 & 
https://bugzilla.redhat.com/show_bug.cgi?id=448458


Best,
Hemant



___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Recent Updates to Sugar Almanac

2008-06-16 Thread Faisal Anwar
Hi James,

Thanks for the feedback. I had two follow up questions for you or others who
are in the know with datastore:

1. You said: 'However, if your application is like Read, Read Etexts, or
View Slides, which are always resumed from existing Journal entries, there
is no need to write a file.  You can still save metadata, even if you don't
write a file.'

I've written the following sample code:

def write_file(self, file_path):
logging.debug('WRITING FILE ...')
self.metadata['current_page'] = '3'

#f = open(file_path, 'w')
#try:
#f.write("Hello World")
#finally:
#f.close()

Now, when the part about writing to a file is commented out, I get the
following error when I run my activity in the terminal:
1213618380.556841 DEBUG root: Error saving activity object to datastore:
org.freedesktop.DBus.Python.IOError: Traceback (most recent call last):
  File "/usr/lib/python2.5/site-packages/dbus/service.py", line 655, in
_message_cb
retval = candidate_method(self, *args, **keywords)
  File
"/home/fanwar/sugar-jhbuild/sugar-jhbuild/install/lib/python2.5/site-packages/olpc/datastore/datastore.py",
line 475, in update
completion=lambda *args: self._update_completion_cb(async_cb,
async_err_cb, content, *args))
  File
"/home/fanwar/sugar-jhbuild/sugar-jhbuild/install/lib/python2.5/site-packages/olpc/datastore/backingstore.py",
line 583, in update_async
filelike = open(filelike, "r")
IOError: [Errno 2] No such file or directory:
dbus.String(u'/home/fanwar/.sugar/default/org.laptop.AnnotateActivity/instance/1213618380')
So I guess the question is how do you just save metadata without writing to
a file? It seems that sugar errors out when I try to do that. Do you have
some sample code I could try out?


2. What exactly is the behavior (or at least the intended behavior) of
metadata and files in the datastore? What are the rules for persisting
metadata - is it a bug that it does not persist through reboots, or is this
intended functionality? Is the metadata-file model one where you always have
a single file in the datastore that maps to a specific activity instance and
metadata is always attached to this file? Or is there some other model for
how the metadata, files and activitities interact?

I guess at a fundamental level, I am wondering how the conception of journal
activities outlined at
http://wiki.laptop.org/go/OLPC_Human_Interface_Guidelines/The_Laptop_Experience/The_Journal#The_Journaltranslates
to some technical model for how stuff is stored. My understanding
(from talking to other sugar developers and looking at what you've written
at Beyond Hello World) has been that datastore has files and metadata for
each activity- but it seems that if everything is supposed to be abstracted
as an activity, then there should be some data structure that represents
this and then the files and metadata are there to give additional
information about the activity itself. This would avoid confusion as to
whether there must be a file or metadata or some other ancillary information
to save an activity.

Faisal



On Mon, Jun 16, 2008 at 10:13 AM, James Simmons <[EMAIL PROTECTED]>
wrote:

> Faisal,
>
> What you wrote looks good, but I did see a possible error in it.  You say:
>
> "The following simple write_file() method shows how both metadata and
> files are written. Currently, write_file() will throw an error unless
> somewhere you actually write an actual file to the file_path that is
> passed to write_file. The code below writes a dummy file within the
> body of write_file itself (you can do this elsewhere as long as you
> have a handle on the file_path variable used by write_file)."
>
> I think this is not always true.  Now if you're creating a new Journal
> entry for your app and have implemented write_file it *might* be true.
>  However, if your application is like Read, Read Etexts, or View Slides,
> which are always resumed from existing Journal entries, there is no need to
> write a file.  You can still save metadata, even if you don't write a file.
>
> Another thing worth pointing out is that metadata doesn't work very well
> right now.  If I was in the position where I needed to write a file but
> didn't have anything that needed to go into it I wouldn't use metadata at
> all.  Instead I would put any saved options, etc. in the file, because
> *that* would persist across reboots but metadata currently does not.  I
> think several activities already do this.
>
> I wrote a wiki page titled "Beyond Hello World" that covers much the same
> ground as yours, but I like yours better.
>
> Thanks,
>
> James Simmons
>
>
>
> Date: Fri, 13 Jun 2008 17:34:43 -0400
> From: "Faisal Anwar" <[EMAIL PROTECTED]>
> Subject: Recent Updates to Sugar Almanac
> To: devel@lists.laptop.org, [EMAIL PROTECTED]
> Message-ID:
><[EMAIL PROTECTED]>
> Content-Type: text/plain; charset="iso-8859-1"
>
>
> Hello All,
>
> As many of you know, I'm writing up a sugar alman

Re: Text To Speech in Read Etexts improved again

2008-06-16 Thread Hemant Goyal
Hi Michael,

The basic package is ready to use, and a few more Q/A issues as described in
the bug report need to be resolved.

The major Q/A issues to be resolved at the moment are :

   1. Conversion of CS language info file to UTF-8 encodings. I am having
   trouble finding the encoding of the file and then converting it correctly
   using iconv.
   2. Also I am working on an init script so that the speech-dispatcher
   daemon can be auto-started when the Operating System loads. The script is
   ready and has been included in the package. The init script has a few bugs
   in that it deletes the wrong pid file when the daemon has to be stopped. I
   will be fixing this bug in the next release.

Hopefully, there wont be any more issues at the package review level after I
resolve the above issues.

Since this is my first package the next step for me is to get *sponsored*. I
wrote 2 informal reviews for this purpose.

The reviews I wrote can be found at :
https://bugzilla.redhat.com/show_bug.cgi?id=448292 &
https://bugzilla.redhat.com/show_bug.cgi?id=448458

Best,
Hemant

On Mon, Jun 16, 2008 at 9:07 PM, Michael Stone <[EMAIL PROTECTED]> wrote:

> On Mon, Jun 16, 2008 at 10:00:58AM -0500, James Simmons wrote:
> > I don't plan on doing much more with this until I can get
> > speech-dispatcher installed and working on my XO.
>
> Hemant - how would you describe your progress on packaging
> speech-dispatcher?
>
> I've seen lots of traffic on
>
>  https://bugzilla.redhat.com/show_bug.cgi?id=432259
>
> but I have little sense of how things are coming along.
>
> Thanks,
>
> Michael
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Text To Speech in Read Etexts improved again

2008-06-16 Thread Michael Stone
On Mon, Jun 16, 2008 at 10:00:58AM -0500, James Simmons wrote:
> I don't plan on doing much more with this until I can get 
> speech-dispatcher installed and working on my XO.

Hemant - how would you describe your progress on packaging
speech-dispatcher?

I've seen lots of traffic on 

  https://bugzilla.redhat.com/show_bug.cgi?id=432259

but I have little sense of how things are coming along.

Thanks,

Michael
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Text To Speech in Read Etexts improved again

2008-06-16 Thread James Simmons
This weekend I made another release of Read Etexts.  This one fixes the 
pause/resume problem.  I also introduced a new toolbar for Speech, which 
is adapted from the toolbar of the Speak activity but is modified to use 
speech-dispatcher.  You can select the language to use and control pitch 
and rate.  What you can't do is change anything while speech is going 
on.  You need to pause, make your change, then resume.

I don't plan on doing much more with this until I can get 
speech-dispatcher installed and working on my XO.  After that I expect a 
whole bunch of usability issues to come up and I'll deal with them at 
that time.  One thing I expect to have to deal with is preventing power 
saving from being activated while speech is in progress.  I'd also like 
speech to pause a bit between paragraphs.  Right now it reads the 
contents of the current page and stops.  I'm considering making going to 
the next page automatic.  Then I'm also trying to think of a good way to 
get it to start reading somewhere other than the top of a page.  That 
would be good to skip over Gutenberg notices and tables of contents.

I've been using the locale files from core Read up to now, so I haven't 
needed any translations to be done.  Now that's starting to change, 
because I've added the Speech toolbar.  I'm not sure how to proceed.

If anyone wants to try this out they can download it here:

http://wiki.laptop.org/go/Read_Etexts

James Simmons

___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re:Recent Updates to Sugar Almanac

2008-06-16 Thread James Simmons
Faisal,

What you wrote looks good, but I did see a possible error in it.  You say:

"The following simple write_file() method shows how both metadata and
files are written. Currently, write_file() will throw an error unless
somewhere you actually write an actual file to the file_path that is
passed to write_file. The code below writes a dummy file within the
body of write_file itself (you can do this elsewhere as long as you
have a handle on the file_path variable used by write_file)."

I think this is not always true.  Now if you're creating a new Journal entry 
for your app and have implemented write_file it *might* be true.  However, if 
your application is like Read, Read Etexts, or View Slides, which are always 
resumed from existing Journal entries, there is no need to write a file.  You 
can still save metadata, even if you don't write a file.

Another thing worth pointing out is that metadata doesn't work very well right 
now.  If I was in the position where I needed to write a file but didn't have 
anything that needed to go into it I wouldn't use metadata at all.  Instead I 
would put any saved options, etc. in the file, because *that* would persist 
across reboots but metadata currently does not.  I think several activities 
already do this.

I wrote a wiki page titled "Beyond Hello World" that covers much the same 
ground as yours, but I like yours better.

Thanks,

James Simmons



Date: Fri, 13 Jun 2008 17:34:43 -0400
From: "Faisal Anwar" <[EMAIL PROTECTED]>
Subject: Recent Updates to Sugar Almanac
To: devel@lists.laptop.org, [EMAIL PROTECTED]
Message-ID:
<[EMAIL PROTECTED]>
Content-Type: text/plain; charset="iso-8859-1"

Hello All,

As many of you know, I'm writing up a sugar almanac to help new sugar/python
developers get up and running with creating useful activities. I will try to
send frequent updates in terms of what has been added. In addition to using
the documentation, I'd appreciate it if people familiar with the different
modules I am writing can send any better or alternative code examples to the
ones that I have written. Review and feedback is ALWAYS appreciated.



___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Usage monitoring: any experience?

2008-06-16 Thread s . boutayeb
Thank you Pia for your comments.

We will examine further if the applications Moodle, which seems to be bundled
with the XS-server, or ClaSS and Openadmin could address the issue of the usage
monitoring.

Best regards,

Samy




___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: [IAEP] booting XO-Live CD from usb key

2008-06-16 Thread WolfgangRohrmoser
On Monday 16 June 2008 11:17, you wrote:
> Bill,
>
> your best bet might be to ask the LiveCD creator himself - cc'ed.
>
> - Bert -
>
> Begin forwarded message:
> > From: "Bill Kerr" <[EMAIL PROTECTED]>
> > Date: 16. Juni 2008 08:47:25 MESZ
> > To: "its. an. education. project"
> > <[EMAIL PROTECTED]
> >
> > Cc: Paul T <[EMAIL PROTECTED]>
> > Subject: [IAEP] booting XO-Live CD from usb key
> >
> > has anyone successfully booted the XO-Live CD from a usb key?
> > (if so we can run it in my classes at school where the CD drives
> > have been disabled due to student vandalism)

The CD-image of the recent XO-LiveCD (Version 080607) contains a 
script to copy the data on a USB key and make it bootable. 
The steps can be summarized to:

  *  mount the CD (or ISO-image) on a Linux Computer.
  *  open a console (shell) and go into the directory tools/
  *  insert a usb memory device and
  *  start: 
  ./make_usbstick.sh -d  -m 

(Hint:   ./make_usbstick.sh -h  gives more documentation)

It should work, if you have any problems please let me know :)
   
regards
  Wolfgang

> >
> > I asked a techie friend and apparently there is more involved than
> > just putting the iso on the key and resetting CMOS
> >
> > --
> > Bill Kerr
> > http://billkerr2.blogspot.com/
> >
> > ___
> > Its.an.education.project mailing list
> > [EMAIL PROTECTED]
> > http://lists.lo-res.org/mailman/listinfo/its.an.education.project


___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel