A DC grid primary protection algorithm based on current measurements