ESP8266 Switch on-board led off - all stops

You did not understand:

post your

complete sketch.

From the very first to the very last line.

Your loop has two functions

functionTare(); 
functionAlarm();

You are asking for help because you yourself are unable to solve the problem.
There is a high chance that the error is somewhere in the code that you don't think of
and this is the reason why you should post your

complete sketch

using this method

best regards Stefan