Tuesday, 2018-09-11

*** tpb has joined #timvideos00:00
cr1901_modernmithro: I'm working on it...00:14
cr1901_modernAnd I still have to test tinyfpga B2 after this00:15
cr1901_modernI may just add that later if you _really_ need the PR immediately00:16
fitzsimmithro: https://github.com/fitzsim/meta-hdl/tree/hx8k-example00:19
tpbTitle: GitHub - fitzsim/meta-hdl at hx8k-example (at github.com)00:19
fitzsimmithro: I found a recipe for a nice simple HX8K example that I'd written at work00:19
fitzsimmithro: try that with SDKMACHINE=x86_64 MACHINE=qemuarm bitbake uart-transmission00:20
fitzsimmithro: if it works for you I'll send a PR to nrossi00:21
fitzsimmithro: once it's built you can load it with the usual iceprog <bit file>00:22
fitzsimmithro: then interact with it over the HX8K eval board UART00:22
shorneCarlFK[m]: other than changing the drive arguments/setup I think it should be OK.  but I havent really tested it01:12
shornehave you had success?01:12
*** CarlFK has joined #timvideos01:13
*** ChanServ sets mode: +v CarlFK01:13
CarlFKshorne: um... I'm not sure I would say I have tested it, I got lost in trying to get the build script to behave01:24
CarlFKmithro: I fixed the space/tab problem - and have just promised I would walk someone though the howto 'soon'  (days  he has to get an Arty...)01:25
mithroCarlFK: I fixed up your changes and merged them02:28
CarlFKmithro: thank you!02:29
*** CarlFK has quit IRC02:31
*** CarlFK has joined #timvideos02:42
*** ChanServ sets mode: +v CarlFK02:42
mithroB2 != BX?03:03
mithrocr1901_modern: I'm happy for you to just do the BX first03:03
thaytanhiyas03:08
mithrohi thaytan!03:08
thaytanmithro, how are things? :)03:09
mithroBusy :-P03:09
thaytanif you weren't, you'd add another project03:11
mithrothaytan: Ha03:14
mithrothaytan: How's thing in the gstreamer?03:14
thaytanmithro, Busy :)03:16
thaytanGStreamer conference is coming up next month in Edinburgh03:17
mithroI fly to Poland before the end of the month03:17
mithrohttps://orconf.org03:17
tpbTitle: ORConf 2018 (at orconf.org)03:17
thaytanthat is cool03:19
thaytanI wonder if we could branch out and find work that would justify going to that next time :)03:20
mithrothaytan: FPGA multimedia acceleration! :-P03:22
thaytanmithro, I'd love to get a gig doing that :)03:28
CarlFKshorne: qemu builds, but then errors when ./scripts/build-qemu.sh tries to run it: ... does not support the option 'serial'03:44
CarlFKbut we knew that.03:44
CarlFKshorne: tail of script http://paste.ubuntu.com/p/2tmTWqPDkH/03:47
tpbTitle: Ubuntu Pastebin (at paste.ubuntu.com)03:47
mithroFYI - https://elinux.org/images/6/65/An_Overview_of_the_Kernel_DMAEngine_Subsystem.pdf03:58
*** rohitksingh_work has joined #timvideos04:11
*** CarlFK has quit IRC05:16
*** CarlFK has joined #timvideos06:00
*** ChanServ sets mode: +v CarlFK06:00
cr1901_modernGAH, THE FBI HEADER IS KILLING ME06:26
cr1901_modernGNU ld _really_ wants the output to start at the beginning of a memory region, but prepending the checksum and length makes this impossible06:27
xobs?06:27
xobsWhat's the issue?06:27
cr1901_modernI need to increment the location counter in a linker script _without_ the addresses I skipped over being FILLed06:28
xobsLinker scripts are a black art.  I always have trouble getting them right.  And I frequently end up segfaulting ld.06:29
xobsAre you trying to set the location counter to some offset, and have nothing come beforehand?06:30
cr1901_modernScrew it, I'm using a hack (create a dummy output section using ".fbi" and then DISCARD it)06:30
cr1901_modernxobs: Yes06:30
cr1901_modernAnd the approach I just listed will work, but it will emit ELF symbols over the region I skipped.06:30
xobsI doubt this is helpful, but on Chibitronics, applications start at offset 0x5900, and this is the linker script we use: https://github.com/chibitronics/ltc-compiler-layer/blob/master/support/KL02Z32-app.ld06:34
tpbTitle: ltc-compiler-layer/KL02Z32-app.ld at master · chibitronics/ltc-compiler-layer · GitHub (at github.com)06:34
cr1901_modernxobs: https://sourceware.org/binutils/docs/ld/Output-Section-Discarding.html This appears to be the correct method06:43
tpbTitle: LD: Output Section Discarding (at sourceware.org)06:43
cr1901_modernhttp://ix.io/1mrW This being my linker script06:44
*** rohitksingh_work has quit IRC06:47
xobsOh, I see.  You can't define user_flash as being 8 bytes later?06:49
cr1901_modernNo, once I have a non-emtpy section, the 8 bytes will get emitted. So I create an empty section that does nothing except increment the location counter.06:51
xobsI think the approach I usually take is the same as yours, though -- emit symbols to fill in the offending section.06:51
cr1901_modernFrom what I can gather, not all assignments to "." create space in the output file. But an assignment to "." will emit an ELF section with NOBITS type06:52
cr1901_modernxobs: I see, looks like you had the same idea https://github.com/chibitronics/ltc-compiler-layer/blob/master/support/KL02Z32-app.ld#L123-L13107:03
tpbTitle: ltc-compiler-layer/KL02Z32-app.ld at master · chibitronics/ltc-compiler-layer · GitHub (at github.com)07:03
xobsThose were added because I kept segfaulting ld, and discovered the workaround hack was to add those symbols.  They didn't seem to affect the output file at all, and I never found anyone else who was having the same problem.07:04
xobsBut yeah, the discard section was useful to get the compile size down.07:04
xobsFor Chibitronics, the "blink an LED" is mostly 48 bytes of program header, which go at the front of the resulting image, followed by just a few bytes of syscalls.07:05
cr1901_modernGod, getting tinyfpga to work initially is a bunch of hacks T_T. Already 2 FIXMEs07:06
*** rohitksingh_work has joined #timvideos07:07
cr1901_modernGonna have to add a third one to force the use of nextpnr until litex-buildenv has a way to override arguments to plat.build()07:08
xobsThe program header is a C struct that gets populated with values that come from the ld script, such as _data, _edata, and _text.  So your program could have a "struct loader_header { uint32_t crc; uint32_t addr; } attribute((section(".progheader")));" and define one of those in a support library somewhere.07:08
xobsAh, or the way we do it in Tomu is https://github.com/im-tomu/tomu-quickstart/blob/master/include/toboot.h#L10907:10
tpbTitle: tomu-quickstart/toboot.h at master · im-tomu/tomu-quickstart · GitHub (at github.com)07:10
* cr1901_modern still needs to get a Tomu this century07:11
cr1901_modernAaaand arachne-pnr isn't going to route this design, is it?!07:11
* cr1901_modern is grumpy tonight07:11
xobsAnd then we define the .text section (which comes first) as having a SORT, and make sure the toboot header is always first: https://github.com/im-tomu/tomu-quickstart/blob/master/tomu-efm32hg309.ld#L2907:12
tpbTitle: tomu-quickstart/tomu-efm32hg309.ld at master · im-tomu/tomu-quickstart · GitHub (at github.com)07:12
* cr1901_modern strongly suggests adding LITEX_EXTRA_CMDLINE="-Ob use_nextpnr True" to your make command line when using tinyfpga07:20
cr1901_modernxobs: I'll check in a bit when I'm done throwing out all electronic devices from my home07:21
cr1901_moderntinyfpga: If you're awake, could I ask for a HUGE favor?07:33
cr1901_modernActually I'll prob just make a PR07:34
cr1901_modernmithro: https://imgur.com/yx0693L Proof that it works. Cleaning up and sending a PR.07:49
tpbTitle: Imgur: The magic of the Internet (at imgur.com)07:49
*** paddatrapper has quit IRC08:00
*** paddatrapper has joined #timvideos08:10
*** paddatrapper has joined #timvideos08:14
cr1901_modernmithro: https://github.com/timvideos/litex-buildenv/pull/5508:50
tpbTitle: Add TinyFPGA BX Platform by cr1901 · Pull Request #55 · timvideos/litex-buildenv · GitHub (at github.com)08:50
*** twoolie has joined #timvideos09:48
*** Shari2 has joined #timvideos10:09
*** twoolie has quit IRC10:14
*** Shari2 has quit IRC11:11
*** rohitksingh_work has quit IRC12:35
*** twoolie has joined #timvideos13:32
*** rohitksingh has joined #timvideos13:42
*** rohitksingh has quit IRC13:46
*** rohitksingh has joined #timvideos14:06
*** CuriousLearner has quit IRC14:15
*** CuriousLearner has joined #timvideos14:18
*** rohitksingh has quit IRC14:30
*** waldo323 has quit IRC14:31
*** rohitksingh has joined #timvideos14:59
*** waldo323 has joined #timvideos14:59
mithrocr1901_modern: Why is it yellow?15:02
*** waldo323 has quit IRC15:09
*** twoolie has quit IRC15:10
*** CuriousLearner has quit IRC15:15
mithrocr1901_modern: Comments added15:17
*** CuriousLearner has joined #timvideos15:20
*** waldo323 has joined #timvideos15:20
*** rohitksingh has quit IRC15:37
*** CuriousLearner has quit IRC15:40
*** CuriousLearner has joined #timvideos15:43
*** swalladge has quit IRC15:52
*** swalladge has joined #timvideos16:27
CarlFKmithro: do you know about this,  qemu-system-or1k -M litex ...  if=mtd,format=qcow2,file=build/arty_net_or1k//qemu.qcow2,serial=n25q128a13  ...  Block format 'qcow2' does not support the option 'serial'17:01
CarlFKmithro: more context: http://paste.ubuntu.com/p/2PbXpgwknG/17:01
tpbTitle: Ubuntu Pastebin (at paste.ubuntu.com)17:01
CarlFKmithro: thats from new qemu from shornes's repo:  export QEMU_REMOTE=https://github.com/stffrdhrn/qemu.git17:05
tpbTitle: GitHub - stffrdhrn/qemu: Official QEMU mirror. Please see http://wiki.qemu.org/Contribute/SubmitAPatch for how to submit changes to QEMU. Pull Requests are ignored. (at github.com)17:05
mithroCarlFK: dunno - that serial was used to provide the flash chip to emulate -- so maybe the option has just changed names?17:10
CarlFKmithro: something like that - shorne was aware of "it changed" and took a guess at what might work, and id didn't17:12
CarlFKI'll open an issue17:12
*** tac-tics has quit IRC17:29
*** tac-tics has joined #timvideos17:43
cr1901_modernmithro: Idk why it's yellow... prob my terminal application19:26
mithrofitzsim: "NOTE: Tasks Summary: Attempted 500 tasks of which 500 didn't need to be rerun and all succeeded."19:54
*** Kripton has quit IRC20:59
*** Kripton has joined #timvideos21:03
cr1901_modernmithro: https://github.com/timvideos/litex-buildenv/pull/55#discussion_r216706869 What do you mean by this?21:14
tpbTitle: Add TinyFPGA BX Platform by cr1901 · Pull Request #55 · timvideos/litex-buildenv · GitHub (at github.com)21:14
*** tac-tics has quit IRC22:41
mithrocr1901_modern: I mean there should just be switches which modify the template in some way rather than having to override whole template23:04
*** twoolie has joined #timvideos23:10
*** twoolie has quit IRC23:15
*** twoolie has joined #timvideos23:20
*** mauz555 has joined #timvideos23:24
fitzsimmithro: ok, I guess uart-transmission succeeded, then?23:39
fitzsimmithro: it looks like you re-ran it to make sure, but nothing needed to be re-run23:39
fitzsimmithro: that's a great thing about Yocto is that its dependency tracking is probably the best I've seen; it only rebuilds stuff when needed, and it seems to always rebuild everything that needs to be rebuilt23:40
fitzsimin comparison, buildroot seems simpler, but less sophisticated (Makefiles and stamp files) although I've only used buildroot a little bit23:40
cr1901_modernmithro: I don't know how we would inject such options. Additionally, I figured that the whole point of the template is that you can manually override it if needed23:54
cr1901_modernhaving the backend fill in some replacement vars23:54
cr1901_modernmithro: I added #ifdef MAIN_RAM_BASE b/c I got a compile failure w/o it. Will check23:55
*** twoolie has quit IRC23:58
*** mauz555 has quit IRC23:58

Generated by irclog2html.py 2.13.1 by Marius Gedminas - find it at mg.pov.lt!