Space–time wave localization in electromechanical metamaterial beams with programmable defects