Re: Apple USBSimple Example & Rosetta
Re: Apple USBSimple Example & Rosetta
- Subject: Re: Apple USBSimple Example & Rosetta
- From: Eric Albert <email@hidden>
- Date: Tue, 3 Jan 2006 08:13:10 -0800
On Jan 3, 2006, at 6:42 AM, Ray Swartz wrote:
<x-tad-bigger>I am working on getting a PowerPC app that uses USB to run on an Intel Mac. The USB code is in a universal binary library. We don't want to make a universal binary of the app, because it uses PowerPlant</x-tad-bigger><x-tad-bigger>.</x-tad-bigger><x-tad-bigger>
</x-tad-bigger>
I'm a bit confused by that. What about PowerPlant is keeping you from making the application universal? The Universal Binary Programming Guidelines has an appendix which describes what you should change to get a PowerPlant application to build and run on Intel.
<x-tad-bigger>The library works when run natively; i.e., when the app is universal, too. But it fails in our PPC app when run on Intel under Rosetta. It connects, finds a configuration, but fails to find any interfaces. It's hard to debug, because the Xcode debugger doesn't work under Rosetta.</x-tad-bigger>
The Universal Binary Programming Guidelines has an appendix about Rosetta which describes how to debug applications running there. That might be helpful....
<x-tad-bigger>One thing I've done is to build the sample Apple project USBSimple Example. To my surprise, this also fails in much the same way on the Intel Mac when run under Rosetta. Has anyone else seen this? </x-tad-bigger>
<x-tad-bigger>When I added the byte-swapping macro USBToHostLong to the following line</x-tad-bigger>
<x-tad-bigger>while ( (usbInterfaceRef = IOIteratorNext( USBToHostLong( iterator ) )))</x-tad-bigger>
<x-tad-bigger>it worked. At least that part. Do I need to add a lot of these macros to my code? Any advice would be appreciated.
</x-tad-bigger>
The USB Device Interface Guide has a section about USB device access on Intel-based Macs which I think you'll find useful: <http://developer.apple.com/documentation/DeviceDrivers/Conceptual/USBBook/index.html#//apple_ref/doc/uid/TP40000973>.
Hope this helps,
Eric
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden