Setting a load cell with known weight

Hi everyone, I'm having a hard time with an action I want to preform!
I have a hx711 load cell that sends weights to a server, I want to set up a code that will implant the last known weight received by the server after the scale restarts (power brake).

I managed to receive the last known weight (int) but can't implement it to the scale.
my initial approach was using the scale.tare(); with the last known weight ( like so: scale.tare(WeightOnDB); ) but that sends my esp8266 to some kind of an error and restarts it again..

would love some help if anyone has an idea.

Thanks

will implant the last known weight received by the server after the scale restarts (power brake).

Could you explain what this means, and what is supposed to happen?

Yes.
While the scale is working it sends the weight to the server, lets say the last weight it sends is 20g.
in case of a power brake the scale will start up and tare to 0.
I want it to know there is a weight of 20g at start up and continue to work regularly from than on in the loop.

Is that clearer now?
Thanks again

Slightly, and the problem most likely lies in the code you forgot to post, what you actually tried, and what happened when you tried it.

To get the most out of this forum, please read and follow the instructions in How to use this forum.