sb0 changed the topic of #m-labs to: ARTIQ, Migen, MiSoC, Mixxeo & other M-Labs projects :: fka #milkymist :: Logs http://irclog.whitequark.org/m-labs
klickverbot_ has joined #m-labs
klickverbot has quit [Ping timeout: 265 seconds]
klickverbot_ has quit [Ping timeout: 265 seconds]
fengling has joined #m-labs
klickverbot_ has joined #m-labs
klickverbot_ has quit [Ping timeout: 265 seconds]
<sb0> rjo, I guess synthesizers should optimize it to "!= 0" in this particular case, but why take bets?
<sb0> looks good to me
<GitHub176> [artiq] sbourdeauducq pushed 1 new commit to master: http://git.io/vekh3
<GitHub176> artiq/master fb91955 Robert Jordens: tests: make hardware-in-the loop flags positive logic...
<sb0> for once, the win32 api is even saner than the termios mess on unix
<sb0> ah. but you can't use this ioctl api with file descriptors, and instead you need IRP_MJ_{READ,WRITE} requests.
travis-ci has joined #m-labs
<travis-ci> m-labs/artiq#80 (master - fb91955 : Robert Jordens): The build passed.
travis-ci has left #m-labs [#m-labs]
<rjo> sb0: if i had to express !=0 or >0 in gates it would always just be a big OR
<rjo> termios has survived way more wars.
rofl__ has quit [Ping timeout: 265 seconds]
rofl__ has joined #m-labs
_whitelogger has joined #m-labs
whitequark has joined #m-labs
<whitequark> sb0: re library, I mean a python one
<whitequark> also you don't need to send ioctl's, there is a function that operates on file handles
<whitequark> er, that's CE for some reason
<acathla> argh! :)
<whitequark> what?
<acathla> a microsoft link, here
<whitequark> I find it amusing how MS did a heel-face turn, going from "we must destroy linux!!1one" to becoming a large committer and open-sourcing .net under MIT
<whitequark> and google, on the other hand...
<GitHub42> [misoc] sbourdeauducq pushed 2 new commits to master: http://git.io/veIHu
<GitHub42> misoc/master 73d3b84 Sebastien Bourdeauducq: crt0-or1k: clean up indentation
<GitHub42> misoc/master 875abde Sebastien Bourdeauducq: make.py: use os.path.join
<GitHub32> [artiq] sbourdeauducq pushed 2 new commits to master: http://git.io/veIHA
<GitHub32> artiq/master 5f7161a Sebastien Bourdeauducq: kc705: 16 TTLs
<GitHub32> artiq/master c6d3750 Sebastien Bourdeauducq: runtime,amp: set kernel memory start to SDRAM+128K, use custom linker file to split memory
<sb0> rjo, I'm going to remove the gpio driver. 1) as we have noticed, it confuses people as it doesn't respond to rtio timing commands 2) implementing it properly for both uniprocessor and biprocessor systems is slightly non-straightforward
klickverbot_ has joined #m-labs
travis-ci has joined #m-labs
<travis-ci> m-labs/artiq#81 (master - c6d3750 : Sebastien Bourdeauducq): The build passed.
travis-ci has left #m-labs [#m-labs]
klickverbot_ has quit [Quit: Quit]
klickverbot_ has joined #m-labs
klickverbot has joined #m-labs
klickverbot_ has quit [Read error: Connection reset by peer]
<GitHub79> [pyparser] whitequark pushed 2 new commits to master: http://git.io/veIbC
<GitHub79> pyparser/master f8dd2b4 whitequark: Add diffs of upstream grammar and lexer documentation changes.
<GitHub79> pyparser/master 6eca9e6 whitequark: Reproduce Python 3.0 lexer more strictly.
<ccube> I am getting lambda name, memory: self.csr_map[name if memory is None else name + "_" + memory.name_override], KeyError: 'nandconf_m' error when I add an Memory() instance to my AutoCSR derived class. what can be wrong?
<sb0> you need to give your memory an address
<sb0> in the map
<ccube> the csr_map?
<ccube> or is it another memory map?
<ccube> ah, mem_map, like framebuffer does?
<sb0> yes
<sb0> you mean dvisampler?
<sb0> dvisampler has a memory for the edid data, look at how it's done there
<ccube> sb0, cant find, where dvisampler defines the map
<rjo> sb0: ack. i would keep one led gpio for the runtime/bios and further leds (where present) rtio channels.
<ccube> gettin NameError: global name 'memory' is not defined error after defining my memory in the csr_map
<rjo> _florent_: re csr "_r" removal in redpid. your patch contained only changes to a small fraction of the CSRs. do you have the rest still somewhere?
klickverbot has quit [Quit: Quit]
klickverbot_ has joined #m-labs
klickverbot_ is now known as klickverbot
_florent_ has joined #m-labs
<ccube> could that be a bug? http://pastebin.com/y7Fgab5D
<ccube> memory was not defined
<_florent_> ccube: yes it's probably an untested case, thanks
<_florent_> rjo: OK for the csr "_r" removal, I'm going to look at that
<GitHub109> [misoc] enjoy-digital pushed 1 new commit to master: http://git.io/veLkP
<GitHub109> misoc/master 0db6e1d Florent Kermarrec: soc/cpuif: fix get_csr_header when obj is Memory (thanks ccube)
<ccube> _florent_, np
<_florent_> ccube: do you still have your NameError?
<ccube> not anymore, but i am not sure if i am doing the right thing. I am now getting a csr name conflict while using CSRStatus and Memory in the same AutoCSR class
<ccube> *CSR region conflict
<_florent_> can you eventually share your code?
<ccube> sure, mom
<whitequark> ...
<_florent_> thanks, looking at that
<ccube> I dont think, Memory class is what I actually need.... I am just playing arounc, cuz I am kind of struggling to understand the whole system of misoc... What I acutally want to have is an interface between my module and and the software running on the SoC, to exchange large amounts of data quickly.
<ccube> i think, DMA is more what I need, but it was hard for me to figure out how to properly use it.
<_florent_> do you have SDRAM on your SoC?
<ccube> yes
<ccube> it is an papilio pro
<_florent_> OK so you don't need to use Memory class, you have to:
<_florent_> - create a SoC derivated from SDRAMSoC (you can use ppro target as a basis)
<ccube> yeah, thats what I am doing
<_florent_> - get a lasmi port from the crossbar as it's done here:
<_florent_> self.lasmixbar.get_master()
<_florent_> - and pass it to your DMA writer or reader
<ccube> ok
<ccube> i tried with self.sdram.crossbar.get_master()
<_florent_> ah... no sorry it's maybe self.sdram.crossbar.get_master() (wondering if Mixxeo is up to date)
<GitHub73> [misoc] sbourdeauducq pushed 2 new commits to master: http://git.io/veLs5
<GitHub73> misoc/master 85b3cce Sebastien Bourdeauducq: use str.format
<GitHub73> misoc/master c7361f1 Sebastien Bourdeauducq: software/common.mak: fix alignment in quiet output
<GitHub164> [artiq] sbourdeauducq pushed 1 new commit to master: http://git.io/veLGq
<GitHub164> artiq/master 21a0919 Sebastien Bourdeauducq: runtime: load support code into kernel CPU
<ccube> okay, I tried to get started with the memtest classes, copied them and played around with it. what I did not understand is, how to modify memory regions from the SoC design (python code). also I wasnt sure about why I need seperate classes for Read and Write and what exactly is the LFSR for.
<_florent_> The LFSR is particular to our memtest, it's used to generate pseudo random datas to test the memory, you don't need it
<_florent_> otherwise if you want simple wishbone access to your memory you can use wishbone2lasmi
<ccube> hmm, i dont know if i want this :D
<_florent_> I don't know what you want to do :)
<ccube> i will connect a nand flash to the io pins of the ppro. will drive the nand to pull out its data.
<ccube> and i have to somehow copy the data from nand's register to ppro memory for accessing it on software side
<_florent_> OK so what you can do:
<ccube> also software side has to control read operations by writing commands to registers/memory regions
<_florent_> (for NAND --> SDRAM direction)
<_florent_> in NandDmaWriter remove all LFSR stuff
<_florent_> - to start you DMA, you have to configure it with the software (look at memtest software for that) and trigger it by software of with self._dma.trigger
<_florent_> - then the DMA is waiting for the number of data configured by the software
travis-ci has joined #m-labs
<travis-ci> m-labs/artiq#82 (master - 21a0919 : Sebastien Bourdeauducq): The build passed.
travis-ci has left #m-labs [#m-labs]
<_florent_> - to present a data: put your data on self._dma.data.d, set self._dma.data.stb to 1
<_florent_> - data is accepted when self._dma.data.ack is 1
<_florent_> - once your DMA is done, you can access your data with the software
<_florent_> (you will need to flush L2 cache)
<_florent_> this makes me think we should provide simple dma examples
<ccube> hehe
<ccube> that would be awesome!!
<ccube> thanks for the explaination.. that was really helpful. ill try to implement something with dummy data and check how it goes
<ccube> _florent_, what exactly means configuring it with the software? memtest is actually not doing anything special.
<ccube> (except of resetting before each r/w operation)
<_florent_> reseting, writing DMA base address, writing DMA length and shoot to start MDA
<_florent_> DMA
<ccube> yeah, gonna try that out
<ccube> what is 'en' and 'en_counter' in MemtestDMAWriter for>
<_florent_> just to generated the right number of data expected by the DMA
<ccube> hmm
klickverbot has quit [Quit: Quit]
klickverbot_ has joined #m-labs
<ccube> so i can leave it away if i pass enough data to self._dma.data.d in one cycle?
<ccube> or has 'd' a fixed length?
<_florent_> you don't need it, you just need to pass the number of data you program your DMA for
sh[4]rm4 has joined #m-labs
rofl__ has quit [Ping timeout: 265 seconds]
fengling has quit [Quit: WeeChat 1.0]
<GitHub171> [misoc] enjoy-digital pushed 1 new commit to master: http://git.io/veLVH
<GitHub171> misoc/master c9c11e7 Florent Kermarrec: soc: add memory.name_override to name when adding csrbankarray.srams to csr_regions
<ccube> _florent_, do I have to set ack to 1?
<ccube> or will it be done automatically
<_florent_> no the DMA drive it, you just have to take care of it to be sure your data has been accepted (if not you have to keep stb high with the same data)
<ccube> my busy_read() call returns always true after triggering the Writer once.
<_florent_> are you sure to send enough data to the DMA?
<ccube> self._dma.data.d.eq(dummy_data)
<ccube> dummy_data = 0xacabaffeacabaffe
<ccube> _length_write(8)
<ccube> do I have to do anything when ack is being set?
<_florent_> release you stb if you are done
<ccube> hmm, "I am done" when ack was set, right?
<_florent_> yes if you only have one data
<ccube> ah, so if I have more than one data, ack will be st for each write cycle?
<sb0> _florent_, won't this change break videomixer?
<sb0> and why did you make it?
<_florent_> ccube: yes
<_florent_> sb0: it's in fact for videomixer
<_florent_> without that we trigger a false CSR region conflict between dvisamplerx and dvisamplerx_edid_mem
<_florent_> because CSR and memory were registrered with the same name
<_florent_> do you see others impacts whith this change?
<sb0> is the generated name in csr.h still the same?
<_florent_> ah no... can I remove this:
<_florent_> and just use r += "#define CSR_"+name.upper()+"_BASE "+hex(origin)+"\n" for memories
<_florent_> (it generates this: #define CSR_DVISAMPLER0_EDID_MEM_EDID_MEM_BASE 0xe000a000=
<_florent_> ie the idea is to pass the fullname directly to regions and after that only use the name of the region
<sb0> ok
<_florent_> thanks
<GitHub64> [misoc] enjoy-digital pushed 1 new commit to master: http://git.io/veLAZ
<GitHub64> misoc/master 2583e97 Florent Kermarrec: soc/cpuif: fix CSR base generation for memories (name is already fullname)
klickverbot_ has quit [Quit: Quit]
klickverbot_ has joined #m-labs
<ccube> _florent_, something is weird... ACK is set, STB is unset, but it seems that nothing is happening, and the busy_read method is returning true after my first trigger
<ccube> code coming.... hang on
whitequark has quit [Ping timeout: 252 seconds]
whitequark has joined #m-labs
<ccube> o
<ccube> its somehow working... its writing to my buffer, but stays busy then
<_florent_> OK, I don't see exactly what is going on, you can maybe try with more than one lasmi word
<ccube> what exactly does that mean?
<ccube> I am trying with larger data (eg 256k)
<_florent_> and the result is the same?
<ccube> looks like it partially works. if i skip the busy check, it writes the data 2 or three times, than the whole system crashes
<_florent_> hmmm.... strange
<_florent_> I'm sorry I have to go
<ccube> no worries, thanks for helping
antgreen has joined #m-labs
fengling has joined #m-labs
fengling has quit [Ping timeout: 250 seconds]
fengling has joined #m-labs
antgreen` has joined #m-labs
antgreen has quit [Ping timeout: 272 seconds]
_florent_ has quit [Read error: Connection reset by peer]
<sb0> how can I get the value of a C preprocessor macro in a makefile?
<sb0> or more simply, whether that macro was defined or not
<ysionneau> sb0: http://pastebin.com/VHCqywk4 ?
klickverbot has joined #m-labs
klickverbot_ has quit [Read error: Connection reset by peer]
<ysionneau> better like this http://pastebin.com/Kss7hKjh
<ysionneau> without the redirect , output goes to stderr and is lost
<ysionneau> also, better replace gcc with $(CC)
klickverbot has quit [Ping timeout: 265 seconds]
klickverbot has joined #m-labs
klickverbot has quit [Ping timeout: 265 seconds]
klickverbot has joined #m-labs
fengling has quit [Ping timeout: 250 seconds]
bentley` has quit [Ping timeout: 252 seconds]
klickverbot has quit [Quit: Quit]
fengling has joined #m-labs
fengling has quit [Ping timeout: 250 seconds]
<sb0> ysionneau, what if the compilation fails for another reason eg the file or the compiler is not found?
Gurty has quit [Ping timeout: 246 seconds]
Gurty has joined #m-labs
siruf has quit [Ping timeout: 250 seconds]
siruf has joined #m-labs