memory usage with object

I'm using this library https://github.com/bogde/HX711 that let's you create an hx711 object. My question is if I use this code

HX711 obj=HX711(A0,A1);

setup(){
...
}

loop(){
...
obj=HX711(A2,A3);
...
obj=HX711(A4,A5);
...
obj=HX711(A0,A1);
...
}

how the memory will be used? Do I need to free it, the space used by the old object will be overwritten by the new object or the space allocated will be automatically deleted? Also creating an array of object is not an option (it doesn't work) but I have added a new method for changing the pin used, is this a better solution than recreating the object?

That would overwrite the original object.

ale066: Also creating an array of object is not an option (it doesn't work)

You must not be doing it right. You can most certainly create an array of objects of any type. Post the code that doesn't work and let's see if we can see what you've done wrong.

I can create the array and it work but only if it has two object more than that and the arduino stop working

ale066: I can create the array and it work but only if it has two object more than that and the arduino stop working

What do you mean? Post some code so we can see what you mean.

Sorry for the late response here two code one uses the array and it blocks and the same happen with using only 1 object.
this is the output for prova_celle_1.ino (this uses only 1 object for 4 load cells)

0
87688
0
-41453
0
55021
1
99273
1
-24595
1
6923

the other one has attached the code for coomunicating with a plc by hostlink

I think I found the problem one of the load cell doesn’t work and that seems to crash the program

prova_celle_1.ino (1.63 KB)

cella_carico_1.0.ino (3.87 KB)