On Don, 2008-02-14 at 09:34 +0800, Tony Lam wrote: > Hi, > > >>Take a working one - "txtinfo" is pretty/relatively small. > > Bernd, I appreciate your help and I do have a look at different > plugin(txtinfo, mini, nameservices). Good. > However, what I want to know is, for example, > what functions which must be implemented in a plugin, > how the plugin can interact with olsrd.......etc. src/txtinfo/olsrd_plugin.c contains: - my_init() and my_fini(): these are called if the shared lib is loaded and unloaded respectively (BTW it is never really unloaded). The __attribute__s (find the function prototypes) tell that the linker BTW. - olsrd_plugin_interface_version() is called by the core to find the version of the API (and is thus usually that simple). - olsrd_get_plugin_parameters() is called by the core to get the number and array of the parameters of your plugin. That's all the core needs/uses from the plugin. The "init" function usually initializes the plugin-local variables and may hook into the core via various callback functions and/or use data structures. And that's the point where others must continue as I fiddled only around with the above functions and never wrote a plugin myself - just patching various things .... > Indeed the "how to" page for interface 4 is what I am looking for > I just wonder if there has a similiar one to that for plugin interface > 5. *eg* Yes, actually we are looking for someone who is reworking that page. > Anyway, thx for the help again~=] Bernd > -- Firmix Software GmbH http://www.firmix.at/ mobil: +43 664 4416156 fax: +43 1 7890849-55 Embedded Linux Development and Services