Giter Site home page Giter Site logo

espressifapp / espblufiforios Goto Github PK

View Code? Open in Web Editor NEW
98.0 98.0 45.0 33.85 MB

EspBlufi is based on the BLUFI protocol, which connect with IOT devices for BLE data communication, realizes device config network, and custom data transmission and reception. EspBlufi is developed and maintained by Espressif Corp.

License: Other

Objective-C 26.78% C 73.22%

espblufiforios's People

Contributors

espressifapp avatar fanbaoying avatar weijian-espressif avatar xuxiangjun avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

espblufiforios's Issues

Secret keys are being logged and showing inside log files

Hello. Will like to point out that secret keys are being logged out for production app in the BlufiClient file.
DH Secret and AES keys are being logged in the negotiateSecurity function. May I suggest wrapping these NSLog within an #if DEBUG scope so that these secret keys are not accidentally displayed in the log files inside a production app.

parseNotification invalid sequence

I'm getting parseNotification invalid sequence most of the time when I call client.configure(param).

Here is the sequence of events:

didDiscoverCharacteristicsForService get write char
didDiscoverCharacteristicsForService get notify char
parseNotification invalid sequence
parseNotification failed
receiveAck expect: 0

Before calling configure, I made sure the gattPrepared status is StatusSuccess

Here is how I set up the configure params.
let params = BlufiConfigureParams() params.opMode = OpModeSta params.staSsid = networkInfo.ssid params.staPassword = networkInfo.pwd

And here is how I'm calling it
return client.rx .configure(param: getConfigParam(networkInfo)) .take(1) .map { $0 == StatusSuccess }

Note that I'm wrapping Blufi delegates in RxSwift, but I don't think that is causing the issue. I haven't had the chance to dig deeper into the - (NotifyStatus)parseNotification:(NSData *)response notification:(BlufiNotifyData *)notification method. I'm hoping someone can shed some light on this.

Compliance with iOS 17

I kindly ask you whether you're going to verify the compliance of the ESPBlufi with iOS 17 and, if needed, release a new version.
Thanks

BlufiClient.onDeviceScanList ignores the status code argument

onDeviceScanList is invoked on both success and failure and is provided an appropriate BluFiStatusCode as an argument but the method ignores it, and always invokes didReceiveDeviceScanResponse on the BlufiDelegate with a status of StatusSuccess.

- (void)onDeviceScanList:(NSMutableArray<BlufiScanResponse *> *)list status:(BlufiStatusCode)code {
    id delegate = _blufiDelegate;
    BlufiClient *client = self;
    if (delegate && [delegate respondsToSelector:@selector(blufi:didReceiveDeviceScanResponse:status:)]) {
        [_callbackQueue addOperationWithBlock:^{
            [delegate blufi:client didReceiveDeviceScanResponse:list status:StatusSuccess];
        }];
    }
}

libblufisdk.a failed to link

missing build of libblufiSDK.a for x86_64

$ lipo -info libblufiSDK.a
Architectures in the fat file: libblufiSDK.a are: armv7 arm64

ld: error: ignoring file EspBlufiForiOS/EspBlufi/EspBlufi/lib/libblufiSDK.a, missing required architecture x86_64 in file EspBlufiForiOS/EspBlufi/EspBlufi/lib/libblufiSDK.a

can't find esp32 without BLUFI prefix in device name

I removed the BLUFI_ prefix from the esp32 device name and also changed the default filter into an empty string, espblufi for android can find the esp32, but the ios version cannot.

I am using esp-idf 4.1 and this is the example used in esp32

https://github.com/espressif/esp-idf/tree/23a03a3bdbaab1fe0ba427dcfcc82ef391cc06f4/examples/bluetooth/blufi

I used the function esp_ble_gap_set_device_name(ble_device_name); to change the name of the esp32

localisation or base language english

Hi,
I have downloaded and ran the example, but the interface is almost impossible to understand. If you are to produce an english base language you will appeal to a far bigger audience.

If i have the time, i could make a fork/pr which would handle the localisation.

无法使用模拟器编译

iPhone现在屏幕有若干尺寸,5.5inch,6.5inch,5.8inch。未来也许还会有更多的尺寸。但是因为模拟器无法编译,导致导致屏幕适配只能使用真机。现在真机数量有限,没有包含所有尺寸,导致某些情况下某个版本的尺寸无法测试到。但是用户实际使用中可能遇到该尺寸的布局问题。实际修改中连再现都要变得很困难。

wifi 的ssid 是中文无法传输

如果wifi 的ssid 是 中文 在STAOpmode 中
[self writeStructDataWithCharacteristic:_WriteCharacteristic WithData:[PacketCommand SetOpmode:STAOpmode Sequence:self.sequence]];
[self writeStructDataWithCharacteristic:_WriteCharacteristic WithData:[PacketCommand SetStationSsid:object.WifiSSid Sequence:self.sequence Encrypt:YES WithKeyData:self.Securtkey]];
[self writeStructDataWithCharacteristic:_WriteCharacteristic WithData:[PacketCommand SetStationPassword:object.WifiPassword Sequence:self.sequence Encrypt:YES WithKeyData:self.Securtkey]];
[self writeStructDataWithCharacteristic:_WriteCharacteristic WithData:[PacketCommand ConnectToAPWithSequence:self.sequence]];
是不支持的 Android的是可以的 但是ios不行

无法使用

3个文件缺失 请检查依赖和配置文件后重新上传

如何判断返回的ssid 是5G WiFI

通过 BlufiClient 实例调用requestDeviceScan 方法可以获取WiFI 列表,didReceiveDeviceScanResponse 代理方法将返回wifi数据,每一条wifi数据为一个 BlufiScanResponse 对象,我看 BlufiScanResponse类有一个type 字段,但是调试发现硬件设备返回type都是1,在这里有没有什么方法可以判断这个wifi 是否是5G wifi。【ps:不考虑通过字符串匹配“5G”字段,不精准】

Security key negotation failed

Hi there,

I'm trying to perform a connection to an ESP32 card using your library BlufiLibrary inside a React-native application.

My problem

Once I'm connected to the card (delegate method centralManager(_ central: didConnect peripheral:) is called), I launch the key negotation. During the negotation process, I have an error code 4 using the following delegate method :

func blufi(_ client: BlufiClient, didReceiveError errCode: Int) {
   print("[BLUFI] Received error. Code = ", errCode)
}

My understanding

Following this documentation, it looks like I got a 0x04: init security error.

My question

The application of this repository works just well when I compile it from my computer and launch it on my device.
Do you have any idea or insights about why I got this error when I use it inside an other app.

My code

@objc(RNEsp32)
class RNEsp32: NSObject, BlufiDelegate, CBCentralManagerDelegate, CBPeripheralDelegate {

    var bluFiClient: BlufiClient?

    @objc(connectESP32:withB:withResolver:withRejecter:)
    func connectESP32(a: Float, b: Float, resolve:RCTPromiseResolveBlock,reject:RCTPromiseRejectBlock) -> Void {
      self.connect()
      resolve()
    }

  private func connect() -> Void {
    print("Connection launched !")
    bluFiClient = BlufiClient.init()
    bluFiClient?.blufiDelegate = self
    bluFiClient?.centralManagerDelete = self
    bluFiClient?.postPackageLengthLimit = 128;
  }

  func blufi(_ client: BlufiClient, gattPrepared status: BlufiStatusCode, service: CBService?, writeChar: CBCharacteristic?, notifyChar: CBCharacteristic?) {
    print("[BLUFI] Blufi ready ! Status = ", status)
    if status == StatusSuccess {
      print("[BLUFI] launch security negotation")
      bluFiClient?.negotiateSecurity()
    }
  }

  func blufi(_ client: BlufiClient, didNegotiateSecurity status: BlufiStatusCode) {
    print("[BLUFI] Security has been negotatited ! Status =", status)
    let params = BlufiConfigureParams()
    params.opMode = OpModeSta
    params.staSsid = "MY_SSID"
    params.staPassword = "MY_PASSWORD"
    print("[BLUFI] Let's connect !!!!!")
    bluFiClient?.configure(params)
  }

  func blufi(_ client: BlufiClient, didReceiveError errCode: Int) {
    print("[BLUFI] Received error. Code = ", errCode)
  }

  func blufi(_ client: BlufiClient, didPostConfigureParams status: BlufiStatusCode) {
    print("[BLUFI] Did Post configuration params")
  }

  func blufi(_ client: BlufiClient, didPostCustomData data: Data, status: BlufiStatusCode) {
    print("[BLUFI] Did post custom data")
  }

  func blufi(_ client: BlufiClient, didReceiveCustomData data: Data, status: BlufiStatusCode) {
    let customString = String(decoding: data, as: UTF8.self)
    print("[BLUFI] did receive custom data : ", customString)
  }

  func centralManagerDidUpdateState(_ central: CBCentralManager) {
    if central.state == .poweredOn {
      bluFiClient?.connect("DEVICE_UUID")
    }
  }

  func centralManager(_ central: CBCentralManager, didConnect peripheral: CBPeripheral) {
    print("[Central] Device connected")
  }

  func centralManager(_ central: CBCentralManager, didFailToConnect peripheral: CBPeripheral, error: Error?) {
    print("[Centrail] Device connection failed")
  }

  func centralManager(_ central: CBCentralManager, didDisconnectPeripheral peripheral: CBPeripheral, error: Error?) {
    print("[Central] Device has been disconnected")
  }
}

Thanks for your help.

配置WiFi没有代理回调

image

用一个BlufiClient对象,给多个蓝牙对象先连接,后写入WiFi,断开连接。
再连接,写入WiFi,就报错!!!!!

一个蓝牙对象,只能用一个新的BlufiClient对象才能 搞?

Linker Issue - Bridging Header

I have been trying to incorporate BlufiLibrary on my SWIFT project. The linker keeps saying

Undefined symbols for architecture arm64:
"OBJC_CLASS$_BlufiClient", referenced from:
objc-class-ref in SettingsViewController.o
"OBJC_CLASS$_BlufiScanResponse", referenced from:
objc-class-ref in SettingsViewController.o
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)

  1. I dragged the BlufiLibrary as is into my project root directory.
  2. Added the Search pathways as describe don this page.

This exception is when I try to declare a blufiClient object.

var blufiClient = BlufiClient()

Any guidance would be greatly appreciated.

NOTE: The App compiles and runs without problems when is completely in Objective-C. I am sure I am forgetting something fundamental.

iPhone的加密模式问题

NSData *SetSecuritydata = [PacketCommand SetESP32ToPhoneSecurityWithSecurity:YES CheckSum:YES Sequence:self.sequence];
这个方法有什么作用?做项目的时候,连接蓝牙写不写这个方法有什么不同?

mac地址问题

我在设备端加了mac地址广播,在安卓手机上用工具看有广播的,在苹果的这个源码上扫描确看不见,只有uuid信息

Difference in behaviour for sending custom data in IOS and Android

I found difference in behaviour on how Android and IOS application sends custom data to ESP32.
Below are my findings for IOS and Android data transfer:-

Data string being used to transfer

{"product_type":4,"cert":"-----BEGIN CERTIFICATE----- MIIDNTCCAh2gAwIBAgIUUg+wiCV2dsAOtDfA0TmBxP3hPvkwDQYJKoZIhvcNAQEL BQAwMTEvMC0GA1UEAwwmOTgzOGYwYWQ4NzU5NDQyZWE5ODIzYTVmYjhiOTQ4NWMu bG9jYWwwHhcNMTkwMjA3MDYzMDU1WhcNMjkwMjA0MDYzMDU1WjAxMS8wLQYDVQQD DCY5ODM4ZjBhZDg3NTk0NDJlYTk4MjNhNWZiOGI5NDg1Yy5sb2NhbDCCASEwDQYJ KoZIhvcNAQEBBQADggEOADCCAQkCggEAK3FMcNTU6GXh6ZRwKZtCQ6v+c6h5tJYl Bn/lLFy8KW6ogX2xP91j09i9D4K68jBfrimhbjqNSRpTVJot2fbypfVY4ZhwLJZE mNQa841jjcdkI4mMUTyoH6LPRUheC6U5SHiE0BzM1PH38yDLWcqtMSvlVvYFdZjI 7EGxV8ajS3kf1Srj+2ZWYyH9MSRFXWIYvaXSenqdVS768HhU6wur7VeZk0AOxFL0 2L6yhNZDJ3UNuOQhnFQdGp99icPqOI2TROcjw0xQiopuVlisq1fRHYg6lwydMun/ Vzkj/Nc8w2uZ5qAZ2iqjwREeyK8B1x9BYihlclyj42n64OXxqiYqiwIDAQABo0Yw RDAPBgNVHRMECDAGAQH/AgEAMDEGA1UdEQQqMCiCJjk4MzhmMGFkODc1OTQ0MmVh OTgyM2E1ZmI4Yjk0ODVjLmxvY2FsMA0GCSqGSIb3DQEBCwUAA4IBAQAUYiFCaKNs s40SUfSM12w+GMrXYNE3iav9b1yPZxmUk9bIwv28YSCzvtCj3W9ZgSxNjeOB+ueC 1PENko0XTbX/JnjYMLxEPn44uJS/gLv/W1LBFD8yvxg0lWNnn2qwIOAnnNvH9tfj d0O1NTCO1DIpO8xMWX7YxPMp7kbNPFDor4liSyDzYRwS1JJG5f2eRci2u4Vtk6Sa Xy1eYcd8EfJLbn3wpZeo3/EeToX9obGQ++MIIcU/Vfn9tVJlMxEO2t+BQTMiU6e1 Rq/magvqxHT9Le1abtbCf/ambLxtusY+eesvJx5BdUF1cSnm/wqY3rCR3/26xvia cfN7/NaYHZM3 -----END CERTIFICATE----- ","product_id":"b8f5cf2fd779404590892e28566fd32e","product_ip":"192.168.1.202"}

Data sent from an Android application and received at ESP32

1. Data is transferred in a single fragment for any data size
2. This is the expected behaviour

Below are the logs from ESP32 while it receives the data from the Android, transferred via Bluetooth
I (279440) HA.Node.blufi: Recv Custom Data 1277
I (279454) Custom Data in char : {"product_type":
I (279469) Custom Data in char : 4,"cert":"-----B
I (279483) Custom Data in char : EGIN CERTIFICATE
I (279497) Custom Data in char : ----- MIIDNTCCAh
I (279510) Custom Data in char : 2gAwIBAgIUUg+wiC
I (279529) Custom Data in char : V2dsAOtDfA0TmBxP
I (279547) Custom Data in char : 3hPvkwDQYJKoZIhv
I (279560) Custom Data in char : cNAQEL BQAwMTEvM
I (279575) Custom Data in char : C0GA1UEAwwmOTgzO
I (279593) Custom Data in char : GYwYWQ4NzU5NDQyZ
I (279607) Custom Data in char : WE5ODIzYTVmYjhiO
I (279622) Custom Data in char : TQ4NWMu bG9jYWww
I (279639) Custom Data in char : HhcNMTkwMjA3MDYz
I (279652) Custom Data in char : MDU1WhcNMjkwMjA0
I (279667) Custom Data in char : MDYzMDU1WjAxMS8w
I (279680) Custom Data in char : LQYDVQQD DCY5ODM
I (279698) Custom Data in char : 4ZjBhZDg3NTk0NDJ
I (279711) Custom Data in char : lYTk4MjNhNWZiOGI
I (279726) Custom Data in char : 5NDg1Yy5sb2NhbDC
I (279740) Custom Data in char : CASEwDQYJ KoZIhv
I (279753) Custom Data in char : cNAQEBBQADggEOAD
I (279766) Custom Data in char : CCAQkCggEAK3FMcN
I (279779) Custom Data in char : TU6GXh6ZRwKZtCQ6
I (279794) Custom Data in char : v+c6h5tJYl Bn/lL
I (279807) Custom Data in char : Fy8KW6ogX2xP91j0
I (279821) Custom Data in char : 9i9D4K68jBfrimhb
I (279834) Custom Data in char : jqNSRpTVJot2fbyp
I (279848) Custom Data in char : fVY4ZhwLJZE mNQa
I (279861) Custom Data in char : 841jjcdkI4mMUTyo
I (279875) Custom Data in char : H6LPRUheC6U5SHiE
I (279889) Custom Data in char : 0BzM1PH38yDLWcqt
I (279903) Custom Data in char : MSvlVvYFdZjI 7EG
I (279917) Custom Data in char : xV8ajS3kf1Srj+2Z
I (279930) Custom Data in char : WYyH9MSRFXWIYvaX
I (279943) Custom Data in char : SenqdVS768HhU6wu
I (279956) Custom Data in char : r7VeZk0AOxFL0 2L
I (279969) Custom Data in char : 6yhNZDJ3UNuOQhnF
I (279983) Custom Data in char : QdGp99icPqOI2TRO
I (279997) Custom Data in char : cjw0xQiopuVlisq1
I (280011) Custom Data in char : fRHYg6lwydMun/ V
I (280024) Custom Data in char : zkj/Nc8w2uZ5qAZ2
I (280038) Custom Data in char : iqjwREeyK8B1x9BY
I (280050) Custom Data in char : ihlclyj42n64OXxq
I (280064) Custom Data in char : iYqiwIDAQABo0Yw
I (280077) Custom Data in char : RDAPBgNVHRMECDAG
I (280090) Custom Data in char : AQH/AgEAMDEGA1Ud
I (280104) Custom Data in char : EQQqMCiCJjk4Mzhm
I (280118) Custom Data in char : MGFkODc1OTQ0MmVh
I (280132) Custom Data in char : OTgyM2E1ZmI4Yjk
I (280145) Custom Data in char : 0ODVjLmxvY2FsMA0
I (280158) Custom Data in char : GCSqGSIb3DQEBCwU
I (280171) Custom Data in char : AA4IBAQAUYiFCaKN
I (280183) Custom Data in char : s s40SUfSM12w+GM
I (280197) Custom Data in char : rXYNE3iav9b1yPZx
I (280210) Custom Data in char : mUk9bIwv28YSCzvt
I (280224) Custom Data in char : Cj3W9ZgSxNjeOB+u
I (280237) Custom Data in char : eC 1PENko0XTbX/J
I (280250) Custom Data in char : njYMLxEPn44uJS/g
I (280263) Custom Data in char : Lv/W1LBFD8yvxg0l
I (280276) Custom Data in char : WNnn2qwIOAnnNvH9
I (280289) Custom Data in char : tfj d0O1NTCO1DIp
I (280304) Custom Data in char : O8xMWX7YxPMp7kbN
I (280316) Custom Data in char : PFDor4liSyDzYRwS
I (280329) Custom Data in char : 1JJG5f2eRci2u4Vt
I (280343) Custom Data in char : k6Sa Xy1eYcd8EfJ
I (280355) Custom Data in char : Lbn3wpZeo3/EeToX
I (280369) Custom Data in char : 9obGQ++MIIcU/Vfn
I (280382) Custom Data in char : 9tVJlMxEO2t+BQTM
I (280395) Custom Data in char : iU6e1 Rq/magvqxH
I (280408) Custom Data in char : T9Le1abtbCf/ambL
I (280421) Custom Data in char : xtusY+eesvJx5BdU
I (280434) Custom Data in char : F1cSnm/wqY3rCR3/
I (280448) Custom Data in char : 26xvia cfN7/NaYH
I (280461) Custom Data in char : ZM3 -----END CER
I (280474) Custom Data in char : TIFICATE----- ",
I (280486) Custom Data in char : "product_id":"b8
I (280499) Custom Data in char : f5cf2fd779404590
I (280513) Custom Data in char : 892e28566fd32e",
I (280526) Custom Data in char : "product_ip":"19
I (280539) Custom Data in char : 2.168.1.202"}

Data sent from an IOS and received at ESP32

1. Data is sent in multiple fragments rather than a single fragment(16 splits)
2. Each fragment contains a incorrect character at the beginning
3. Some initial characters are not getting transferred

Below are the logs from ESP32 while it receives the data from the IOS, transferred via Bluetooth
I (10390) HA.Node.blufi: Recv Custom Data 82
I (10395) Custom Data in char : P
I (10397) Custom Data in char : ":4,"cert":"----
I (10400) Custom Data in char : -BEGIN CERTIFICA
I (10404) Custom Data in char : TE----- MIIDNTCC
I (10409) Custom Data in char : Ah2gAwIBAgIUUg+w
I (10414) Custom Data in char : iC
E (10418) HA.Node.blufi: Internal error : P

I (10507) HA.Node.blufi: Recv Custom Data 82
I (10512) Custom Data in char : P
I (10514) Custom Data in char : xP3hPvkwDQYJKoZI
I (10516) Custom Data in char : hvcNAQEL BQAwMTE
I (10520) Custom Data in char : vMC0GA1UEAwwmOTg
I (10525) Custom Data in char : zOGYwYWQ4NzU5NDQ
I (10531) Custom Data in char : yZ
E (10535) HA.Node.blufi: Internal error : P

I (10570) HA.Node.blufi: Recv Custom Data 82
I (10576) Custom Data in char : P
I (10578) Custom Data in char : iOTQ4NWMu bG9jYW
I (10580) Custom Data in char : wwHhcNMTkwMjA3MD
I (10584) Custom Data in char : YzMDU1WhcNMjkwMj
I (10589) Custom Data in char : A0MDYzMDU1WjAxMS
I (10595) Custom Data in char : 8w
E (10599) HA.Node.blufi: Internal error : P

I (10630) HA.Node.blufi: Recv Custom Data 82
I (10635) Custom Data in char : P
I (10638) Custom Data in char : DM4ZjBhZDg3NTk0N
I (10640) Custom Data in char : DJlYTk4MjNhNWZiO
I (10644) Custom Data in char : GI5NDg1Yy5sb2Nhb
I (10649) Custom Data in char : DCCASEwDQYJ KoZI
I (10654) Custom Data in char : hv
E (10659) HA.Node.blufi: Internal error : P

I (10691) HA.Node.blufi: Recv Custom Data 82
I (10696) Custom Data in char : P
I (10698) Custom Data in char : ADCCAQkCggEAK3FM
I (10700) Custom Data in char : cNTU6GXh6ZRwKZtC
I (10704) Custom Data in char : Q6v+c6h5tJYl Bn/
I (10710) Custom Data in char : lLFy8KW6ogX2xP91
I (10715) Custom Data in char : j0
E (10719) HA.Node.blufi: Internal error : P

I (10778) HA.Node.blufi: Recv Custom Data 82
I (10783) Custom Data in char : P
I (10785) Custom Data in char : hbjqNSRpTVJot2fb
I (10787) Custom Data in char : ypfVY4ZhwLJZE mN
I (10791) Custom Data in char : Qa841jjcdkI4mMUT
I (10796) Custom Data in char : yoH6LPRUheC6U5SH
I (10802) Custom Data in char : iE
E (10806) HA.Node.blufi: Internal error : P

I (10840) HA.Node.blufi: Recv Custom Data 82
I (10846) Custom Data in char : P
I (10848) Custom Data in char : qtMSvlVvYFdZjI 7
I (10850) Custom Data in char : EGxV8ajS3kf1Srj+
I (10854) Custom Data in char : 2ZWYyH9MSRFXWIYv
I (10859) Custom Data in char : aXSenqdVS768HhU6
I (10865) Custom Data in char : wu
E (10869) HA.Node.blufi: Internal error : P

I (10901) HA.Node.blufi: Recv Custom Data 82
I (10907) Custom Data in char : P
I (10909) Custom Data in char : 2L6yhNZDJ3UNuOQh
I (10911) Custom Data in char : nFQdGp99icPqOI2T
I (10915) Custom Data in char : ROcjw0xQiopuVlis
I (10920) Custom Data in char : q1fRHYg6lwydMun/
I (10926) Custom Data in char : V
E (10930) HA.Node.blufi: Internal error : P

I (10960) HA.Node.blufi: Recv Custom Data 82
I (10966) Custom Data in char : P
I (10968) Custom Data in char : Z2iqjwREeyK8B1x9
I (10970) Custom Data in char : BYihlclyj42n64OX
I (10974) Custom Data in char : xqiYqiwIDAQABo0Y
I (10979) Custom Data in char : w RDAPBgNVHRMECD
I (10985) Custom Data in char : AG
E (10989) HA.Node.blufi: Internal error : P

I (11020) HA.Node.blufi: Recv Custom Data 82
I (11025) Custom Data in char : P
I (11028) Custom Data in char : UdEQQqMCiCJjk4Mz
I (11030) Custom Data in char : hmMGFkODc1OTQ0Mm
I (11034) Custom Data in char : Vh OTgyM2E1ZmI4Y
I (11039) Custom Data in char : jk0ODVjLmxvY2FsM
I (11045) Custom Data in char : A0
E (11049) HA.Node.blufi: Internal error : P

I (11080) HA.Node.blufi: Recv Custom Data 82
I (11086) Custom Data in char : P
I (11088) Custom Data in char : wUAA4IBAQAUYiFCa
I (11090) Custom Data in char : KNs s40SUfSM12w+
I (11094) Custom Data in char : GMrXYNE3iav9b1yP
I (11099) Custom Data in char : ZxmUk9bIwv28YSCz
I (11105) Custom Data in char : vt
E (11109) HA.Node.blufi: Internal error : P

I (11140) HA.Node.blufi: Recv Custom Data 82
I (11146) Custom Data in char : P
I (11148) Custom Data in char : +ueC 1PENko0XTbX
I (11150) Custom Data in char : /JnjYMLxEPn44uJS
I (11154) Custom Data in char : /gLv/W1LBFD8yvxg
I (11160) Custom Data in char : 0lWNnn2qwIOAnnNv
I (11165) Custom Data in char : H9
E (11169) HA.Node.blufi: Internal error : P

I (11200) HA.Node.blufi: Recv Custom Data 82
I (11207) Custom Data in char : P
I (11209) Custom Data in char : IpO8xMWX7YxPMp7k
I (11212) Custom Data in char : bNPFDor4liSyDzYR
I (11215) Custom Data in char : wS1JJG5f2eRci2u4
I (11222) Custom Data in char : Vtk6Sa Xy1eYcd8E
I (11226) Custom Data in char : fJ
E (11230) HA.Node.blufi: Internal error : P

I (11290) HA.Node.blufi: Recv Custom Data 82
I (11297) Custom Data in char : P
I (11299) Custom Data in char : oX9obGQ++MIIcU/V
I (11301) Custom Data in char : fn9tVJlMxEO2t+BQ
I (11305) Custom Data in char : TMiU6e1 Rq/magvq
I (11310) Custom Data in char : xHT9Le1abtbCf/am
I (11316) Custom Data in char : bL
E (11320) HA.Node.blufi: Internal error : P

I (11350) HA.Node.blufi: Recv Custom Data 82
I (11356) Custom Data in char : P
I (11358) Custom Data in char : dUF1cSnm/wqY3rCR
I (11360) Custom Data in char : 3/26xvia cfN7/Na
I (11364) Custom Data in char : YHZM3 -----END C
I (11369) Custom Data in char : ERTIFICATE-----
I (11375) Custom Data in char : ",
E (11379) HA.Node.blufi: Internal error : P

I (11412) HA.Node.blufi: Recv Custom Data 77
I (11417) Custom Data in char : "product_id":"b8
I (11420) Custom Data in char : f5cf2fd779404590
I (11422) Custom Data in char : 892e28566fd32e",
I (11427) Custom Data in char : "product_ip":"19
I (11432) Custom Data in char : 2.168.1.202"}

For IOS correct data is being sent only in the cases where there is only a single fragment being transferred(small data size)

Data being sent from IOS to ESP32
{"product_type":4,","product_ip":"192.168.1.202"}

1. It transferred correct data when single fragment is being transferred from an IOS

ESP32 logs transferred from an IOS below
I (75253) HA.Node.blufi: Recv Custom Data 49
I (75269) Custom Data in char : {"product_type":
I (75284) Custom Data in char : 4,","product_ip"
I (75297) Custom Data in char : :"192.168.1.202"
I (75311) Custom Data in char : }

My questions
1. How can we send data in IOS just like the way android does(in a single fragment)?
2. The multiple fragment transmission in IOS is sending incorrect data which may be corrected although I would request code changes to make transfer in a single fragment

No callbacks being called when passing over wrong SSID/Password in BlufiConfigureParams in OpModeSta to ESP32

This issue is related to passing over BlufiConfigureParams in OpModeSta mode.

Correct staSsid and staPassword:
Calling

- (void)configure:(BlufiConfigureParams *)params;

will call the delegate

- (void)blufi:(BlufiClient *)client didPostConfigureParams:(BlufiStatusCode)status;
- (void)blufi:(BlufiClient *)client didReceiveDeviceStatusResponse:(nullable BlufiStatusResponse *)response status:(BlufiStatusCode)status;

Wrong staSsid or staPassword:
Only

- (void)blufi:(BlufiClient *)client didPostConfigureParams:(BlufiStatusCode)status;

Is there any other way for me to receive a callback stating the Wifi is disconnected when passing wrong staSsid and/or staPassword?

Currently, I am using a delay of 2s before calling requestDeviceStatus but this solution is not stable.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.