IRC logs for #openrisc Sunday, 2015-05-03

--- Log opened Sun May 03 00:00:33 2015
olofkstekern: Maybe you could push the sockit dts to orpsoc-cores?06:28
stekernolofk: I don't have one for the current sockit in orpsoc-cores06:30
olofkah ok06:30
stekernyou know what we should do if we host the orpsoc-cores dts'es in orpsoc-cores, we should make a common dts that the others can include, and just enable the peripherals that is in use06:31
stekernsince we are using a unified memory map and irqs06:32
olofkDo we need to merge them manually, or can you specify multiple dts files in Linux?06:32
stekernyou "merge" them manually, by saying #include "orpsoc-cores.dtsi"06:35
stekernfor instance06:36
olofkah cool06:36
olofkdidn't know06:36
stekernyou can look at the the socfgpa dts for an example: https://github.com/openrisc/linux/blob/master/arch/arm/boot/dts/socfpga_cyclone5_sockit.dts06:36
olofkI still want something built on top of FuseSoC that can provide a little better integration for OpenRISC systems06:38
olofkLike generating a BSP from the contents of wb_intercon.conf and pulling in drivers from each core06:38
stekernsomething I'd really like would be some way to inherit systems/cores06:39
olofkYou can do that somewhat for the RTL files, but not for other files.06:40
olofkAre you thinking about the dts file, or something else?06:41
stekernno I meant the whole system06:43
stekernde0 nano could be inhereted from mor1kx-generic for instance06:43
olofkYeah, I've been looking for something like that too06:44
stekernI want to add a de0 nano system that has support for all the cool stuff my migen extension boards have06:44
olofks/migen/minimig ?06:45
stekernnow, that means I just copy the existing one hack that up06:45
stekernyes, minimig ;)06:45
stekerntoo much stuff starts with 'mi'06:46
stekernmigen, milkymist, minimig, mist...06:46
olofkYeah, and that was one of the intentions with FuseSoC. A bit sad that it's not really there yet06:46
stekerndoes any board use the opencores sdcard core yet?06:47
olofkI think that ordb2a uses it, but it's only available in an orpsocv2 fork in the VirtualBox image06:48
stekernoh, right06:48
stekernbecause, it'd actually be pretty cool if the sdcard accesses on the minimig-de0_nano could be speed up by using that06:49
olofkstekern: If you depend on de0_nano in your minimig port, what do you need to change? top-level, pin assignments, constraints?06:49
stekernyes06:50
olofks/?/...anything else?06:50
stekernno, I think that's it. I'll of course need to extend the .core file and change wb_intercon06:51
olofktrue06:51
stekernbut that's my point, you should be able to have a base 'class' and only define/override the things you actually want to change06:51
olofkhmm... I'm thinking about how to do that06:52
stekernand for the top-level, I think that the template system that hansfbaier started to look into would be a good step towards it06:53
olofkI was hoping that IP-Xact could take away some of the boring aspects of top-level generation, but I forgot that XML files are horrible for VCS06:56
olofkFor tcl/sdc files I'm thinking of using the same solution as for RTL files, with private_tcl_files for files that you don't want other systems to inherit06:59
olofkThat will make it easier to reuse snippets of constraints for example in CDCs found in subcomponents07:00
stekernyes, and tcl/sdc files are pretty easy to make modular, like we had for de0 nano in orpsocv207:06
GeneralStupidwhats about conf.d folders?07:49
bandviglatif: I've never used  the orpsocv2. I read the blog just a general guiding a used fusesoc. Excuse me, but I haven't any more ideas.09:20
olofklatif: I'm trying to figure out how to debug this. It's a bit awkward without a real debugger. I see several potential problems09:45
olofk1. The boot ROM doesn't copy the image from flash to RAM and execute it09:45
olofk2. The image in the Flash is broken09:46
olofk3. The file is loaded correctly, but the program itself doesn't work09:46
olofk4. Anything else :)09:46
olofkantgreen: Do you have a clue why objcopy makes the verilog memory files executable?10:02
GeneralStupidi need some help with that GDB :)10:02
olofkahh.. could it be because I'm creating it via an elf file10:02
GeneralStupidcontinue does not mean that the program is running permanent?10:03
olofkGeneralStupid: Not an gdb expert, but when I used gdb on OpenRISC I used detach instead of continue10:03
olofkBut I mostly just used OpenOCD nowadays. It works fine if I just want to download and run programs and look at registers and memory10:05
GeneralStupidOhh iam too stupid :) Its working... all LEDs are lighting because its too fast :)10:06
olofkhaha10:06
GeneralStupidi wish i could say im doing this the first time this year10:06
olofkme too :)10:06
olofkstekern: Have you programmed the de0 nano SPI Flash with an FPGA image + sw?10:14
GeneralStupidInfo : clock speed 3000 kHz10:16
GeneralStupidisnt that a bit low? :-D10:16
olofkGeneralStupid: haha. It's the JTAG clock10:16
GeneralStupidok. I mean "Info: Clock Speed" is very misleading for a hardware newcomer like :)10:24
olofkI won't argue with that :)10:24
olofkAlright. I pushed some patches to de0 nano to port over the SPI boot loader from ORPSoCv210:25
olofkI'll soon release my or1k_bootloaders repo so that it will be available to all systems10:25
GeneralStupidi dont think thats normal behaviour?! if i do reset in telnet my LEDs still lighting.10:35
GeneralStupidhe dont react to the reset pushbutton10:35
olofkstrange10:37
GeneralStupidi put everything into a while loop thats ok ? I want to run it forever...10:40
olofkCan't see a problem with that10:46
GeneralStupidhttps://dpaste.de/r3C710:50
GeneralStupidok i got it11:07
GeneralStupidfor normal GPIO the size is 2, if i dont need them bidirectional (for LEDs) the size is only 1. So 0x9...0 is the data, and 0x9...1 is useless11:07
GeneralStupidFor the "normal" configuration i have on github. Is it bad to have alld LEDs in between 0x900000 and 0x9000?? ? ...11:08
stekernolofk: yes, some time long ago11:25
olofkGeneralStupid: There is some kind of semi-standardized address space for the OpenRISC systems, but I'm not sure what is said about extra GPIO components11:44
olofkstekern: ah ok. I've never done it with the Altera tools so I'm not sure about how to do it11:46
stekernyou need to generate a .pof file11:51
stekernI can look up how it was done when I'm back home11:51
olofkcool. That would be great11:51
olofkJust found that you have a de2_115 port for ORPSoCv2 at chokladfabriken also11:52
GeneralStupiddo i have to do anything to roll out the changes to the register?13:24
olofkGeneralStupid: Not sure what you mean13:35
GeneralStupidi want to "listen" to a button... while(1) { if (button_pressed) led1 = 1; else led1 = 0; }13:37
GeneralStupidbut it goes only into else13:37
olofkNo, that should work13:37
GeneralStupidhttps://dpaste.de/q7AA13:38
GeneralStupidthats it actually13:38
olofkhmm13:40
GeneralStupidok forget it, lets try something different. How do you start programs with openocd?13:40
olofkYour leds are mapped to 0xb000000013:40
olofk?13:40
GeneralStupidplease np13:41
GeneralStupid0xb300000013:41
GeneralStupidOk thats right13:41
olofkah sorry. Yes. See it now13:42
olofkok. Loading programs with openocd then13:42
olofkconnect openocd (I assume you know that part if you're using gdb)13:43
olofkThen start a new terminal and run telnet localhost 444413:43
GeneralStupidok13:44
olofkThe it's just halt; load_image <elf file>; reg npc 0x100; reset13:45
olofkor  perhaps resume instead of reset13:46
olofkgtg13:48
GeneralStupidolofk: thanks, its the same issue. i have to try out a bit more13:50
GeneralStupidokay okay, there is a failure in that pinmap from terasic. Switches 0 to 7 are mixed up with 8 to 1514:28
stekernolofk: it wasn't called .pof, but .jic16:01
stekernbut I think that .pof actually is something too16:01
stekernanyway, this are the steps, and I got them from a guy called gong tao16:01
stekerncreate a .cof file, for example like this: http://oompa.chokladfabriken.org/openrisc/orpsoc.cof16:02
stekernthen cherry pick what you need from this:16:02
stekernhttp://pastie.org/1012683016:02
latifhi all.. have a nice day...16:03
stekernnow when I look at this again, I think juliusb might have copied those instructions to some wiki page or something ;)16:03
latifolofk: I think there is a problem with atlys.S which is in or1k-tollchain... board mem size was defined 0x2000000..that means 32 megabyte..but atlys has a 128 megabyte ddrram...16:05
stekernlatif: you're right, that's wrong16:07
stekernit's my mistake, I probably just copied it from the de0 nano one and forgot to change it16:08
GeneralStupidi have 32 defined but only 8 on board16:09
GeneralStupidstekern: i will put it on my to do list :)16:09
stekernthat's worse ;)16:09
latifalso there is a problem in this tutorial...http://www.rte.se/blog/blogg-modesty-corex/loading-and-executing-program/2.7  the mem size was defined as 0x800000 ..but this should be 0x8000000.. one 0 is missing!!16:09
GeneralStupidstekern: i will propably add a "driver" for 7 segment display16:10
GeneralStupidi need to ask if it is able to publish16:10
latifcan someone say me that what is the defined mem size for atlys in or32 toolchain???16:11
latifaha soryy.. in or32 toolchain there doesnt exist atlys.S... forget about it:)16:14
GeneralStupidoh fuck, i have to optimize a lot my fpga is very full right now :)16:20
GeneralStupidOkay 0x400000 . I check it16:30
latifstekern:olofk: I ve got a question.. flash size of atlys is 16 mb..ram is 128 mb.. in flash size image 1.5 mb is for a bit file (for example openrisc processor) and 14.5 mb is for user data or program etc.. But if or1k-elf thinks that there is a 128 mb area and compiles the a code it may causes an error for spi flash..because it is just 14.5 mb..this is may be the error..just a questiıon??18:00
latifI mean if a code compiles for 128 mb or 32mb even if it is small it may causes an error while it is being writed to the spi flash..because it is just 16 mb and just 14.5 mb is for user program..I think this is not correct..is it??18:02
latifolofk: stekern: yes that is why spi flash is not booted... because of this mem eroor.. I made the mem size 8 mb in atlys.S and compiled it then put it in /opt/or1k...libboard-atls.a .. then I used v2 and a led test program.. at the end I have managed to write .mcs file to spi flash and booting gpga from spi!!18:59
latifI am realy happy about that :)18:59
stekernlatif: that shouldn't be related at all, the setting you changed is only used to setup the stack pointer19:40
latifstkern: I dont know what the whole problem is... I can just say that now I can access Leds and booting FPGA from SPI.. by using orpsocv2.. tomorrow ı will try to do it with orpsocv3..19:50
olofklatif: Great to hear that it's working out21:46
olofkGeneralStupid: Seems like you managed to get things working as well. Great21:47
olofkstekern: Thanks for the instructions. I'll see if I can try them out tomorrow. I've been working a bit on the de0 nano port recently21:48
olofkStill considering to throw out the or1200 support to make it a bit cleaner. On the other hand, it doesn't add too much complexity and it can be nice to have the choice21:48
GeneralStupidolofk:  yes its getting forward but its only a side project. :)22:19
GeneralStupidthx 4 help22:20
--- Log closed Mon May 04 00:00:21 2015

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