Help with door sensor

Not sure it will help, but the following is a good place to start: