Sunday, 2021-05-09

*** tpb has joined #litex00:00
*** Degi_ has joined #litex00:02
*** Degi has quit IRC00:03
*** Degi_ is now known as Degi00:03
*** mikeK_de1soc has joined #litex00:47
*** mikeK_de1soc has quit IRC01:12
*** TMM has quit IRC03:11
*** TMM has joined #litex03:11
*** Bertl_oO is now known as Bertl_zZ03:34
*** Degi_ has joined #litex04:01
*** Degi has quit IRC04:02
*** Degi_ is now known as Degi04:03
*** chgavilana has quit IRC04:18
*** captain_morgan has quit IRC06:09
*** captain_morgan has joined #litex06:10
*** pftbest has quit IRC07:00
*** kgugala has joined #litex07:24
*** kgugala_ has quit IRC07:24
*** kgugala has quit IRC07:47
*** kgugala has joined #litex07:47
*** d_olex has joined #litex08:23
nickoemmm, is this a bad idea to try to make the clock of a module slower?          self.comb += ClockSignal().eq(clock_domain.clk)09:33
nickoeVsim just appears to never complete.09:33
nickoe_florent_: Is there or was there a bug in litedram that could cause the LiteDRAMDMAReader to act differently in simulation and hardware? https://i.snipboard.io/geh8WT.jpg I am talking about the mydma_dma_sink_sink_ready signal. In the simulation it ready'es a lot to fill its fifo, but on hardware it does not and it will have those odd ready signals multiple clock cylces with a low cycle.09:59
nickoeI am currently on litedram 080948d49c0cfe3fa8e10dcea1ae123bbe3949ac which is a bit old. I have not tested my design on latest of everything yet.10:01
*** pftbest has joined #litex10:24
*** kgugala_ has joined #litex10:28
*** kgugala has quit IRC10:30
*** pftbest has quit IRC10:50
*** pftbest has joined #litex10:54
*** kgugala has joined #litex11:09
*** kgugala_ has quit IRC11:13
*** mikeK_de1soc has joined #litex11:53
mikeK_de1socHi Nickoe: Can I ask you a questions about litex?11:54
*** TMM has quit IRC12:05
*** TMM has joined #litex12:05
nickoemikeK_de1soc: you can try, but I am no expert12:07
mikeK_de1socThanks.  Like I said I am still learning, IS there an example of using the PWM function that Florent has in some of his example code?12:09
mikeK_de1socSo for example I am looking through the Litex-boards examples, and I found something under LEDs but it looks like you can only use the PWM through the CSR's from the Risc-V cpu?12:10
mikeK_de1socThe question is not confusing I hope..12:11
mikeK_de1socBascally How can I access the pins in Litex-Boards?12:11
mikeK_de1socMaybe that's too loaded of a question...12:12
mikeK_de1socSorry.12:12
mikeK_de1socLets TRy this simple Question How Do I send a Link to a Line of the Code, From Github for example?12:27
mikeK_de1sochttps://github.com/enjoy-digital/litex/blob/9bec0ce7a28afb498c7b7eb79943c270225c061a/litex/soc/cores/led.py12:28
mikeK_de1socHere's the Code I am working with... I just need to add the PPM modulation Here instead of the PWM??  (This is my Ultimate Goal, To send PPM signals to an RC controller instead of PWM signals)12:30
*** Bertl_zZ is now known as Bertl12:45
nickoemikeK_de1soc: You can clik the line number or multiple to get a direct link range that is highlighted13:05
mikeK_de1socOK thanks!13:06
nickoethat CSRStorage is available as a register you can write or read to from the cpu13:07
nickoe litex_cli --regs   | grep led13:07
nickoe0x82005800 : 0x00000000 leds_out13:07
nickoein my design13:07
mikeK_de1socOk thanks... IS there a Wiki example or documented somewhere?13:08
nickoeand that add_pwm function is just exactly that, an example on how to use the PWM() module13:09
mikeK_de1socRight now my Linux-on-litex-vexriscv build envrioment is broken.. :(13:10
nickoeI have mostly been using the bare metal cpu thing, not the linux one13:10
mikeK_de1socah ok..13:10
nickoeWhat hardware do you have?13:11
mikeK_de1socAltera...   DE10NAno and the DE1Soc13:11
mikeK_de1sochence in the name... :)13:11
nickoeok13:11
mikeK_de1socDo you have an example of a Bare metal CPU?13:12
mikeK_de1socA wiki if you will??13:12
nickoeI think you can add some other CSRStorage things to attach to the args of add_pwm and you can control the pwm from the cpu13:12
mikeK_de1socI am driking from the firehose here..  :)13:12
nickoeessentially the same as you do for linux, just that you don't run linux13:13
nickoehttps://github.com/enjoy-digital/litex/wiki/Load-Application-Code-To-CPU13:13
mikeK_de1socSweet thanks!!13:14
nickoeI build the demo.bin with: python ../../../litex/litex/soc/software/demo/demo.py --build-path=build/sim13:14
nickoeand that builds a main.c somewhre in the demo path that you can modify13:14
nickoethe demo vil write to the led register directly here, https://github.com/nickoe/litex/blob/1540aeaa701e220ce42038acd4ee8c8c7fe03c5a/litex/soc/software/demo/main.c#L108-L13613:16
mikeK_de1socOh wow...13:16
mikeK_de1socOk, so is this Riscv based??13:16
nickoeyes13:17
mikeK_de1socok....13:17
mikeK_de1socso you still need the Linux-on-litex-vexriscv13:17
nickoeSo if you want to implement the PPM protocol, I guess you want to create your own simple PPM module and give it some registers you can control from sw13:17
nickoeno, I am not using linux-on-llitex-vexriscv13:18
nickoeJust using the example in litex-boards directly13:18
mikeK_de1socoh ok...13:18
mikeK_de1socthat's exactly what I am doing, I took the PWM code, then I am changing it to the PPM, in Verilog. (well python to verilog)13:20
mikeK_de1socwhere I get a little confused is where the Gateware stops and the software starts..13:20
mikeK_de1socthe links you sent is a great start... more reading!!  :)13:21
nickoewell, the python is essentially gateware13:21
nickoeas it generates  verilog13:21
nickoeif you add --csr-csv=csr.csv when building your target, you can see what registers you can acccess13:22
nickoeor, I call them registers, but they are the CSRStorage things13:22
mikeK_de1socAH ok...13:22
nickoeThat can be wired up to signals in the gateware but are addressable from the CPU13:23
nickoeor that etherbone stuff13:23
nickoehttps://github.com/enjoy-digital/litex/wiki/Use-Host-Bridge-to-control-debug-a-SoC13:23
mikeK_de1socYes, I remember now.  still learning, The only down side right now with the Terasic boards, is that the Ethernet is connected  to the CPU side on the ARM processor PART in the FPGA IC.13:25
nickoeIs it possible to use that CPU in the litex soc project or is that not supported?13:26
mikeK_de1socwell.. it's complicated...  No from my limited understanding..13:27
*** mikeK_de1soc has quit IRC13:29
*** mikeK_de1soc has joined #litex13:35
mikeK_de1socit's not supported..   So long story, within the Quartus SOC builder you create a SOC system with the Canned Software, But it would be possible if you have a Wishbone to to AXI bus bridge..13:35
*** mikeK_de1soc has quit IRC13:41
*** mikeK_de1soc has joined #litex13:53
*** mikeK_de1soc has quit IRC15:09
nickoe_florent_: I tried it with latest litedram and it appears to have similar symptoms. I wonder why my sim is different to my hw.15:47
*** kgugala_ has joined #litex16:31
*** kgugala has quit IRC16:33
*** kgugala has joined #litex16:36
nickoezyp: Is it possible for the ClockDomainCrossing to overflow?16:37
zypnot if flow control is implemented16:38
*** kgugala_ has quit IRC16:38
*** mikeK_de1soc35 has joined #litex16:46
nickoemmm!!!16:49
nickoeI think it is sort of an endianess problem16:49
nickoeI get 4x32 bits from the DMA thing, but I get the lowest address last.16:50
nickoecompare https://dpaste.com/E87NKBLM616:51
tpbTitle: dpaste: E87NKBLM6 (at dpaste.com)16:51
nickoehttps://i.snipboard.io/Dqf8TW.jpg16:51
nickoeRight there using  the DMAReader from litevideo16:51
nickoehttps://github.com/enjoy-digital/litevideo/blob/master/litevideo/output/core.py#L41-L12216:54
nickoehttps://github.com/nickoe/litex-boards/blob/f3090247db0a7d26291c39860eede3a3aa46ca64/litex_boards/targets/mars_ax3_custom.py#L133-L15216:54
nickoezyp: So that snippet of data dump is made with this code on the target https://dpaste.com/C7Y2HH8EZ.txt16:56
nickoeWhy this difference on target and sim happens, I can't explain.17:01
*** kgugala_ has joined #litex17:05
*** kgugala has quit IRC17:07
*** kgugala has joined #litex17:20
*** kgugala_ has quit IRC17:23
*** mikeK_de1soc35 has quit IRC17:48
*** pftbest has quit IRC17:50
*** pftbest has joined #litex17:53
*** pauluzs has joined #litex19:18
*** Bertl is now known as Bertl_zZ21:14
nickoezyp: Someone in #symbiflow had the answer! :D  This is happening because of the conversion from 128-bit native DRAM width to the 32-bit width requested here: https://github.com/nickoe/litex-boards/blob/f3090247db0a7d26291c39860eede3a3aa46ca64/litex_boards/targets/mars_ax3.py#L229 The solution is to add the parameter 'reverse=True' to the get port function call which will switch the order of 32-bit words when splitting a 128-bit word.21:49
*** pftbest has quit IRC22:40
*** pftbest has joined #litex22:54
*** lf has quit IRC23:08
*** lf has joined #litex23:08

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