external event in PhAB

I know that I can trigger a callback periodically (same as polling) using timers. But is there a way to trigger a callback from external event outside of PhAB? For example, from a sotware that is not PhAB which sends message. Or Intrupt signal that PhAB can respond to?

Thanks

Sure look at PtAppAddSignalProc for signals, or PtAppAddInput. All familly of PtApp* function.