Developer Terms and Conditions The Development Android development Wrong documentation [Connect to SCiO Sensor] Reply To: Wrong documentation [Connect to SCiO Sensor]

#43595
Ayelet
Keymaster

Hi Sacha,

 

Below is the correct code for Android:

ScioDevice myScio = new ScioDevice(this, scioAddress);
myScio.connect(new ScioDeviceConnectHandler() {
    @Override
    public void onConnected() {
        /* put your code for successfully connecting to the SCiO here */
        
        Log.d("DemoApp", "SCiO was connected successfully");
    }

    @Override
    public void onConnectFailed() {
        /* put your code for failing to connect to the SCiO here */
        
        Log.d("DemoApp", "Timeout while connecting");
    }
});

Ayelet