It was a while ago but I think a problem with the midi cable tends to do this. Either its the wrong cable, the wrong way or loose. I think it needs to be 7pin (I think), plugged in the right way and have a strong connection.
https://www.thegearpage.net/board/index.php?threads/mesa-boogie-mark-v-problem.1576373/
From that thread:
"A common problem with the Mark V is a poor connection between the footswitch and amp. If the cable is somewhat loose you'll experience relay chatter."
It sounds like "relay chatter" that I've had before as well. Would give that a go first given it is common.