The USB ports - Programmers Heaven

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

Welcome to the new platform of Programmer's Heaven! We apologize for the inconvenience caused, if you visited us from a broken link of the previous version. The main reason to move to a new platform is to provide more effective and collaborative experience to you all. Please feel free to experience the new platform and use its exciting features. Contact us for any issue that you need to get clarified. We are more than happy to help you.

The USB ports

bluebird2002bluebird2002 Posts: 2Member

How can I access the USB ports using QuickBasic? Any help will be appreciated.

Harry Jones

Comments

  • IDKIDK Posts: 1,784Member
    :
    : How can I access the USB ports using QuickBasic? Any help will be appreciated.
    :
    : Harry Jones
    :
    Try google:
    http://www.google.com/search?hl=en&q=usb+programming&btnG=Google+Search

    You'll need a lot of knowledge...
  • casio-games.tkcasio-games.tk Posts: 35Member
    : :
    : : How can I access the USB ports using QuickBasic? Any help will be appreciated.
    : :
    : : Harry Jones
    : :
    : Try google:
    : http://www.google.com/search?hl=en&q=usb+programming&btnG=Google+Search
    :
    : You'll need a lot of knowledge...
    :
    :-(

    Why does the computer companies HAVE TO replace the old serial ports with usb? Just because serial is old, its not necessary bad...

    Ive seen programs that uses the serial port so thats possible. Maybe usb isnt...

    I suppose that the author of this thread agrees ;-)
    [hr][hr]
    Don't write pH, write Ph!



  • IDKIDK Posts: 1,784Member
    : : :
    : : : How can I access the USB ports using QuickBasic? Any help will be appreciated.
    : : :
    : : : Harry Jones
    : : :
    : : Try google:
    : : http://www.google.com/search?hl=en&q=usb+programming&btnG=Google+Search
    : :
    : : You'll need a lot of knowledge...
    : :
    : :-(
    :
    : Why does the computer companies HAVE TO replace the old serial ports with usb? Just because serial is old, its not necessary bad...
    :
    : Ive seen programs that uses the serial port so thats possible. Maybe usb isnt...
    :
    : I suppose that the author of this thread agrees ;-)
    : [hr][hr]
    : Don't write pH, write Ph!
    :
    :
    :
    :
    The serial port has a speed of 96 kbaud wich I think is like 96 kB/s.
    USB 2.0 can handle 48 mb/s.
    That's the main reason, the other reason may be that the serial cable is a little unhandy, it needs screws and there's a lot of pins, while the usb cable is small and nice.
    I also don't think that the serial port is able to detect plug and play devices.
  • CyGuyCyGuy Posts: 312Member
    : : : :
    : : : : How can I access the USB ports using QuickBasic? Any help will be appreciated.
    : : : :
    : : : : Harry Jones
    : : : :
    : : : Try google:
    : : : http://www.google.com/search?hl=en&q=usb+programming&btnG=Google+Search
    : : :
    : : : You'll need a lot of knowledge...
    : : :
    : : :-(
    : :
    : : Why does the computer companies HAVE TO replace the old serial ports with usb? Just because serial is old, its not necessary bad...
    : :
    : : Ive seen programs that uses the serial port so thats possible. Maybe usb isnt...
    : :
    : : I suppose that the author of this thread agrees ;-)
    : : [hr][hr]
    : : Don't write pH, write Ph!
    : :
    : :
    : :
    : :
    : The serial port has a speed of 96 kbaud wich I think is like 96 kB/s.
    : USB 2.0 can handle 48 mb/s.
    : That's the main reason, the other reason may be that the serial cable is a little unhandy, it needs screws and there's a lot of pins, while the usb cable is small and nice.
    : I also don't think that the serial port is able to detect plug and play devices.
    :
    A USB controller can sing, whereas RS323 and Serial conections barely whistle
  • PrzemekG_PrzemekG_ Posts: 595Member
    An other good reason for USB is that you can have a hub and connect many devices.

    : A USB controller can sing, whereas RS323 and Serial conections barely whistle
    :
    I saw schematics for 8bit sound card for parallel port with win95 drivers :)


    You shouldn't touch USB from dos bacause it will most likely mess with windows or cause a GPF
  • anthrax11anthrax11 Posts: 511Member
    : I saw schematics for 8bit sound card for parallel port with win95 drivers :)
    :
    :
    I`ve made a similar one:
    http://www.answers.com/topic/covox-speech-thing

    and I must say, the sound quality was above expectations!
    Though I doubt the serial port would be a match for it..


    Anyway, for interfacing with the USB, QB is probably the worst choice..
    The USB port appeared with later versions of Win95, many years after QBasic, so QB certainly doesn`t have standard functions to acces it.

    I don`t know, maybe something can be accomplished under pure DOS by using some high memory addresses, but as a general rule, USB is [b]not[/b] supported in DOS.
  • mstechcamstechca Posts: 64Member
    USB could be used in DOS.

    I personally would see myself with parallel and serial ports because they are more secure, especially if your device is to the far left or far right of the computers back. With usb, the end could bend. With the other ports, screwing the plug in is very effective.

    Also, I find it highly disappointing that everyone wants Windows 98+ for USB.

    As for DOS, I have discovered something. But you will need to first go to windows. Go to Windows Device manager, and select the USB controller. Go to the resources tab.

    If you see Input/Output range, then you are lucky.

    That is the address range you will use.

    In my case, the address range is DCE0 - DCFF.

    In Qbasic you can use INP followed by one of the addresses in your range, and it will tell you data.

    I'm looking for information as to what each address is supposed to do.
  • 0me0my0me0my Posts: 3Member
    The following link takes you to a site that has a nice program to print from DOS programs to the USB port. I've used it successfully many times with QBX programs, with just a little tweaking on the LPRINT tabs. It's a try for free, then buy program.

    http://www.dos2usb.com/download.htm
  • dos3dos3 Posts: 1Member
    Would you please elaborate on this tweaking on the LPRINT tabs?

Sign In or Register to comment.