Programming on the Host
/* Host C-binding for custom function*/
void Func(long Thread, long Src, long Dst, long OSB)
/* Initialize message contents */
im_msg_start(&msg,OPCODE_Func, 2, “Func”);
/* Pack function parameters in message */
im_msg_put_long(&msg,0,Src);
im_msg_put_long(&msg,1,Dst);
/* Send message to target thread and don’t wait */
im_msg_send(&msg,0,Thread,OSB,_IM_NO_WAIT);
/*Report errors and clean up */