How to talk to a USB device
  • Order of the Butterfly
    Order of the Butterfly
    asrael22
    Posts: 404 from 2014/6/11
    From: Germany
    Hi.

    I have a USB<->UART hardware which I need for a project.
    When I plug it into my MorphOS system Poseidon says that it loaded the serialcp210x.class all right.
    Now how do I use this class for sending/receiving data?
    Are there any examples (in C), maybe for other hardware?



    Manfred
  • »15.06.14 - 15:27
    Profile
  • Moderator
    Kronos
    Posts: 2362 from 2003/2/24
    Basicly you need any source code that handles serial on the Amiga/MorphOS. Even 25 year old would work after you replaced "serial.device" with whatever Poseidon uses. This should be "serialpl2303.device" (or maybe ""serialpl220.device" if yours is useing a different chipset) Use http://morphos-files.ppa.pl/download/Scout to check whats in your system (and the USB prefs pane to check wether Poseidon likes your adaptor).

    In general it's a good idea to get yourself a copy of the Amiga-Developer-CD or atleast the 3.x(AmigaOS)NDK as these will cover those lowlevel aspects relativly good.
  • »15.06.14 - 16:05
    Profile
  • Order of the Butterfly
    Order of the Butterfly
    asrael22
    Posts: 404 from 2014/6/11
    From: Germany
    All right, thanks.
    I've got the 3.1 and 3.9 NDK here. I'll have a look there.

    Could you with a few words explain why the .class is handled as a device?

    Couldn't open Scout, see screenshot. The error message is a bit cryptic. Does it make any sense to you?


    Manfred
    [img align='left']http://nnamgreb.de/files/Grab.png[/img]
  • »15.06.14 - 17:41
    Profile
  • MorphOS Developer
    itix
    Posts: 1520 from 2003/2/24
    From: Finland
    MorphOS build of Scout is buggy (thanks to broken deps system I used...) and formatting of strings is broken sometimes. Unfortunately it still isnt fixed properly but you can use 68k build to run Scout.

    I think that requester appear because Scout still requires NList.mcc classes. It should be removed but no time to do that...
    1 + 1 = 3 with very large values of 1
  • »15.06.14 - 17:51
    Profile
  • MorphOS Developer
    itix
    Posts: 1520 from 2003/2/24
    From: Finland
    Serialcp210x.class is a Poseidon USB driver and this driver installs serialcp210x.device to the system.
    1 + 1 = 3 with very large values of 1
  • »15.06.14 - 18:01
    Profile