Tuesday, 2020-06-30

*** tpb has joined #tomu00:00
*** st-gourichon-f has joined #tomu00:03
*** st-gourichon-fid has quit IRC00:04
xobsacathla: the wishbone-tool error looks like it's unable to open the device, or possibly it's not receiving the expected response (i.e. the target device doesn't have a debug bridge).02:22
xobsBlinking red usually means the CPU crashed, which means it didn't find the byte-order marker on the top of the flash image.02:22
*** guan has quit IRC02:36
*** mithro has quit IRC02:37
*** mithro has joined #tomu02:38
*** guan has joined #tomu02:41
*** emeb has quit IRC03:59
CarlFKxobs: I told someone about betrusted "verifiable hardware" , response: "does that mean we can have voting machines we can trust?"04:51
xobsVoting is hard :-/04:52
CarlFKim sure you are up to it04:52
CarlFKonce you betrusted is done, maybe make a larger thing that is a little more general purpose04:54
Toba__voting should be done on paper05:31
*** squelch has joined #tomu05:31
CarlFKwhat do you think of a machine that prints out your ballet, and the human readable print out is later scanned?05:32
Toba__i would have more thoughts if it wasn't half past midnight05:32
Toba__im gonna go sleep05:32
CarlFKheh05:32
CarlFKsee ya05:33
*** st-gouri- has joined #tomu06:47
*** st-gourichon-f has quit IRC06:50
*** lucab has quit IRC08:38
*** leons has quit IRC08:38
*** promach3 has quit IRC08:38
*** jimt[m] has quit IRC08:38
*** nurelin has quit IRC08:38
*** david-sawatzke[m has quit IRC08:38
*** john_k[m] has quit IRC08:38
*** xobs has quit IRC08:38
*** john_k[m] has joined #tomu08:49
*** david-sawatzke[m has joined #tomu08:57
*** lucab has joined #tomu08:57
*** nurelin has joined #tomu08:57
*** xobs has joined #tomu08:57
*** jimt[m] has joined #tomu08:57
*** promach3 has joined #tomu08:57
*** leons has joined #tomu08:57
acathlaxobs, what's the command-line used to build the released foboot? --revision pvt and --with-debug usb only?09:20
xobsacathla: correct, adding --seed as necessary09:21
acathlaok, thank you. Still no way to do faster build using multiple cores?09:22
*** im-tomu has quit IRC11:37
acathlawishbone-tool seems to work now. xobs, any idea on how to debug the upload with dfu-util? How can I test the usb quality maybe?11:40
xobsacathla: `wishbone-tool -s random-test` will write random data to RAM and read it back. If the connection is flaky, data will come back with an error.11:41
acathlaOh, nice. Communication seems fine...11:44
xobsAre you uploading a riscv binary or an FPGA bitstream?11:48
*** im-tomu has joined #tomu11:52
*** im-tomu has quit IRC11:56
*** im-tomu has joined #tomu12:24
acathlaxobs, I tried anything, it always end with a usb disconnection and red blinking LED12:30
xobsEven `riscv-blink`? https://github.com/im-tomu/fomu-workshop/blob/master/riscv-blink/src/main.c12:31
tpbTitle: fomu-workshop/main.c at master · im-tomu/fomu-workshop · GitHub (at github.com)12:31
xobs(Note: That actually installs a USB driver that means it should still enumerate)12:31
acathlaxobs, yes even riscv-blink fails12:35
acathlaI had to expand the top-multiboot.bin to 2MB to program the flash with flashrom, so I added zeros, I hope it's ok.12:36
xobsOh, so this isn't on Fomu, it's on something else?12:37
acathlaYes, sorry. It's a PCB with almost the same things as on fomu EVT12:40
xobsAre you sure the flash is getting written? You can poke around with `wishbone-tool`. I believe it should be at address 0x20040000 (but don't quote me on that)12:41
acathlaDoes dfu-util always write to the flash? FPGA bitstream and riscv binary?12:43
xobs`dfu-util` always writes to the flash.12:43
xobsIt will write whatever you give it -- riscv binary or FPGA bitstream.12:44
xobsThe bootloader determines which it is by looking for the bitstream sync bytes to determine if it's an FPGA bitstream, and assumes it's a binary if it can't find it.12:44
acathlaOk12:44
xobsSince it's blinking red, that means it hasn't determined it's a bitstream.12:44
xobsWhich, if it can't write the flash, could be the source of your problems.12:44
xobsThat might happen if, for example, you have quad mode disabled (which is the default) and the WP/ pin is... high?12:45
acathlaHum, IO2 and IO3 are defined in the platform, I guessed it's handled somewhere...12:48
xobsYou definitely should see if data's actually getting written.12:49
acathlaValue at 20040000: eeeeeeee12:49
acathlanot good12:49
xobsI seem to recall the default SPI device actually gangs all four outputs together.12:49
xobsSo one workaround would be to enable quad mode for your chip.12:50
xobsFomu has that done in the factory as part of the test, so we don't need to check for it on the device.12:50
acathlainout wire [3:0] spiflash4x_dq in top.v, does it means quad_spi is enabled?12:52
xobsIt means it's using a quad-enabled SPI block.12:52
xobsBut your SPI flash chip needs to have quad mode enabled.12:52
acathlaah, in the fuses?12:53
acathlaI read that somewhere12:53
xobsYep12:53
acathlaI'm still reading eeeeeee but it seems to work !14:28
*** emeb has joined #tomu15:48
*** CarlFK has quit IRC16:04
*** CarlFK has joined #tomu16:16
st-gouri-Hi there! Have some difficuly sending "bulk" data (say, 100kb) through litex_server to a wishbone-based UART.16:31
st-gouri-To be clearer, PC communicates through a 3-wire UART to the design.  We target registers that drive a second UART to some other device.16:32
st-gouri-We could not find clear documentation.  First, we could not read any byte received by the second UART until we did self._wb.regs.uart_ev_pending.write(2) where 2 is a magic value found in litex/litex/soc/software/include/hw/flags.h16:34
st-gouri-We're accessing the wishbone bus of the design from a Python program on our PC.16:36
xobsYou might get more help in #litex.16:37
xobsHowever, you may also want to generate the documentation for your design.16:37
xobsFor example, the UART we use in Betrusted looks like https://ci.betrusted.io/betrusted-soc/doc/uart.html16:38
tpbTitle: UART LiteX SoC Project documentation (at ci.betrusted.io)16:38
st-gouri-xobs, thanks for writing. Looking at links.16:38
xobs(Also, it's late here and I'm about ready to log off, sorry)16:38
st-gouri-okay, thanks all the more.16:39
st-gouri-That does shine some light.16:39
st-gouri-Confirms hypotheses.16:39
xobsAlso also, if you're doing wishbone debugging stuff, you may want to look at wishbone-tool (https://github.com/litex-hub/wishbone-utils/releases/latest) which might give you more options on working with wishbone.16:39
tpbTitle: Release v0.7.3 · litex-hub/wishbone-utils · GitHub (at github.com)16:39
st-gouri-We need to implement some protocol.  Looks like Rust savvyness required?16:40
st-gouri-xobs, where on earth are you? Eastern Europe?16:41
*** ppisati has quit IRC16:42
st-gouri-Ahah! Using libeb-c from C may be a good option! Thanks xobs.16:44
*** squelch has quit IRC17:21
*** wrtlprnft has quit IRC18:20
*** wrtlprnft has joined #tomu18:21
*** craigo has joined #tomu19:32
*** craigo has quit IRC20:01
*** ukembedded has quit IRC21:15
*** daveshah has quit IRC21:15
*** ukembedded has joined #tomu21:15
*** daveshah has joined #tomu21:15
*** js has quit IRC22:10
*** squelch has joined #tomu22:23
*** st-gouri- has quit IRC22:42
*** squelch has quit IRC23:00
*** squelch has joined #tomu23:01

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