[Pythonmac-SIG] Zope py2app, some progress

Bob Ippolito bob at redivi.com
Thu Feb 10 09:22:34 CET 2005


On Feb 10, 2005, at 2:51 AM, Roger Binns wrote:

>> Obviously not people familiar with http://developer.apple.com/ :)
>
> Actually Steven Palm who did most of the original got some changes
> I still don't understand into libusb to make it work correctly on
> Mac.  There is deep voodoo involved since some of the phones are
> actually composite devices and MacOS only binds drivers to some
> of the interfaces while BitPim needed to access the other interfaces.

Probably because it doesn't have drivers for them.  If there's no 
matching driver, it won't pull up a useful nub to stick on it.

>> Well, if you take a look at the example, it's really straight-forward 
>> and you can come up with something specific to your app in just an 
>> hour or two.
>
> I have looked through the API and I have looked in the Explorer.  I
> can find serial/modem ports and I can find USB devices.  I still
> don't see where they are linked.
>
> For example the device with USB vendorid 0x1004, productid 0x6000,
> interface 1 is /dev/cu.usbmodem5B231.  I don't see where to get
> the USB details starting with the /dev name or the /dev name starting
> with the USB details.
>
> I have no problem getting the details seperately.  It is linking
> them that matters.

Given a USB device, you look for an IOSerialBSDClient down the tree.
Given a BSD device, you look for a USB device up the tree.

The information is not in the same place because the data is in a tree. 
  The IOSerialBSDClient nub has no business knowing about USB crap.  
It's all very elegant.

A good way to look at this tree is the Mr. Registry app that is one of 
the targets in /Developer/IOKit/firewire/FWOffice -- despite its name, 
it lets you look at the whole tree, not just IOFireWire.

>> compatible with BitPim.  I'd really like to see BlackBerry 7100 
>> support, but it doesn't even show up as a serial device over USB
>
> That is why BitPim uses libusb for some phones and just talks
> straight at them.  In fact that is even easier than serial style
> access.
>
>> don't really know where to start with reverse engineering it
>
> Generally you need to record what some existing working program
> does and go from there.  That or make wild guesses.

I'd have to do a lot of reading up on that to see how to get dumps of 
USB traffic.  I could run the BlackBerry Desktop via VirtualPC (or on a 
real PC) to figure out how the modem stuff works, the rest I could 
probably get by reverse engineering PocketMac.

-bob



More information about the Pythonmac-SIG mailing list