Re: [hai-dev] FYI, I banned HomistaGuy

25 views
Skip to first unread message
Message has been deleted

Philip Prindeville

unread,
Nov 8, 2010, 7:39:14 PM11/8/10
to hai...@googlegroups.com
Where do these people come from?

BTW: I've not heard from Dan Cunningham in a while. Has anyone else?

Is anyone using the sources from Gitorious currently?

I had wanted to do a Perl library but hadn't had the time (staring a lot at ZigBee these days).

Rick Macdonald

unread,
Nov 8, 2010, 7:41:56 PM11/8/10
to hai...@googlegroups.com
I haven't made any code changes since my first round.

Rick

Dax Kelson

unread,
Nov 9, 2010, 1:42:09 PM11/9/10
to hai...@googlegroups.com
On Mon, 2010-11-08 at 16:39 -0800, Philip Prindeville wrote:
> Where do these people come from?

SPAMers suck. I adjusted the settings in the google group to moderate
the first few posting by brand new members.

> BTW: I've not heard from Dan Cunningham in a while. Has anyone else?
>
> Is anyone using the sources from Gitorious currently?
>
> I had wanted to do a Perl library but hadn't had the time (staring a
> lot at ZigBee these days).

I would love a Perl library!

Dax Kelson

Rick Macdonald

unread,
Nov 9, 2010, 2:33:57 PM11/9/10
to hai...@googlegroups.com
I've been aware of SWIG for many many years but never had a need for it. I think it might be worth a try for the HAI library. The basic idea is that with little or no changes to the library code, SWIG can generate C code wrappers that you compile to add some or all of the functions to scripting languages such as Ruby, PHP, Tcl, Perl, Python.

I think the biggest issue might be error messages and error handling, since our library mostly prints its errors. That could require significant code change.

In my scripting I just run the hai executable repeatedly with command line arguments to get what I need done. Using SWIG or porting to something like PERL would give access to lower level functions.

Dax and others, any comments?

http://www.swig.org/

SWIG runs on UNIX, Windows and Mac. Here is a more complete list of supported target languages:

The following scripting languages were supported in the final SWIG 1.1 release.
  • Tcl 8.0 and newer versions.
  • Python 1.5 and newer.
  • Perl 5.003 or newer.
  • Guile 1.3.4 and newer.
The following languages are also supported in swig-1.3.6 onwards.
  • Java JDK 1.1 and newer.
  • Ruby.
  • Mzscheme.
PHP support was added in swig-1.3.11.
Objective Caml (Ocaml) and Pike support was added in swig-1.3.14.
Support for C# and the Chicken scheme compiler was added in swig-1.3.18.
Support for Allegro CL and Modula-3 was added in swig-1.3.22.
Support for Lua, CLISP and Common Lisp with UFFI was added in swig-1.3.26.
Support for Common Lisp with CFFI was added in swig-1.3.28.
Support for R was added in swig-1.3.30.
Support for Octave was added in swig-1.3.35.
Support for the Go language was added in swig-2.0.1.

Rick

Philip Prindeville

unread,
Nov 11, 2010, 12:53:37 AM11/11/10
to hai...@googlegroups.com
If it's going to be a library, it needs to be re-entrant and support multiple instances.

I started changing the sources in Git to use instance variables instead of globals, but haven't had time to regress it and make sure everything still works.

Has anyone else tried them?

Thanks.


On 11/9/10 11:33 AM, Rick Macdonald wrote:
> I've been aware of SWIG for many many years but never had a need for it. I think it might be worth a try for the HAI library. The basic idea is that with little or no changes to the library code, SWIG can generate C code wrappers that you compile to add some or all of the functions to scripting languages such as Ruby, PHP, Tcl, Perl, Python.
>
> I think the biggest issue might be error messages and error handling, since our library mostly prints its errors. That could require significant code change.
>
> In my scripting I just run the hai executable repeatedly with command line arguments to get what I need done. Using SWIG or porting to something like PERL would give access to lower level functions.
>
> Dax and others, any comments?
>
> http://www.swig.org/
>
> SWIG runs on UNIX, Windows and Mac. Here is a more complete list of supported target languages:
>
> The following scripting languages were supported in the final SWIG 1.1 release.
>

> * Tcl 8.0 and newer versions.
> * Python 1.5 and newer.
> * Perl 5.003 or newer.
> * Guile 1.3.4 and newer.


>
> The following languages are also supported in swig-1.3.6 onwards.
>

> * Java JDK 1.1 and newer.
> * Ruby.
> * Mzscheme.

Rick Macdonald

unread,
Nov 11, 2010, 12:14:05 PM11/11/10
to hai...@googlegroups.com
I can't think of why it has to be re-entrant with multiple instances.
Could I trouble you for an explanation? :-[

Thanks,
Rick

Philip Prindeville

unread,
Nov 11, 2010, 1:07:49 PM11/11/10
to hai...@googlegroups.com
Let's say I wanted to run a web service that talked to multiple residential systems collecting alarms, managing thermostats, etc.
Reply all
Reply to author
Forward
0 new messages