// Update is called once per frame void Update() { if (Input.GetKeyDown(KeyCode.I)) { _value++; _irCharacteristic.UpdateValue(BitConverter.GetBytes(_value)); } }
// Update is called once per frame void Update() { if (Input.GetKey(KeyCode.W)) { _timer += Time.deltaTime; if (_timer > Interval) { _timer -= Interval; _value++; _irCharacteristic.UpdateValue(BitConverter.GetBytes(_value)); } } }