示例#1
0
// send a message to Blued
func (ble *BLE) sendCBMsg(id int, args dict) {
	message := dict{"kCBMsgId": id, "kCBMsgArgs": args}
	if ble.verbose {
		log.Printf("sendCBMsg %#v\n", message)
	}

	C.XpcSendMessage(ble.conn, goToXpc(message), true, ble.verbose == true)
}
示例#2
0
func (x *XPC) Send(msg interface{}, verbose bool) {
	// verbose == true converts the type from bool to C._Bool
	C.XpcSendMessage(x.conn, goToXpc(msg), true, verbose == true)
}