Friday, 2017-09-08

*** tpb has joined #timvideos00:00
cr1901_modernmithro: Yes, I wanted you to review my commit yesterday for another round of feedback (and totally forgot to tell you).00:13
mithrocr1901_modern: Please put a comment on the pull request saying as such - otherwise I'll ignore it :-P00:13
cr1901_modernmithro: https://github.com/timvideos/flterm/pull/3#issuecomment-327964545 :D00:15
tpbTitle: Add XMODEM support compatible w/ HDMI2USB by cr1901 · Pull Request #3 · timvideos/flterm · GitHub (at github.com)00:15
mithrocr1901_modern: Just two minor changes and we can merge...00:18
cr1901_modernmithro: Ok, cool00:19
mithroCarlFK[m]: Your new bug doesn't make any sense :-P00:26
*** whatnick has joined #timvideos00:27
cr1901_modernmithro: What's wrong with the brace wrapping on the doxygen doc blocks? They all have that ending00:27
cr1901_modernoh wait wait nevermind00:27
cr1901_modernmithro: Pushed00:28
mithrocr1901_modern: merged - now how about the other side :-P00:31
cr1901_modernmithro: Working on it :P00:33
*** sb0 has joined #timvideos01:03
*** sb0 has quit IRC01:18
cr1901_modernmithro: Do you have a pinout for the JTAG header?02:31
mithrocr1901_modern: On?02:35
cr1901_modernmithro: On Opsis... I wanted to see whether I could program the FPGA from Windows via direct connection to FPGA's JTAG pins02:35
cr1901_modern(this appears to be "no")02:35
mithrocr1901_modern: You should most definitely be able to do that02:36
mithrocr1901_modern: That is how _florent_ does it02:36
mithrocr1901_modern: The pins are standard positioned and labeled on the silkscreen02:37
cr1901_modernOh... oops02:37
cr1901_modernmithro: I assumed I couldn't do it b/c I read the FPGA's JTAG pins go the the FX2 chip02:39
mithrocr1901_modern: They do02:39
cr1901_modernIs it a chain of multiple devices?02:39
cr1901_modernFX2, then LX45?02:40
cr1901_modernNope, accoding to OpenOCD, only thing there is the FPGA...02:54
mithrocr1901_modern: Correct02:58
cr1901_modernhrm, Tera Term also can't display characters properly in windows using this driver ._.03:03
cr1901_modernAnd neither can PuTTY (which numato themselves use03:05
cr1901_modernmithro: ^^ What's the easiest way to get in contact w/ Numato?03:06
mithrocr1901_modern: With the Mimas?03:06
cr1901_modernmithro: Sadly, it extends to the Opsis too03:07
mithrocr1901_modern: We don't have windows drivers for the Opsis?03:07
cr1901_modernmithro: No, we do... just the serial port has the same problem w/ garbled characters on the Opsis as it does w/ the Mimasv203:08
mithrocr1901_modern: Where are the Opsis windows drivers?03:09
cr1901_modernmithro: http://numato.com/product/numato-opsis-fpga-based-open-video-platform Downloads tab03:09
tpbTitle: Numato Opsis: FPGA-based open video platform | Numato Lab (at numato.com)03:09
mithroI started creating Windows drivers here -> https://github.com/mithro/HDMI2USB-and-Numato-Opsis-Windows-Drivers but never finished it...03:10
tpbTitle: GitHub - mithro/HDMI2USB-and-Numato-Opsis-Windows-Drivers: Drivers and related code/data for improving the hardware experience for the HDK on Windows (at github.com)03:10
mithroWow, numato's website just changed...03:10
mithroI've never seen them before -- so no guarantees they work at all :-P03:11
xfxflol what03:12
xfxfofficial windows drivers!?03:12
cr1901_modern"you'll need a code-signing certificate" there's a way around this so you can deploy self-signed drivers without requiring test mode03:12
xfxfwow03:12
cr1901_modernbut I don't remember the details03:12
xfxfthey've actually made proper inf/cat files for the usb device id's03:12
xfxfjust a cursory look over the zip contents just makes the device recognised properly under windows (capture, terminal, tofe lowspeed io), doesn't provide any software03:13
xfxfmithro: i'm amused this happened without your knowledge lol03:13
xfxfalso this means they're selling them again?03:13
mithroxfxf: Well, I sent them files to sign and stuff and they sent me stuff back - I didn't realize they had published stuff03:14
xfxfmithro: ah, the contents of their zip look the same as your repo03:14
cr1901_modern... bahaha, really :P. Nice!03:14
mithroIt *definitely* wasn't finished03:14
xfxfi rly should finish the bloody UI03:14
cr1901_modernin any case, something's very wrong w/ both Numato serial ports03:14
mithroxfxf: Yes you should03:15
cr1901_modernI don't have a way to debug this...03:15
xfxfi was quite enjoying writing it, different paradigm to web programming03:15
xfxfactually had a legitimate reason to use explicit threading03:15
mithrocr1901_modern: I wouldn't waste time on it03:15
cr1901_modernmithro: I don't intend to, but it's still a bug/problem for windows development.03:16
mithrocr1901_modern: Log a bug on the HDMI2USB-fx2-firmware repo about it03:16
CarlFK[m]mithro (IRC): looks like that edid change landed ^ed6c81b (Tim Ansell 2017-08-17 13:31:39 +1000 339)     {03:16
cr1901_modernmithro: Will do03:17
CarlFK[m]my opsis version built: Jul 27 2017 01:11:2503:17
cr1901_modernmithro: Just FYI, I've never had issues w/ FTDI or Keypsan CDC drivers; Numato seems to be the only place where I have issues.03:17
mithroCarlFK[m]: Hrm.... Looking at https://github.com/timvideos/HDMI2USB-litex-firmware/blame/master/firmware/processor.c it seems like it was 8 months ago?03:18
tpbTitle: HDMI2USB-litex-firmware/firmware/processor.c at master · timvideos/HDMI2USB-litex-firmware · GitHub (at github.com)03:18
CarlFK[m]hmm.. um..03:19
cr1901_modernmithro: Btw... you said you have a blob of Numato's PIC firmware for the mimasv2 somewhere? (Just in case)03:20
mithrocr1901_modern: Haven't had time to look for it yet03:20
mithrobe back later - getting lunch03:20
cr1901_modernmithro: That's fine... have fun03:21
* CarlFK[m] uploaded an image: file1504841145208.jpg (412KB) <https://matrix.org/_matrix/media/v1/download/matrix.org/GMZkokmsRWREUSZckPwlzzhp>03:26
*** rohitksingh_work has joined #timvideos03:35
mithroCarlFK[m]: plug in a Windows or Mac computer03:36
CarlFKmithro: um... no.  ;)   How about I file a bug report with whatever that GUI is?    Whats the command line tool to show whatever that string is called ?03:38
mithroxrandr --xprops I think?03:38
*** sb0 has joined #timvideos03:39
*** paradisaeidae has joined #timvideos03:59
Ishan_Bansalmithro : Actually I feel asleep last night so I fixed some of the errors but I try to fix all the errors by tonight.04:05
mithroIshan_Bansal: no hurry, make sure you get good nights sleep :-)04:06
*** paradisaeidae has quit IRC05:04
*** rohitksingh_work has quit IRC05:06
*** sb0 has quit IRC05:58
*** nueces has quit IRC06:08
*** sb0 has joined #timvideos08:16
*** sb0 has quit IRC08:33
*** sb0 has joined #timvideos09:16
*** cr1901_modern1 has joined #timvideos10:11
*** cr1901_modern has quit IRC10:13
CarlFKmithro: juser@cnt1:~$ hwinfo --monitor --short11:51
CarlFKmonitor:                              HDMI2USB-1 HDMI2USB-2 Acer AL151111:51
mithroCarlFK: hrm?11:52
CarlFKhwinfo --monitor shows   Model: "HDMI2USB-2"   Vendor: OHW11:52
mithroCarlFK: That is what I expect?11:53
CarlFKmithro: yes - mostly just showing you what the command is in case you need it11:54
CarlFKissue closed.  Now I can make coffee11:57
mithroCarlFK: Happy to solve your bug before you created it :-P12:25
CarlFKmithro: do more of that!  :p12:57
*** ChanServ sets mode: +v thaytan_12:58
*** thaytan_ is now known as thaytan12:58
*** nueces has joined #timvideos13:07
*** rohitksingh has joined #timvideos13:29
*** tsglove has joined #timvideos13:50
*** nueces has quit IRC14:04
*** nueces has joined #timvideos16:05
*** cr1901_modern1 is now known as cr1901_modern17:24
*** rohitksingh has quit IRC18:14
*** CarlFK has quit IRC22:14
cr1901_modernmithro: I just realized something (I think)... the opsis bitstream (i.e. the .bit/.bin file generated by ISE) embeds an extra copy of the LiteX BIOS in addition to the copy that's stored in flash. Is this correct?22:28
cr1901_moderncc: _florent_ ^^22:36
mithrocr1901_modern: yes22:58
mithrocr1901_modern: we want the same flash layout for consistence22:58
mithroBut having an embedded gateware means we don't have to flash the bios seperately22:59
cr1901_modernmithro: So why doesn't mimasv2 have the same issue?23:04
mithroThe mimasv2 doesn't have the space being an lx923:07
mithrocr1901_modern: at some point the lx45 in the Atlys / Opsis might get to full and we have to kick the bios out23:08
mithroWe should probably do that for the hdmi2usb target at some point23:09
cr1901_modernI see... I tried reprogramming the opsis earlier... just as a test I loaded a bitstream by itself (no flash), and was surprised to see the LiteX BIOS w/ a "Sept 6, 2017" date23:09
cr1901_modern(instead of a MiSoC BIOS w/ Jan 2016 date :P)23:09
cr1901_modernSo it threw me off a bit23:09
mithroSorry23:10
cr1901_modernNo worries23:11
cr1901_modernright now I have a bigger issue. I flashed new firmware successfully, but I lost ttyACM0 :/23:11
cr1901_moderndmesg says: Product: Opsis (JTAG Mode)23:12
mithroIt does make it quick to load the gateware and then tftp the firmware during development23:12
cr1901_modernmithro: True :P23:12
mithrocr1901_modern: the FPGA will reset the FX2 after booting23:12
cr1901_modernSo this indicates the FPGA failed to boot properly (because it didn't exist JTAG mode)?23:13
mithroNot necessarily23:13
mithrocr1901_modern: I sent you a lsio board right?23:14
cr1901_modernmithro: Yes, you did. It's attached to my Opsis right now23:15
mithrocr1901_modern: you can use the USB UART on that too see everything even when the FX2 is being reset23:15
mithroYou have to set an environment variable to get that to happen23:16
mithroTo build a gateware with lsio board support23:16
mithroOtherwise, just remove the jumper that will prevent the FPGA from resetting the FX223:17
cr1901_modernmithro: Worth a shot. B/c right now my current status is... I can program the Opsis flash via my JTAG adapter (TLDR; it is most convenient for me right now compared to the "mode switch" way). But ttyACM1 decided to disappear when I power cycled the board23:17
cr1901_modern(power cycle == "unplug it/plug it back in")23:18
mithrohttps://opsis.hdmi2usb.tv/features/usb-peripheral.html#cypress-fx2-reset-circuit23:18
* cr1901_modern takes a look23:19
mithroWhat target are you flashing with at the moment?23:19
cr1901_modernThe flash.bin generated from opsis_lm32_base + bios + hdmi2usb firmware23:19
cr1901_modernI flashed it at address 023:20
mithroThe fx2 should come up in JTAG mode in that config in theory23:20
mithroBtw at some point I want to get mode switch working on windows23:21
cr1901_modernmithro: Unplugging opsis USB cable now and plugging back in.23:22
mithroNow we have fx2 loader in python that should be more doable23:22
cr1901_modernmithro: "Btw at some point I want to get mode switch working on windows" Understood. Just doing what I thought would be the quickest way :P.23:23
mithroYeah, perfectly reasonable23:23
mithroI was just hinting that might be on your to-do list next :-)23:24
cr1901_modernmithro: That too :P23:25
cr1901_modernmithro: Okay, I have some good news and bad news23:25
cr1901_moderngood news is Linux detects the device23:25
cr1901_modernbad news is everything else: https://hastebin.com/rufipefago.vbs23:25
mithroIf we can port the xmodem code to the FX2 (and JTAG rather than SPI flash mode)23:26
mithrocr1901_modern: that means the FX2 is in failsafe mode23:26
cr1901_modernmithro: It is my intent to make libmodem able to target the 8051's w/ the limited buffer space23:26
cr1901_modernmithro: I swear I didn't do anything bad... I think23:26
mithroIE the FX2 was reset and it was unable to load the FX2 firmware off the FPGA23:27
cr1901_modernVID/PID don't match Cypress in the dmesg output I linked23:28
mithrohttps://opsis.hdmi2usb.tv/getting-started/usb-ids.html#summary23:28
mithroBtw would appreciate help with updating the docs too :-)23:29
cr1901_modernmithro: Okay that's fair... let me just un-hose my Opsis first23:30
mithrohttps://github.com/timvideos/HDMI2USB-numato-opsis-docs?files=123:30
tpbTitle: HDMI2USB-numato-opsis-docs/ at master · timvideos/HDMI2USB-numato-opsis-docs · GitHub (at github.com)23:30
cr1901_modernmithro: According to your table, I'm in "Unconfigured mode"23:33
mithroYeah23:35
* cr1901_modern consults FX2 datasheet23:35
mithroMeans the FX2 booted from the EEPROM but was unable to read a full firmware from the FPGA23:35
mithroYou won't find it there23:36
cr1901_modernmithro: Oh, I was wondering how the FX2 knows which I2C secondary it knows to talk to23:36
cr1901_modernSince the FPGA and phyiscal EEPROM can both serve that role23:36
mithrocr1901_modern: You can now send the FX2 firmware via USB using fxload23:37
mithrocr1901_modern: the FX2 loads this program from the EEPROM -> https://github.com/timvideos/HDMI2USB-fx2-firmware/tree/master/microload23:38
tpbTitle: HDMI2USB-fx2-firmware/microload at master · timvideos/HDMI2USB-fx2-firmware · GitHub (at github.com)23:38
cr1901_modernmithro: okay let me do that...23:39
mithrocr1901_modern: the EEPROM is only 128 bytes, it isn't really big enough to store a real FX2 program23:39
cr1901_modernWait the docs say 2048 kilobits23:39
mithro2048 kilobits == 256 kilobytes -- but the top 128 bytes are not writable IIRC23:41
mithrohttps://github.com/mithro/HDMI2USB-mode-switch/blob/opsis-prod/opsis_eeprom.py23:44
tpbTitle: HDMI2USB-mode-switch/opsis_eeprom.py at opsis-prod · mithro/HDMI2USB-mode-switch · GitHub (at github.com)23:44
cr1901_modernOkay, got a i2c-prod.hex23:45
mithroThat doc needs some updates - the eeprom that was populated ignores the i2c address lines...23:45
mithrocr1901_modern: you don't need that23:45
mithrocr1901_modern: all you need to do is an "fxload <fx2 firmware>" - "hdmi2usb-modeswitch --mode=jtag" will do it for you23:47
mithrocr1901_modern: or build a gateware with lsio support and then use the UART on that to see what is going wrong...23:47
mithrocr1901_modern: don't touch the eeprom  otherwise it will be a pain to get working again :-P23:49
mithropaddatrapper: you going to be around this weekend?23:49
cr1901_modernmithro: I won't lol... but at some point I'd like to be competent enough that I could touch the eeprom safely :P23:52
cr1901_modern(Also recall I do have an external JTAG/SPI/I2C breakout programmer)23:53
cr1901_modernSo as incompetent as I might be tonight, it's not likely I'll actually truly hose my device (famous last words)23:53
mithrocr1901_modern: it's actually pretty hard to get into a state were you can't recover by just removing some jumpers23:53
cr1901_modernmithro: Okay, so now I'm back into JTAG Mode for the USB device returned23:55
mithrocr1901_modern: what did you do?23:56
cr1901_modern"hdmi2usb-modeswitch --mode=jtag"23:56
cr1901_modernas soon as it finished dmesg showed the device reporting itself in JTAG mode23:56
cr1901_modernUnplugging the USB cable and back in- device still shows up in JTAG mode23:58

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