status = IOServiceGetMatchingServices(
io_master_port, IOServiceNameMatching("IOHWSensor"), &iterator);
if (status != kIOReturnSuccess) {
ERROR("IOServiceGetMatchingServices failed: %s", mach_error_string(status));
status = IOServiceGetMatchingServices(
io_master_port, IOServiceNameMatching("IOHWSensor"), &iterator);
if (status != kIOReturnSuccess) {
ERROR("IOServiceGetMatchingServices failed: %s", mach_error_string(status));