Shop OBEX P1 Docs P2 Docs Learn Events
SmartPin USB (was: SmartPin state machine modes) - Page 11 — Parallax Forums

SmartPin USB (was: SmartPin state machine modes)

1678911

Comments

  • MJBMJB Posts: 1,235
    Cluso99 wrote: »
    The PID/VID has been discussed on many forums. Some people/companies bought PID/VID groups from USB org when there were no sub-licensing restrictions but the USB have been heavy handed with them. Now you cannot sub-license the VID/PID.

    For use here, there are some VID/PID numbers that some users decided can be used and you can get one+ from a website for free. They are not valid VID/PIDs, just what some users have decided to use. The general consensus seems to be that VID/PID cannot be patented so you are free to use what you like, but alas, there is always the concept that they may get legitimately allocated someday.

    For the time being, I suggest we just use some of these.

    From what I understand, you need to join the USB.org for some crazy amount like $7Kpa. Then you buy a PID/VID set for ~$1500. Now you need to test your product for compliance - more $$$ to USB org. Then MS gets their $$$ for testing and including your USB driver in Windows. This is a regular cost, each release of Windows, Windows Server/NT, etc. Then of course, you need to be a MS registered developer (free?) but then you need to buy MSDN (or whatever they call it now) - it's an SDK plus all software - used to be ~$3500pa but I heard that was doubled a couple of years ago.

    My recommendation... Just do the hw. Don't go near the USB org as once you sign up you are committing to licensing their stuff.

    I think I posted this quite some time ago already
    here you can get a PID cheap
    mcselec.com/index.php?page=shop.product_details&flypage=shop.flypage&product_id=92&category_id=20&option=com_phpshop&Itemid=1
  • cgraceycgracey Posts: 14,152
    edited 2016-02-25 00:54
    MJB wrote: »

    From that link:
    Another option is to buy a PID from MCS. Together with the VID you will have a unique combination.
    MCS has sold PID's since 2005.
    When MCS purchased the VID, there was NO INFORMATION about the usage of the VID-PID.
    USB-IF was only focused to get a payment. There were no rules or conditions or a contract.

    That changed in June 2009 when USB-ORG wrote an email that it was not permitted to sell VID or PID.
    MCS pointed out that in The Netherlands you can not enforce or change rules AFTER a product/service is sold.
    So we continued as usual.
    In reaction USB-ORG offered our money back but that would mean existing customers would not have a valid PID anymore.
    So we got some more letters and finally USB-ORG wrote a letter that they revoked our VID.

    Of course our VID can not be re-used by USB-ORG. This means that our VID will still be unique.

    If you want to produce a USB device that need to be tested/verified by USB-ORG you need your own VID.
    If you only need a real unique VID & PID combination, you can still use ours.
    So what we offer is a unique VID & PID combination.
  • RaymanRayman Posts: 14,640
    Interesting... I wonder if Windows would allow a disavowed VID device to connect...
  • rjo__rjo__ Posts: 2,114
    edited 2016-02-25 03:37
    It seems to me that what is true in the Netherlands is also true in the United States. You cannot really enforce a contract that says once you buy this you cannot resell it. And you cannot enforce a rule about a product that you created after you sold the product. I suppose copyright protection could be invoked, but isn't the unlimited copying implied in the original sale? What is the difference if MCS uses it's VID exclusively or allows others to do so. How does this harm USB-ORG? The alternative is to buy a product that has a VID and add it in... so those folks might be harmed, but do they have any standing in court? I doubt it.

    Windows can do anything it likes... but in the process, they would open up a legal liability for USB-ORG. Who knows, after the lawsuit, maybe the future owner of USB-ORG will be MCS.

    IF USB-ORG had a legal leg to stand on... I think this would have been in court a long time ago.

    MCS accepts PayPal:) Get them before they are gone!!!!




  • cgraceycgracey Posts: 14,152
    rjo__ wrote: »
    It seems to me that what is true in the Netherlands is also true in the United States. You cannot really enforce a contract that says once you buy this you cannot resell it. And you cannot enforce a rule about a product that you created after you sold the product.

    Windows can do anything it likes... but in the process, they would open up a legal liability for USB-ORG. Who knows, after the lawsuit, maybe the future owner of USB-ORG will be MCS.

    IF USB-ORG had a legal leg to stand on... I think this would have been in court a long time ago.

    MCS accepts PayPal:) Get them before they are gone!!!!




    As someone said, "In most countries you have laws. In America you have lawyers."
  • rjo__rjo__ Posts: 2,114
    This might not be the place for it, but it is USB related. I simply do not understand why I can use my cheapo computer to send the P2 data using 3Mbaud but when the P2 sends data to the computer, I have to put an incredible wait in between TX calls to make the communications reliable. I'm using the same bit rate... I'm only waiting between bytes. Effectively, I'm getting around 64Kbaud. How can the two be so different?
  • rjo__rjo__ Posts: 2,114
    edited 2016-02-25 03:55
    To be honest... I have junk in my serial event handler... but when I took it out, there didn't seem to be much improvement. So it doesn't seem to be my overhead... it seems to be in the machine... somewhere:) When I moved it out, I created other problems for myself, so I put it back in after a little testing.
  • rjo__ wrote: »
    This might not be the place for it, but it is USB related. I simply do not understand why I can use my cheapo computer to send the P2 data using 3Mbaud but when the P2 sends data to the computer, I have to put an incredible wait in between TX calls to make the communications reliable. I'm using the same bit rate... I'm only waiting between bytes. Effectively, I'm getting around 64Kbaud. How can the two be so different?

    I'm guessing it's where the buffering is occurring. On the PC side of the FTDI chip (I'm assuming that's what you are using), you have lots and lots of memory. On the P2 side, you only have the buffer that's built into the FTDI. Also, it's certainly possible that PC-to-P2 data is taking advantage of a different transfer method than P2-to-PC (e.g. isochronous or bulk one way, interrupt the other).
  • jmgjmg Posts: 15,173
    edited 2016-02-25 04:35
    deleted ghost post
  • jmgjmg Posts: 15,173
    edited 2016-02-25 04:32
    rjo__ wrote: »
    This might not be the place for it, but it is USB related. I simply do not understand why I can use my cheapo computer to send the P2 data using 3Mbaud but when the P2 sends data to the computer, I have to put an incredible wait in between TX calls to make the communications reliable. I'm using the same bit rate... I'm only waiting between bytes. Effectively, I'm getting around 64Kbaud. How can the two be so different?
    What Serial device ?

    USB like larger buffers, and packets above a minimum size.

    Examples:

    When I test FT232H, (HS USB) I can send simplex at 8MBd and 12MBd, with no gaps, but when I loop back, the Rx Char counter shows only 93% received at 12MBd
    At 8MBd duplex, that improves to 99.9758 , and at 6MBd that is 100.00%

    Those numbers get better with smaller test files.

    That shows even at HS USB, getting duplex above 6MBd is tricky & likely depends on PC speed, and other factors.
    (I'm assuming the FT232H can actually manage 12MB Duplex itself here)

    Suggestions: Start with compact code that just counts chars, and enable largest Rx Buffers.
  • jmgjmg Posts: 15,173
    edited 2016-02-25 04:35
    deleted ghost post
  • rjo__rjo__ Posts: 2,114
    Chip,

    My mother used to have to tell me to close the front door... "were you born in a barn?"
    If I had been born in a barn ... I probably would have remembered to close the door.
    Best to keep your doors closed.

    And why do we need it anyway? All I want to do is hook USB stuff up to my P2... we don't need anybody's permission for that:) I don't care what the boards cost. I am going to buy them anyway:)... and so will everybody else.

    Seirth

    "Also, it's certainly possible that PC-to-P2 data is taking advantage of a different transfer method than P2-to-PC (e.g. isochronous or bulk one way, interrupt the other). "

    I assume that when this all gets nailed down and is in silicon, one of the first utilities I will see is a USB helper... so, it can wait. But it does make me curious.

    Thanks.
  • cgraceycgracey Posts: 14,152
    rjo__ wrote: »
    Chip,

    My mother used to have to tell me to close the front door... "were you born in a barn?"
    If I had been born in a barn ... I probably would have remembered to close the door.
    Best to keep your doors closed.

    And why do we need it anyway? All I want to do is hook USB stuff up to my P2... we don't need anybody's permission for that:) I don't care what the boards cost. I am going to buy them anyway:)... and so will everybody else.

    Seirth

    "Also, it's certainly possible that PC-to-P2 data is taking advantage of a different transfer method than P2-to-PC (e.g. isochronous or bulk one way, interrupt the other). "

    I assume that when this all gets nailed down and is in silicon, one of the first utilities I will see is a USB helper... so, it can wait. But it does make me curious.

    Thanks.

    Rjo, I discovered, when working on the PX.exe program that loads the Prop123 FPGA board, that anytime you reverse direction in USB data flow, there is a huge delay. I want to say it was several 10's of milliseconds. Trying to do handshakes often will just kill the speed. Send LOTS of data in one direction at a time to avoid this.
  • Cluso99Cluso99 Posts: 18,069
    cgracey wrote: »
    As someone said, "In most countries you have laws. In America you have lawyers."

    And then they came to Australia too..... :(

    How a case can take 8 years in the Supreme Court, you win both the case and appeal, and at the end be $2M out of pocket is beyond my comprehension. Believe me, I know this to be true.

  • rjo__rjo__ Posts: 2,114
    MY best friend in college became one of the best lawyers in Chicago.

    5 marriages later...

    Next time you complain about lawyers, remember ... there are lots of wives and children depending on them.
  • rjo__rjo__ Posts: 2,114
    Chip,

    I have noticed that most of the misses seem to be at the beginning. Not sure how to program around it. I'll figure it out.

    Thanks

    Rich
  • Cluso99Cluso99 Posts: 18,069
    edited 2016-02-25 05:24
    rjo__ wrote: »
    It seems to me that what is true in the Netherlands is also true in the United States. You cannot really enforce a contract that says once you buy this you cannot resell it. And you cannot enforce a rule about a product that you created after you sold the product.

    Windows can do anything it likes... but in the process, they would open up a legal liability for USB-ORG. Who knows, after the lawsuit, maybe the future owner of USB-ORG will be MCS.

    IF USB-ORG had a legal leg to stand on... I think this would have been in court a long time ago.

    MCS accepts PayPal:) Get them before they are gone!!!!

    If we bought a VID/PID combination, then we would all only be able to use one driver. While we could all use our own unique serial number, the driver would be the same.

    Here is a hackaday article where you can get a free VID/PID pair. There are a few places to get free ones. Note all the VID/PID pairs obtainable this way are mostly revoked VIDs but who cares for now at least. If you get a volume product then you can reconsider at that time.
  • AribaAriba Posts: 2,690
    edited 2016-02-25 06:46
    cgracey wrote: »
    Ariba wrote: »
    Edit: I have bought 10 VID-PID pairs years ago when it was still legal. I would happyly spend one of them for a P2 USB bootloader.

    Those might come in very handy. Since you can't sublet them, can you bequeath them?

    Ultimately, it would be good to have one for the Prop2 chip and one for things that customers make. That is, if I understand this whole thing properly.

    I bought my 10 PIDs from a company similar to MCS. So the VID is not mine and the only guarantee I got is my name assigned to a range of 10 PIDs in a list on a website. It was long before 2009 so it was not forbidden at that time. The company stopped selling VIDs when they got the email from USB.org so I don't know if their VID also got revoked later.
    There is no way to transfer something to Parallax, I just can decide to use one of the PIDs for CDC serial communication with a Propeller 2. Parallax can then be sure that other companies/devices do not use this VID-PID pair, thats all.

    Users don't need another PID as long as they do serial communication over USB. It's just like all the FT232 chips have the same VID-PID pair (if you don't customize it with FT-Prog).
    As FTDI shows you can further divide a single VID-PID pair with serial numbers. Hmm maybe this is not forbidden and I can make a lot of money by selling serial numbers... :smile:

    Andy
  • kwinnkwinn Posts: 8,697
    Cluso99 wrote: »
    cgracey wrote: »
    As someone said, "In most countries you have laws. In America you have lawyers."

    And then they came to Australia too..... :(

    How a case can take 8 years in the Supreme Court, you win both the case and appeal, and at the end be $2M out of pocket is beyond my comprehension. Believe me, I know this to be true.

    Job security for lawyers, and since most politicians are lawyers this is unlikely to change. When deciding who to vote for being a lawyer is a big black mark against a candidate for me.
  • Cluso99Cluso99 Posts: 18,069
    kwinn wrote: »
    Cluso99 wrote: »
    cgracey wrote: »
    As someone said, "In most countries you have laws. In America you have lawyers."

    And then they came to Australia too..... :(

    How a case can take 8 years in the Supreme Court, you win both the case and appeal, and at the end be $2M out of pocket is beyond my comprehension. Believe me, I know this to be true.

    Job security for lawyers, and since most politicians are lawyers this is unlikely to change. When deciding who to vote for being a lawyer is a big black mark against a candidate for me.
    How true!

    And the judges are ex-baristers! Nothing like keeping it in the family ;)

  • kwinnkwinn Posts: 8,697
    Cluso99 wrote: »
    kwinn wrote: »
    Cluso99 wrote: »
    cgracey wrote: »
    As someone said, "In most countries you have laws. In America you have lawyers."

    And then they came to Australia too..... :(

    How a case can take 8 years in the Supreme Court, you win both the case and appeal, and at the end be $2M out of pocket is beyond my comprehension. Believe me, I know this to be true.

    Job security for lawyers, and since most politicians are lawyers this is unlikely to change. When deciding who to vote for being a lawyer is a big black mark against a candidate for me.
    How true!

    And the judges are ex-baristers! Nothing like keeping it in the family ;)

    yep, one big happy incestuous family.
  • cgraceycgracey Posts: 14,152
    edited 2016-02-26 04:29
    kwinn wrote: »
    Cluso99 wrote: »
    kwinn wrote: »
    Cluso99 wrote: »
    cgracey wrote: »
    As someone said, "In most countries you have laws. In America you have lawyers."

    And then they came to Australia too..... :(

    How a case can take 8 years in the Supreme Court, you win both the case and appeal, and at the end be $2M out of pocket is beyond my comprehension. Believe me, I know this to be true.

    Job security for lawyers, and since most politicians are lawyers this is unlikely to change. When deciding who to vote for being a lawyer is a big black mark against a candidate for me.
    How true!

    And the judges are ex-baristers! Nothing like keeping it in the family ;)

    yep, one big happy incestuous family.

    I've heard that it's important to clean fish immediately after catching them. Otherwise, the parasitic worms that are in the stomach will begin eating their way out, right into the flesh.
  • evanhevanh Posts: 15,915
    edited 2016-02-26 04:57
    I'm not sure what sort of case Cluso was referring to but I find there is a lot of commercial type cases that can be over quick, or not, but in the end the judgement seems to have very little in the way of enforcible teeth. Legal fees can be quite small, the loss of business is far more.

    The scumbag that caused all the trouble just ignores the ruling or folds up and starts a new business. You never get any money back either way.

    Of course this is just small timer stuff for both parties. No-one with political ties.
  • Email message to lawyer = "That all looks in order, go ahead with that."
    Lawyer adds $15 to bill for "reading" the email! :(
    Criminals!
  • Cluso99Cluso99 Posts: 18,069
    ozpropdev wrote: »
    Email message to lawyer = "That all looks in order, go ahead with that."
    Lawyer adds $15 to bill for "reading" the email! :(
    Criminals!
    Who do you use? $500/hr is quite typical for a good lawyer :(

  • rjo__rjo__ Posts: 2,114
    edited 2016-02-26 14:21
    A company once broke a contract with us and wanted me to accept something that I hadn't ordered. I went to my lawyer, asked what I should do about it. He told me that I hadn't yet been damaged and that it was my job to avoid being damaged. So, we huffed and puffed and went with Hitachi. In the end, I had a way better product. Toshiba sued me for not accepting a unit that they had never actually built... The same lawyer explained to me that $150,000 to settle would be way cheaper than litigating it... so that is what we did.

    Later on that $150,00 turned out to be the difference between sinking and swimming.

    Contracts in general are sink holes. If you need a contract, you should be dealing with someone else.
  • potatoheadpotatohead Posts: 10,261
    edited 2016-02-26 16:15
    Oh, I disagree with that.

    I do use contracts very regularly. The trick on those is to actually consider everyone when writing it. Often, people will just consider themselves, and those contracts tend to be poor. Yeah, deal with someone else.

    But, a good one means having an understanding. In the case of sink or swim, knowing that may well have resulted in not doing that business, for example.

    If one is not needed, great. Love it when that happens.

    If one is needed, do the work to understand the other party, and that contract will often save attorney fees. Source? My attorney, who taught me what I just wrote, and many years of successful projects.

    And when or if you need an attorney, pick one that will own being expensive and who cares about that impact on you. Ideally, you never do. Also pick one you can call and just get educated on the potential dynamics in play. Spend an hour to save many days. Early on, I spent a few hours to really understand contracts.

    My latest one was a Web design. They presented a one sided contract, and the first thing I did was sort that out for mutual benefit, then we talked price, features, dates...

    Egos flared on that one, and I called all of them to the table, brought it out, made sure their thinking machinery was well lubricated, and got it all back on track. They came to understand I needed my guys and theirs to succeed, and that mattered more than ego did.

    We rank high on their list of favorite customers now. That is because the projects work, are on reasonable time and on appropriate costs, not just the lowest or fixed costs. When the unknown happens, they call and we deal. It's in the contract.

    Ever wonder about that appropriate cost bit? Many will request fixed cost on high risk projects. Know what that bid will be? Max risk case considered costs. Expensive. Or you get a good bid, but it's a loser for them. Bad contract for both parties. Better to not even do it. Nobody wants to complete loser work, and nobody wants the product of work people didn't want to, or could not afford to do right, either.

    If, cost and risk dynamics are considered, then the bid will vary, but so can the risk, and you have control and or the ability to choose what is worth what. Almost always a lower cost, even when a little more ends up being needed somehow. Do this right, and you will seem generous and accommodating, while never paying top dollar, nor rock bottom. And, they will often go to the mat for you too.

    Very high value, hard lesson in all of that. Shared here, and is worth exactly what you think it is.

    For me, worth a ton. YMMV

    Just remember a contract is for all parites. They are as valuable as the work you do on them. Generic, or standard ones mean generic or standard results. Ones aligned with the right result mean the right result.

    The single most important thing is to find out if everyone will come out OK, should the worst of that contract play out. Do not enter into one, until you know that for you, and them. That means talking through worst case, and remaining friends, not just what everybody wants out of it. Truth is, that potential bad outcome may happen. Plan for it.

    I have turned down sweet contracts for me because I did not believe the worst case would work for them.

  • TL;DR. Most bad contract experiences result from not doing the work needed to have good ones. No joke.
  • cgraceycgracey Posts: 14,152
    edited 2016-02-26 17:08
    That's good advice, Potatohead, that the contract needs to be represent both parties' interests and must be survivable to both, in the worst case. If such a contract can't be made, better to not have one.

    What I think Rjo__ had probably experienced was the bad end of a stick from a huge company which just wasn't into seeing it from the other guy's perspective. In my experience, the bigger the company, the more one-sided they insist on making it. And the more ready they are to abuse the system to harass people they think may be hurting their business.

    Getting into a court situation is never prosperous, from what I've seen. The only sure winners are the lawyers and all the court employees. More stirred-up trouble equals more business. It is a huge racket which has just about destroyed free enterprise, free association, maybe soon, free speech, and everything else which would permit a sense of freedom. The longer the systems lasts, the worse it gets.

    In the last days of the Roman Empire, there was a huge idle rich class and a huge idle poor class. The few productive people were being taxed to death until they just quit, with farmers relinquishing their property rather than trying to pay impossible taxes. Then, the whole thing fell apart.

    The last of the political class were said to have been quite self-absorbed. From wiki:
    At that time they say that the Emperor Honorius in Ravenna received the message from one of the eunuchs, evidently a keeper of the poultry, that Roma had perished. And he cried out and said, "And yet it has just eaten from my hands!" For he had a very large cockerel, Roma by name; and the eunuch comprehending his words said that it was the city of Roma which had perished at the hands of Alaric, and the emperor with a sigh of relief answered quickly: "But I thought that my fowl Roma had perished." So great, they say, was the folly with which this emperor was possessed.

    — Procopius, The Vandalic War (De Bellis III.2.25–26)
  • Yeah, that rings true for me too Chip.

    I'll always ask. Sometimes I get, often I don't with the big players. Avoid those players for sure.

Sign In or Register to comment.