*** tpb has joined #timvideos | 00:00 | |
shorne | hello, last time I built the gateware I had hacked up the build to find Vivado in "/opt/shorne/software/xilinx-2017.3/Vivado/2017.3/..." | 01:10 |
---|---|---|
shorne | I am tyring to make this corret now, I found the 'toolchain' path is set in 'enter-env.sh' but it doesn't seem to allow me to set things up for Vivado | 01:11 |
shorne | how are others getting around this? Should I patch enter-env.sh for Vivado? Or do I need to do something else | 01:12 |
shorne | ok... I patched enter-env.sh something like | 01:14 |
shorne | if [ ! -z "$XILINX_DIR" ]; then | 01:15 |
shorne | - export MISOC_EXTRA_CMDLINE="-Ob toolchain_path $XILINX_DIR/opt/Xilinx/" | 01:15 |
shorne | + export MISOC_EXTRA_CMDLINE="-Ob toolchain_path $XILINX_DIR" | 01:15 |
shorne | then i do export | 01:15 |
shorne | export XILINX_DIR=/opt/Xilinx/Vivado | 01:15 |
shorne | and it works fine | 01:15 |
shorne | I think thats the right thing to do | 01:15 |
mithro | shorne: I recently changed way it finds Vivado, you should just be able to use '/opt/Xilinx' if you update to the latest... | 01:59 |
shorne | mithro: ok, updating to master now | 02:19 |
shorne | mithro: every time I update to latest I do... git pull origin master, but do I need to do something to get the sub modules? | 02:21 |
shorne | i.e. ./scipts/download-env.sh again? | 02:22 |
mithro | shorne: in theory the Makefile should fix them for you, but you will have to force third_party/litex back to that other branch | 02:22 |
mithro | Maybe take a look at https://github.com/mithro/HDMI2USB-litex-firmware/tree/litex-linux ? | 02:23 |
tpb | Title: GitHub - mithro/HDMI2USB-litex-firmware at litex-linux (at github.com) | 02:23 |
shorne | mithro: yeah, because sometimes I have changes in the submodules as I hack on this | 02:25 |
mithro | shorne: Okay, we should try and get your changes upstream if they are useful :-) | 02:25 |
shorne | well, sometimes its just adding print to see see whats going on | 02:27 |
mithro | Ahh okay | 02:28 |
shorne | mithro: I think the branch litex-linux is already merged to master | 02:34 |
shorne | This commit seems to break things for me 6dca7084daf817efb52f930be7a9bc35cfc223e4 | 02:34 |
shorne | - export MISOC_EXTRA_CMDLINE="-Ob toolchain_path $XILINX_DIR" | 02:34 |
shorne | + export MISOC_EXTRA_CMDLINE="-Ob toolchain_path $XILINX_DIR/opt/Xilinx/" | 02:34 |
shorne | because, inside the litex builder litex looks for a verion directory directly under 'toolchain_path' | 02:35 |
shorne | but my version directory is '/opt/Xilinx/Vivado/2017.3/...' | 02:35 |
shorne | I want to set 'toolchain_path' to '/opt/Xlinix/Vivado' | 02:36 |
mithro | shorne: https://github.com/enjoy-digital/litex/commit/e07bd71b16932a504b7435a96901a3b0eb5a99cd | 02:36 |
tpb | Title: build/xilinx: Fixing settings finding. · enjoy-digital/litex@e07bd71 · GitHub (at github.com) | 02:36 |
shorne | mithro: ok, that submodule update is not getting pulled in | 02:37 |
shorne | let me double check | 02:38 |
shorne | ahh, its there now | 02:38 |
shorne | mithro: ok, I did a submodule update manually and it came in, not sure why it didnt come in during the regular build | 02:39 |
shorne | ok, well I was going to work on arty but I realized I didnt plug in the arty at home and I am out of town right now | 02:42 |
shorne | :) | 02:42 |
mithro | The arty is small enough to travel with you :-P | 02:44 |
shenki | I took mine on this trip :) | 02:48 |
shorne | yeah, but I dont have the environment setup on my laptop | 02:49 |
shorne | I should do that, a lot of friends have been asking me to demo this stuff | 02:50 |
shenki | oh? cool :) | 02:50 |
shenki | mithro: liteeth doesn't do dma, does it? | 02:50 |
mithro | shenki: I thought it did - but maybe not by default? | 02:52 |
shenki | ok. i was just reading the docs | 02:52 |
mithro | shenki: Not sure | 02:54 |
mithro | https://github.com/enjoy-digital/liteeth/blob/master/liteeth/frontend/etherbone.py | 02:55 |
tpb | Title: liteeth/etherbone.py at master · enjoy-digital/liteeth · GitHub (at github.com) | 02:55 |
mithro | https://github.com/enjoy-digital/liteeth/blob/master/liteeth/frontend/tty.py | 02:55 |
tpb | Title: liteeth/tty.py at master · enjoy-digital/liteeth · GitHub (at github.com) | 02:55 |
mithro | There seems to be a crossbar type thing... | 02:56 |
mithro | https://github.com/enjoy-digital/liteeth/blob/master/liteeth/core/udp.py | 02:57 |
tpb | Title: liteeth/udp.py at master · enjoy-digital/liteeth · GitHub (at github.com) | 02:57 |
mithro | But it would be pretty easy to do a DMA I think? | 02:57 |
shenki | ok | 03:08 |
shenki | mithro: do you get the performance you need for hdmi2usb without dma? (does hdmi2usb do ethernet these days?) | 03:08 |
mithro | It only does ethernet for control | 03:08 |
shenki | ok | 03:14 |
mithro | shenki: You should be able to telnet to port 22 and get the HDMI2USB> prompt... | 03:27 |
mithro | (On both the Arty and the Opsis) | 03:27 |
shenki | ok. ping works :) | 03:31 |
shenki | Successfully downloaded 3887612 bytes from boot.bin over TFTP | 03:31 |
shenki | Unable to download cmdline.txt over TFTP | 03:31 |
shenki | No command line parameters found | 03:31 |
shenki | Unable to download initrd.bin over TFTP | 03:31 |
shenki | No initial ramdisk found | 03:31 |
shenki | Executing booted program at 0x40000000 | 03:31 |
shenki | nothing after that tho | 03:32 |
shenki | mithro: which tree should I test? | 03:32 |
shenki | (kernel tree) | 03:32 |
mithro | shenki: https://github.com/mithro/linux-litex/tree/litex-minimal I think? | 03:33 |
tpb | Title: GitHub - mithro/linux-litex at litex-minimal (at github.com) | 03:33 |
cr1901_modern | mithro: Did you know that TinyFPGA B has a USB bootloader in Verilog? I knew it could be done (USB 1.1 on FPGA) but I still find it utterly fascinating. | 03:35 |
mithro | cr1901_modern: Yes | 03:35 |
cr1901_modern | That must've been an absolute pain to debug | 03:35 |
mithro | cr1901_modern: Why USB1.1 has good sigrok support and has been done like a bunch of times before | 03:36 |
* cr1901_modern adds USB transceiver to migen bucket list | 03:36 | |
mithro | cr1901_modern: Talk to rohit, he's already doing a USB2.0 core thingy... | 03:36 |
cr1901_modern | Oh nice!' | 03:37 |
mithro | cr1901_modern: https://github.com/rohitk-singh/usb-device | 03:37 |
tpb | Title: GitHub - rohitk-singh/usb-device: USB 2.0 Device IP core using Migen with out-of-box AXI Slave Interface (at github.com) | 03:37 |
mithro | cr1901_modern: I have a design for doing a PHYless USB2.0 with Spartan 6 SERDES | 03:37 |
mithro | cr1901_modern: https://github.com/mithro/soft-utmi | 03:38 |
cr1901_modern | mithro: Are you trying to break the natural order like azonenberg does for Ethernet :P? | 03:38 |
tpb | Title: GitHub - mithro/soft-utmi: A "soft" (VHDL) implementation of the UTMI+ PHYs specification using the SERDES found in Xilinx Spartan-6. (at github.com) | 03:38 |
cr1901_modern | mithro: Maybe I'm just naive. USB has overwhelmed me a few times, but I'm less stupid now than I was back then | 03:38 |
cr1901_modern | Additionally I'm not sure if the LA I bought is fast enough to debug USB 1.1 (24MHz) | 03:39 |
cr1901_modern | USB 1.1 is what, 12Mbps? | 03:39 |
mithro | shenki: I keep getting confused what we should be using - so I've put it all in a script -> https://github.com/mithro/HDMI2USB-litex-firmware/blob/litex-linux/scripts/build-linux.sh :-P | 03:39 |
tpb | Title: HDMI2USB-litex-firmware/build-linux.sh at litex-linux · mithro/HDMI2USB-litex-firmware · GitHub (at github.com) | 03:39 |
shenki | hah, that google drive url | 03:40 |
*** rohitksingh_work has joined #timvideos | 03:41 | |
cr1901_modern | rohitksingh_work: Just learned that apparently you're doing a USB 2.0 core in Migen. Is that including the PHY/bitstuffer part? | 03:42 |
shenki | mithro: you're missing the signed-off-by for your jump to reset commit | 03:42 |
shenki | oh. ive already got that in my tree | 03:43 |
rohitksingh_work | cr1901_modern: Hi! :) No, it doesn't include PHY/bitstuffing/serialization etc. It has ULPI interface instead. | 03:44 |
cr1901_modern | rohitksingh_work: Was just wondering. That's still cool though. AIUI, USB 2.0 PHY can't really be done w/ FPGA I/O alone unless you're mithro | 03:44 |
cr1901_modern | USB is a bit overwhelming for me, tbh. I'd like to fix that tho | 03:45 |
shenki | mithro: can we wire up one of the arty buttons to reset the CPU? | 03:45 |
mithro | shenki: Sure! | 03:45 |
mithro | shenki: What do the two red buttons do? | 03:46 |
shenki | the one on the usb connection side of the board resets the FPGA | 03:46 |
shenki | (so you lose the gateware) | 03:46 |
mithro | shenki: Also "make gateware-load" is so fast, I just do that.... | 03:46 |
mithro | "make tftp && make gateware-load && make firmware-connect" | 03:47 |
shenki | oh, the other one resets the cpu | 03:48 |
shenki | the one labeled "RESET" | 03:48 |
mithro | :-P | 03:49 |
shenki | https://pastebin.com/raw/H2UbRUab | 03:49 |
rohitksingh_work | cr1901_modern: Indeed! Only mithro can attempt those pushing-the-boundary kind of techniques! :p | 03:52 |
mithro | Or maybe I'm only crazy + silly enough ;-) | 03:52 |
mithro | Actually Hamster is much better at it then me | 03:52 |
shenki | mithro: i thought that shorne's changes meant i should get to userspace? | 03:54 |
mithro | shenki: I believe you should, but I have not tested shorne's changes... | 03:54 |
mithro | shenki: Oh wait, you get a console in Qemu | 03:54 |
mithro | shenki: I'm getting something similar on real hardware -- see "Latest update... Console in qemu!" email | 03:55 |
shenki | doh | 03:55 |
shenki | ben explained how to write a network driver to me last night | 03:56 |
shenki | and he's free to help me this afternoon | 03:56 |
shenki | but i need a console | 03:56 |
mithro | Use qemu | 03:56 |
shenki | do we have a model for the network device? | 03:56 |
mithro | yes | 03:56 |
shenki | ok | 03:56 |
mithro | you can even tftpboot it | 03:56 |
*** puck has quit IRC | 04:03 | |
*** puck has joined #timvideos | 04:08 | |
shorne | shenki: your final output "Executing booted program at 0x40000000" is what I get too when I was booting the kernel on arty | 05:12 |
shenki | shorne: you get this: | 05:14 |
shenki | [ 7.280000] b[ =[ 7.280000g[ 7.290000] s[ 7.300000] i[ 7.300000] i[ 7.340000] r | 05:14 |
shenki | ? | 05:14 |
shorne | no, I havent see that last time I tried | 05:14 |
shenki | ah ok | 05:14 |
shenki | with the changes you sent on top of my litex-minimal branch, that's what I get | 05:14 |
shenki | I've started hacking on the network driver. Too tired to think about serial :D | 05:15 |
shorne | I see your output, its failing right when we switch from bootconsole to the real console | 05:15 |
shenki | yeah | 05:15 |
shorne | I am pretty sure there are some more problems in serial, my fixes were enough to get qemu running | 05:16 |
shorne | but I was suspecting it would need some more work for real hardware | 05:16 |
shenki | perhaps something funky with irqs? getting interleaved printk output when there's only one CPU is strange | 05:16 |
shenki | yeah | 05:16 |
shorne | yeah, the realconsole doesnt use IRQs | 05:16 |
shorne | also, I think there is something different in the hardware IRQs i.e. its level based vs edge or something | 05:17 |
shorne | hardware vs qemu | 05:17 |
shorne | but good we get output up until that pointI can debug when I get back home | 05:18 |
shenki | ok | 05:18 |
shorne | sorry... I mean "the boot console doesnt use irqs" | 05:18 |
shenki | yeah, i follow :) | 05:18 |
_florent_ | shenki: we don't have DMA for now in liteeth, just N RX/TX buffers (N is configurable but set to 2 by default) | 08:08 |
_florent_ | shenki: all the stuff mithro was showing for liteeth is only use with the udp/ip hardware stack, which is not what we are using here with linux (only the mac) | 08:09 |
_florent_ | shenki: here are 3 different drivers if that can help: | 08:09 |
_florent_ | https://github.com/enjoy-digital/litex/blob/master/litex/soc/software/libnet/microudp.c | 08:10 |
tpb | Title: litex/microudp.c at master · enjoy-digital/litex · GitHub (at github.com) | 08:10 |
_florent_ | https://github.com/enjoy-digital/liteeth/tree/master/liteeth/software/liblwip | 08:10 |
tpb | Title: liteeth/liteeth/software/liblwip at master · enjoy-digital/liteeth · GitHub (at github.com) | 08:10 |
_florent_ | https://github.com/enjoy-digital/liteeth/tree/master/liteeth/software/libuip | 08:10 |
tpb | Title: liteeth/liteeth/software/libuip at master · enjoy-digital/liteeth · GitHub (at github.com) | 08:10 |
_florent_ | if hardware preamble/crc is enabled, you will no need to handle that in software | 08:11 |
_florent_ | init: https://github.com/enjoy-digital/liteeth/blob/master/liteeth/software/libuip/liteethmac-drv.c#L35 | 08:14 |
tpb | Title: liteeth/liteethmac-drv.c at master · enjoy-digital/liteeth · GitHub (at github.com) | 08:14 |
_florent_ | we clear the interrupts, set the rx/tx buffer addresses, set the current rx/tx slots, set the current rx/tx buffers | 08:15 |
_florent_ | send packet : https://github.com/enjoy-digital/liteeth/blob/master/liteeth/software/libuip/liteethmac-drv.c#L69 | 08:16 |
tpb | Title: liteeth/liteethmac-drv.c at master · enjoy-digital/liteeth · GitHub (at github.com) | 08:16 |
_florent_ | set data, set slot, set length, wait the sram_reader to be ready, then start the xfer | 08:17 |
_florent_ | then update txslot/txbuffer | 08:17 |
_florent_ | receive packet (polling): https://github.com/enjoy-digital/liteeth/blob/master/liteeth/software/libuip/liteethmac-drv.c#L52 | 08:18 |
tpb | Title: liteeth/liteethmac-drv.c at master · enjoy-digital/liteeth · GitHub (at github.com) | 08:18 |
_florent_ | similar to tx in the reverse order | 08:18 |
_florent_ | i hope that can help, have fun :) | 08:20 |
*** rohitksingh_work has quit IRC | 12:42 | |
*** rohitksingh has joined #timvideos | 13:23 | |
*** rohitksingh has quit IRC | 13:38 | |
*** CarlFK has quit IRC | 13:52 | |
*** CarlFK has joined #timvideos | 14:25 | |
*** ChanServ sets mode: +v CarlFK | 14:25 | |
*** rohitksingh has joined #timvideos | 14:53 | |
mithro | _florent_: Thanks! | 16:58 |
*** rohitksingh has quit IRC | 17:31 | |
*** samsagaz has joined #timvideos | 19:32 | |
*** CarlFK has quit IRC | 20:02 | |
*** CarlFK has joined #timvideos | 20:39 | |
*** ChanServ sets mode: +v CarlFK | 20:39 | |
*** samsagaz_ has joined #timvideos | 20:52 | |
*** samsagaz has quit IRC | 20:54 | |
*** samsagaz__ has joined #timvideos | 21:45 | |
*** samsagaz_ has quit IRC | 21:47 |
Generated by irclog2html.py 2.13.1 by Marius Gedminas - find it at mg.pov.lt!