[Nut-upsdev] Re: [nut-commits] svn commit r433 - in trunk: data drivers include

Arnaud Quette aquette.dev at gmail.com
Tue Jun 20 09:20:53 UTC 2006


I've forgotten to add that a "driver.version.communication" (or alike)
should be added to track the comm subdriver type and version. I've
intentionaly let the double versioning in the banner for now (just
changing it to "xxx driver %version - core %version%").

I'll also have to make some command names propositions for outlets (ie
outlet.x.load.{off,on}), but there is also the parameter possibility
that hasn't been finished (allowing "load.off {all, outlet.x}"
defaulting to "all")

2006/6/20, Arnaud Quette <aquette.dev at gmail.com>:
> Hi Peter,
>
> 2006/6/19, Peter Selinger <selinger at mathstat.dal.ca>:
> > Hi Arnaud,
> >
> > I have a suggestion on code organization. Since libshut.c and libhid.c
> > are intended to share the same interface, perhaps this should be
> > made explicit by making them use the same header file. I.e.,
> > newhidups.c would always include libhid.h, instead of including
> > one of libshut.h / libhid.h.
> >
> > The stuff in libshut.c that does not implement the libhid interface
> > (essentially the definition of the shut_subdriver data structure)
> > would be moved into its own source file, by analogy with the
> > {apc,belkin,generic,mge,tripplite}-hid.[ch] files. This way there
> > would be a clear distinction between (1) the HID/SHUT (abstract)
> > interface, and (2) specific driver code.
> >
> > Ultimately, it would be a nice goal to make the HID/SHUT interface
> > abstract enough to eliminate all the new #ifdef's from newhidups.c,
> > i.e., it should be transparent to newhidups whether it is using HID or
> > SHUT.
>
> that was intended for a second round, along with set_report and
> notification management.
> If you have a bit of time to do the above, be my guest as I'll again
> be missing for some more time...

Arnaud
-- 
Linux / Unix Expert - MGE UPS SYSTEMS - R&D Dpt
Network UPS Tools (NUT) Project Leader - http://www.networkupstools.org/
Debian Developer - http://people.debian.org/~aquette/
OpenSource Developer - http://arnaud.quette.free.fr/



More information about the Nut-upsdev mailing list