From RPiconfig - eLinux.org

Set the output format to VGA 60 Hz (hdmi_group=1 hdmi_mode=1) and boot up the Raspberry Pi

sudo tvservice -d /boot/edid.dat

Then add to config.txt -

hdmi_edid_file=1
hdmi_force_hotplug=1