[obdgpslogger] Some questions

Peter Buelow goballstate at gmail.com
Wed May 12 11:45:28 EDT 2010

Thanks for the quick reply. I'll be getting this up and testing to some
extent hopefully next week. I gotta admit to hating DBus as well (we use it
extensively at work for automotive computing), but it's hard to argue
against a solid distributed messaging scheme, even if the API is ugly and
hard to manage (I'm using QT, and if it's hard to do in QT, then it's just
damn ugly). I thought about scraping, but that leaves me with a lot of
parser work I don't particularly like, plus having to invent my own
notification system. And reading the DB means I either invent polling for
it, or use a timer, which I don't like. The system is only 400 Mhz, and is
actually going to be doing quite a bit of other stuff, so I'd like to keep
the overhead small. BTW, this is being done with a Gumstix Verdex using OE.
I'll send an OE recipe to you when I have one that works, for reference, as
it might be useful to provide an OE version as well.

I hope to finish my project pages which should have the SVN repos, a ticket
system, and details about the project available before too long (gonna start
it tonight, but it may take a week or two to get started). Check it out at

Will be talking to you with questions and stories soon enough I imagine.

On Wed, May 12, 2010 at 10:38 AM, Gary Briggs <chunky at icculus.org> wrote:

> On Wed, May 12, 2010 at 07:58:51AM -0500, Peter Buelow wrote:
> > Ok, just want to use this project for a automotive HUD I'm building. You
> saved me, I tried to get a couple of other packages working, but never
> could, so I'm gonna use this project. This might be exactly what I've been
> looking for. However, a  quick question.
> >
> > Does the main app send it's log data over DBUS at any point?
> Yep. It only sends signals, it doesn't actually "communicate" over DBus,
> /per se/, but you can just listen and get updates.
> The code is in the function obddbussignalpid in src/logger/obddbus.c
> To understand how to read the signals, this code should explain:
> #define OBDDBUS_INTERFACENAME "org.icculus.obdgpslogger"
> // "/obd" is the path, and "value" is the name.
> msg = dbus_message_new_signal("/obd", OBDDBUS_INTERFACENAME, "value");
> dbus_message_append_args (msg,
>    DBUS_TYPE_UINT32, &(cmd->cmdid), // PID
>    DBUS_TYPE_DOUBLE, &val, // Actual value
>    DBUS_TYPE_STRING, &(cmd->db_column), // Short name
>    DBUS_TYPE_STRING, &(cmd->human_name), // Long name
>    DBUS_TYPE_INVALID // Sentinel
> );
> You should be able to see signals being announced by using this at the
> command prompt:
> dbus-monitor --system
> As a mere aside, I despise dbus. It's an awful API, and the developers
> of the reference implementation documented it by saying "don't use this,
> it sucks". If you have any better suggestions, I'm more than open to
> putting
> them in and urging people to use them instead of dbus.
> Other approaches that might work:
> The current [hokey-as-hell] gui launches obdgpslogger and reads
> obdgpslogger's stdout to see how to update the GUI. You could always
> just scrape the latest values directly from the database, although
> that may induce small amounts of lag. shared-memory.
> > I don't much need the database, but will keep it so I can export it to
> save trip details and such. However, the primary use, being a HUD, I just
> need the near realtime updates of the ECU data (speed, tach, temp right
> now). I noticed the sim uses DBUS, and in main(), there's a DBUS init
> routine, but I'm not quite up to speed on exactly how it's used yet. Still
> perusing the code. If it doesn't do this, how hard would it be to make this
> ability an addon, enabled using a command line switch?
> Should just magically work.
> If you're not seeing anything, you should check that dbus support was
> actually compiled in. You'll need your distro's dbus dev package [on
> debian and friends it's libdbus-1-dev]. If it wasn't installed before,
> you may need to purge your build dir and rebuild, as cmake usually won't
> pick up changes like that. CMake tells you whether it finds it or not
> when you run it.
> > I'm more than willing to do the work, I'll have to anyway, I need some
> useful async messaging to get OBD data into my app, and this seems like it
> would be a good way to do it (although DBUS is kinda ulgy for small things
> like this).
> DBus is kinda ugly for *everything* :-)
> > Thoughts? Thanks for building this. I'm looking forward to being able to
> make it go with my stuff.
> Coo, please let me know how it works out. I really am happy to help
> where I can
> Gary (-;
> _______________________________________________
> obdgpslogger mailing list
> obdgpslogger at icculus.org
> http://icculus.org/mailman/listinfo/obdgpslogger

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://icculus.org/pipermail/obdgpslogger/attachments/20100512/8a8a87ff/attachment.htm>

More information about the obdgpslogger mailing list