Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #28040

Re: Sending USB commands with Python

Path csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!news.mixmin.net!eweka.nl!hq-usenetpeers.eweka.nl!xlned.com!feeder7.xlned.com!news2.euro.net!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail
Return-Path <python-python-list@m.gmane.org>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.008
X-Spam-Evidence '*H*': 0.98; '*S*': 0.00; 'python.': 0.02; 'subject:Python': 0.05; 'variant': 0.07; 'port,': 0.09; 'received:80.91': 0.09; 'received:80.91.229': 0.09; 'received:gmane.org': 0.09; 'received:list': 0.09; 'aug': 0.13; 'pdf)': 0.16; 'received:80.91.229.3': 0.16; 'received:plane.gmane.org': 0.16; 'package.': 0.17; 'admin': 0.18; 'appears': 0.18; 'code,': 0.18; '(or': 0.18; 'trying': 0.21; 'bit': 0.21; 'seems': 0.23; 'device': 0.24; 'command': 0.24; 'appear': 0.26; 'raw': 0.27; 'label': 0.27; 'interface': 0.27; 'header:X-Complaints-To:1': 0.28; 'generous': 0.29; 'privileges': 0.29; 'subject:Sending': 0.29; "i'm": 0.29; 'etc.)': 0.32; 'could': 0.32; 'url:home': 0.33; 'to:addr:python-list': 0.33; 'whatever': 0.35; 'described': 0.35; "won't": 0.35; 'received:org': 0.36; 'wanted': 0.36; 'method': 0.36; 'subject:with': 0.36; 'charset:us-ascii': 0.36; 'pdf': 0.37; 'does': 0.37; 'level': 0.37; 'subject:: ': 0.38; 'to:addr:python.org': 0.39; 'header:Received:5': 0.40; 'perfect': 0.63; 'serial': 0.66; 'receive': 0.71; 'low': 0.83; 'printer': 0.84; 'printer,': 0.84; 'subject:commands': 0.84; 'url:documents': 0.84; 'dennis': 0.91; 'received:108': 0.91; 'luck': 0.93
X-Injected-Via-Gmane http://gmane.org/
To python-list@python.org
From Dennis Lee Bieber <wlfraed@ix.netcom.com>
Subject Re: Sending USB commands with Python
Date Tue, 28 Aug 2012 22:54:08 -0400
Organization > Bestiaria Support Staff <
References <ff6f931d-e5ad-40ee-aa4d-f2bbd1303046@googlegroups.com>
Mime-Version 1.0
Content-Type text/plain; charset=us-ascii
Content-Transfer-Encoding 7bit
X-Gmane-NNTP-Posting-Host adsl-108-79-222-169.dsl.klmzmi.sbcglobal.net
X-Newsreader Forte Agent 3.3/32.846
X-No-Archive YES
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.12
Precedence list
List-Id General discussion list for the Python programming language <python-list.python.org>
List-Unsubscribe <http://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive <http://mail.python.org/pipermail/python-list>
List-Post <mailto:python-list@python.org>
List-Help <mailto:python-list-request@python.org?subject=help>
List-Subscribe <http://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe>
Newsgroups comp.lang.python
Message-ID <mailman.3918.1346208855.4697.python-list@python.org> (permalink)
Lines 25
NNTP-Posting-Host 2001:888:2000:d::a6
X-Trace 1346208855 news.xs4all.nl 6931 [2001:888:2000:d::a6]:55499
X-Complaints-To abuse@xs4all.nl
Xref csiph.com comp.lang.python:28040

Show key headers only | View raw


On Tue, 28 Aug 2012 17:04:49 -0700 (PDT), "Adam W."
<AWasilenko@gmail.com> declaimed the following in
gmane.comp.python.general:

> So I'm trying to get as low level as I can with my Dymo label printer, and this method described the PDF http://sites.dymo.com/Documents/LW450_Series_Technical_Reference.pdf seems to be it.
> 
> I'm unfamiliar with dealing with the USB interface and would greatly appreciate it if someone could tell me how to send and receive these commands with Python.  Perhaps if you were feeling generous and wanted to write a bit of sample code, sending the "Get Printer Status" command and receiving the response (page 17 of the PDF) would be perfect to get me on my way.
> 

1)		what OS?

2)		does the printer appear as a serial port by the OS? Or as a
printer device?

	If it appears as a serial port, you may want to obtain the pyserial
(or whatever the name is this year) package. For USB, you may need one
of the variant USB packages (pywinusb, pyusb, etc.) With luck you won't
need to use admin privileges to access the port as a raw device vs
having to go through an OS driver...


-- 
	Wulfraed                 Dennis Lee Bieber         AF6VN
        wlfraed@ix.netcom.com    HTTP://wlfraed.home.netcom.com/

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Sending USB commands with Python "Adam W." <AWasilenko@gmail.com> - 2012-08-28 17:04 -0700
  Re: Sending USB commands with Python Dennis Lee Bieber <wlfraed@ix.netcom.com> - 2012-08-28 22:54 -0400
    Re: Sending USB commands with Python hamilton <hamilton@nothere.com> - 2012-08-28 21:03 -0600
      Re: Sending USB commands with Python alex23 <wuwei23@gmail.com> - 2012-08-28 22:04 -0700
        Re: Sending USB commands with Python hamilton <hamilton@nothere.com> - 2012-08-28 23:18 -0600
  Re: Sending USB commands with Python Tim Roberts <timr@probo.com> - 2012-08-28 23:45 -0700
    Re: Sending USB commands with Python Dennis Lee Bieber <wlfraed@ix.netcom.com> - 2012-08-29 16:09 -0400
      Re: Sending USB commands with Python "Adam W." <AWasilenko@gmail.com> - 2012-08-29 14:21 -0700
        Re: Sending USB commands with Python Tim Roberts <timr@probo.com> - 2012-08-30 20:55 -0700
      Re: Sending USB commands with Python Dennis Lee Bieber <wlfraed@ix.netcom.com> - 2012-08-29 17:57 -0400

csiph-web