Monday, 2020-03-23

*** tpb has joined #litex00:00
*** gregdavill has joined #litex00:06
mfnysomlo: the nexys is long retired, cant get it00:10
mfnyhttps://store.digilentinc.com/nexys-a7-fpga-trainer-board-recommended-for-ece-curriculum/00:11
tpbTitle: Nexys A7 Artix-7 FPGA Trainer Board - Digilent (at store.digilentinc.com)00:11
mfnythis is the replacement.. its the same board with different name ?00:11
mfnywill it work the same ?00:11
Findenexys4ddr and nexysa7 are essentially the same yah00:12
Finde*yeah00:12
mfnyso all the same support as the old board in respect of  litex00:13
mfny?00:13
mfnyi.e ethernet, SD00:15
mfnyand flash , is flash supported yet/now ?00:15
mfnynvm that board is to expensive00:17
mfnyover £20000:17
mfnyother options ?00:18
mfnythere is a DDR used ? https://www.ebay.co.uk/itm/Nexys-4-DDR-Artix-7-FPGA-Trainer-Board-140-292/254545972475?hash=item3b441f4cfb:g:ovgAAOSwD75edJWa00:19
tpbTitle: Nexys 4 DDR Artix-7 FPGA, Trainer Board 140-292 | eBay (at www.ebay.co.uk)00:19
mfnyis the flash on the Arty A7 large enough to boot Linux from ?00:24
mfny16mb00:24
Findemfny: there's a table of boards here - https://github.com/litex-hub/linux-on-litex-vexriscv00:25
tpbTitle: GitHub - litex-hub/linux-on-litex-vexriscv: Linux on LiteX-VexRiscv (at github.com)00:25
mfnyFinde: I know, but it seems like from that my options are all to expensive ? I need ether flash or SD boot and also ethernet ?00:27
mfnythe only boards on that list that seem to do that are all over £200 exept for the Arty A700:27
mfnybut the A7 flash may be to small ?00:27
sajattack[m]the linux image is only 12-ish MB00:29
sajattack[m]maybe 1300:29
mfnyalso the Future Electronics Avalanche is not available to me for some reason from the FE site ?00:30
mfnysays wrong region ?00:30
mfnyactuly the Future Electronics Avalanche is no longer there at all ?00:33
mfnyare there any other options not on that list maybe ?00:37
mfnythat will work with minimal tweaking ?00:37
john_k[m]There are a ton of boards, you’re going to have the best luck with a board from the list. Anything else, there is going to be some work required.00:41
john_k[m]Unless you have experience with Vivado, I’d highly recommend going with an ECP5 based board. Adding an SD card to a board is probably the easiest thing to do, all things considered00:41
john_k[m]The Radiona ULX3S would be perfect for you but it’s not generally available yet - see https://www.crowdsupply.com/radiona/ulx3s00:44
tpbTitle: ULX3S | Crowd Supply (at www.crowdsupply.com)00:44
mfnyjohn_k[m]: would the normal ECP5 board work, the non versa ?.. oh wait .. no ethernet damnit00:46
john_k[m]Versa board has Ethernet00:47
john_k[m]I’m not sure if anyone has done the work to bring it up yet though00:47
john_k[m]I’ve got one here, but hasn’t been high on my priority list yet00:48
mfnyjohn_k[m]: so it looks like my only option is the Arty A7 which has bootable flash, but not a lot of  it and a supported ethernet ?00:52
john_k[m]You’d need to use Vivado for that one and I haven’t used it so can’t speak to its status00:53
mfnymeh none of these options are very good it seems00:54
mfnywell exept the ECP5 Versa and the Nexys A7 but they are £200+00:55
sajattack[m]mfny: what are your goals for litex?00:58
mfnyno particular projects as yet, more of a learning tool01:05
mfnybut yeah it seems I am for the most part priced out of this01:07
mfnyunless someone here can verify that the A7 indeed does work .. out of the box so to speak01:08
sajattack[m]I'm not sure litex is ready for an "out of the box" experience. depends on your definition I guess01:09
sajattack[m]imo, it's more of a tool for developers who already have a bit of experience01:12
sajattack[m]you pretty much have to read the code to understand anything that's going on01:14
sajattack[m]or ask around01:15
awyglehi mfny :)01:34
mfnyhi01:50
zypsajattack[m], that touches on a question I've been meaning to ask; are there any API docs available anywhere?01:55
rjeschmizyp: for litex?01:55
zypyes01:55
rjeschmiI found this useful: https://github.com/timvideos/litex-buildenv/wiki/LiteX-for-Hardware-Engineers01:56
tpbTitle: LiteX for Hardware Engineers · timvideos/litex-buildenv Wiki · GitHub (at github.com)01:56
rjeschmibut overall the migen docs are a bit more thorough for syntax01:56
rjeschmihttps://m-labs.hk/migen/manual/reference.html01:57
tpbTitle: API reference Migen 0.8.dev0 documentation (at m-labs.hk)01:57
zypalready read that and I'm aware of the migen API reference, just missing one for litex01:57
sajattack[m]there are some doc comments I've seen but I'm not sure if they're processed and turned into a page available online anywhere01:57
zypso far I've been digging through the code to figure out how to use it, which works, but a proper reference would save time01:58
sajattack[m]I'm gonna guess that's a no https://litex.readthedocs.io/en/latest/02:00
tpbTitle: Welcome to Read the Docs litex latest documentation (at litex.readthedocs.io)02:00
sajattack[m]you could try running sphinx locally maybe02:00
*** Degi has quit IRC02:12
*** HoloIRCUser2 has joined #litex02:12
*** Degi has joined #litex02:14
*** HoloIRCUser1 has quit IRC02:14
*** HoloIRCUser1 has joined #litex03:16
*** HoloIRCUser2 has quit IRC03:20
*** _whitelogger has quit IRC04:27
*** _whitelogger has joined #litex04:29
*** HoloIRCUser has joined #litex06:30
*** HoloIRCUser1 has quit IRC06:34
*** HoloIRCUser1 has joined #litex07:27
*** HoloIRCUser2 has joined #litex07:28
*** HoloIRCUser has quit IRC07:29
*** HoloIRCUser1 has quit IRC07:32
*** HoloIRCUser2 has quit IRC07:32
*** HoloIRCUser has joined #litex07:32
sajattack[m]how do I represent a signal indexed by another signal in migen?07:48
sajattack[m]Like this: https://github.com/tmatsuya/milkymist-ml401/blob/8886e6385eebdccdbd7be792fc3ea2c52bbcfbac/cores/ps2/rtl/ps2.v#L21507:48
sajattack[m]it says `Cannot use type Signal as key` if I try to do it the way I'd expect07:48
tpbTitle: milkymist-ml401/ps2.v at 8886e6385eebdccdbd7be792fc3ea2c52bbcfbac · tmatsuya/milkymist-ml401 · GitHub (at github.com)07:48
zypwhat is the way you expect?08:03
_florent_mfny: for Linux-on-LiteX-Vexriscv and boards that are not too expensive (~100$), i would recommend the Versa ECP5, ULX3S, OrangeCrab or Arty A7. If SDCard is missing, it's easy to use a PMOD or IOs to add that.08:08
_florent_sajattack[m]: you can use Array: https://github.com/m-labs/migen/blob/master/examples/basic/arrays.py08:09
tpbTitle: migen/arrays.py at master · m-labs/migen · GitHub (at github.com)08:09
mfny_florent_: the Versa ECP5 is not $100, its over double that ?08:11
mfny$208 on Digikey, but that's £200 to me as I am in the UK with VAT08:13
mfnyso where are you seeing it at 100 bucks ?08:13
sajattack[m]_florent_: hmm but then I can't use .eq in another part of the code08:14
_florent_mfny: ah sorry, IIRC Lattice is sometimes doing  discount for it and sells it at 99$, but the regular price is indeed around 200$08:14
_florent_https://www.semiconductorstore.com/blog/2016/For-a-limited-time-get-the-Lattice-ECP5-Versa-Development-Board-for-only-99-00/1799/08:15
tpbTitle: For a limited time, get the Lattice ECP5™ Versa Development Board for $99.00 (at www.semiconductorstore.com)08:16
mfnythats from 201608:18
sajattack[m]I figured it out08:22
sajattack[m]thanks08:22
_florent_If you are ok using Vivado (for now), the Arty A7 is a good option:  easy to get, 130$, DDR3/Ethernet/PMODs/SPIFlash. That's the board i probably using the most. It's possible to boot Linux from the SPI Flash and you can easily add a SDCard PMOD. The open source ECP5 boards are also really nice, but you'll probably have to wait a bit.08:23
sajattack[m]now I have another question, how do I tell when a CSRField is being accessed?08:23
sajattack[m]more concretely, replicate this logic https://github.com/tmatsuya/milkymist-ml401/blob/master/cores/ps2/rtl/ps2.v#L18908:24
tpbTitle: milkymist-ml401/ps2.v at master · tmatsuya/milkymist-ml401 · GitHub (at github.com)08:24
sajattack[m]it looks like a raw csr can do it via we and re but idk what to do for csrfield08:25
sajattack[m]oh hang on08:28
sajattack[m]a csrfield is a split up csr08:28
sajattack[m]I guess I'm doing it too deep down the chain08:28
sajattack[m]I need to do it on the csrstorage, not on the csrfield?08:28
sajattack[m]then why does it tell me csrstorage has no attribute 'we'08:30
* sajattack[m] sent a long message: < https://matrix.org/_matrix/media/r0/download/matrix.org/dohCuVHuIvSWemEWOtUiKrPm >08:31
sajattack[m]that would do it08:31
sajattack[m]why doesn't CSRStatus have re like CSRStorage does?08:35
sajattack[m]I thought a CSRStatus was just a read-only CSRStorage08:35
_florent_For CSRStatus, there is a we signal you can use to know when the CSRStatus is read (sorry the names are indeed confusing): https://github.com/enjoy-digital/litescope/commit/7a9fa9d3b18362bf707dff25a78661395ef9ee7a08:37
tpbTitle: core: use new CSRStatus.we signal to speed-up Storage upload (>10x sp… · enjoy-digital/litescope@7a9fa9d · GitHub (at github.com)08:37
sajattack[m]oh weird08:38
sajattack[m]ok08:38
_florent_sajattack[m]: i'm trying to spend some time creating a proper wiki, i'll make sure we document this08:41
sajattack[m]yeah take your time08:42
sajattack[m]I know it's hard to do docs when a project is still in it's infancy08:42
sajattack[m]and constantly evolving08:43
mfny_florent_ so the A7 is pretty much "fully supported" right now ? with LiteX .. no major caveats ?08:46
_florent_mfny: yes, the A7 is fully supported and tested regularly (that's the one i used the most for regression testing). It's also the board that is used by Symbiflow/PrjXRay to validate things on hardware, so you can find examples to use the open source tools with it.08:52
_florent_sajattack[m]: btw, for your SDCard issue, it's the change from 400KHz to 16MHz after the initialization that breaks things on your side? (ie https://github.com/enjoy-digital/litex/commit/2bf31a31da336b628825aced248396b8ba3e3105#diff-7469999040746bb90f3e3fc8a8a1b1e8?)08:55
tpbTitle: Reclock spi sdcard access after initialisation · enjoy-digital/litex@2bf31a3 · GitHub (at github.com)08:55
mfny_florent_ so realy its between the ECP5 Versa, Arty A7 and the Nexys A7 for full support then ?10:02
mfnyor so it seems10:03
mfnythe Nexys A7 is the Nexys 4 DDR with a new name10:04
*** HoloIRCUser has quit IRC10:34
_florent_mfny: the others boards as also fully supported but are generally more expensive, i only listed the ones with a good capabilities/cost ratio10:34
*** HoloIRCUser has joined #litex10:37
*** HoloIRCUser1 has joined #litex10:40
sajattack[m]_florent_: yeah I checked with git bisect and the commit it reported was the reclock one10:41
sajattack[m]https://matrix.to/#/!njNLVSISzXbRIRJASZ:matrix.org/$1584814214430548HFqtH:matrix.org?via=matrix.org10:42
tpbTitle: [matrix] (at matrix.to)10:42
sajattack[m]er, I guess that doesn't help for you irc guys10:42
sajattack[m]`2bf31a31da336b628825aced248396b8ba3e3105 is the first bad commit`10:43
*** HoloIRCUser has quit IRC10:43
mfny_florent_ I need a board with SD or Flash boot and Ethernet and those boards I mentioned are the only ones that have that right now ?10:47
_florent_The nexysA7 has all this, the Arty A7 and Versa can boot from SPI Flash but will be missing the SD, but you can use a 10$ a PMOD ( https://store.digilentinc.com/pmod-microsd-microsd-card-slot )10:53
tpbTitle: Pmod MicroSD: microSD Card Slot - Digilent (at store.digilentinc.com)10:53
mfny_florent_: is that PMOD supported as is by the litex bsp for the A7 ?10:54
_florent_The versa is also already well supported by the open-source toolchains and has 2 x 1Gbps ethernet ports (vs 100Mbps on NexysA7/ArtyA7), for the Digilent board you will need to use Vivado for now10:55
mfnyI may be able to go for something like the versa .. maybe10:56
_florent_for the SDCard PMOD, you will just need to add the few pins to the platform definition, similar to this for example: https://github.com/litex-hub/litex-boards/commit/57bcadb5b4c1a0a2592b5e85bdd98ab375ce7e3310:56
tpbTitle: platforms/nexys4ddr: add spisdcard pins. · litex-hub/litex-boards@57bcadb · GitHub (at github.com)10:56
mfnyoh ok that seems simple enough10:58
mfnybtw the reason I am here is because I bought a Pynq Z2 board and the support/docs have been not great for anything other then the official Pynq SD image11:00
mfnyi.e if you are not using Pynq via the official SD image you are on your own11:00
mfnythe BSP does not even work with a standard Petalinux built.. nor does it work for Vitis Linux Apps ether11:01
mfnyso I am returning the Z211:02
_florent_ok i see, you can also run LiteX on Zynq, but you have to share peripherals between PS and PL and the memory is generally directly connected to the PS, so that make things more complicated for Linux-on-LiteX-Vexriscv since we would need to access the DDR3 through the AXI interface of the PS.11:06
sajattack[m]_florent_: any tips on setting up wishbone-tool?11:07
_florent_sajattack[m]: to use it over UART/Ethernet?11:08
sajattack[m]uart aye11:09
sajattack[m]https://termbin.com/838a11:09
sajattack[m]that's what I have so far11:09
sajattack[m]just hangs and I don't even get bios11:09
sajattack[m]I'm trying to do some reads of my ps2 CSRs for testing11:10
_florent_the easiest way would be to specific serial pins for that in your platform11:12
_florent_do you have an USB/UART dongle you can use for that?11:12
sajattack[m]yeah11:12
sajattack[m]I'm using the same pins as the bios11:12
_florent_ah ok you are using the uart in crossover mode11:14
mfny_florent_: this IRC has already been far more helpful then the Offical Pynq forums have been re my Z2 issues11:14
sajattack[m]I copied from esden11:14
mfnyi mean in terms of answering my questions about Litex11:14
mfnyrelative to the Pynq forums answering about the Z211:15
mfnywhen I am looking at Dev boards and anything related to them i look at the community support and documentation11:16
mfnyvery important11:16
_florent_mfny: ok, glad we've been able to help you. If you are new to FPGA, you should probably start using raw FPGAs (is without processing systems like Zynq), it's easier to start with and understand things.11:16
mfnyi am ether gonna buy a diffent better supported Zynq board, or get something that can run Litex11:17
_florent_sajattack[m]: if you have a USB/UART dongle, you can just try this: https://github.com/enjoy-digital/litex/wiki/Use-Host-Bridge-To-Control12:01
tpbTitle: Use Host Bridge To Control · enjoy-digital/litex Wiki · GitHub (at github.com)12:01
*** gregdavill has quit IRC12:10
somlomfny: Think of the Zynq chip as either an FPGA with special hard-IP (asic) CPUs you can connect to the other configurable blocks on the fpga die, or as a hard-IP, asic, CPU with some FPGA fabric "coprocessor" :) On the plus side, you have an FPGA witha hardware-acelerated (pair of) cpus that can do cool things for you; on the downside, if you want to do soft-IP ("pure FPGA" things, like LiteX) you're limited to accessing the RAM on your dev board12:43
somlothrough the asic CPU. Like _florent_ said, if learning about FPGAs and digital design is your main goal, stay away from the Zynq; if, OTOH, you have a specific application in mind, and the Zynq's hard-wired arm cpu cores are specifically helpful for that, that's a whole different reason to stick with Zynq :)12:43
*** tmichalak has quit IRC12:53
*** kgugala has quit IRC12:53
*** kgugala has joined #litex12:55
*** tmichalak has joined #litex12:55
*** karol4 has joined #litex13:56
*** tmichalak has quit IRC13:56
*** tmichalak has joined #litex13:56
*** kgugala has quit IRC13:58
*** mfny has quit IRC14:22
*** keesj has joined #litex14:36
keesjlo14:36
*** tnt has joined #litex18:03
tntIs there a way for the litex SPI to set QE=1 on boot ?18:06
_florent_tnt: not yet :) i'm generally setting it with OpenOCD, but that could indeed be useful18:20
HoloIRCUser1the link to 'use host bridge to control' was broken in the wiki sidebar. Correct link should be https://github.com/enjoy-digital/litex/wiki/Use-Host-Bridge-to-control-debug-a-SoC18:31
tpbTitle: Use Host Bridge to control debug a SoC · enjoy-digital/litex Wiki · GitHub (at github.com)18:31
*** HoloIRCUser1 is now known as dasdgw18:31
tnt_florent_: yeah, just bit me. First time all the weird letters at the end of the flash chip part number had any importance :p18:36
_florent_tnt: here is an OpenOCD patch to set it: https://github.com/enjoy-digital/openocd/commit/d10978c9729efa3735a25e75b2ee03503b86edce18:39
tpbTitle: add jtagspi set_qe command · enjoy-digital/openocd@d10978c · GitHub (at github.com)18:39
*** HoloIRCUser has joined #litex18:40
_florent_tnt: you can then set it in your OpenOCD script with jtagspi set_qe 0 118:40
tnt_florent_: I modified iceprog to set it.18:40
_florent_ah ok18:40
*** dasdgw has quit IRC18:42
tntAm I mis-understanding how to use the uart : I would expect this to be an echo :19:38
tnt        if (!uart_rxempty_read())19:39
tnt                uart_rxtx_write(uart_rxtx_read());19:39
tntBut instead as soon as I send ca char to the SoC, it crashes / stops executing.19:39
*** mfny25 has joined #litex19:46
mfny25_florent_: does the arty a7 indeed have enough flash and logic to fully use LiteX ? 16mb flash seems tight and I am reading that for more complex stuff the 35t is a bit tight also ?19:49
tnthuh, if I don't use the generated accessor bu access it as a byte (instead of uint32_t) manually with volatile uint8_t * ... it works better.20:28
_florent_mfny25: it depends what you want to do with the board, but i found the size of the FPGA quite adapted on the Arty A7 regarding the peripherals the board has. I never went out of logic with it, and with Symbiflow, you'll be able to use it as a 50T :)20:49
*** gregdavill has joined #litex22:17
mfny25_florent_ what about the flash issue ?23:15
mfny25also would there be support for this in LiteX ? https://store.digilentinc.com/pmod-i2s2-stereo-audio-input-and-output/23:42
tpbTitle: Pmod I2S2: Stereo Audio Input and Output - Digilent (at store.digilentinc.com)23:42

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