Kevin,
First, I wanted to apologize for not replying for a full month, as well as thank you very much for your reply. I was pulled away from this project for a couple weeks, and when I got back I was still spinning my wheels getting the driver installed.
I only today found my issue, which wasn't something you could have helped with since I hadn't thought to include the correct context in my original comment. I only found the issue after careful log monitoring in the Console app during the install process as my main installer app was running.
It turns out that my bundle ID was too long.
It was 67 characters and, apparently the maximum is 63. Seems like an arbitrarily short max in this day and age, and you'd think both XCode and the Developer Portal would catch that, but that's what it was. When I redid my bundle IDs more succinctly (and all my permissions on the Apple Developer Portal), I was able to successfully install/register/enable the driver. I have granted it permission in System Settings, it shows up under systemextensionsctl list, everything seems on the up and up.
So now I am moving on to other issues, and if you're still willing, I'll gladly accept additional help.
First, to answer your original question about my goals, the primary goal is to translate this custom USB protocol into something that an iMac will recognize as an external UPS battery.
Meaning, when the UPS data cable is plugged in, the iMac shows the battery icon widget in the Notification Center area with the correct battery percentage. Unless I'm completely wrong about it, which is entirely plausible, that means I need a driver (virtual or otherwise) that speaks HID in the Power Device class format to the operating system. And the UPS I'm working with does not speak that protocol.
Although I plan/hope to pull some of the data I'll get from the UPS battery out into user-app space to support future functionality, that's a nice-to-have. My primary goal is translating the battery into something the OS recognizes.
So, on to my current problem. The driver installs... but doesn't load. Probably because it's not matching. So I'm going to give more detailed information in the hope you can help me with this.
As I said, the device is a UPS battery, connected via USB cable from its data port. It speaks a custom RPC protocol over USB (I have internal documentation from the vendor with the bytecodes it uses). It uses a stock Silicon Labs firmware chip
When I plug the device into any iMac, I get the following item in the IO Registry / USB Tree:
CP2102N USB to UART Bridge Controller:
Location ID: 0x01120000
Connection Type: Removable
Manufacturer: Silicon Labs
Serial Number: 0c3421465321e86fcce05720eef3
Link Speed: 12 Mb/s
USB Vendor ID: 0x10c4
USB Product ID: 0xea60
USB Product Version: 0x0100
Those hex codes translate to Vendor ID 4242 and Product ID 60000.
Using Console and trawling through the logs when I plug the device in, I was able to find the following log entry:
CP2102N USB to UART Bridge Controller@01120000: IOUSBHostDevice::setConfigurationGated: AppleUSBHostCompositeDevice selected configuration 1
And immediately after that several entries involving the matching pocess, which resulted in
Picked matching dext for bundle identifier com.apple.DriverKit-AppleUSBSLCOM: Dext com.apple.DriverKit-AppleUSBSLCOM v1 in executable dext bundle com.apple.DriverKit-AppleUSBSLCOM at /System/Library/DriverExtensions/com.apple.DriverKit-AppleUSBSLCOM.dext.
Snooping around in there I found the following in its Info.plist under the IOKitPersonalities dict:
<key>DriverKit-AppleUSBSLCOM-CP2102</key>
<dict>
<key>CFBundleIdentifier</key>
<string>com.apple.DriverKit-AppleUSBSLCOM</string>
<key>CFBundleIdentifierKernel</key>
<string>com.apple.driver.driverkit.serial</string>
<key>IOClass</key>
<string>IOUserSerial</string>
<key>IOProviderClass</key>
<string>IOUSBHostInterface</string>
<key>IOUserClass</key>
<string>AppleUSBSLCOM</string>
<key>IOUserServerName</key>
<string>com.apple.driverkit.AppleUSBSLCOM</string>
<key>bConfigurationValue</key>
<integer>1</integer>
<key>bInterfaceNumber</key>
<integer>0</integer>
<key>idProduct</key>
<integer>60000</integer>
<key>idVendor</key>
<integer>4292</integer>
</dict>
Along with several others with different product and vendor IDs.
I tried to match it in my own Info.plist:
<key>AmstronBatteryDriver</key>
<dict>
<key>CFBundleIdentifier</key>
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
<key>CFBundleIdentifierKernel</key>
<string>com.apple.driver.driverkit.serial</string>
<key>IOClass</key>
<string>IOUserService</string>
<key>IOProviderClass</key>
<string>IOUSBHostInterface</string>
<key>IOUserClass</key>
<string>AmstronBatteryDriver</string>
<key>IOUserServerName</key>
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
<key>UserClientProperties</key>
<dict>
<key>IOClass</key>
<string>IOUserUserClient</string>
<key>IOUserClass</key>
<string>BatteryStatusUserClient</string>
</dict>
<key>bConfigurationValue</key>
<integer>1</integer>
<key>bInterfaceNumber</key>
<integer>0</integer>
<key>idProduct</key>
<integer>60000</integer>
<key>idVendor</key>
<integer>4292</integer>
</dict>
But so far I have had no luck.
Any suggestions on how I can get my driver to be picked rather than the default one?