implemented HV autodetection