[maemo-developers] send data to bluetooth printer via SPP

From: Lauro Moura lauromoura at gmail.com
Date: Thu Jul 12 16:31:19 EEST 2007
On 7/12/07, maemo at komarov.info <maemo at komarov.info> wrote:
> I try to use blueZ- components installed on an N800 device
> to send data (escape-sequences) to my bluetooth-enabled
> inkjet printer (it also supports PCL).
> First of all, I assured that the printer is visible from
> N800:
> I perform 'hcitool scan --scan' under root console and see
> this printer with its BD address, name, and class.
> I found a code example (in Python, here:
> http://wiki.bluez.org/wiki/HOWTO/SerialConnections) that
> allows communicate to the printer using SPP. I have Python
> installed, so I run the example script (I called file
> dbus.py) and receive error:
> File "./dbus.py", line 3, in <module>
> import dbus
> File "/media/mmc1/dbus.py", line 7, in <module>
> bus= dbus.SystemBus()
> AttributeError: 'module' has no attribute 'SYstem.Bus'

If the error message is correct, looks like you have a typo on
dbus.SystemBus (Check the case of y...).

Lauro Moura ("lmoura" on Freenode)
INdT / Recife

More information about the maemo-developers mailing list