*** tpb has joined #yosys | 00:00 | |
*** emeb has quit IRC | 00:01 | |
*** futarisIRCcloud has joined #yosys | 00:29 | |
*** _whitelogger has quit IRC | 00:44 | |
*** _whitelogger has joined #yosys | 00:46 | |
*** cr1901_modern has quit IRC | 01:40 | |
*** Laksen has quit IRC | 01:44 | |
*** gsi__ has joined #yosys | 02:14 | |
*** gsi_ has quit IRC | 02:17 | |
*** PyroPeter has joined #yosys | 03:08 | |
*** MoeIcenowy has quit IRC | 04:25 | |
*** MoeIcenowy has joined #yosys | 04:25 | |
*** futarisIRCcloud has quit IRC | 04:49 | |
*** vonnieda has joined #yosys | 04:55 | |
*** rohitksingh has joined #yosys | 05:06 | |
*** rohitksingh has quit IRC | 05:16 | |
*** futarisIRCcloud has joined #yosys | 05:23 | |
*** rohitksingh_work has joined #yosys | 05:28 | |
*** gsi__ is now known as gsi_ | 05:55 | |
*** alexhw has quit IRC | 06:01 | |
*** alexhw has joined #yosys | 06:09 | |
*** MoeIcenowy has quit IRC | 06:19 | |
*** MoeIcenowy has joined #yosys | 06:19 | |
*** Jybz has joined #yosys | 06:29 | |
*** Jybz has quit IRC | 06:32 | |
*** proteusguy has joined #yosys | 07:04 | |
*** proteusguy has quit IRC | 07:08 | |
*** flaviusb has quit IRC | 07:08 | |
*** m4ssi has joined #yosys | 07:20 | |
*** proteusguy has joined #yosys | 07:20 | |
*** jevinskie has joined #yosys | 07:22 | |
*** _whitelogger has quit IRC | 07:29 | |
*** _whitelogger has joined #yosys | 07:31 | |
*** Jybz has joined #yosys | 07:35 | |
*** rohitksingh has joined #yosys | 07:39 | |
*** rohitksingh_work has quit IRC | 07:44 | |
*** rohitksingh_work has joined #yosys | 07:46 | |
*** promach has quit IRC | 07:48 | |
*** rohitksingh has quit IRC | 07:49 | |
*** rohitksingh has joined #yosys | 07:50 | |
*** promach has joined #yosys | 07:52 | |
*** plaes has joined #yosys | 07:56 | |
*** rohitksingh has quit IRC | 08:03 | |
*** emeb_mac has quit IRC | 08:11 | |
plaes | any idea whether there are boards that support muxing two hdmi streams into single one that also support open tools? | 08:15 |
---|---|---|
*** fsasm has joined #yosys | 08:18 | |
tnt | plaes: don't think so. Only working open tools are ice40 and ecp5 (I mean those with enough maturity to go from .v to bitstream for that kind of non-toy project). ice40 is way too small for that. And I have not seen any ecp5 board with 2 hmdi in and 1 hdmi out. | 08:19 |
plaes | ok, quick googling gave me Numato Opsis (with Spartan-6) and NeTV2 (with Artix-7 but not yet readily available) | 08:28 |
tnt | yup those would have been my recommendations if you didn't require open tools. | 08:30 |
tnt | but the netv2 is available afaik. | 08:30 |
tnt | crowdsupply shows it "in stock". | 08:31 |
plaes | hmm.. cool | 08:33 |
tnt | I'd go with the netv2. | 08:35 |
*** proteusguy has quit IRC | 08:35 | |
*** vid has joined #yosys | 08:42 | |
plaes | ooh.. Project X-Ray | 08:43 |
*** fsasm has quit IRC | 09:04 | |
*** proteusguy has joined #yosys | 09:14 | |
*** unkraut has quit IRC | 10:37 | |
*** vid has quit IRC | 10:47 | |
*** MoeIcenowy has quit IRC | 11:02 | |
*** MoeIcenowy has joined #yosys | 11:03 | |
*** fsasm has joined #yosys | 11:29 | |
*** citypw has joined #yosys | 11:34 | |
*** vid has joined #yosys | 12:56 | |
*** citypw has quit IRC | 12:57 | |
*** vid has quit IRC | 13:18 | |
*** vid has joined #yosys | 13:21 | |
*** citypw has joined #yosys | 13:44 | |
*** unkraut has joined #yosys | 13:44 | |
*** vonnieda has quit IRC | 13:45 | |
*** rohitksingh_work has quit IRC | 13:50 | |
*** vonnieda has joined #yosys | 13:59 | |
*** citypw has quit IRC | 14:48 | |
*** rohitksingh has joined #yosys | 15:04 | |
*** rohitksingh has quit IRC | 15:33 | |
*** fsasm has quit IRC | 15:42 | |
*** rohitksingh has joined #yosys | 15:53 | |
*** Cerpin has quit IRC | 15:57 | |
*** Cerpin has joined #yosys | 15:57 | |
*** futarisIRCcloud has quit IRC | 15:59 | |
*** emeb has joined #yosys | 16:13 | |
*** Laksen has joined #yosys | 16:25 | |
*** Cerpin has quit IRC | 16:33 | |
*** m4ssi has quit IRC | 16:35 | |
*** Cerpin has joined #yosys | 16:45 | |
*** Postmanmods has joined #yosys | 16:46 | |
Postmanmods | Hi everyone! I have a question about yosys synthesis process vs the icecube process... Have been banging my head against this for a while now and can't seem to find a solid answer. | 16:47 |
Postmanmods | I have a verilog program that synthesizes in yosys in about 20 seconds and works fine on my ice40hx1k but takes ~3 hours to synthesize and uses 10,000% of my allocated LUTs on icecube2! What am I missing? | 16:48 |
tnt | Postmanmods: you're probably relying on it to infer a RAM | 16:51 |
tnt | and inferring stuff ... is ... unreliable depending on what the tool support. | 16:51 |
Postmanmods | Bear with me as I am dipping me feet into FPGA for the first time with this project I have undertaken. | 16:52 |
tnt | post your verilog somewhere | 16:52 |
Postmanmods | kk just a sec... It has a lot of nested if statements which I hear is a big no no in verilog. | 16:53 |
ZipCPU | Could also be the result of a multiply within the code as well. | 16:56 |
Postmanmods | https://pastebin.com/FuUuds9P | 16:56 |
tpb | Title: `default_nettype none disable implicit definitions by Verilog //apio build --si - Pastebin.com (at pastebin.com) | 16:56 |
Postmanmods | It's... Rough... I know. First verilog project that I cobbled together. | 16:57 |
*** Jybz has quit IRC | 16:57 | |
*** Jybz has joined #yosys | 16:57 | |
ZipCPU | Ok, lines 49 and 54 or a problem ... | 16:57 |
*** Jybz has quit IRC | 16:58 | |
*** Jybz has joined #yosys | 16:58 | |
ZipCPU | Check out the block RAM rules in http://zipcpu.com/tutorial/lsn-08-memory.pdf | 16:59 |
Postmanmods | Will do. Is it an issue with my code or the way I configured the synthesis? | 17:00 |
tnt | ZipCPU: why ? | 17:00 |
ZipCPU | In particular, your design breaks rule #3--and so yosys cannot manage to turn it into a RAM | 17:00 |
ZipCPU | tnt: His design cannot map to the iCE40 hardware as written | 17:00 |
tnt | ZipCPU: yosys works fine, icecuble doens't AFAIU | 17:00 |
ZipCPU | Heheh ... yosys has some fun little clean up pieces of logic that not all of the big synthesizers support | 17:01 |
Postmanmods | Yeah, that's what I am trying to reconcile. The code compiles and works perfectly from spi flash. | 17:01 |
Postmanmods | Grrrr, thats what I figured! | 17:02 |
ZipCPU | You could make the #46-60 block work if you calculated the memory address combinatorially | 17:02 |
tnt | ZipCPU: I don't see why it couldn't map. A mux on the write address input to switch between 0 and waddr would work fine. | 17:02 |
ZipCPU | Yes, exactly--yosys does that, but many vendor synthesis tools will not | 17:02 |
ZipCPU | Many of the vendor synthesis tools are *really* strict when about what logic will infer block rams and which logic will not | 17:03 |
tnt | Sorry I misunderstood, I thought you said there was no way to produce logic what would implement that behavior. | 17:03 |
Postmanmods | So I have a second question, this one about NVCM. | 17:03 |
ZipCPU | tnt: I did say that, didn't I? But if it works in yosys and not the vendor tool, then that can't be it. | 17:04 |
* ZipCPU google's NVCM, gets: "Noe Valley Chamber Music" | 17:04 | |
Postmanmods | LOL | 17:04 |
tnt | Well " His design cannot map to the iCE40 hardware as written" ... I understand this as there is not theoritical way you could map that verilog to an ice40 design that implements it. | 17:04 |
* ZipCPU tries duck duck go, gets "New Vision Christian Ministries" | 17:04 | |
Postmanmods | 2x LOL | 17:05 |
tnt | Non Volatile Configuration Memory | 17:05 |
ZipCPU | tnt: Yes. That's usually what's going wrong, but ... not in this case. (i.e. I was wrong. Oops) | 17:05 |
Postmanmods | Non Volatile Configurable Memory, for one time flashing | 17:05 |
Postmanmods | *configuration | 17:05 |
* ZipCPU needs to step away ... | 17:05 | |
tnt | what about it ? | 17:06 |
Postmanmods | Is it possible to generate a nvcm bitmap from yosys for an ice40? | 17:06 |
Postmanmods | Or is that a vendor app only thing? | 17:07 |
tnt | is the nvcm bitmap different from the normal bitmap ? | 17:07 |
Postmanmods | I think? One sec, lemme double check. | 17:08 |
Postmanmods | Oh jeeze, they might be the same. Lemme post a .nvcm file for reference. | 17:09 |
*** vid has quit IRC | 17:10 | |
Postmanmods | Real quick, thank you sincerely. Learning FPGA is one HELL of a steep learning curve. | 17:10 |
Postmanmods | https://pastebin.com/X74NSVDd | 17:10 |
tpb | Title: #DF 4-15-2019 #DC 512a #SR 2017.08.27940 #DN iCE40HX8K #PT CT256 #HF 01 06 - Pastebin.com (at pastebin.com) | 17:10 |
*** rohitksingh has quit IRC | 17:20 | |
*** vid has joined #yosys | 17:22 | |
ZipCPU | tnt: The reason for my earlier answer was that I've been burned several times over by the fact that the iCE40 hardware requires that the output of any memory read be registered. I was a bit hasty, before looking at the code, to conclude that was the problem since it's a common ice40 problem that you have when porting "working" designs to the iCE40 | 17:28 |
ZipCPU | Postmanmods: I'm not sure I know the answer to that one. I've never successfully loaded an iCE40 from flash, more from a lack of trying than anything else | 17:29 |
*** vid has quit IRC | 17:30 | |
tnt | ZipCPU: heh no worries. I actually misread you answer, I read "I didn't say that did I" instead of "I did say that, didn't I" :p so I guess we both read too quickly. | 17:34 |
ZipCPU | Sometimes I think it's a trait of a "good" engineer. :D | 17:35 |
*** rohitksingh has joined #yosys | 17:36 | |
tnt | The 'reset to 0' of the read register is also a common reason bram mapping fails. | 17:36 |
tnt | In general I put all my inferred logic in a separate module with just that in it to try and make it as easy as possible for the tool to notice. | 17:37 |
tnt | But icecube is really dumb ... I mean even a non-power of 2 memory depth prvents mapping. | 17:37 |
emeb | I've noticed that too. | 17:37 |
Postmanmods | Ok so its most likely a case of lattice's sorftware being picky. | 17:40 |
Postmanmods | So that means a code clean up if I want a well optimized bitstream? | 17:40 |
emeb | AFAIK the NVCM on iCE40 is programmed with the same bitstream format you'd load into the RAM directly, or into external SPI flash. But iceprog doesn't seem to support talking to the NVCM and I've heard that there's some sort of special unlock sequence needed to access it. | 17:41 |
emeb | All that, plus the fact that it's OTP and I've avoided it. | 17:41 |
tnt | Someone just needs to sniff and document it ... | 17:42 |
*** Ultrasauce has quit IRC | 17:42 | |
Postmanmods | I actually jimmy rigged an ice40 with an rs2232 to interface with the spi. Diamond programmer actually sees it and writes the CRAM! | 17:42 |
Postmanmods | Better than paying $200 for Lattice's overpriced POS... | 17:43 |
tnt | you mean ft2232 ? | 17:43 |
*** Ultrasauce has joined #yosys | 17:43 | |
Postmanmods | Oh thank you,yes. | 17:43 |
Postmanmods | Not serial lol | 17:43 |
Postmanmods | I'll let you guys know what I find in my NVCM adventures. It would be really helpful for to use for some applications. | 17:47 |
emeb | Cool. | 17:48 |
emeb | It would be great for a default bootloader | 17:48 |
emeb | and of course for low-cost / high volume stuff that's not expected to change. But who in this space ever does that? :) | 17:48 |
tnt | emeb: unfortunately if NVCM is enable WARMBOOT doesn't work :/ | 17:50 |
emeb | tnt: ouch! missed that detail. | 17:51 |
tnt | yeah :/ | 17:52 |
*** Cerpin has quit IRC | 17:55 | |
*** Cerpin has joined #yosys | 17:56 | |
emeb | So if the NVCM is enabled you can't use external SPI flash - only option is slave configuration. | 17:58 |
*** rohitksingh has quit IRC | 17:59 | |
*** rohitksingh has joined #yosys | 17:59 | |
*** vid has joined #yosys | 18:05 | |
emeb | Interesting reading about Cold Boot mode - wondering how the device differentiates between an external SPI flash that has the "Cold/Warm Boot applet" and one that's just raw bitstream. | 18:08 |
emeb | must be some reserved bits in the start of the bitstream... | 18:08 |
Postmanmods | No no, I was reading about a dual boot feature... Can't back that up with a source rn but I think it may be possible. | 18:15 |
Postmanmods | It is also an option in the Diamond programmer utility so there's that too. | 18:15 |
tnt | SB_WARMBOOT and the multiboot header. | 18:15 |
Postmanmods | Ah, right | 18:16 |
tnt | you can specify 5 images in a header at the beginning of flash. First one is the one loaded by default. Then via the warmboot primitive the design inside the fpga can trigger a reload of any of the 4 other images. | 18:16 |
Postmanmods | No documentation on that in my findings unfortunetly /: | 18:16 |
Postmanmods | Dang... That would be so nice for prototyping. | 18:17 |
Postmanmods | Have a polished design in the nvcm and rough code on the flash | 18:17 |
tnt | example : https://github.com/smunaut/ice40-playground/blob/usb-test/projects/boot_stub/utils/mkmultiboot.py | 18:17 |
tpb | Title: ice40-playground/mkmultiboot.py at usb-test · smunaut/ice40-playground · GitHub (at github.com) | 18:17 |
Postmanmods | Oh nice | 18:18 |
Postmanmods | so these are python scripts for this dev board? | 18:19 |
Postmanmods | Err, any dev board rather. | 18:19 |
tnt | well (1) it's mostly verilog, there are a few python helpers (2) with changes to the pcf you can make it work on many ice40 boards. | 18:19 |
tnt | this whole repo is just where I put my ice40 stuff so I can easily share the 'reusable' cores between projects. | 18:20 |
*** jevinskie has quit IRC | 18:22 | |
Postmanmods | Cool! Thanks for the resource, I will poke at it when I get a chance. Should be fun. | 18:25 |
*** adjtm has quit IRC | 18:29 | |
*** adjtm has joined #yosys | 18:30 | |
*** jevinskie has joined #yosys | 18:36 | |
*** jevinskie has quit IRC | 18:39 | |
*** rohitksingh has quit IRC | 19:11 | |
*** pie___ has joined #yosys | 19:16 | |
*** vid has quit IRC | 19:18 | |
*** indy_ has joined #yosys | 19:20 | |
*** Jybz has quit IRC | 19:31 | |
*** Cerpin has quit IRC | 20:29 | |
*** Cerpin has joined #yosys | 20:39 | |
*** vonnieda has quit IRC | 22:53 | |
*** futarisIRCcloud has joined #yosys | 23:31 | |
Postmanmods | ZipCPU IT WORKED! | 23:33 |
Postmanmods | @ZipCPU | 23:33 |
Postmanmods | https://imgur.com/a/Sq5Eoc2 | 23:33 |
tpb | Title: Imgur: The magic of the Internet (at imgur.com) | 23:33 |
Postmanmods | Did I tag him correctly? Still used to discord. | 23:34 |
Postmanmods | But you were correct, it was a blocking issue. Thank you so much for the advice, I spent an embarrassing amount of time on that... | 23:34 |
*** Laksen has quit IRC | 23:47 | |
ZipCPU | Wha .. wha .. what happened! Did it work? | 23:51 |
ZipCPU | Postmanmods: Did I miss something? | 23:52 |
Postmanmods | Oh, the link you sent me | 23:55 |
ZipCPU | Did that help? | 23:55 |
Postmanmods | It turned out my issue was exactly what you said! I rewrote the blocking for the memory I/O and BOOM. Synthesized in icecube2 in 60 seconds flat with 30% LUT usage! :D | 23:56 |
Postmanmods | Thank you so much, I could not understand why it was having such issue. You made my week man. | 23:57 |
ZipCPU | Awesome! | 23:57 |
Postmanmods | So you have a website with other resources like that? | 23:57 |
ZipCPU | There's a lot of really useful information in those tutorial slides. You can find all of them from http://zipcpu.com/tutorial | 23:57 |
tpb | Title: Verilog, Formal Verification and Verilator Beginner's Tutorial (at zipcpu.com) | 23:57 |
ZipCPU | I've tested many of the designs on iCE40s too--although I have left some errors behind in most cases for you to find ;) | 23:58 |
Postmanmods | I love the tuts, concise and to the point with examples. | 23:58 |
ZipCPU | Thank you | 23:58 |
Postmanmods | haha wonderful, debugging the tutorials code. Great way to learn! | 23:58 |
ZipCPU | Well, isn't it? | 23:59 |
ZipCPU | The last statistic I learned suggested you'd spend 30% writing your code, and 70% making sure it works | 23:59 |
ZipCPU | If you are going to spend that much time getting it to work, shouldn't instruction be focused on that part of the design process? | 23:59 |
ZipCPU | ... or at least that was my thinking when putting the slides together | 23:59 |
Postmanmods | Since I started learning about FPGA's I haven't really found any solid resources. Even the manufacturers info is meh at best. | 23:59 |
Generated by irclog2html.py 2.13.1 by Marius Gedminas - find it at mg.pov.lt!