octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Octave control via d-bus


From: Jaroslav Hajek
Subject: Re: Octave control via d-bus
Date: Wed, 27 Jan 2010 07:18:02 +0100

On Wed, Jan 27, 2010 at 5:31 AM, Patrick Noffke
<address@hidden> wrote:
> Greetings,
>
> I would like to add the ability to exchange data between octave and the
> spreadsheet programs openoffice, kspread, and gnumeric.  Pedro Lucas (cc'd),
> the developer of QtOctave, suggested this to me when I asked him what I
> could do to help with QtOctave.  At first, I was looking at just openoffice,
> and at octave being the "master" and openoffice being the "slave."  That is,
> run a command in octave (maybe with a nice gui in QtOctave) to generate a
> spreadsheet (or writer document with table) from an octave array (I am aware
> of PyUNO and have experimented some with this).  But it seemed that it is
> more useful for the spreadsheet to be the master, since that gives the user
> control over the formatting.  I'm thinking something like the Matlab Excel
> Link, for those of you that know about this product.
>
> All three spreadsheet programs are python scriptable, and you can react to
> events (e.g. changes in a cell that might be a parameter to an octave
> function, and require re-calling the octave function).
>
> At a minimum, I want to do the following:
> * SetMatrix (an operation that sets an octave workspace variable using
> contents from a spreadsheet).
> * GetMatrix (an operation that retrieves an octave workspace variable and
> updates the spreadsheet contents).
> * RunScript (an operation that runs an octave script with parameters from
> the spreadsheet and returning one or more arrays).
>
> I thought about using a mechanism like Pedro uses with QtOctave
> (communicating via octave stdin/stdout, and passing data in temporary
> files).  This is not a bad option, and would meet all three of my goals.
>
> But I also thought it would be nice to do the following:
> * Add a debug interface (dbstep, dbcont, etc.)
> * Connect the spreadsheet to an existing instance of octave.
>
> And I also thought d-bus is taking hold with KDE and Gnome, so it is likely
> to be around for a while.  Plus there is python-dbus which would I could use
> to make the spreadsheets talk to octave.
>

Did you also look at Pytave? <https://launchpad.net/pytave/>
It can't connect to an existing instance, instead Octave is embedded
into the Python process. This has the advantage that data don't need
to be sent through sockets or pipes (but of course there are also
disadvantages).
Otherwise, it should enable you to do all the stuff. I've never tried
debugging from within Pytave but in principle it could be possible.


regards


-- 
RNDr. Jaroslav Hajek, PhD
computing expert & GNU Octave developer
Aeronautical Research and Test Institute (VZLU)
Prague, Czech Republic
url: www.highegg.matfyz.cz



reply via email to

[Prev in Thread] Current Thread [Next in Thread]