rg350
HowTo
Display timing
zcrc explained to me how to define display timing values: your screen's datasheet should give you the values for the front porch / back porch and clock frequency to use lildurdenYesterday at 9:55 PM Datasheet gives me values to use for 720x1280 At least vertical and horizontal synchronization are wrong on it. zcrcYesterday at 10:09 PM ah the panel is 640x480, right? lildurdenYesterday at 10:09 PM Yes zcrcYesterday at 10:09 PM Ok. So let me explain the theory You want to solve this equation: htotal * vtotal * bytes_per_pixel * 60 == (432 MHz / X) X being an integer is it a 16-bit or 24/32-bit panel? with htotal = hdisplay + h_front_porch + hsync + h_back_porch and vtotal = vdisplay + v_front_porch + vsync + v_back_porch lildurdenYesterday at 10:13 PM 24bit zcrcYesterday at 10:14 PM ok So that means: (hdisplay + h_front_porch + hsync + h_back_porch) * (vdisplay + v_front_porch + v_back_porch) == 432M / (4 * 60 * X) you know hdisplay and vdisplay, these are 640 / 480 you just need to find values that work for the other ones Now, a possible solution for this equation would be htotal = 800, vtotal = 600 because 800 * 600 == 432.000.000 / (4 * 60 * 15) X = 15 and it's an integer, so that works That means: 640 + h_front_porch + hsync + h_back_porch == 800 and 480 + v_front_porch + vsync + v_back_porch == 600 lildurdenYesterday at 10:21 PM Ok I think the values I choose are close to this zcrcYesterday at 10:21 PM so: h_front_porch + hsync + h_back_porch == 160 v_front_porch + vsync + v_back_porch == 120 The actual values you pick don't matter that much, as long as this equation is respected. The panel itself will support a range of values for the front/back porches and h/v sync if you use values that are too small / too big then it may not work correctly, but in general the panels don't care that much If you wonder why that equation should be respected: this gives you a perfect 60.00 Hz frame rate lildurdenYesterday at 10:24 PM ok that's clear! in fact my values are 4 times too big to solve the equation Can I vary X? zcrcYesterday at 10:28 PM yes lildurdenYesterday at 10:31 PM great, thank you very much, I'll work on it. another question, last one, how do I choose .clock parameter? zcrcYesterday at 10:58 PM 800*600*60 so 28,8 MHz aka 28800 kHz so .clock = 28800 lildurdenYesterday at 11:06 PM Great, I wait compilation ends then will be able to try