![]() |
Re: mbarcode
Quote:
I'll get round to updating the plugins page to reflect the new callbacks and the Python plugins. Quote:
Quote:
Quote:
I'll get round to making the plugin settings window use a custom delegate + renderer, but I thought people might like some working, if cosmetically not optimum, code before I headed off for Christmas :) |
Re: mbarcode
Hi,
I've been using mbarcode for a few weeks now, mostly for fun and to show off the phone, as I did not have a real use for it. It works really well, though. Recently I tidied up my library and thought that it would be a good idea to index it, since I found out that I'd bought a few books twice, after thinking that I'd lost my original copy (yes, I'm that well organized). So basically I wrote a pretty straightforward Perl script to read a list of ISBNs, ask Amazon for metadata on the books, and write the metadata to a database. Now I just need a way to get the ISBNs without typing them one by one. This is where I finally have a real use for a barcode reader. I tried zbarcam but it dies immediately on my N900 ("system error: queuing video buffer (VIDIOC_QBUF): Input/output error (5)"). Basically, what I need is a simple plugin for mbarcode that appends the decoded data to a text file. If I understand correctly, if only one plugin is activated, it is possible to make it run immediately without going through the "results" window. Since I have a) little C++ skills and absolutely no Qt experience, and b) not managed to make the Python example show up in the plugins list, and even less Python experience than C++... I guess I'm requesting a feature? (Boy, I hate writing feature request posts, it makes me feel really unappreciative of the existing functionality.) |
Re: mbarcode
Quote:
I've been doing some hacking on a Python app to do this, but it's no-where near finished (itemdb in Garage, and in fact I need to push some updates to that). In the short term, let's see if we can get your Python save-to-a-text-file code working - can you create a tarball and attach it (.py is not allowed as an extension for attachments) or copy and paste the code into a reply? Also try starting mBarcode from the terminal and see what the error is (it will tell you why the plugin didn't load). |
Re: mbarcode
Quote:
|
Re: mbarcode
1 Attachment(s)
I've not tried this, but it should do basically what you want, hopefully!
Touchscreen seems to have just failed on my N900 so I can't actually test it. |
Re: mbarcode
Quote:
Code:
Created scannerI do have the python wrapper plugin installed, by the way (unless the version currently in the repositories doesn't work, or is that the same as SVN head? I am not familiar with garage either...) (edit) I should add my thanks for replying this fast on New Year's Eve, and even producing code for a random user! |
Re: mbarcode
It should be placed in /usr/share/mbarcode/plugins/pythonqt/ part of the app is optified, and eventually that directory will be a symlink to the /opt stuff.
Curious that you don't see any output in the terminal. My N900 has suddenly started working again (thank goodness!) so I'll have a look myself and get back to you. |
Re: mbarcode
1 Attachment(s)
Right, 'twas my fault. I've just pushed updated versions of mBarcode and the pythonqtwrapper plugin to Extras-devel. These should provide more debugging output now. In addition the problem was that I'd not added a dep on libshiboken1.0 for the pythonqtplugin (though I have now).
I've also attached a fixed version of the Python code (you need to install python-pyside manually - normally this would be a dep of this python code's deb file. This is quite a large install, but it goes to /opt, so shouldn't be a problem. OTOH as it doesn't actually use PySide you could well be able to remove that import & superclass references (to QtGui.QWidget iirc) and see if it works anyway.) In any case let me know how you get on, and a Happy New Year to everyone :) |
Re: mbarcode
1 Attachment(s)
OK, it works better now. I installed python-pyside, updated mbarcode and plugins. The plugin appears in the list and outputs correctly to barcodes.txt, looks good.
The problem now is that the Results page appears even if the "Auto-run plugin" option is checked; not only this makes the workflow difficult (ideally you'd just run the camera over the barcodes with no other interaction necessary), but there is nothing to interact with on the page (I disabled all plugins except the isbn saver), it just stays there and doesn't respond to the back button either, so it needs to killed from the window switcher. Attached is the stdout and stderr from mbarcode while it's started up, scans a barcode, looks for plugins, does its thing with the barcode, displays results and is killed from the window switcher. Happy new year to all. |
Re: mbarcode
1 Attachment(s)
Right, fixed that problem and a few others, I'm currently trying to push to Extras-devel, but the autobuilder web page doesn't seem to be responding.
Hopefully just a temporary glitch, I'll try again this afternoon. In the meantime I've attached the updated deb here. |
| All times are GMT. The time now is 08:47. |
vBulletin® Version 3.8.8