Shop OBEX P1 Docs P2 Docs Learn Events
Still pulling out of FTDI hell — Parallax Forums

Still pulling out of FTDI hell

RANT MODE = 1

Man, I spent a ton of time today trying to get Prop Plugs and or the 123 board to talk to a PC. Finally found one Prop Plug that seems to work, until it doesn't, then I change ports, wait, pray to the voodoo gods, and it works again.

Any of you guys have this trouble? Last time I worked with these Plugs and PC, it was stable. Could run for a day, no worries.

That aside, I'm up and running on the new image. DE2 for now, mostly because the 123 just isn't talking. But it's LED's are awesome! So there is that. I'll give it a go on an entirely different machine later on. I'm so @#$(&@)#(&$@#% I just want to write some PASM...

:)

Oh, and screw Apple. I made a GREAT setup with Win 7, Quartus, Virtual Box, and the FTDI support is absolutely horrible. (and yes I did all the remove Apple .kext, dork around with the two MacOS version stuff I found out there and it only ever sort of worked) Maybe I'll come back to that because I really wanted to just use Mac this time around. But not with how things are working.

RANT MODE = 0

Comments

  • Remember to breathe Potatohead! :)
    Hope you get it sorted soon.
  • Seems if I use just ONE port, and don't futz with it...

    Maybe this laptop is getting crappy on USB. Boy, was I PO'ed though.

  • AleAle Posts: 2,363
    Try the hoodoo gods when the voodoo are busy...

    I don't know where the deal is but some USB devices are not always recognized, like unplugging them doesn't clean the state and then replugging them mean they go into this "non-working" old state... happens to my pickit 3 quite often...no idea if it is ftdi based or no though...
  • Yeah, I think I'm going to yank all the USB drivers and go back to what I think was there last time I did Propeller stuff on this machine. There have been some updates since, and it's just not stable at all.

    I pretty much need to leave it unplugged, try it until it takes, then go while it works...
  • RaymanRayman Posts: 14,767
    edited 2015-10-11 11:57
    I haven't had that kind of intermittent behavior.
    Well actually I think there was a problem once with some other program that kept polling the ports and messed it up...

    BTW: I use sometimes VirtualBox on MacBook Air with Win10 for Propeller work and it works just fine...
  • I've a 2012 MacBook Pro, and it's been an excellent machine. Just refuses to work with anything FTDI.

    What is your OS on that one? Maybe 10.10 is at issue. I could upgrade. 10.6 was pretty awesome. I had no trouble at all.

    Of course, the same could be said for the Win 7 machine I'm on too. Hard to believe both got some mess or other, but anything is possible. I'll trudge through a clean sweep on all COM / USB related things another day.
  • RaymanRayman Posts: 14,767
    I just remembered a time when it was a bad USB cable causing bad connections....
  • mindrobotsmindrobots Posts: 6,506
    edited 2015-10-11 15:17
    Potatohead, I recall s similar problem I had with my Mac - I think it was on 10.10 - it just stopped doing FTDI. There's a fix but I need to be on a PC (not phone) so I can search. I did make a forum post.


    HERE it is!!

    This cleared up my FTDI issues on my 10.10 Mac Mini
  • potatoheadpotatohead Posts: 10,261
    edited 2015-10-11 16:36
    I tried that.

    So, what I'll do is let it all sit a day. Gonna go up on the mountain to play some. I'll get new cables and pull my old XP machine out as a baseline. It worked perfectly day in and day out, and obviously has NO updates. It should fire up and do what it has always done with this stuff.

    If it does, I'm in driver hell. If it doesn't, I'm in hardware hell. But, I'll know at least.

  • jmgjmg Posts: 15,175
    If USB is hopelessly tangled, can you write to a SD card and somehow use that ?
    Or, use some old box as a USB bridge ?
  • Maybe. At this stage, I really need that rapid, write it, run it, think on it cycle.

    And that's the test cycle anyway...

    I will probably take the punishment and just make the USB work, whatever that takes. Was just cranky at a large block of fun time got biffed. Might have had a nice bitmap done given the time USB consumed.
  • Took the punishment, and removed everything related to USB on my Win7 machine, reboot, install fresh, recent. Total Smile.

    Went back a revision, total Smile.

    Changed cable. Total Smile.

    Connected Prop Plug to old XP machine. Awesome. Same as last time. And that's crappy.

    Went back to Win7, everything works golden. ???

    I'm not touching it. Both PropPlugs work, even the one that never touched the XP machine this time around.

    Voodoo. But I'll take it. Now it doesn't take 10 plug, unplug cycles to maybe run code once.

  • Took the punishment, and removed everything related to USB on my Win7 machine, reboot, install fresh, recent. Total Smile.

    Went back a revision, total Smile.

    Changed cable. Total Smile.

    Connected Prop Plug to old XP machine. Awesome. Same as last time. And that's crappy.

    Went back to Win7, everything works golden. ???

    I'm not touching it. Both PropPlugs work, even the one that never touched the XP machine this time around.

    Voodoo. But I'll take it. Now it doesn't take 10 plug, unplug cycles to maybe run code once.

  • See? If only you used Linux... :)
  • potatoheadpotatohead Posts: 10,261
    edited 2015-10-14 05:22
    Right now, if I used Linux, it would be a net time loss for me. I've got machines, work, applications to support, and that set of dependencies is best resolved with Win 7 and Mac OS.

    This one problem was a PITA, but I've actually gained a ton working how I do. So no big deal. Once the Mac is sorted, I'll move Prop work to that and be golden for a long time. Been itching to do that for a while now. I did give Linux a spin a while back. After a setup, virtual machine to handle some apps, etc... it just wasn't where I need it to be professionally. BTW, the Mac with Parallels actually is. Runs way better than I would expect. I've got Virtual Box setup on it, and for Prop work, I think that will actually do well.

    I do have a live Linux or two that I will boot, from time to time. Stripping passwords from a locked PC, or doing filesystem work / data rescue. Works a treat! But it's just not a daily driver for me for a lot of reasons. And those reasons pay for the toys too. No brainer.

    The nice thing is I'm free to move. I'm OS fluent. It's all about time / materials optimization.
  • Update: Found the voodoo!!

    It's a bad interaction between the PropPlug FTDI combination and the ASUS Display Link. Set services to manual, and life is good now. I just won't use that secondary USB display and a Prop Plug. This is fine, because I've never dual screened it in that way. Not missing anything I really want to or have to have.

    Now I thump on the Mac tomorrow, because that is still the primary P2 target.
  • Heater.Heater. Posts: 21,230
    edited 2015-10-14 08:36
    Electrodude,
    If only you used Linux...
    If only you used Linux you might be in my situation:

    I plug in a USB/Serial adapter, any kind not just FTDI. A kernel message announces some error and that it is disabling some interrupt. The adapter works fine. BUT, my mouse has become slow, unresponsive and jerky. The machine is barely usable until the next reboot.

    All this on Debian Jessie.This was not a problem under Wheezy on the same machine.

    Given the trouble people have with USB on all manner of machines and operating systems I don't blame my Linux. I blame USB itself. Why is USB so crappy?

    Try reading some USB specifications. Then you realize why USB is so crappy and never works. Despite having been developed since 1998 or whatever! The specs. are huge tortuous and complex. How could anyone dream up such a complex way to get the simplest thing in the world, a serial port?

    Remember when Bill Gates demoed USB to the public on Win 98 for the first time? When he plugged in the cable the machine blue screened immediately! The writing was on the wall. We should have just rejected USB then and there.

    And thus concludes my morning rant.




  • TorTor Posts: 2,010
    edited 2015-10-14 09:29
    USB and FTDI work fine on my Jessie Debian (no mouse issues), but I think that's just because the hardware happens to work.
    And yes USB is horrible as a protocol. Unbelievably so. It's a miracle anything works at all. But you can kind of see why, when you look at USB host adapters.. even the Ebay ones (if you want to install a controller into your PC because it doesn't have one, or it doesn't have USB 3.0 already) have just recently come down in price. Until last year they cost as much as some of the FPGA development boards. Those USB host controllers are intricate.

  • Heater.Heater. Posts: 21,230
    Yep, it's a quirk of the USB hardware on that motherboard together with whatever kernel driver for it that has been broken in the move to Jessie. My other Debian Jessie machines don't have a problem.
  • "If only you had used Linux"

    I started down the P2 trail on Linux until I found PNUT unable to talk to the P2 when running under Wine. Still haven't been able to make that work so any P2 stuff is now done on Win10.
  • cgraceycgracey Posts: 14,208
    edited 2015-10-14 12:01
    I wish USB had been something that could have been more easily bit-banged for low-data-rate uses. They put CRC response requirements into the protocol that pretty much necessitated custom silicon. Doubtful that such things ever detected many errors. More relaxed approaches could have been 99.99% as effective. Seems like they wanted to make it very exclusive. Make everyone pay to play. I don't like stuff like that. And this notion of logging everything that ever gets plugged into a machine is very obnoxious, as if anonymity is verboten.
  • potatoheadpotatohead Posts: 10,261
    edited 2015-10-14 12:18
    Indeed.

    It's small and easy, though whoever designed the, "have to look at it every single time and still get it wrong" plug deserves a darwin award, or something. (prolly something because civilized, but it's annoying as all get out) Bonehead engineering right there.

    So we use the Smile out of it, and it's gotten fast too, but the basis is crappy.

  • Sir GawainSir Gawain Posts: 32
    edited 2015-10-14 15:23
    When I have problems, there is usually one of two things that help.
    With Windows, I have found that sometimes the device has to be plugged in for quite a while before I can access it.
    Secondly, a reboot can help; especially if the COM port / usbtty* was previously used by the device or another device without a reboot.
    It is inconvenient to reboot, but it has helped at times.
    Hope it helps.
Sign In or Register to comment.