HC SR04 stopped working

I think you have a wiring problem. If you touch a wire and get signals, then it is likely that the Arduino input is "floating", i.e. is not actually connected to the sensor.

Redo the wiring and make sure that you have good connections. Use a multimeter to check for continuity.