예제 #1
0
파일: device.go 프로젝트: harikb/nfc
// Turn NFC device in idle mode. In initiator mode, the RF field is turned off
// and the device is set to low power mode (if avaible); In target mode, the
// emulation is stoped (no target available from external initiator) and the
// device is set to low power mode (if avaible).
func (d Device) Idle() error {
	if *d.d == nil {
		return errors.New("device closed")
	}

	return Error(C.nfc_idle(*d.d))
}
예제 #2
0
파일: device.go 프로젝트: harikb/nfc
// Turn NFC device in idle mode. In initiator mode, the RF field is turned off
// and the device is set to low power mode (if avaible); In target mode, the
// emulation is stoped (no target available from external initiator) and the
// device is set to low power mode (if avaible).
func (d *Device) Idle() error {
	if d.d == nil {
		return errors.New("Device closed")
	}

	return Error(C.nfc_idle(d.d))
}