第七色在线视频,2021少妇久久久久久久久久,亚洲欧洲精品成人久久av18,亚洲国产精品特色大片观看完整版,孙宇晨将参加特朗普的晚宴

為了賬號安全,請及時綁定郵箱和手機(jī)立即綁定
已解決430363個問題,去搜搜看,總會有你想問的

BLE 值_變化

BLE 值_變化

C#
達(dá)令說 2021-06-29 05:01:40
private async void Characteristic_ValueChanged(GattCharacteristic sender, GattValueChangedEventArgs args)        {            // BT_Code: An Indicate or Notify reported that the value has changed.            // Display the new value with a timestamp.            var newValue = FormatValueByPresentation(args.CharacteristicValue, presentationFormat);            var message = $"Value at {DateTime.Now:hh:mm:ss}: {newValue}";            await Dispatcher.RunAsync(CoreDispatcherPriority.Normal,                () => CharacteristicLatestValue.Text = message);        }這是值更改的設(shè)置。^ private async void CharacteristicReadButton_Click()        {             // BT_Code: Read the actual value from the device by using Uncached.            GattReadResult result = await selectedCharacteristic.ReadValueAsync(BluetoothCacheMode.Uncached);            if (result.Status == GattCommunicationStatus.Success)            {                string formattedResult = FormatValueByPresentation(result.Value, presentationFormat);                rootPage.NotifyUser($"Read result: {formattedResult}", NotifyType.StatusMessage);            }            else            {                rootPage.NotifyUser($"Read failed: {result.Status}", NotifyType.ErrorMessage);            }             }這是讀取值的設(shè)置。所以當(dāng)我點(diǎn)擊“閱讀”按鈕時。它捕獲當(dāng)時的數(shù)據(jù)。但是我希望在值更改時刷新此數(shù)據(jù),因此我訂閱了值更改?,F(xiàn)在的問題是,在我點(diǎn)擊訂閱后,它說的是“未知格式”。所以我需要弄清楚如何更改我的格式以讀取我的 rfduino 值。
查看完整描述

2 回答

  • 2 回答
  • 0 關(guān)注
  • 327 瀏覽

添加回答

舉報

0/150
提交
取消
微信客服

購課補(bǔ)貼
聯(lián)系客服咨詢優(yōu)惠詳情

幫助反饋 APP下載

慕課網(wǎng)APP
您的移動學(xué)習(xí)伙伴

公眾號

掃描二維碼
關(guān)注慕課網(wǎng)微信公眾號