Interface BasicSensorPort

    • Method Detail

      • getMode

        int getMode()
        Get the current operating mode of the sensor
        Returns:
        the current mode
      • getType

        int getType()
        Get the current type setting. Note that types are typically used to control the operation of Legacy and i2c sensors. They are normally not used for EV3 sensors.
        Returns:
        the current sensor type
      • setMode

        boolean setMode​(int mode)
        Set the current operating mode for the sensor attached to the port.
        Parameters:
        mode - the new mode
        Returns:
        true if the mode has been accepted
      • setType

        boolean setType​(int type)
        Set the operating type for the attached sensor. Normally type setting is only used with legacy sensors and for i2c devices (to set the speed and operating voltage). It is not normally used with EV3 sensors.
        Parameters:
        type -
        Returns:
        true if type accepted
      • setTypeAndMode

        @Deprecated
        boolean setTypeAndMode​(int type,
                               int mode)
        Deprecated.