GithubHelp home page GithubHelp logo

Comments (7)

TuyaRonbin avatar TuyaRonbin commented on May 20, 2024

Can you provide a complete crash stack?

from tuyasmart_home_ios_sdk.

MimikFc7 avatar MimikFc7 commented on May 20, 2024

Can you provide a complete crash stack?

Hello, yes, i come back to home after a 8 hours and send.

from tuyasmart_home_ios_sdk.

MimikFc7 avatar MimikFc7 commented on May 20, 2024

2019-12-18 22:42:48.465149+0300 HomeAlone[998:190713] filter dps from lan 2019-12-18 22:42:48.465311+0300 HomeAlone[998:190713] -[__NSCFNumber length]: unrecognized selector sent to instance 0xb28e97f01270aa7c 2019-12-18 22:42:48.465563+0300 HomeAlone[998:190713] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '-[__NSCFNumber length]: unrecognized selector sent to instance 0xb28e97f01270aa7c' *** First throw call stack: (0x185652a48 0x185379fa4 0x1855565a8 0x185656af4 0x185658a7c 0x192a540d0 0x192a54270 0x1bab8c0f4 0x1007cf9cc 0x10138df4c 0x1855ae288 0x1855ae2d0 0x1855ad630 0x1855ad2e8 0x18552959c 0x1855acc38 0x185909138 0x10096ec2c 0x1034957fc 0x103496bd8 0x1034a4c34 0x1855d05e4 0x1855cb5d8 0x1855caadc 0x18f550328 0x1896c5ae0 0x1008614fc 0x185454360) libc++abi.dylib: terminating with uncaught exception of type NSException

from tuyasmart_home_ios_sdk.

MimikFc7 avatar MimikFc7 commented on May 20, 2024

so i found where that trouble!
in conversion type:

- (void)device:(TuyaSmartDevice *)device signal:(NSString *)signal

signal - it's a pointer, but in that pointer come NSNumber
in Swift types conversion very strong.

i make a simple class and override that!

`- (void)device:(TuyaSmartDevice *)device signal:(NSString *)signal{

if(self.delegate != nil){
    
    NSNumber *cater = signal;
    [self.delegate device:device signal: [NSString stringWithFormat:@"%ld",[cater longValue]]];
}

}`

and it's work!
please fix that!

from tuyasmart_home_ios_sdk.

TuyaRonbin avatar TuyaRonbin commented on May 20, 2024

We will fix the errors in the next version.
Sorry, I haven't tested swift before.

from tuyasmart_home_ios_sdk.

MimikFc7 avatar MimikFc7 commented on May 20, 2024

Yep, no problem, if you want, you can give me some codes for tested =)

from tuyasmart_home_ios_sdk.

Zabihullahkayani avatar Zabihullahkayani commented on May 20, 2024
        func getWifiSignalStrength() {
        self.device?.getWifiSignalStrength(success: {
            print("get wifi signal strength success")
        }, failure: { (error) in
            if let e = error {
                print("get wifi signal strength failure: \(e)")
            }
        })
    }
    
    // MARK: - TuyaSmartDeviceDelegate
    func device(_ device: TuyaSmartDevice!, signal: String!) {
    
    }

I am using this function from Tuya docs for iOS, my problem is my delegate method never call.

from tuyasmart_home_ios_sdk.

Related Issues (20)

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.