Open mithro opened 8 years ago
This is possible a duplicate of https://github.com/timvideos/HDMI2USB-misoc-firmware/issues/39
It is straight forward to set hdmi_in0_connected
to 1 when the EDID is being read by the mean of raising an IRQ when the EDID FSM is not in its WAIT_START
state.
The IRQ handler running on the LM32 would then set the global variable hdmi_in0_connected
to 1.
But on which condition do we set it back to 0? How can we detect that the source has been unplugged?
Do we keep hdmi_in0_connected
set to 1 regardless?
I think we want a hdmi_in0_edid_started
and a hdmi_in0_edid_finished
notifications (maybe with timestamps?). Like normal interrupts, they should be triggered by the gateware and then clearable by the lm32 firmware.
Can someone test this on Atlys board / hdmi2usb target? https://github.com/fallen/HDMI2USB-misoc-firmware/commit/5d771720b6553665b87058ae7fbe1d077dd0a5f6
On the Atlys we don't have access to the hotplug line, so we don't know when a new device is plugged in. Most devices will however read the EDID information right after being connected. Hence if we have yet to see a valid signal, the EDID being read is a good sign we should try looking for one.
Hence the softcore needs to be notified when the EDID is read.