The CNC Shield V4 came with some factory errors being a cloned version for china, the step puls and step direction pin numbers have been alternated, this article also show how to correct it. Just modify one file.
modify cpu_map.h file at line 39
#define X_STEP_BIT 5 // Uno Digital Pin 2
#define Y_STEP_BIT 6 // Uno Digital Pin 3
#define Z_STEP_BIT 7 // Uno Digital Pin 4
and line 47
#define X_DIRECTION_BIT 2 // Uno Digital Pin 5
#define Y_DIRECTION_BIT 3 // Uno Digital Pin 6
#define Z_DIRECTION_BIT 4 // Uno Digital Pin 7
save and exit
recompile and upload firmware
and done.