Any chance you’re using an enclosure that also traps the air in/out of the electronics box? I had horrible HORRIBLE problems on two occasions when I let the enclosure inside-top temp get up to about 45C. At that point the at-the-table temp was about 38C, which means the air supposedly “cooling” the stepper motor drivers and electronics was already hotter than was appropriate. On those two prints, my Z-axis simply stopped moving. At all. I had one 100mm-tall print where the Z-axis simply stopped moving at around 65mm, but the dumb thing still thought it was doing fine. The LCD even reported Z at 100.2mm, but it was nowhere near there. Instead the head was embedded waist-deep in a veritable carpet of plastic chaos on the part top, and the hobbed bolt had done its thing on the filament, etc., etc.
The lesson (it seems to be working now) is don’t let the ambient air around the electronics/stepper motors DRIVERS get into the 40+C range, or those switches might just stop working until they’re cool enough. I wouldn’t be surprised if the servo driver chip’s thermal shutoff was cutting in. The reason I don’t think it’s the motor itself is that the z-axis stayed perfectly level the whole time and is still just fine, so both motors clearly were not responding to…what likely was no signals from the drivers.
I have since then thermally isolated the electronics from the print enclosure by ducting both the intake and output through the side wall. Now it takes in cool air (20C) and puts out normal warm air (~30C), even when the enclosure itself is in the 40C’s. Granted, after seeing that mess I’m a little skittish about letting it get much about 40C in there (at the top of the box; bottom of the box stays around 30C). Next step is to see if there’s a way to heatsink the drivers wholly inside the electronics enclosure, so the drivers aren’t trying to push heat into an already-hot metal case, and they can have a nice air-cooled heatsink like they like.
So, if you’re recirculating warm/hot air into the electronics enclosure, watch that the internals aren’t getting unhappy in the heat. If you have an insulated temperature probe, maybe insert it into the box while it’s running and monitor the temp.
Hope that helps.