*** tpb has joined #timvideos | 00:00 | |
FelixVi | which is where we're pulling the firmware code from? | 00:00 |
---|---|---|
FelixVi | but why is the flash boot address flash + gateware + bios? | 00:01 |
FelixVi | isn't bios part of gateware when it's stored in BRAM? | 00:01 |
mithro | FelixVi: Yes | 00:02 |
FelixVi | so shouldn't I get rid of gateware size as we're counting that twice now? | 00:02 |
mithro | FelixVi: But we leave a gap in the flash image so that we have a consistent flash layout | 00:02 |
FelixVi | oh, nvm | 00:03 |
FelixVi | now I get it | 00:03 |
FelixVi | but then what's the bios size for? | 00:03 |
mithro | FelixVi: Also makes it easier to switch to a bios from flash at a later date | 00:04 |
FelixVi | I'd upload to 0x200000 and isn't that where we'd start executing? | 00:04 |
FelixVi | oh, so bios_size should be 0 for now - and if there's flash bios that will change | 00:04 |
FelixVi | or i need to upload firmware to 0x200000 + 20000 | 00:05 |
FelixVi | that way, I can just leave space for a flash bios if I want that later on? | 00:05 |
FelixVi | so, if I synthesized this now, I'd upload top.bit with bios to 0x0 and firmware to 0x204E20 | 00:06 |
FelixVi | alright, bios is talking with me | 00:10 |
FelixVi | and it's trying to boot from flash | 00:10 |
FelixVi | but it says flash boot image length is invalid (0x0000000) | 00:11 |
mithro | FelixVi: Great! | 00:11 |
FelixVi | thanks! This would have taken me weeks | 00:12 |
mithro | FelixVi: I would upload the firmware to 0x200000 + 20000 | 00:12 |
FelixVi | yeah, that's what i did | 00:12 |
mithro | FelixVi: So, the next thing is to figure out if your flash is working at all | 00:12 |
mithro | FelixVi: This is where cr1901_modern comes in | 00:12 |
FelixVi | where is the flash image length defined? | 00:12 |
FelixVi | if that was correct, we'd know in a sec | 00:12 |
FelixVi | oh, or is it trying to read the length from flash to begin with? | 00:13 |
FelixVi | I suppose I could try to write/read from flash if I knew how it's mapped | 00:14 |
FelixVi | so, at 0x20000000, I just see all zeroes | 00:16 |
FelixVi | and using mw 0x20000000 1 2 3 4 and then reading back with mr 0x20000000 yields all zeroes | 00:17 |
FelixVi | if I'm using the commands correctly, flash is not working | 00:17 |
FelixVi | I don't seem to be able to write to 0x0 either, though | 00:18 |
*** sb0_ has quit IRC | 00:19 | |
FelixVi | this seems to be where flashboot fails: https://github.com/m-labs/misoc/blob/master/misoc/software/bios/boot.c#L276 | 00:24 |
tpb | Title: misoc/boot.c at master · m-labs/misoc · GitHub (at github.com) | 00:24 |
FelixVi | I am not exactly positive on "length = *flashbase++;" and why it's written like that | 00:27 |
cr1901_modern | mithro/FelixVi: Not available right now, sorry | 00:30 |
shorne | shenki: I think I got it now, it looks like calling convention issues with syscall(2). | 00:30 |
mithro | FelixVi: You won't be able to write to the flash | 00:30 |
mithro | FelixVi: (from the BIOS that is) | 00:31 |
FelixVi | ah, that explains that | 00:31 |
FelixVi | cr1901_modern: Do you think you'll be around later today? | 00:31 |
FelixVi | I'm basically trying to figure out if I want to stay at work or drive home | 00:32 |
*** sb0_ has joined #timvideos | 00:33 | |
cr1901_modern | FelixVi: By all means, drive home. I have other things to check off my todo list personally | 00:33 |
FelixVi | cr1901_modern: Cool, should I place an issue report about flash or is that the same as letting you know in here? | 00:34 |
cr1901_modern | FelixVi: I'll take care of that when we diagnose the problem | 00:34 |
FelixVi | well, I guess I did that already in misoc anyways - but if you think it's worthwhile I can add detail there | 00:34 |
cr1901_modern | FelixVi: Can you work from home at all? | 00:34 |
FelixVi | cr1901_modern: Yeah, I can be on later tonight if that's helpful | 00:35 |
FelixVi | I just need to take the working saturn board as mine at home is shot - that was a painful lesson | 00:35 |
cr1901_modern | FelixVi: That would work better if we could continue work when you get home | 00:36 |
FelixVi | or we can continue tomorrow if that works better for you | 00:36 |
FelixVi | alright, I'll take it and let you know when I'm around | 00:36 |
cr1901_modern | Alright cool | 00:37 |
cr1901_modern | mithro: Did you ever take a look at my PR for flash updates as-is? | 00:38 |
mithro | cr1901_modern: No I haven't had a chance -- lots of things to do | 00:38 |
cr1901_modern | We agreed to merge it in despite having simulation issues | 00:38 |
cr1901_modern | mithro: Good, that makes two of us | 00:38 |
cr1901_modern | No rush at all | 00:38 |
mithro | cr1901_modern: Oh, I needed to chat with you about the xmodem support in flterm -- it seems to be causing problems, can we move it behind a flag? | 00:38 |
cr1901_modern | mithro: Yes | 00:39 |
cr1901_modern | Go for it | 00:39 |
cr1901_modern | Prob no need for it to be mutually exclusive w/ sfl either | 00:39 |
cr1901_modern | (it == the flag) | 00:39 |
*** FelixVi has quit IRC | 00:42 | |
*** sb0_ has quit IRC | 00:42 | |
*** CarlFK has quit IRC | 00:45 | |
*** felix_ has quit IRC | 01:11 | |
*** felix_ has joined #timvideos | 01:11 | |
*** sb0 has joined #timvideos | 01:40 | |
*** FelixVi has joined #timvideos | 01:53 | |
FelixVi | cr1901_modern: k, got everything setup here again - getting "Error: Invalid flash boot image length 0x00000000" again | 02:04 |
cr1901_modern | FelixVi: Ack, give me a few minutes please | 02:09 |
FelixVi | cr1901_modern: No rush, just wanted to give you a heads up | 02:09 |
FelixVi | I'm looking to switch over to mitex - it doesn't fix misoc but might work out of the box and also seems to be better commented | 02:10 |
FelixVi | *litex | 02:10 |
cr1901_modern | I mean, it should work. But I would prefer that your changes are contributed/test on both to avoid divergence. | 02:11 |
cr1901_modern | (Do as I say, not as I do) | 02:11 |
FelixVi | cr1901_modern: yeah, whatever we get fixed I'll write up as a PR | 02:12 |
mithro | cr1901_modern: https://gist.github.com/mithro/289c5dce5fd1c4ea2c0d352e1d511d0b | 02:15 |
tpb | Title: Prepare an upstream migen/misoc for merging into litex · GitHub (at gist.github.com) | 02:15 |
cr1901_modern | mithro: Okay, this makes me feel _much_ better. I have no idea how/why it works, but clearly you put thought into it. | 02:19 |
mithro | cr1901_modern: The aim there is to try and get LiteX / migen+misoc closer together again | 02:20 |
cr1901_modern | mithro: So my intent was to at the very least make litex PRs for the two platforms I added to migen/misoc since I started my current round of PRs. >> | 02:21 |
cr1901_modern | if you decide to run this script later, would the end merge of my two PRs be equivalent as if I never bothered sending the PRs at all? | 02:21 |
cr1901_modern | (and just let your script add the new platforms instead) | 02:22 |
cr1901_modern | Easier q: Should I just keep making PRs to migen/misoc and let your script handle merging in changes? Or should I make equivalent PRs for each migen/misoc feature I need to get tinyfpga running? | 02:29 |
cr1901_modern | (Some PRs I made to migen/misoc are irrelevant to litex) | 02:29 |
* cr1901_modern is afk for a bit | 02:38 | |
mithro | cr1901_modern: Could you get stuff into LiteX sooner rather than later? | 02:42 |
FelixVi | mithro: is it OK to ask you a question or two about targets in litex? I'm trying to port Saturn to litex so that we can work on that directly | 02:48 |
FelixVi | here's me trying to add Saturn to litex - what I can't figure out is how to just build the basesoc: https://github.com/FelixVi/HDMI2USB-litex-firmware/commit/c024ee58fd4047986962a90580d601b78273b3d2 | 03:02 |
tpb | Title: Adding Saturn · FelixVi/HDMI2USB-litex-firmware@c024ee5 · GitHub (at github.com) | 03:02 |
* FelixVi is also back in a little while | 03:03 | |
mithro | FelixVi: export TARGET=base | 03:06 |
mithro | FelixVi: You don't want lines 207/208 -- https://github.com/FelixVi/HDMI2USB-litex-firmware/commit/c024ee58fd4047986962a90580d601b78273b3d2#diff-47bed5475599814fcc3cdcebe4b02429R207 | 03:11 |
tpb | Title: Adding Saturn · FelixVi/HDMI2USB-litex-firmware@c024ee5 · GitHub (at github.com) | 03:11 |
*** rohitksingh_work has joined #timvideos | 03:38 | |
FelixVi | NameError: name 'BaseSoc' is not defined | 04:00 |
FelixVi | what might this be about? | 04:00 |
cr1901_modern | It's BaseSoC* I think | 04:01 |
FelixVi | hmm, it works in mimasv2 but not saturn | 04:02 |
cr1901_modern | Of course it does ._. | 04:03 |
cr1901_modern | Just once, I would like _one_ solution I propose these past 2 weeks to be right XD. | 04:03 |
FelixVi | well, you got more right than me so far ;) | 04:04 |
FelixVi | I'm slowly getting used to misoc/litex though - FWIW | 04:04 |
FelixVi | doh - I think it's the 'c' which needs to be "C" | 04:05 |
FelixVi | that's progress - now it complains about the uart phy | 04:06 |
FelixVi | https://pastebin.com/4X9Sgmxz | 04:07 |
tpb | Title: python3 make.py --platform saturn Traceback (most recent call last): File " - Pastebin.com (at pastebin.com) | 04:07 |
FelixVi | this is the traceback | 04:07 |
FelixVi | I'll see if I can figure this out - mimasv2 didn't complain about this | 04:08 |
* cr1901_modern stares at Felix | 04:09 | |
cr1901_modern | (11:03:16 PM) FelixVi: doh - I think it's the 'c' which needs to be "C" | 04:09 |
cr1901_modern | (10:59:16 PM) cr1901_modern: It's BaseSoC* I think | 04:09 |
cr1901_modern | :P | 04:09 |
FelixVi | well, point is that it works now ;) | 04:10 |
*** skay_ has joined #timvideos | 04:12 | |
cr1901_modern | FelixVi: I am not exactly positive on "length = *flashbase++;" and why it's written like that <-- flash image is supposed to embed the length of the image | 04:13 |
cr1901_modern | as well as a checksum | 04:13 |
FelixVi | I think it takes the length from the first object at the base pointer and increments it by 1 | 04:13 |
FelixVi | then takes the crc from there | 04:14 |
FelixVi | but why it's written like that is a mystery to me | 04:14 |
cr1901_modern | B/c it works :P | 04:14 |
*** skay has quit IRC | 04:14 | |
*** skay_ is now known as skay | 04:14 | |
FelixVi | you need to know the operator priority to figure out what it does | 04:14 |
*** skay is now known as Guest57653 | 04:15 | |
FelixVi | so IMO writing it in explicit notation makes it easier to read | 04:15 |
cr1901_modern | ++ has low priority. It's one of the last things done | 04:15 |
FelixVi | but either way, it does not find a valid length, so I assume we're not actually reading from flash :P | 04:15 |
cr1901_modern | Did you update the flash to use spiflash1x? | 04:15 |
FelixVi | when it's on the right yes, but I think on the left it would get resolved before dereferencing | 04:16 |
FelixVi | either way, the fact that we talk about it means the notation is not readable | 04:16 |
FelixVi | unless the mantra is to minimize lines in the code | 04:16 |
cr1901_modern | *b++ = *a++ is a common memcpy idiom | 04:17 |
cr1901_modern | but that's not really important | 04:17 |
FelixVi | agreed | 04:17 |
cr1901_modern | I want to know whether you changed the spiflash to use 1x | 04:17 |
FelixVi | spi_flash.SpiFlashSingle is what I use | 04:18 |
FelixVi | but we get hung up on serial configuration as of now | 04:18 |
cr1901_modern | please show me your code | 04:18 |
FelixVi | hold on - is it more convenient for you to work on misoc or litex? | 04:18 |
cr1901_modern | focus on litex for now | 04:19 |
FelixVi | https://github.com/FelixVi/HDMI2USB-litex-firmware/blob/120c39e8c5c2b16c034e31141ae3bc8d72ba7cf2/targets/saturn/base.py | 04:19 |
tpb | Title: HDMI2USB-litex-firmware/base.py at 120c39e8c5c2b16c034e31141ae3bc8d72ba7cf2 · FelixVi/HDMI2USB-litex-firmware · GitHub (at github.com) | 04:19 |
FelixVi | and the traceback as seen above is what I got from this | 04:20 |
FelixVi | I think line 169 is likely the problem | 04:20 |
FelixVi | well, but it defaults to 115200 in soc_core.py | 04:22 |
cr1901_modern | I have no idea, I've never seen this error before | 04:23 |
FelixVi | it seems like tx is not assigned | 04:24 |
cr1901_modern | It clearly is though, since it's in your platform file | 04:25 |
FelixVi | but one of the terms in uart.py L85-89 is not recognized as migen statement | 04:25 |
FelixVi | you should be able to pick up my platform and target and recreate it on your machine | 04:26 |
FelixVi | it wouldn't be unheard of if that's a cygwin issue -.- | 04:27 |
FelixVi | or python 3.6 :) | 04:27 |
cr1901_modern | Of course you remembered to update the litex provided w/ hdmi2usb. Of course you did. | 04:28 |
FelixVi | either way, I claim " self.submodules.uart_phy = uart.RS232PHY(platform.request("serial"), clk_freq, uart_baudrate)" has all the right arguments | 04:28 |
cr1901_modern | It would be too easy if you forgot | 04:28 |
FelixVi | or does litex not like fractional clk_freq? | 04:28 |
cr1901_modern | No! All of this stuff has worked before! Just not when you use it ._. I'm sorry, but it's driving me nuts lmao | 04:28 |
FelixVi | -.- | 04:28 |
FelixVi | I did not update litex | 04:29 |
FelixVi | just changed the tracer b/c the old version is python 3.6 incompatible | 04:29 |
FelixVi | but that is fixed in my litex repo | 04:29 |
cr1901_modern | Right, that was my point. | 04:29 |
FelixVi | ah OK, I've done that | 04:29 |
FelixVi | I'm war past the auto CSR issue | 04:29 |
FelixVi | *way | 04:30 |
cr1901_modern | "(11:24:37 PM) FelixVi: you should be able to pick up my platform and target and recreate it on your machine" It is currently inconvenient to duplicate your setup | 04:34 |
FelixVi | oh, I mean in your environment | 04:34 |
FelixVi | you should just need the target and platform, right? | 04:34 |
FelixVi | if I disable uart, I get another error complaining about another signal not being a migen value | 04:37 |
cr1901_modern | Felix In RS232PHYTX, could you put a "print(type(pads.tx.eq(0))" before the offending error? | 04:37 |
FelixVi | so I think the problem is in my environment somewhere | 04:37 |
FelixVi | <class 'migen.fhdl.structure._Assign'> | 04:39 |
FelixVi | does litex rely on a present migen installation? | 04:43 |
cr1901_modern | No | 04:44 |
FelixVi | why do we have a migen object then? | 04:44 |
cr1901_modern | Because you must've imported it from somewhere | 04:44 |
FelixVi | shouldn't this be litex.fhdl | 04:45 |
cr1901_modern | https://github.com/FelixVi/HDMI2USB-litex-firmware/blob/120c39e8c5c2b16c034e31141ae3bc8d72ba7cf2/platforms/saturn.py#L1-L3 | 04:45 |
tpb | Title: HDMI2USB-litex-firmware/saturn.py at 120c39e8c5c2b16c034e31141ae3bc8d72ba7cf2 · FelixVi/HDMI2USB-litex-firmware · GitHub (at github.com) | 04:45 |
cr1901_modern | Don't mix migen and litex like that. | 04:46 |
FelixVi | yeah, just found it | 04:47 |
cr1901_modern | Eventually Subsignals will "resolve to" something that can be used in a migen.fhdl._Statement or litex.fhdl._Statement | 04:47 |
FelixVi | now it doesn't know Pins?!? | 04:47 |
cr1901_modern | https://github.com/FelixVi/litex/blob/7df6c9110da7f43f8555539074d9314b68d4687d/litex/build/generic_platform.py#L14 | 04:48 |
tpb | Title: litex/generic_platform.py at 7df6c9110da7f43f8555539074d9314b68d4687d · FelixVi/litex · GitHub (at github.com) | 04:48 |
cr1901_modern | I really should stop hiding the fact that _I'm_ annoyed. Why. Are. The. Errors. Cascading?! | 04:50 |
FelixVi | https://github.com/FelixVi/HDMI2USB-litex-firmware/commit/c024ee58fd4047986962a90580d601b78273b3d2#diff-47bed5475599814fcc3cdcebe4b02429R103 | 04:50 |
tpb | Title: Adding Saturn · FelixVi/HDMI2USB-litex-firmware@c024ee5 · GitHub (at github.com) | 04:50 |
FelixVi | this is what it doesn't like | 04:50 |
FelixVi | adding a reset pin as extension | 04:50 |
cr1901_modern | You need to import litex.build.generic_platform into base.py | 04:51 |
cr1901_modern | I don't see it | 04:51 |
FelixVi | k, it builds | 04:54 |
cr1901_modern | Good. Now commit that. And we can work from there | 04:55 |
FelixVi | it doesn't find a platform definition in the firmware makefile | 04:56 |
cr1901_modern | Add it? :) | 04:57 |
FelixVi | https://github.com/FelixVi/HDMI2USB-litex-firmware/blob/master/firmware/Makefile#L5 | 04:57 |
tpb | Title: HDMI2USB-litex-firmware/Makefile at master · FelixVi/HDMI2USB-litex-firmware · GitHub (at github.com) | 04:57 |
FelixVi | that's just export right? | 04:57 |
cr1901_modern | yes, ideally what you're supposed to do is run a shell script provided w/ hdmi2usb | 04:58 |
cr1901_modern | but I never actually do that | 04:58 |
cr1901_modern | PLATFORM=saturn TARGET=base CPU=lm32 should work | 04:58 |
xfxf | whoa, you support building for sega saturns now? :P | 04:59 |
cr1901_modern | Yes, we decided to create a new Sega Saturn soft core using the j-core CPU | 04:59 |
cr1901_modern | And then add HDMIUSB functionality to our PCB prototype for marketing purposes | 04:59 |
cr1901_modern | (I wish) | 04:59 |
FelixVi | couldn't we use hdmiusb to emulate a sega genesis and play some sonic? | 05:00 |
FelixVi | but let's tackle that tomorrow | 05:00 |
cr1901_modern | Sure, but I wouldn't trust aa 50MHz core to emulate a 68k reliably | 05:01 |
cr1901_modern | fast, accurate, pick one | 05:01 |
FelixVi | https://pastebin.com/rVUg4LuJ | 05:01 |
tpb | Title: python3 make.py --platform saturn --cpu lm32 --target base (at pastebin.com) | 05:01 |
cr1901_modern | never seen that one either | 05:03 |
cr1901_modern | in fact I have no idea what that file is | 05:03 |
FelixVi | pretty sure that's cygwin having an issue with bash files | 05:03 |
cr1901_modern | I'll check | 05:04 |
FelixVi | my best guess is that some package is missing | 05:04 |
cr1901_modern | mithro: When all's said and done, might as well add Saturn to HDMI2USB as a permanent target. It doesn't have I/O built-in but there are definitely cheap PMODs to add HDMI | 05:04 |
FelixVi | cr1901_modern: I literally just cut a HDMI cable cable and retrofit it with molex headers - works fine on my TFT | 05:05 |
cr1901_modern | FelixVi: do "less firmware/hdmi_in.sh" is it in DOS format? | 05:08 |
cr1901_modern | (Yes, yes it is most likely; I get the same error in Cygwin) | 05:09 |
cr1901_modern | run dos2unix -i firmware/hdmi_in.sh and try again | 05:09 |
FelixVi | i tried to remove bom | 05:09 |
cr1901_modern | Please don't do that. | 05:09 |
FelixVi | k, it's reset | 05:10 |
cr1901_modern | I strongly suspect this indeed is cygwin choking on line endings, so change the line endings to Unix | 05:10 |
FelixVi | this is just unbelievable | 05:11 |
FelixVi | thanks for staying with it | 05:11 |
FelixVi | it says 49 0 0 no_bom test *filename* | 05:12 |
cr1901_modern | the hell? | 05:12 |
cr1901_modern | what are you viewing it in? | 05:12 |
FelixVi | it has CR LF line endings | 05:12 |
FelixVi | should I flip it to CR only? | 05:13 |
cr1901_modern | Yes, that is why I said run dos2unix on it | 05:13 |
cr1901_modern | "49 0 0 no_bom test *filename*" Where did this output come from? | 05:13 |
FelixVi | I did, but it still had CR LF | 05:13 |
FelixVi | from dos2unix | 05:13 |
cr1901_modern | dos2unix -i (for in place) | 05:14 |
cr1901_modern | Ummm, I apologize | 05:14 |
cr1901_modern | that's wrong | 05:14 |
cr1901_modern | "dos2unix firmware/hdmi_in.sh" will do in-place | 05:15 |
cr1901_modern | That was totally my fault | 05:15 |
cr1901_modern | "-i" is "info" not "in-place" | 05:15 |
FelixVi | https://pastebin.com/munDB5G0 | 05:16 |
tpb | Title: python3 make.py --platform saturn --cpu lm32 --target base (at pastebin.com) | 05:16 |
FelixVi | yeah, I used my editor to change line endings with the same result | 05:16 |
FelixVi | that's actually not cygwin, but git under windows | 05:16 |
FelixVi | one can change that when git is installed and you can opt to keep unix line endings - but most people don't | 05:17 |
cr1901_modern | FelixVi: That compiler error is known to happen on recent gccs. Haven't gotten around to committing the actual fix. You're gonna most likely get an error in pll.c next after this one | 05:18 |
FelixVi | should I go ahead and compile an old gcc version? | 05:19 |
cr1901_modern | No not at all | 05:19 |
cr1901_modern | Just turn ((token = ...) into (*(token = ...) | 05:19 |
FelixVi | yeah, then I had to fix line endings again | 05:21 |
FelixVi | and now I got the pll_config_10x error | 05:21 |
cr1901_modern | what line endings (again?) | 05:22 |
cr1901_modern | why did they change back? | 05:22 |
FelixVi | for firmware/version_data.sh | 05:22 |
FelixVi | it's another file | 05:23 |
cr1901_modern | oh | 05:23 |
cr1901_modern | right | 05:23 |
cr1901_modern | You can comment out the pll_config_10x for now | 05:23 |
cr1901_modern | IIRC the error is that it isn't used | 05:23 |
FelixVi | I'll get that worked out - when one clones the repo there must be an optioni to checkout LF line endings | 05:23 |
cr1901_modern | core.autocrlf=false | 05:23 |
FelixVi | lm32-elf-ld: firmware.elf section `.bss' will not fit in region `sram' | 05:24 |
FelixVi | lm32-elf-ld: region `sram' overflowed by 4708 bytes | 05:24 |
FelixVi | I'll test and verify the fix for git - ideally we don't change settings | 05:25 |
cr1901_modern | Increase the integrated_sram_size | 05:25 |
FelixVi | there is none as of now - that's commented out | 05:25 |
cr1901_modern | Then paste your regions.ld file | 05:26 |
FelixVi | what is integrated sram vs integrated rom? | 05:26 |
cr1901_modern | one's read-write the other's read-only | 05:26 |
cr1901_modern | they both use block RAM | 05:26 |
FelixVi | oh ok, got that fixed | 05:26 |
FelixVi | now software is done | 05:26 |
cr1901_modern | But I want to see your regions.ld file | 05:26 |
cr1901_modern | from before your fix | 05:26 |
FelixVi | xst is not recognized | 05:26 |
cr1901_modern | Add the cygwin fixes to litex | 05:27 |
cr1901_modern | Or alternative just add Xilinx to your path | 05:27 |
* cr1901_modern doesn't remember where xst lives | 05:27 | |
FelixVi | https://pastebin.com/Z1fzqxLk | 05:28 |
tpb | Title: MEMORY { rom : ORIGIN = 0x00000000, LENGTH = 0x00008000 sram : ORIGIN = 0x10 - Pastebin.com (at pastebin.com) | 05:28 |
FelixVi | this is pre-fix | 05:28 |
cr1901_modern | That doesn't seem right... why would sram require over 32kb? | 05:29 |
cr1901_modern | oh wait | 05:29 |
cr1901_modern | hrm, sram shouldn't require 0x1000 + 4708 bytes IME | 05:30 |
cr1901_modern | but whatever, just increase the SRAM size for now | 05:30 |
cr1901_modern | okay I guess I was wrong, mimasv2's sram_size is 0x4000 | 05:32 |
FelixVi | ah, now we got the path stuff going on again | 05:33 |
FelixVi | source file paths | 05:33 |
FelixVi | I think I know how to fix that | 05:33 |
cr1901_modern | right, so add your path fixes to litex, or just add "wherever xst lives" to your Cygwin path | 05:33 |
FelixVi | that I got fixed | 05:33 |
FelixVi | it's the POSIX thing | 05:34 |
FelixVi | ERROR:Xst:2927 - "\cygwin64\home\dell\HDMI2USB-litex-firmware\build\saturn_base_lm32\gateware\top.prj" line 1: Source file /home/dell/HDMI2USB-litex-firmware/third_party/litex/litex/soc/cores/cpu/lm32/verilog/submodule/rtl/lm32_adder.v does not exist | 05:34 |
FelixVi | ISE running in windows doesn't know /home/ | 05:35 |
FelixVi | at least these things start to repeat - this is probably the last error before it builds gateware | 05:36 |
cr1901_modern | oh right... | 05:37 |
FelixVi | alright, and we're up and running | 05:40 |
cr1901_modern | praise the lord | 05:40 |
FelixVi | phew, that was quite painful | 05:40 |
cr1901_modern | I may or may not have spewed a few profanities in the past hour :3 | 05:41 |
FelixVi | yeah, sometimes I wish I had a boxing bag in the office... | 05:41 |
FelixVi | It turnes out taking a 10 minute walk helps a lot :) | 05:42 |
FelixVi | k, it routed without hesitation | 05:42 |
FelixVi | I think it works | 05:44 |
FelixVi | invalid length is 0xffffffff now - which is because I don't have a firmware image in flash | 05:44 |
cr1901_modern | think? | 05:44 |
cr1901_modern | well, that's good | 05:44 |
FelixVi | I suppose I could boot bios from flash | 05:44 |
FelixVi | let me try that | 05:45 |
FelixVi | what's the boot address in flash now? | 05:45 |
cr1901_modern | that is likely to crash unless you build it w/ the correct relocations | 05:45 |
FelixVi | oh, nvm then :) | 05:45 |
FelixVi | I had some print statement in a loop | 05:45 |
cr1901_modern | And I don't remember... too fried to remember right now | 05:46 |
FelixVi | let me just commit and push everything we did | 05:46 |
FelixVi | and I'll test with the loop when I get to work tomorrow | 05:47 |
FelixVi | unless you really want to know now ;) | 05:47 |
cr1901_modern | Let me know now so I have something to use to sob into my pillow tonight | 05:48 |
FelixVi | sure, this is the new repository: https://github.com/FelixVi/HDMI2USB-litex-firmware/commits/master | 05:50 |
tpb | Title: Commits · FelixVi/HDMI2USB-litex-firmware · GitHub (at github.com) | 05:50 |
FelixVi | should have all the changes to get it going | 05:50 |
FelixVi | I'll clean up history for a PR tomorrow | 05:50 |
cr1901_modern | You're gonna want to _not_ commit the litex changes in your PR | 05:50 |
FelixVi | oh yeah, I use my own one for now | 05:51 |
FelixVi | relocated mitex to my git | 05:51 |
cr1901_modern | in other words please keep that local to your repo | 05:51 |
cr1901_modern | Ahhh I see | 05:51 |
cr1901_modern | you changed where the submodule points to | 05:51 |
FelixVi | yeah, for now | 05:51 |
cr1901_modern | well don't commit that relocation :3 | 05:51 |
FelixVi | hehe, I'll check with you when I got everything staged | 05:52 |
cr1901_modern | Welp, now we can play Sega Saturn using hdmi2usb now | 05:52 |
cr1901_modern | (except the 'Sega' part) | 05:52 |
FelixVi | ;) man, there was some messing around with libraries in the makefile I just remember | 05:52 |
FelixVi | to get the print example going | 05:53 |
xfxf | \o/ | 05:53 |
FelixVi | I hope litex is not different from misoc as far as compiling software goes | 05:53 |
cr1901_modern | it's not | 05:53 |
FelixVi | phew, this should be easy then | 05:53 |
cr1901_modern | they use the same dir structure and libraries. Just different package hierarchy | 05:54 |
FelixVi | builder.add_software_package("test_print") | 05:55 |
FelixVi | what's the equivalent for that? | 05:55 |
cr1901_modern | it should be the same? | 05:56 |
FelixVi | at least that's how I got misoc to compile my test code along with the rest | 05:56 |
FelixVi | but for misoc that was under _main_ | 05:56 |
FelixVi | https://github.com/FelixVi/misoc/commit/e11bb8d884f14486e8c4c054b3982f2b29037875#diff-7cf59b233c36902d34e2f277c8c22223R159 | 05:56 |
tpb | Title: targets/saturn: Adding target for Numato Saturn board · FelixVi/misoc@e11bb8d · GitHub (at github.com) | 05:56 |
cr1901_modern | https://github.com/enjoy-digital/litex/blob/master/litex/soc/integration/builder.py#L51 | 05:57 |
tpb | Title: litex/builder.py at master · enjoy-digital/litex · GitHub (at github.com) | 05:57 |
cr1901_modern | I understand it's literally quicker for me to find it, but I'm out of energy. Please do a grep for missing identifiers for the time being, b/c I'm pretty shot right now :P | 05:58 |
FelixVi | Well, I found it but didn't get it to work | 06:01 |
FelixVi | let me check on it in the morning as I'm also pretty shot | 06:01 |
FelixVi | I am sure I can figure it out when not completely fried | 06:01 |
cr1901_modern | wonder if migen stuff got imported in again by accident | 06:02 |
FelixVi | not that I can see | 06:02 |
FelixVi | but I'll doublecheck that, too | 06:03 |
FelixVi | I got gateware and do get a bios prompt though | 06:03 |
FelixVi | and it doesn't get all zeroes from flash | 06:03 |
FelixVi | so I feel pretty good about this working | 06:03 |
cr1901_modern | did you get something besides all ones from flash too? | 06:04 |
FelixVi | all other litex targets appear to have main() defined - so I'm confused one more time as mimasv2 doesn't | 06:04 |
FelixVi | I got all ones | 06:04 |
FelixVi | which I really hope is flash default when not overwritten | 06:05 |
FelixVi | https://github.com/enjoy-digital/litex/blob/99f2e31b2e673f8a5a977e5a62ebb4ae1c9f19c6/litex/boards/targets/de0nano.py#L113 | 06:05 |
tpb | Title: litex/de0nano.py at 99f2e31b2e673f8a5a977e5a62ebb4ae1c9f19c6 · enjoy-digital/litex · GitHub (at github.com) | 06:05 |
FelixVi | this i.e. calls builder.build(), but we don't as of now | 06:05 |
cr1901_modern | I'm gonna have to retire for the night, sorry | 06:09 |
FelixVi | same here -.- | 06:09 |
FelixVi | I'll try one more thing, but it might have to wait until tomorrow morning | 06:09 |
FelixVi | thanks for all the help! | 06:09 |
FelixVi | have a good night! | 06:09 |
FelixVi | if anything comes out of this, I'll post it here | 06:09 |
cr1901_modern | cool | 06:10 |
FelixVi | k, it doesn't seem to boot either my test code (compiled with misoc) or the bios - but I'll check on that in the morning | 06:18 |
FelixVi | actually, I think I'll be in a bit late tomorrow, but will try to jump right on this | 06:18 |
*** FelixVi has quit IRC | 06:19 | |
*** sb0 has quit IRC | 07:04 | |
*** sb0 has joined #timvideos | 07:16 | |
*** sb0_ has joined #timvideos | 07:32 | |
*** sb0__ has joined #timvideos | 07:33 | |
*** sb0 has quit IRC | 07:33 | |
*** sb0_ has quit IRC | 07:37 | |
*** sb0__ has quit IRC | 08:01 | |
*** rohitksingh_work has quit IRC | 08:11 | |
*** rohitksingh_work has joined #timvideos | 08:13 | |
*** sb0 has joined #timvideos | 10:11 | |
*** CarlFK has joined #timvideos | 10:24 | |
*** ChanServ sets mode: +v CarlFK | 10:24 | |
*** sb0 has quit IRC | 10:37 | |
*** sb0 has joined #timvideos | 11:22 | |
shenki | shorne: nice work with the varargs find! | 11:28 |
shenki | shorne: i wrote a patch and ping works now | 11:28 |
*** rohitksingh_work has quit IRC | 12:31 | |
shorne | shenki: great, let me look at the patch I was just going to log in and write one too | 12:48 |
shorne | shenki: the mail is to the uclibc maintainer, he might just accept the patch as is | 12:48 |
shorne | I am good with the patch as is, now to move onto liteeth | 12:58 |
*** rohitksingh has joined #timvideos | 13:08 | |
*** sb0_ has joined #timvideos | 13:13 | |
*** sb0 has quit IRC | 13:17 | |
shorne | shenki: I tested your patch it works good for me too | 13:17 |
*** sb0__ has joined #timvideos | 13:50 | |
*** sb0_ has quit IRC | 13:50 | |
*** sb0_ has joined #timvideos | 14:11 | |
*** sb0__ has quit IRC | 14:11 | |
*** sb0__ has joined #timvideos | 14:11 | |
*** sb0_ has quit IRC | 14:15 | |
*** Guest57653 is now known as skay | 14:35 | |
*** skay has joined #timvideos | 14:35 | |
*** ChanServ sets mode: +v skay | 14:35 | |
mithro | shenki / shorne: \o/ | 15:57 |
mithro | shorne: I believe shenki has a bunch of stuff going on liteeth | 15:57 |
*** tsglove has quit IRC | 16:50 | |
*** tsglove has joined #timvideos | 16:50 | |
*** tsglove has quit IRC | 16:51 | |
*** CarlFK has quit IRC | 18:16 | |
*** FelixVi has joined #timvideos | 18:32 | |
mithro | Morning FelixVi | 18:42 |
FelixVi | morning, we had pretty good success yesterday | 18:43 |
mithro | FelixVi: that's great! | 18:43 |
FelixVi | toolchain is up and running in Windows, but I see why appveyor might be the way to go in the future | 18:43 |
FelixVi | just setting up, trying to get flashboot to work | 18:43 |
mithro | I found https://github.com/joaope/LocalAppVeyor | 18:44 |
tpb | Title: GitHub - joaope/LocalAppVeyor: Run your AppVeyor builds, locally (at github.com) | 18:44 |
FelixVi | that looks awesome, I just starred it and will take a look at it | 18:45 |
FelixVi | if lm32-gcc can be build with it, life will be easy on the windows end | 18:45 |
mithro | FelixVi: If we can get conda building the Windows packages automatically it makes setting up windows very easy | 18:45 |
FelixVi | mithro: I'm interested - my plan is to show that litex is useful as of now | 18:46 |
FelixVi | when people realize how much user control that enables, they will ask for a compiler toolchain pretty soon | 18:47 |
mithro | FelixVi: great! :-) | 18:47 |
FelixVi | so I think a Windows extension is the only option if you want to allow people to program their CPU | 18:47 |
FelixVi | To get started, cygwin is probably OK - but I'll start looking at appveyor | 18:49 |
FelixVi | I think it might be useful for distributing other packages as well, so there could be a pretty big benefit | 18:49 |
FelixVi | How is it different from travis ci? | 18:49 |
FelixVi | should I look at different alternatives or are we going to go with appveyor no matter what? | 18:50 |
mithro | AppVeyor is basically the "windows" version of Travis-CI - Travis only supports Linux/Mac | 18:50 |
FelixVi | ah, so that's a pretty good argument | 18:50 |
FelixVi | I know too little to have a preference - I'll play with the local version | 18:51 |
mithro | FelixVi: We would still keep Travis for Linux/Mac | 18:51 |
FelixVi | Yeah, It seems to be the standard for most projects | 18:53 |
FelixVi | I'm a scientist by training, so software development is something I'm trying to pick up on the side | 18:54 |
FelixVi | no excuse, but hopefully that gives a little context why I don't know a lot of these things already | 18:54 |
*** rohitksingh has quit IRC | 18:58 | |
FelixVi | https://github.com/timvideos/HDMI2USB-litex-firmware/blob/89f5b6604ac921866ca5a7d6dae83f5882d3902a/make.py#L120 | 18:59 |
tpb | Title: HDMI2USB-litex-firmware/make.py at 89f5b6604ac921866ca5a7d6dae83f5882d3902a · timvideos/HDMI2USB-litex-firmware · GitHub (at github.com) | 18:59 |
FelixVi | is there a way to add a software package from the command line? | 19:00 |
mithro | FelixVi: not at the moment | 19:00 |
FelixVi | I'm trying to compile some test firmware along with the project and this seems to be the only place where one has access to the builder | 19:00 |
mithro | FelixVi: Feel free to add a command line argument to make.py | 19:01 |
FelixVi | that's something I might add | 19:01 |
FelixVi | I think ultimately I'll make it standalone so that people can compile firmware with default libraries easily | 19:02 |
mithro | FelixVi: at some point soon I'm going to rename the current firmware in firmware/ to something like "firmware/hdmi2usb" -- we now have Linux and MicroPython firmwares in development as well | 19:05 |
FelixVi | is that on openrisc or risc-v? | 19:07 |
FelixVi | or are you using the lm32 mmu? | 19:07 |
FelixVi | i'm curious about the embedded risc-v variety, but things don't seem very stable at the moment - not sure if there's even a spec yet | 19:07 |
mithro | FelixVi: or1k | 19:08 |
mithro | FelixVi: I hope to add sh2 and risc-v to LiteX in the near future | 19:08 |
FelixVi | my hope is to have a student work on risc-v next spring - but that's still up in the air | 19:09 |
*** tsglove has joined #timvideos | 19:21 | |
mithro | FelixVi: I'm more then happy to merge the saturn + waxwing support into the HDMI2USB-litex-firmware repo | 19:48 |
FelixVi | mithro: I think that's useful to people - I'm still stuck with the Makefile, but should have something to report back by the end of the day | 19:54 |
cr1901_modern | "not sure if there's even a spec yet" user mode spec is done, but privileged spec is under revision (which includes interrupts). | 20:21 |
cr1901_modern | picorv32 opts not to use the privileged spec to implement interrupts | 20:21 |
*** msantana has quit IRC | 20:33 | |
*** jea[m] has quit IRC | 20:33 | |
*** medicalwei has quit IRC | 20:33 | |
*** CarlFK[m] has quit IRC | 20:37 | |
*** mikal has quit IRC | 20:41 | |
*** CarlFK has joined #timvideos | 20:42 | |
*** ChanServ sets mode: +v CarlFK | 20:42 | |
*** mikal has joined #timvideos | 20:45 | |
*** msantana has joined #timvideos | 20:49 | |
*** medicalwei has joined #timvideos | 20:49 | |
FelixVi | cr1901_modern: Ah, so I think early next year might be a good time to start | 21:08 |
FelixVi | if you're after linux, though, you're gonna run the integer version I assume? | 21:09 |
FelixVi | either way, I generated some firmware that I'll test now - but not sure about the flash offsets still | 21:10 |
FelixVi | memory_region,spiflash,0x20000000,16777216, | 21:20 |
FelixVi | this is in csr.csv - isn't the flash region very much on the small side? | 21:20 |
FelixVi | the saturn has 128Mbit flash | 21:21 |
FelixVi | oh nvm, that's in MByte | 21:22 |
FelixVi | cr1901_modern: I'm really sorry but I just realize that the Numato schematics aren't accurate | 21:29 |
FelixVi | it says it's a M25P16 but those don't come in 128Mbit | 21:29 |
mithro | FelixVi: you can use openocd to read the flash ID to figure out what it is | 21:34 |
mithro | shenki: Can you look at https://github.com/timvideos/HDMI2USB-litex-firmware/pull/377 ? | 21:34 |
FelixVi | N25Q128A13ESE40 is what I got | 21:34 |
tpb | Title: Better parallel make support by mithro · Pull Request #377 · timvideos/HDMI2USB-litex-firmware · GitHub (at github.com) | 21:34 |
mithro | CarlFK: When this build finishes -> https://travis-ci.org/timvideos/HDMI2USB-litex-firmware/builds/312632988 -- can you try the download firmware script? | 21:36 |
*** froztbyte has quit IRC | 21:41 | |
*** juliusb has quit IRC | 21:41 | |
mithro | lol - no programmers using travis - watch the first 5 minutes of https://www.youtube.com/watch?v=lG5AIeFaeLk :-P | 21:50 |
FelixVi | cr1901_modern: Is there a good way to see if we can write/read from flash? | 21:55 |
*** froztbyte has joined #timvideos | 22:04 | |
*** juliusb has joined #timvideos | 22:04 | |
FelixVi | cr1901_modern: I'm sorry, I have to switch projects - I pushed all the latest files and should be able to get back to this soon | 22:25 |
Generated by irclog2html.py 2.13.1 by Marius Gedminas - find it at mg.pov.lt!