The compact sensor detects changes in position or vibrations and can perform a variety of tasks in the smart home. The reliable monitoring of garage doors, windows or mailbox flaps, for example, ensures greater comfort and security. The highly sensitive sensor detects even the smallest vibrations at the installation location and immediately reports them to the Homematic IP system. The sensitivity of the sensor can be individually adjusted for the respective application. The sensor detects changes in position at an angle of 10 to 45°. Alternatively, it can also be configured as a shock sensor.