| _florent_ | Hi! | 09:35 |
|---|---|---|
| _florent_ | I have some questions / suggestions about Migen | 09:36 |
| _florent_ | for some modules, I want to be able to pass all in/out signals directly in parameters | 09:36 |
| _florent_ | but I also want to be able to use those modules with only some of the parameters | 09:37 |
| _florent_ | and that the others use their default values. (ie reset values) | 09:37 |
| _florent_ | for example on this code: http://pastebin.com/Dk1vBmUi | 09:37 |
| _florent_ | I'm using an ifthenelse function to declare the signal if it is not passed on parameters | 09:38 |
| _florent_ | but I don't find it very elegant... | 09:38 |
| _florent_ | lekernel: do you have suggestions to improve that? I was thinking of adding an optionnal parameter to Signal class: | 09:39 |
| _florent_ | self.c = ifthenelse(c, c, Signal()) | 09:39 |
| _florent_ | can become: | 09:39 |
| _florent_ | self.c = Signal(from=c) (from is maybe not appropriated). | 09:40 |
| _florent_ | if from is not None: self.c = from | 09:40 |
| _florent_ | if from is None we created a new signal. | 09:40 |
| _florent_ | but I'm not sure you'll find that more elegant ;) | 09:40 |
| lekernel | how about always declaring signals in the module, eg self.c = Signal() | 09:40 |
| lekernel | instead of passing them as parameters | 09:41 |
| lekernel | then you use object_instance.c in other statements? | 09:41 |
| _florent_ | because for some case it is interesting to directly pass in in parameter | 09:41 |
| _florent_ | for example for the oddr: | 09:42 |
| _florent_ | I only need this line | 09:42 |
| _florent_ | self.submodules.oddr = oddr.ODDR(c=self.clk, d1=1, d2=0, q=self.hdmi_clk) | 09:42 |
| _florent_ | if not passed in parameter I will need to affect each signal manually | 09:43 |
| lekernel | you can do | 09:44 |
| lekernel | if c is None: c = Signal() | 09:44 |
| lekernel | self.c = c | 09:44 |
| lekernel | or - how about using Instance("ODDR", ...) directly? feels a bit weird to have a ODDR module with just a ODDR instance | 09:45 |
| _florent_ | just because I have created some xilinx primitive module | 09:46 |
| lekernel | I'd rather use the Instance directly every time... | 09:46 |
| lekernel | keep it simple | 09:46 |
| _florent_ | hmm... yes but no :) | 09:47 |
| _florent_ | this is simple for the oddr | 09:47 |
| _florent_ | but for the plle2_base for example | 09:47 |
| _florent_ | it's easier to have a class than to use the Instance each time | 09:48 |
| _florent_ | in this module: | 09:48 |
| _florent_ | http://github.com/Florent-Kermarrec/milkymist-ng-kc705/blob/master/milkymist/kc705crg/__init__.py | 09:48 |
| _florent_ | the plle2_base is done in 8 lines | 09:49 |
| lekernel | how about using a function, instead? | 09:49 |
| lekernel | self.specials += plle2_base(...) | 09:50 |
| lekernel | and plle2_base returns Instance | 09:50 |
| lekernel | then we can handle None in the Instance IOs | 09:50 |
| lekernel | eg treat it as 0 for inputs and disconnected for outputs | 09:51 |
| _florent_ | yes why not, it will be almost the same since in the module I'm only instanciating the verilog | 09:51 |
| lekernel | if you want to pass a different default you can use eg Instance.Input("port", value or 2) | 09:51 |
| _florent_ | yes, can be interesting | 09:52 |
| lekernel | I'd like to keep the Modules with IO signals as members... | 09:53 |
| _florent_ | In fact I was having an issue with my code: | 09:53 |
| _florent_ | when I was using self.submodules.oddr = oddr.ODDR(c=self.clk, d1=1, d2=0, q=self.hdmi_clk) | 09:53 |
| _florent_ | I want that ce, s and r use their default values which is not the case. | 09:53 |
| _florent_ | In verilog.py in the printinit function, the instances input are not initialized | 09:54 |
| _florent_ | but it's maybe something that would be solved with what you suggested | 09:55 |
| lekernel | ah, that's a bug | 09:56 |
| lekernel | but I'm actually refactoring that code right now, and that problem should be solved | 09:56 |
| lekernel | and yes the function option would resolve this as well | 09:56 |
| _florent_ | ok so I will try to change my module to functions | 09:58 |
| lekernel | the original bug that refactoring was supposed to solve is you cannot use Array() in Instance expressions | 09:58 |
| _florent_ | ok | 09:59 |
| lekernel | so you doing the HDMI out? | 10:00 |
| _florent_ | thanks for the advices | 10:00 |
| _florent_ | i'm trying to use the ADV7511 on the KC705 | 10:00 |
| lekernel | maybe you should put all the functions in a single Python module, so you don't have too many imports and files | 10:01 |
| _florent_ | but it's not working for the moment | 10:01 |
| lekernel | ah | 10:01 |
| _florent_ | I have to do simulation | 10:01 |
| lekernel | I wonder why they added that chip | 10:01 |
| lekernel | kintex 7 io can do TMDS, no? | 10:01 |
| lekernel | maybe for 225MHz (2250Gbps data rate, iirc k7 can only do 1800)? I wonder why FPGA vendors only seem to be able to make only slow IOs, even in 28nm devices :( | 10:03 |
| _florent_ | I don't know about TDMS on kintex7 | 10:03 |
| lekernel | s/Gbps/Mbps | 10:03 |
| _florent_ | yes I remember that for the DDR the IOs were limited to 1800 or 1600 | 10:04 |
| _florent_ | for the moment I'm trying to figure how to configure the ADV7511... don't seems to be easy | 10:05 |
| _florent_ | but that's a spare time project so I'm not going very fast... | 10:06 |
| lekernel | how about hooking up a HDMI cable to the IO expansion header and driving TMDS directly? | 10:06 |
| lekernel | this way you don't depend on some proprietary chip | 10:06 |
| _florent_ | I'm waiting for your HDMI extension to work and after that why not ;) ! | 10:07 |
| lekernel | DVI signaling is a mere 8b10b encoding of the VGA samples | 10:07 |
| lekernel | I'm doing a HDMI receiver... there won't be much, if anything, in common | 10:08 |
| _florent_ | ah ok | 10:08 |
| _florent_ | I was thinking i was doing both | 10:08 |
| _florent_ | after the ADV7511 configuration I will need a ddr controller... | 10:10 |
| _florent_ | but it will be another story | 10:10 |
| lekernel | you can try it with a generated pattern first | 10:10 |
| _florent_ | yes that what I'm planning to do | 10:11 |
| lekernel | my first vga-out was on a cyclone 2 with no sdram and not even a dac :) just used a few resistors | 10:11 |
| _florent_ | the same for me on a altera de1 | 10:12 |
| _florent_ | I have to return to work.. | 10:13 |
| _florent_ | thanks for the advices | 10:13 |
| _florent_ | I will try to use function instead of Module | 10:13 |
| _florent_ | bye | 10:13 |
| lekernel | bye! | 10:14 |
| larsc | lekernel: the chip was added so we can sell it of course ;) | 12:28 |
| lekernel | yeah I picked that up... | 12:28 |
| larsc | but the same is on all the xilinx boards | 12:28 |
| lekernel | same for the tmds chip on the atlys I guess | 12:28 |
| lekernel | but from TI this time | 12:28 |
| larsc | they used TI before but switched to AD for all the newer boards | 12:29 |
| lekernel | at least it has a purpose on the kc705: compensate a bit for the super-slow FPGA IOBs | 12:29 |
| lekernel | on the atlys it's completely useless afaict | 12:29 |
| lekernel | it provides some electrical protection for the FPGA, but you could do the same with TVS diodes | 12:30 |
| larsc | got a sick-note for the next two weeks, so lots of time for migen hacking ;) | 12:34 |
| Fallenou | :) | 12:41 |
| lekernel | hahaha | 12:43 |
| lekernel | btw it would be great to get migen presented at http://www.ohwr.org/projects/ohr-meta/wiki/OHW2013 - I'm very far from SF at that date (30+ hrs air travel) :/ | 12:43 |
| lekernel | I can contribute to the travel costs if that helps... | 12:47 |
| Fallenou | if they pay for the ride it can help to make up someone's mind :) | 12:47 |
| Fallenou | have you asked Florent K. ? | 12:48 |
| lekernel | not yet | 12:49 |
| GitHub117 | [migen] sbourdeauducq pushed 2 new commits to master: http://git.io/xP7vPA | 13:39 |
| GitHub117 | migen/master e95d2f4 Sebastien Bourdeauducq: fhdl/tools/value_bits_sign: support not | 13:39 |
| GitHub117 | migen/master dc55289 Sebastien Bourdeauducq: fhdl/tools/_ArrayLowerer: complete support for arrays as targets | 13:39 |
| GitHub50 | [milkymist-ng] sbourdeauducq pushed 5 new commits to master: http://git.io/Npb_1A | 18:03 |
| GitHub50 | milkymist-ng/master 3a0cf27 Sebastien Bourdeauducq: dvisampler: fixes | 18:03 |
| GitHub50 | milkymist-ng/master 621526f Sebastien Bourdeauducq: dvisampler/datacapture: fix tap counter reg | 18:03 |
| GitHub50 | milkymist-ng/master 74cc045 Sebastien Bourdeauducq: dvisampler/datacapture: connect IODELAY IOCLK0 | 18:03 |
| GitHub122 | [mibuild] sbourdeauducq pushed 1 new commit to master: http://git.io/0Lkxhw | 18:03 |
| GitHub122 | mibuild/master 797411c Sebastien Bourdeauducq: generic_platform: do not create clock domains during Verilog conversion | 18:03 |
| GitHub140 | [migen] sbourdeauducq pushed 3 new commits to master: http://git.io/GpZiPg | 18:03 |
| GitHub140 | migen/master 7a06e94 Sebastien Bourdeauducq: Lowering of Special expressions + support ClockSignal/ResetSignal | 18:03 |
| GitHub140 | migen/master af4eb02 Sebastien Bourdeauducq: examples/basic/arrays: demonstrate lowering of Array in Instance expression | 18:03 |
| GitHub140 | migen/master 17f2b17 Sebastien Bourdeauducq: fhdl/verilog: optionally disable clock domain creation | 18:03 |
| GitHub168 | [milkymist-ng] sbourdeauducq pushed 1 new commit to master: http://git.io/KIitRQ | 18:04 |
| GitHub168 | milkymist-ng/master 5126f61 Sebastien Bourdeauducq: dvisampler: use pix5x as IODELAY clock | 18:04 |
| GitHub73 | [qemu] mwalle created for-upstream (+607 new commits): https://github.com/mwalle/qemu/compare/40475087a5ee^...b1e5fff4afd0 | 18:45 |
| GitHub73 | qemu/for-upstream 4047508 Paolo Bonzini: test-i386: QEMU_PACKED is not defined here... | 18:45 |
| GitHub73 | qemu/for-upstream 1b99f83 Paolo Bonzini: test-i386: make it compile with a recent gcc... | 18:45 |
| GitHub73 | qemu/for-upstream 93ab25d Paolo Bonzini: target-i386: use OT_* consistently... | 18:45 |
| GitHub166 | [milkymist-ng] sbourdeauducq pushed 1 new commit to master: http://git.io/MB6nUQ | 19:33 |
| GitHub166 | milkymist-ng/master 28cb970 Sebastien Bourdeauducq: dvisampler/clocking: proper pix5x reset synchronization | 19:33 |
| --- Tue Mar 19 2013 | 00:00 | |
Generated by irclog2html.py 2.9.2 by Marius Gedminas - find it at mg.pov.lt!