<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en-gb">
	<link rel="self" type="application/atom+xml" href="https://forum.stereopi.com/app.php/feed/topic/1355" />

	<title>StereoPi Forum</title>
	<subtitle>StereoPi Forum</subtitle>
	<link href="https://forum.stereopi.com/index.php" />
	<updated>2023-04-12T21:47:26+00:00</updated>

	<author><name><![CDATA[StereoPi Forum]]></name></author>
	<id>https://forum.stereopi.com/app.php/feed/topic/1355</id>

		<entry>
		<author><name><![CDATA[Realizator]]></name></author>
		<updated>2023-04-12T21:47:26+00:00</updated>

		<published>2023-04-12T21:47:26+00:00</published>
		<id>https://forum.stereopi.com/viewtopic.php?p=3372#p3372</id>
		<link href="https://forum.stereopi.com/viewtopic.php?p=3372#p3372"/>
		<title type="html"><![CDATA[Re: HDMI output to Oculus DK2]]></title>

		
		<content type="html" xml:base="https://forum.stereopi.com/viewtopic.php?p=3372#p3372"><![CDATA[
Hi iPutBack,<br><br>I have no DK2 nearby to test, so I can't confirm the settings. Did you happen to try to test this config using regular Raspberry Pi 4? (Pi3 is not good, but RPi4 has the same CPU as CM4).  <br><br>ENOSPC means insufficient video memory; you can try to increase GPU MEM in config.txt Also, did you stop SLP2 scripts over console before doing raspistill? <br><br>By the way, which StereoPi do you have? I guess it's V2 with CM4 (due to "dtoverlay=dwc2,dr_mode=host" in your config file).<br><br>A few notes on your settings:<br><strong class="text-strong">NOTE 1:</strong><br>hdmi_timings=1080 1 33 10 15 1920 1 1 1 13 0 0 0 75 0 165000000 3<br>If you look at hdmi_timings section here <a href="https://www.raspberrypi.com/documentation/computers/config_txt.html" class="postlink">https://www.raspberrypi.com/documentati ... g_txt.html</a>, you can find that in your case:<br><br>&lt;h_active_pixels&gt; = 1080   horizontal pixels (width)<br>&lt;h_front_porch&gt;   = 33      horizontal forward padding from DE active edge<br>&lt;h_back_porch&gt;    = 15      horizontal back padding from DE active edge<br>&lt;v_active_lines&gt;  = 1920    vertical pixels height (lines)<br>&lt;v_front_porch&gt;   = 1         vertical forward padding from DE active edge<br>&lt;v_back_porch&gt;    = 13      vertical back padding from DE active edge<br>&lt;frame_rate&gt;      = 75<br>&lt;pixel_freq&gt;      = 165000000<br><br>So:<br>&lt;pixel_freq&gt; = (&lt;h_active_pixels&gt;+&lt;h_front_porch&gt;+&lt;h_back_porch&gt;) * (&lt;v_active_lines&gt;+&lt;v_front_porch&gt;+&lt;v_back_porch&gt;) * &lt;frame_rate&gt; =<br> (1080+33+15) * (1920 + 1 + 13) * 75 = 1128 * 1934 * 75 = <strong class="text-strong">163616400</strong><br>And you have <strong class="text-strong">165000000</strong>. In my experiments with other custom HDMI screens, this parameter ruined the output if miscalculated.<br><br>If you are not sure which data to use, download EDID using <br>/opt/vc/bin/tvservice -d edid.dat; /opt/vc/bin/edidparser edid.dat (<a href="https://www.raspberrypi.com/documentation/computers/config_txt.html#which-values-are-valid-for-my-monitor" class="postlink">details</a>). This trick helped me a lot with custom HDMI screens.<br><br><strong class="text-strong">NOTE 2:</strong><br>Looks like DK2 has not the 1920x1080, but 1080x1920 resolution. This mobile-like screen orientation ruined <a href="https://stereopi.com/blog/diy-vr-headset-stereopi-10-ms-latency-just-135" class="postlink">one of our first experiments</a>. The screen rotation decreases FPS a lot. I see "display_rotate=3" in your settings, it means you try to rotate it. Technically it will work, but with artefacts and low FPS.<br>BTW "display_rotate" is <a href="https://www.raspberrypi.com/documentation/computers/config_txt.html#display_rotate" class="postlink">deprecated</a>...<br><br><strong class="text-strong">NOTE 3:</strong><br>Our search of horizontally oriented screen led us to <a href="https://www.aliexpress.com/item/1005002823687820.html" class="postlink">this item</a>. Yes, it's bulky and need a 3D printed case, as well as <a href="https://www.walmart.com/ip/VR-Headset-with-Controller-Adjustable-3D-VR-Glasses-Virtual-Reality-Headset-HD-Blu-ray-Eye-Protected-Support-5-7-Inch-for-Android-Phone-windows/201000459?athbdg=L1600" class="postlink">plastic gear with lenses</a> like this one. But it finally works with custom settings and resolution 1440x1440 per eye, or 2880x1440 as the total HDMI output resolution.<div class="inline-attachment"><dl class="file"><dt class="attach-image"><img src="https://forum.stereopi.com/download/file.php?id=301" class="postimage" alt="IMG_6655.jpeg" onclick="viewableArea(this);" /></dt></dl></div><p>Statistics: Posted by <a href="https://forum.stereopi.com/memberlist.php?mode=viewprofile&amp;u=2">Realizator</a> — Wed Apr 12, 2023 9:47 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[iPutBack]]></name></author>
		<updated>2023-01-21T18:13:11+00:00</updated>

		<published>2023-01-21T18:13:11+00:00</published>
		<id>https://forum.stereopi.com/viewtopic.php?p=3338#p3338</id>
		<link href="https://forum.stereopi.com/viewtopic.php?p=3338#p3338"/>
		<title type="html"><![CDATA[HDMI output to Oculus DK2]]></title>

		
		<content type="html" xml:base="https://forum.stereopi.com/viewtopic.php?p=3338#p3338"><![CDATA[
Hi everyone,<br><br>I have been trying for several hours to display the output of the two cameras (or even a single camera in 2D mode) to an Oculus DK2. I have found configuration parameters for the headset that are supposed to work on raspbian (see for instance <a href="https://github.com/WayneKeenan/python-vrzero/blob/master/config/config_DK2.txt" class="postlink">this</a> and <a href="https://www.morikuma.net/archives/archives/392" class="postlink">this</a>).<br><br>My current config.txt file is the following:<div class="codebox"><p>Code: </p><pre><code>hdmi_timings=1080 1 33 10 15 1920 1 1 1 13 0 0 0 75 0 165000000 3hdmi_group=2hdmi_mode=87config_hdmi_boost=4max_framebuffer_width=1080max_framebuffer_height=1920display_rotate=3hdmi_force_hotplug=1#hdmi_ignore_edid=0xa5000080hvs_priority=0x32ffhdmi_pixel_freq_limit=400000000dtparam=audio=ondisable_overscan=1[pi4]dtoverlay=vc4-fkms-v3dmax_framebuffers=2[all]gpu_mem=256start_x=1dtoverlay=pi3-disable-btdtoverlay=dwc2,dr_mode=host</code></pre></div>The DK2 displays the stereopi logo for a few seconds, then black screen and LED is orange.<br><br>The TFT screen is working, preview option is on, 2D and 3D modes have been tried. Seems like the TFT screen is the one that has been resized by the parameters (it is more narrow and stretched than usual).<br>Taking a picture using raspistill in the console leads to an ENOSPC error (mmal: mmal_vc_component_enable: failed to enable component: ENOSPC).<br><br><br>I don't know what I am missing.<p>Statistics: Posted by <a href="https://forum.stereopi.com/memberlist.php?mode=viewprofile&amp;u=1144">iPutBack</a> — Sat Jan 21, 2023 6:13 pm</p><hr />
]]></content>
	</entry>
	</feed>
