Commit a3a778cc authored by jflynn129's avatar jflynn129
Browse files

removed constraints

parent e76dea0e
This diff is collapsed.
......@@ -116,13 +116,13 @@ class DetectViewController: UIViewController, UIPickerViewDelegate, UIPickerView
override func viewWillDisappear(_ animated: Bool) {
super.viewWillDisappear(animated)
WriteCharacteristic(peripheral: currentPeripheral, lstate: state[SP1])
WriteCharacteristic(peripheral: currentPeripheral, lstate: state[SP2])
WriteCharacteristic(peripheral: currentPeripheral, lstate: state[SD1])
WriteCharacteristic(peripheral: currentPeripheral, lstate: state[SD2])
WriteCharacteristic(peripheral: currentPeripheral, lstate: state[OOT])
WriteCharacteristic(peripheral: currentPeripheral, lstate: state[OMT])
WriteCharacteristic(peripheral: currentPeripheral, lstate: state[OCM])
//jmf WriteCharacteristic(peripheral: currentPeripheral, lstate: state[SP1])
//jmf WriteCharacteristic(peripheral: currentPeripheral, lstate: state[SP2])
//jmf WriteCharacteristic(peripheral: currentPeripheral, lstate: state[SD1])
//jmf WriteCharacteristic(peripheral: currentPeripheral, lstate: state[SD2])
//jmf WriteCharacteristic(peripheral: currentPeripheral, lstate: state[OOT])
//jmf WriteCharacteristic(peripheral: currentPeripheral, lstate: state[OMT])
//jmf WriteCharacteristic(peripheral: currentPeripheral, lstate: state[OCM])
save_settings()
}
......
......@@ -59,7 +59,7 @@ class IDRMOutputConfigViewController: UIViewController {
override func viewWillDisappear(_ animated: Bool) {
super.viewWillDisappear(animated)
state[LFM].val[0] = currentVal
WriteCharacteristic( peripheral:currentPeripheral, lstate: state[LFM] )
//jmf WriteCharacteristic( peripheral:currentPeripheral, lstate: state[LFM] )
save_settings()
}
......
......@@ -26,9 +26,9 @@ class LightSoundViewController: UIViewController {
override func viewWillDisappear(_ animated: Bool) {
super.viewWillDisappear(animated)
WriteCharacteristic(peripheral: currentPeripheral, lstate: state[SDT])
WriteCharacteristic(peripheral: currentPeripheral, lstate: state[ALH])
WriteCharacteristic(peripheral: currentPeripheral, lstate: state[ALL])
//jmf WriteCharacteristic(peripheral: currentPeripheral, lstate: state[SDT])
//jmf WriteCharacteristic(peripheral: currentPeripheral, lstate: state[ALH])
//jmf WriteCharacteristic(peripheral: currentPeripheral, lstate: state[ALL])
save_settings()
}
......
......@@ -47,9 +47,9 @@ class RadarConfigViewController: UIViewController, UITextFieldDelegate {
override func viewWillDisappear(_ animated: Bool) {
super.viewWillDisappear(animated)
WriteCharacteristic(peripheral: currentPeripheral, lstate: state[MDD])
WriteCharacteristic(peripheral: currentPeripheral, lstate: state[MVH])
WriteCharacteristic(peripheral: currentPeripheral, lstate: state[MVL])
//jmf WriteCharacteristic(peripheral: currentPeripheral, lstate: state[MDD])
//jmf WriteCharacteristic(peripheral: currentPeripheral, lstate: state[MVH])
//jmf WriteCharacteristic(peripheral: currentPeripheral, lstate: state[MVL])
save_settings()
}
......
......@@ -29,7 +29,7 @@ class TrigViewController: UIViewController {
override func viewWillDisappear(_ animated: Bool) {
super.viewWillDisappear(animated)
WriteCharacteristic(peripheral: currentPeripheral, lstate: state[DLC])
//jmf WriteCharacteristic(peripheral: currentPeripheral, lstate: state[DLC])
save_settings()
}
......
......@@ -253,7 +253,7 @@ func ReadCharacteristic( lstate : idrm_state) -> [UInt8] {
func WriteCharacteristic( peripheral: CBPeripheral, lstate : idrm_state) {
print("write \(lstate.name), value of \(lstate.val)")
let txData : Data = Data(lstate.val)
peripheral.writeValue( txData, for: lstate.characteristic!, type: .withoutResponse)
//jmf peripheral.writeValue( txData, for: lstate.characteristic!, type: .withoutResponse)
}
......@@ -312,7 +312,7 @@ class ViewController: UIViewController, CBCentralManagerDelegate, CBPeripheralDe
// Only allow storyboard changes if we are connected to the device
override func shouldPerformSegue(withIdentifier identifier: String, sender: Any?) -> Bool {
return connected
return true //return connected
}
@objc func appMovedToBackground() {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment