_florent_ changed the topic of #litex to: LiteX FPGA SoC builder and Cores / Github : https://github.com/enjoy-digital, https://github.com/litex-hub / Logs: https://freenode.irclog.whitequark.org/litex
tpb has quit [Remote host closed the connection]
tpb has joined #litex
gregdavill has joined #litex
<mfny> somlo: the nexys is long retired, cant get it
<tpb> Title: Nexys A7 Artix-7 FPGA Trainer Board - Digilent (at store.digilentinc.com)
<mfny> this is the replacement.. its the same board with different name ?
<mfny> will it work the same ?
<Finde> nexys4ddr and nexysa7 are essentially the same yah
<Finde> *yeah
<mfny> so all the same support as the old board in respect of litex
<mfny> ?
<mfny> i.e ethernet, SD
<mfny> and flash , is flash supported yet/now ?
<mfny> nvm that board is to expensive
<mfny> over £200
<mfny> other options ?
<tpb> Title: Nexys 4 DDR Artix-7 FPGA, Trainer Board 140-292 | eBay (at www.ebay.co.uk)
<mfny> is the flash on the Arty A7 large enough to boot Linux from ?
<mfny> 16mb
<Finde> mfny: there's a table of boards here - https://github.com/litex-hub/linux-on-litex-vexriscv
<tpb> Title: GitHub - litex-hub/linux-on-litex-vexriscv: Linux on LiteX-VexRiscv (at github.com)
<mfny> Finde: I know, but it seems like from that my options are all to expensive ? I need ether flash or SD boot and also ethernet ?
<mfny> the only boards on that list that seem to do that are all over £200 exept for the Arty A7
<mfny> but the A7 flash may be to small ?
<sajattack[m]> the linux image is only 12-ish MB
<sajattack[m]> maybe 13
<mfny> also the Future Electronics Avalanche is not available to me for some reason from the FE site ?
<mfny> says wrong region ?
<mfny> actuly the Future Electronics Avalanche is no longer there at all ?
<mfny> are there any other options not on that list maybe ?
<mfny> that will work with minimal tweaking ?
<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.
<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 considered
<john_k[m]> The Radiona ULX3S would be perfect for you but it’s not generally available yet - see https://www.crowdsupply.com/radiona/ulx3s
<tpb> Title: ULX3S | Crowd Supply (at www.crowdsupply.com)
<mfny> john_k[m]: would the normal ECP5 board work, the non versa ?.. oh wait .. no ethernet damnit
<john_k[m]> Versa board has Ethernet
<john_k[m]> I’m not sure if anyone has done the work to bring it up yet though
<john_k[m]> I’ve got one here, but hasn’t been high on my priority list yet
<mfny> john_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 ?
<john_k[m]> You’d need to use Vivado for that one and I haven’t used it so can’t speak to its status
<mfny> meh none of these options are very good it seems
<mfny> well exept the ECP5 Versa and the Nexys A7 but they are £200+
<sajattack[m]> mfny: what are your goals for litex?
<mfny> no particular projects as yet, more of a learning tool
<mfny> but yeah it seems I am for the most part priced out of this
<mfny> unless someone here can verify that the A7 indeed does work .. out of the box so to speak
<sajattack[m]> I'm not sure litex is ready for an "out of the box" experience. depends on your definition I guess
<sajattack[m]> imo, it's more of a tool for developers who already have a bit of experience
<sajattack[m]> you pretty much have to read the code to understand anything that's going on
<sajattack[m]> or ask around
<awygle> hi mfny :)
<mfny> hi
<zyp> sajattack[m], that touches on a question I've been meaning to ask; are there any API docs available anywhere?
<rjeschmi> zyp: for litex?
<zyp> yes
<tpb> Title: LiteX for Hardware Engineers · timvideos/litex-buildenv Wiki · GitHub (at github.com)
<rjeschmi> but overall the migen docs are a bit more thorough for syntax
<tpb> Title: API reference Migen 0.8.dev0 documentation (at m-labs.hk)
<zyp> already read that and I'm aware of the migen API reference, just missing one for litex
<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 anywhere
<zyp> so far I've been digging through the code to figure out how to use it, which works, but a proper reference would save time
<sajattack[m]> I'm gonna guess that's a no https://litex.readthedocs.io/en/latest/
<tpb> Title: Welcome to Read the Docs litex latest documentation (at litex.readthedocs.io)
<sajattack[m]> you could try running sphinx locally maybe
Degi has quit [Ping timeout: 246 seconds]
HoloIRCUser2 has joined #litex
Degi has joined #litex
HoloIRCUser1 has quit [Ping timeout: 250 seconds]
HoloIRCUser1 has joined #litex
HoloIRCUser2 has quit [Ping timeout: 246 seconds]
_whitelogger has joined #litex
HoloIRCUser has joined #litex
HoloIRCUser1 has quit [Ping timeout: 250 seconds]
HoloIRCUser1 has joined #litex
HoloIRCUser2 has joined #litex
HoloIRCUser has quit [Ping timeout: 246 seconds]
HoloIRCUser1 has quit [Ping timeout: 265 seconds]
HoloIRCUser2 has quit [Read error: Connection reset by peer]
HoloIRCUser has joined #litex
<sajattack[m]> how do I represent a signal indexed by another signal in migen?
<sajattack[m]> it says `Cannot use type Signal as key` if I try to do it the way I'd expect
<tpb> Title: milkymist-ml401/ps2.v at 8886e6385eebdccdbd7be792fc3ea2c52bbcfbac · tmatsuya/milkymist-ml401 · GitHub (at github.com)
<zyp> what is the way you expect?
<_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.
<tpb> Title: migen/arrays.py at master · m-labs/migen · GitHub (at github.com)
<mfny> _florent_: the Versa ECP5 is not $100, its over double that ?
<mfny> $208 on Digikey, but that's £200 to me as I am in the UK with VAT
<mfny> so where are you seeing it at 100 bucks ?
<sajattack[m]> _florent_: hmm but then I can't use .eq in another part of the code
<_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$
<tpb> Title: For a limited time, get the Lattice ECP5™ Versa Development Board for $99.00 (at www.semiconductorstore.com)
<mfny> thats from 2016
<sajattack[m]> I figured it out
<sajattack[m]> thanks
<_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.
<sajattack[m]> now I have another question, how do I tell when a CSRField is being accessed?
<tpb> Title: milkymist-ml401/ps2.v at master · tmatsuya/milkymist-ml401 · GitHub (at github.com)
<sajattack[m]> it looks like a raw csr can do it via we and re but idk what to do for csrfield
<sajattack[m]> oh hang on
<sajattack[m]> a csrfield is a split up csr
<sajattack[m]> I guess I'm doing it too deep down the chain
<sajattack[m]> I need to do it on the csrstorage, not on the csrfield?
<sajattack[m]> then why does it tell me csrstorage has no attribute 'we'
<sajattack[m]> that would do it
<sajattack[m]> why doesn't CSRStatus have re like CSRStorage does?
<sajattack[m]> I thought a CSRStatus was just a read-only CSRStorage
<_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/7a9fa9d3b18362bf707dff25a78661395ef9ee7a
<tpb> Title: core: use new CSRStatus.we signal to speed-up Storage upload (>10x sp… · enjoy-digital/litescope@7a9fa9d · GitHub (at github.com)
<sajattack[m]> oh weird
<sajattack[m]> ok
<_florent_> sajattack[m]: i'm trying to spend some time creating a proper wiki, i'll make sure we document this
<sajattack[m]> yeah take your time
<sajattack[m]> I know it's hard to do docs when a project is still in it's infancy
<sajattack[m]> and constantly evolving
<mfny> _florent_ so the A7 is pretty much "fully supported" right now ? with LiteX .. no major caveats ?
<_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.
<_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?)
<tpb> Title: Reclock spi sdcard access after initialisation · enjoy-digital/litex@2bf31a3 · GitHub (at github.com)
<mfny> _florent_ so realy its between the ECP5 Versa, Arty A7 and the Nexys A7 for full support then ?
<mfny> or so it seems
<mfny> the Nexys A7 is the Nexys 4 DDR with a new name
HoloIRCUser has quit [Ping timeout: 246 seconds]
<_florent_> mfny: the others boards as also fully supported but are generally more expensive, i only listed the ones with a good capabilities/cost ratio
HoloIRCUser has joined #litex
HoloIRCUser1 has joined #litex
<sajattack[m]> _florent_: yeah I checked with git bisect and the commit it reported was the reclock one
<sajattack[m]> https://matrix.to/#/!njNLVSISzXbRIRJASZ:matrix.org/$1584814214430548HFqtH:matrix.org?via=matrix.org
<tpb> Title: [matrix] (at matrix.to)
<sajattack[m]> er, I guess that doesn't help for you irc guys
<sajattack[m]> `2bf31a31da336b628825aced248396b8ba3e3105 is the first bad commit`
HoloIRCUser has quit [Ping timeout: 265 seconds]
<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 ?
<_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 )
<tpb> Title: Pmod MicroSD: microSD Card Slot - Digilent (at store.digilentinc.com)
<mfny> _florent_: is that PMOD supported as is by the litex bsp for the A7 ?
<_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 now
<mfny> I may be able to go for something like the versa .. maybe
<_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/57bcadb5b4c1a0a2592b5e85bdd98ab375ce7e33
<tpb> Title: platforms/nexys4ddr: add spisdcard pins. · litex-hub/litex-boards@57bcadb · GitHub (at github.com)
<mfny> oh ok that seems simple enough
<mfny> btw 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 image
<mfny> i.e if you are not using Pynq via the official SD image you are on your own
<mfny> the BSP does not even work with a standard Petalinux built.. nor does it work for Vitis Linux Apps ether
<mfny> so I am returning the Z2
<_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.
<sajattack[m]> _florent_: any tips on setting up wishbone-tool?
<_florent_> sajattack[m]: to use it over UART/Ethernet?
<sajattack[m]> uart aye
<sajattack[m]> that's what I have so far
<sajattack[m]> just hangs and I don't even get bios
<sajattack[m]> I'm trying to do some reads of my ps2 CSRs for testing
<_florent_> the easiest way would be to specific serial pins for that in your platform
<_florent_> do you have an USB/UART dongle you can use for that?
<sajattack[m]> yeah
<sajattack[m]> I'm using the same pins as the bios
<_florent_> ah ok you are using the uart in crossover mode
<mfny> _florent_: this IRC has already been far more helpful then the Offical Pynq forums have been re my Z2 issues
<sajattack[m]> I copied from esden
<mfny> i mean in terms of answering my questions about Litex
<mfny> relative to the Pynq forums answering about the Z2
<mfny> when I am looking at Dev boards and anything related to them i look at the community support and documentation
<mfny> very important
<_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.
<mfny> i am ether gonna buy a diffent better supported Zynq board, or get something that can run Litex
<_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-Control
<tpb> Title: Use Host Bridge To Control · enjoy-digital/litex Wiki · GitHub (at github.com)
gregdavill has quit [Ping timeout: 246 seconds]
<somlo> mfny: 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 board
<somlo> through 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 :)
tmichalak has quit [Ping timeout: 258 seconds]
kgugala has quit [Ping timeout: 256 seconds]
kgugala has joined #litex
tmichalak has joined #litex
karol4 has joined #litex
tmichalak has quit [Read error: Connection reset by peer]
tmichalak has joined #litex
kgugala has quit [Ping timeout: 240 seconds]
mfny has quit [Ping timeout: 240 seconds]
keesj has joined #litex
<keesj> lo
tnt has joined #litex
<tnt> Is there a way for the litex SPI to set QE=1 on boot ?
<_florent_> tnt: not yet :) i'm generally setting it with OpenOCD, but that could indeed be useful
<HoloIRCUser1> the 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-SoC
<tpb> Title: Use Host Bridge to control debug a SoC · enjoy-digital/litex Wiki · GitHub (at github.com)
HoloIRCUser1 is now known as dasdgw
<tnt> _florent_: yeah, just bit me. First time all the weird letters at the end of the flash chip part number had any importance :p
<tpb> Title: add jtagspi set_qe command · enjoy-digital/openocd@d10978c · GitHub (at github.com)
HoloIRCUser has joined #litex
<_florent_> tnt: you can then set it in your OpenOCD script with jtagspi set_qe 0 1
<tnt> _florent_: I modified iceprog to set it.
<_florent_> ah ok
dasdgw has quit [Ping timeout: 246 seconds]
<tnt> Am I mis-understanding how to use the uart : I would expect this to be an echo :
<tnt> if (!uart_rxempty_read())
<tnt> uart_rxtx_write(uart_rxtx_read());
<tnt> But instead as soon as I send ca char to the SoC, it crashes / stops executing.
mfny25 has joined #litex
<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 ?
<tnt> huh, 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.
<_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 :)
gregdavill has joined #litex
<mfny25> _florent_ what about the flash issue ?
<mfny25> also would there be support for this in LiteX ? https://store.digilentinc.com/pmod-i2s2-stereo-audio-input-and-output/
<tpb> Title: Pmod I2S2: Stereo Audio Input and Output - Digilent (at store.digilentinc.com)