I suggest you test X, Y and Z homing individually until they are all working. Make sure that your M574 command in config.g is correct, and make sure that your homez.g file is correct according to whether you are using a microswitch or a Z probe to home Z. See https://duet3d.com/wiki/Configuring_RepRapFirmware_for_a_Cartesian_printer#Homing_files.