Hi
I am trying to write a Cocoa program which detects iPods connected to Mac OS. I am listening to NSWorkspaceDidMountNotification and NSWorkspaceDidUnmountNotification for the USB device mount and unmount notifications. I can get the device path of the mounted device using NSString *path = [[notif userInfo] objectForKey:@"NSDevicePath"...
Is there a reliable, quick, deterministic way (definitely not benchmark) to check whether system drive in Mac OS X is on Solid State Drive?
Is there any other indicator how well disk handles parallel access? I'm trying to adjust number of threads that my program is going to use for disk-bound operations.
I'm not interested in raw spee...
I'm looking at options to access DVB data on OS X. Initially I want to support the EyeTV DTT USB device, but in the long-run I'd like to support a number of popular devices. The problem I have is that there is no standard way of controlling such devices.
All the applications I know of that use them either hide the driver code within t...
I'm about to attempt to write a USB driver for my application on OS X using IOKit. I've opted for the userspace route rather than developing a kext since it's so much easier to debug etc, but I'm having trouble working out how I could possibly test-drive my development.
If possible, I'd like to find a way to insert a fake USB device i...
I'm getting started with IOKit on OS X, and I've been puzzled by the '245' tagged onto data types in the IOKit USB library, such as IOUSBInterfaceInterface245. What does the 245 mean? I'm just curious what this number tacked onto the end is supposed to indicate. It seems like a version number of something.
Is there a generic version ...
Can anyone shed some light on how to get CPU temperature and fan speeds in osx? I understand that information is obtained from IOHWSensor in IOKit, but I'm unable to find any reliable information on how to exactly do that.
I've found an article with a sample program - http://www.booktou.com/node/148/0321278542/ch10lev1sec7.html but all ...
Hello everyone,
I have an IOKit-based kernel extension on Mac OS X, a subclass of IOService. When this service loads i need to publish additional specific runtime information from it and i need it to be accessible from user space without making some specific IOUserClient requests. The information in question is basically field\value pai...
Just wondering, is there any "API" for sending signals through a USB cable to a device using Apple's cocoa programming language, so I could incorporate it with an app?
is it much more complicated than a couple of commands, or do i need a library?
I have no experience with external device communication so any help is welcomed!
...
Hi,
I'm trying to write an app that associates a particular USB string descriptor (of a USB mass storage device) with its volume or bsd name.
So the code goes through all the connected USB devices, gets the string descriptors and extracts information from one of them. I would like to get the volume name of those USB devices. I can't ...
I want to get the hardware address of my mac's ethernet card. In all samples I saw in include on IOKit/assert.h . Which doesn't seem to exist on my system. GCC throws an error saying he doesn't know the type IOEthernetAddress.
Is assert.h necessary for my task? It would be great if someone coud give me a working sample.
[edit] here's my ...
Hi,
I am creating a software on Mac and I would like to change the value of an IORegistryEntry. I can view it on the IORegistryExplorer, but I can't edit it. So it's my understanding that I have to edit it via code. Here is my code:
CFMutableDictionaryRef matchingDict = IOServiceNameMatching("AppleUSBMultitouchDriver");
io_service_t se...
I wrote this code to subscribe to USB devices being plugged in and unplugged; the point is for IOKit to deliver notifications to my iAttached() and iDetached() functions when the corresponding events occur. However, I don't get notifications.
The code can be seen here: http://gist.github.com/402391
I didn't want to over-populate this p...
In Mac OS X, every display gets a unique CGDirectDisplayID number assigned to it. You can use CGGetActiveDisplayList() or [NSScreen screens] to access them, among others. Per Apple's docs:
A display ID can persist across
processes and system reboot, and
typically remains constant as long as
certain display parameters do not
...
I use the function "IOPMSchedulePowerEvent" to schedule Sleep or Wake-Events and registered my daemon with "IORegisterForSystemPower" to receive power-state-changes. Everything works fine!
When system going sleep and later waking up at scheduled time, my daemon do some work, and after it system should going sleep again.
Now my question...
Hi all,
i'm working on a project were i need the usb port to communicate with a external device. I have been looking for exemple on the net (Apple and /developer/IOKit/usb exemple) and trying some other but i can't even find the device. In my code i blocking at the place where the fucntion looks for a next iterator (pointer in fact) wit...
Hello,
I have previously written an application for Mac OSX that includes a kernel extension. It does not drive any real hardware but is instead an in-kernel IOKit service. Now the task is to figure out if porting of the whole application is possible on the iPad which basically means if kernel extensions can be written for iPad.
I hav...
Currently I have an objective-C program that detects when a Fujitsu scanner is added and removed from the computer. I'm trying to add the ability to ask the scanner information about itself. I know the command for this, however, something is going wrong. I'm doing a bit of cargo-cult programming, from two different cargo cults (How do yo...
I have a simple question. How do I get iPhone's battery level?
[UIDevice currentDevice] batteryLevel]
Simple enough? However there is a little catch - I can't use UIKit. Here is what I wrote so far, but I don't think it works:
// notification port
IONotificationPortRef nport = IONotificationPortCreate(kIOMasterPortDefault);
CFRu...
Hi all,
I would like to build a controller for a robot which would communicate through USB to an iPad. However I don't have an iPad yet as I don't if it is ever possible to build such software (even with jailbreak).
So I have a few questions for those iPad owners: In a jailbroken iPad is it possible to use iokit for usb communication th...
Hello,
Is there a way to get a string representation for the Constants and enums defined in IOKit?
I making a forage into IOKit and trying to console log out some parameter which USB devices return. But I'm ending up with lists of numbers. Is there another way to list what these mean?
For example in IOHIDKeys.h
enum IOHIDElementType ...