Got Mach ports demo working correctly, thanks to extensive Apple documentation (not).