Class HiTechnicMagneticSensor

    • Constructor Detail

      • HiTechnicMagneticSensor

        public HiTechnicMagneticSensor​(AnalogPort port)
        Create a magnetic sensor on an analog port
        Parameters:
        port - the analog port
      • HiTechnicMagneticSensor

        public HiTechnicMagneticSensor​(Port port)
        Create a magnetic sensor on a sensor port
        Parameters:
        port - the analog port
    • Method Detail

      • init

        protected void init()
      • getMagneticMode

        public SampleProvider getMagneticMode()
        HiTechnic Magnetic sensor, Magnetic mode
        Measures the strength og the vertical magnetic field

        Size and content of the sample
        The sample contains one element containing the strength of the magnetic field around the sensor. The value is normalized (0-1) where 1 corresponds with the maximum field strength.