Microchip (TM) PICKit 2 USB Driver, HID attachment?
Hunting for resources to program PIC embedded microcontrollers on macs, ran into microchip's way cheap PICKit 2 USB programmer:
http://microchip.com/stellent/idcplg?IdcService=SSGETPAGE&nodeId=1406&dDocName=en023805
They publish the source and Xcode project for an unsupported Mac tool that drives the PICkit 1 usb programmer from userland
http://www.aeria.net/pub/PICkit2dev.zip
however, after building it, changing the usbProduct #define to reflect the new device and tracing the output I'm finding that all writes to the device fail becuase something else claimed the programmer endpoints in exclusive mode usb
usb io trace follows (can provide buckets of debugging on request):
Timestamp Lvl Message
--------- --- --------------------------------------
3.822 [1] [0x2e15c00]::start - USB HID Interface #0 of device PICkit 2 Microcontroller Programmer @ 2 (0x19100000)
3.837 [1] IOUSBInterface[0x1a25100]::handleOpen failing because super::handleOpen failed (someone already has it open)
3.837 [1] IOUSBInterface[0x1a25100]::open super::open failed (0x0)
The Questions:
Has someone allready done this? For this device? Which device does it work on?
Why did microchip call a chip programmer a HID device?
Why did the apple HID framework attach the device when it has no HID compliant controls?
Can I get the Apple HID controls to release the programmer or not to attach at all?
(or) I have to write a kext/driver stack to match the vendor/product/model exactly to force the point?
Background:
This project would enable high visibility robotics and educational applications that permit interfacing robotics and telematics with high level programming. (RE: build your own robot to enter a contest or collect your socks). The programmer downloads machine code to little embedded computers (PIC chips) that you can then instruct it to perform neat things that may earn you sex appeal or peer acclaim in the correct circles.
Many Macs Mac OS X (10.4.3)
http://microchip.com/stellent/idcplg?IdcService=SSGETPAGE&nodeId=1406&dDocName=en023805
They publish the source and Xcode project for an unsupported Mac tool that drives the PICkit 1 usb programmer from userland
http://www.aeria.net/pub/PICkit2dev.zip
however, after building it, changing the usbProduct #define to reflect the new device and tracing the output I'm finding that all writes to the device fail becuase something else claimed the programmer endpoints in exclusive mode usb
usb io trace follows (can provide buckets of debugging on request):
Timestamp Lvl Message
--------- --- --------------------------------------
3.822 [1] [0x2e15c00]::start - USB HID Interface #0 of device PICkit 2 Microcontroller Programmer @ 2 (0x19100000)
3.837 [1] IOUSBInterface[0x1a25100]::handleOpen failing because super::handleOpen failed (someone already has it open)
3.837 [1] IOUSBInterface[0x1a25100]::open super::open failed (0x0)
The Questions:
Has someone allready done this? For this device? Which device does it work on?
Why did microchip call a chip programmer a HID device?
Why did the apple HID framework attach the device when it has no HID compliant controls?
Can I get the Apple HID controls to release the programmer or not to attach at all?
(or) I have to write a kext/driver stack to match the vendor/product/model exactly to force the point?
Background:
This project would enable high visibility robotics and educational applications that permit interfacing robotics and telematics with high level programming. (RE: build your own robot to enter a contest or collect your socks). The programmer downloads machine code to little embedded computers (PIC chips) that you can then instruct it to perform neat things that may earn you sex appeal or peer acclaim in the correct circles.
Many Macs Mac OS X (10.4.3)