Friday, 2020-04-03

*** tpb has joined #litex00:00
*** CarlFK has quit IRC00:03
*** CarlFK has joined #litex00:21
*** Degi has quit IRC00:49
*** Degi has joined #litex00:50
*** tcal has joined #litex04:57
*** scanakci has joined #litex05:55
_florent_zyp: yes the provided configuration is like this because i was just testing UART over Etherbone, which avoid using a regular UART, but constraints the design a lot more.06:07
_florent_zyp: if you want something that meets timings and with SDRAM working, you can lower the sys_clk_freq to 40-60MHz here:06:08
_florent_https://github.com/litex-hub/litex-boards/blob/master/litex_boards/targets/colorlight_5a_75b.py#L6706:08
tpbTitle: litex-boards/colorlight_5a_75b.py at master · litex-hub/litex-boards · GitHub (at github.com)06:08
_florent_and use a regular UART by defining serial pins to the plaform, similar to this:06:09
_florent_https://github.com/litex-hub/litex-boards/blob/master/litex_boards/platforms/ulx3s.py#L22-L2506:10
tpbTitle: litex-boards/ulx3s.py at master · litex-hub/litex-boards · GitHub (at github.com)06:10
_florent_all the IOs are output only on this board, you could use the button IO for the serial.rx06:11
_florent_also here, the Ethernet is running at 125MH because we are using the hardware stack, when using the Ethernet MAC with the CPU, the frequency can be lowered. So with a regular UART, you could have  SDRAM + Ethernet working and pass timings.06:13
_florent_i'll try to update the target today to allow this configuration06:14
*** peepsalot has left #litex06:30
zypalready did that last night :)08:28
zyphttps://paste.jvnv.net/view/lMEoN08:28
tpbTitle: JVnV Pastebin View paste – Untitled (at paste.jvnv.net)08:28
_florent_zyp: ah ok great, i just did something similar and pushed it to the repo: https://github.com/litex-hub/litex-boards/commit/a7fbe0a724a1b2fd788699def52c89a05cd556e508:30
tpbTitle: colorlight_5a_75b: add SoC with regular UART (on J19). · litex-hub/litex-boards@a7fbe0a · GitHub (at github.com)08:30
zypI also thought about using the button/led for uart, but decided against that and removed one of the buffers instead: https://bin.jvnv.net/file/8L4wZ.jpg08:31
_florent_zyp: yes, also thought about removing a buffer, for now i used the option that requires the minimal hardware changes, but then we can't use the button/led in the SoC, we'll see in the future what's the best08:33
zypspeaking of frequency, is it possible to get an accurate 48MHz from the 25MHz clock input? the closest the PLL config is getting is *21/11 giving 47.73 MHz08:42
zypit's a bit unclear to me whether the CLKI range refers to before or after the CLKI divider - I guess after which makes it impossible to satisfy the ranges08:46
zypotherwise, /5*96/10 should work08:47
_florent_for now CLKI_DIV is fixed to 1, we could add support for the supported divider range (1 to 128) but i also think the CLKI range refers to after the CLKI divider since it makes more sense (ie real input of the PLL)09:00
zypthat was my reasoning too09:01
zypbut I think I just solved it by chaining two PLLs :)09:01
zypI don't really know what I'm doing, but this looks reasonable to me: https://paste.jvnv.net/view/OvL4K09:03
tpbTitle: JVnV Pastebin View paste – Untitled (at paste.jvnv.net)09:03
_florent_zyp: looking at FPGA-DS-02012-2.1 that's indeed not clear, maybe the 128 max divider is already taken into account in the provided fIN Min09:04
_florent_zyp: i could try to add support for CLKI_DIV in ECP5PLL09:05
_florent_zyp: https://github.com/enjoy-digital/litex/commit/6043108376ddfd438e5a11f846be3aa89331bc9e09:17
tpbTitle: soc/cores/clock/ECP5PLL: add CLKI_DIV support. · enjoy-digital/litex@6043108 · GitHub (at github.com)09:17
_florent_tested with https://gist.github.com/enjoy-digital/7e9b12d584c1f5c287fc83725e23df1309:17
tpbTitle: gist:7e9b12d584c1f5c287fc83725e23df13 · GitHub (at gist.github.com)09:17
_florent_in your case, the frequency input of the PLL will be 5MHz09:17
_florent_so even if fIN Min is not taking into account the possible 128 divider, it's not far from the 8MHz so could work09:18
_florent_you have to use margin=0 because for now we are taking the first value that satisfies the margin, i'll need to improve that and use the config that minimize the errors09:20
*** futarisIRCcloud has quit IRC09:31
zypI figured I'd check what clarity designer suggests, and somehow it's refusing to give me anything better than *26/13 for 50 MHz09:31
_florent_ok thanks, so it means the Fin range is after the divider as we were guessing?09:33
zypI wouldn't draw that conclusion yet, it should have found the 47.73 MHz option09:34
*** HoloIRCUser has joined #litex09:37
*** HoloIRCUser3 has quit IRC09:37
zypif I'm asking clarity designer for 24 -> 128, it's giving me /3*80/5, if I'm asking clarity designer for 12 -> 128 it can't solve it, even though /1*64/3 should be a valid solution10:46
_florent_zyp: hmm strange, not sure if clarity designer is aware of other un-documented constraints or if it's not flexible/clever enough...10:54
zypah, I figured out why, I missed the part where VCO freq is decided by CLKFB, and my selected feedback source couldn't generate the appropriate freq11:01
zypit looks like I can't persuade clarity to divide CLKI down below 8 MHz, so I guess that means the lower bound applies after the division11:45
*** scanakci has quit IRC11:59
_florent_zyp: ok  thanks, then i should probably update the ECP5PLL code to reflect that13:00
zypmy cascaded PLLs didn't appear to work in practice either, but I'll play more with that later13:02
zypI don't need 48 MHz right now, but I'm planning to play with usb later13:03
zypand 47.73 is not gonna work for that :)13:03
*** pdp7_ has left #litex14:32
*** pdp7 has joined #litex14:34
*** futarisIRCcloud has joined #litex14:45
*** HoloIRCUser1 has joined #litex17:16
*** HoloIRCUser has quit IRC17:16
*** HoloIRCUser has joined #litex18:51
*** HoloIRCUser2 has joined #litex18:52
*** HoloIRCUser1 has quit IRC18:55
*** HoloIRCUser has quit IRC18:55
*** rohitksingh has quit IRC19:04
*** FFY00 has quit IRC22:16
*** FFY00 has joined #litex22:16

Generated by irclog2html.py 2.17.2 by Marius Gedminas - find it at https://mg.pov.lt/irclog2html/!