Loading ...
Sorry, an error occurred while loading the content.

serial port

Expand Messages
  • Bart Hibbs
    I have a USB to serial adaptor. How do I get Chipmunk Basic to use it? I found this in some of the documentation: open COM1:/dev/cu.modem:1200,N,8,1 for
    Message 1 of 3 , Jul 16, 2004
    • 0 Attachment
      I have a USB to serial adaptor. How do I get Chipmunk Basic to use it?
      I found this in some of the documentation:

      open "COM1:/dev/cu.modem:1200,N,8,1" for output as #1
      open "COM1:/dev/cu.modem:1200,N,8,1" for input as #2

      but I assume I need to specify something other than

      /dev/cu.modem:1200,N,8,1

      for the port I have. What do I use?

      Thanks
    • hotpaw2
      Try using the terminal console app ( ls -ltr /dev ) to find out what devices are added to your /dev directory after you plug in your USB adapter. - Ron
      Message 2 of 3 , Oct 10, 2004
      • 0 Attachment
        Try using the terminal console app ( ls -ltr /dev ) to find out what devices are
        added to your /dev directory after you plug in your USB adapter.

        - Ron

        --- In chipmunkbasicforum@yahoogroups.com, "Bart Hibbs" <bart_hibbs@y...>
        wrote:
        > I have a USB to serial adaptor. How do I get Chipmunk Basic to use it?
        > I found this in some of the documentation:
        >
        > open "COM1:/dev/cu.modem:1200,N,8,1" for output as #1
        > open "COM1:/dev/cu.modem:1200,N,8,1" for input as #2
        >
        > but I assume I need to specify something other than
        >
        > /dev/cu.modem:1200,N,8,1
        >
        > for the port I have. What do I use?
        >
        > Thanks
      • Bart Hibbs
        I finally got around to trying that. It works. It also turns out that the code fragment in the mannula works: 20 sp1$ = macfunction( serialpath ,1) : print
        Message 3 of 3 , Nov 15, 2004
        • 0 Attachment
          I finally got around to trying that. It works. It also turns out that
          the code fragment in the mannula works:

          20 sp1$ = macfunction("serialpath",1) : print sp1$
          30 if sp1$ = "" then stop
          40 sp2$ = macfunction("serialpath",2) : print sp2$
          50 config$ = "COM1:"+sp2$+":9600,N,8,1"
          60 print config$ : print
          70 open config$ for input as #2
          80 open config$ for output as #1

          sp2$ gets the port name for the keyspan adaptor.

          --- In chipmunkbasicforum@yahoogroups.com, hotpaw2 <no_reply@y...> wrote:
          >
          > Try using the terminal console app ( ls -ltr /dev ) to find out what
          devices are
          > added to your /dev directory after you plug in your USB adapter.
          >
          > - Ron
          >
          > --- In chipmunkbasicforum@yahoogroups.com, "Bart Hibbs"
          <bart_hibbs@y...>
          > wrote:
          > > I have a USB to serial adaptor. How do I get Chipmunk Basic to use it?
          > > I found this in some of the documentation:
          > >
          > > open "COM1:/dev/cu.modem:1200,N,8,1" for output as #1
          > > open "COM1:/dev/cu.modem:1200,N,8,1" for input as #2
          > >
          > > but I assume I need to specify something other than
          > >
          > > /dev/cu.modem:1200,N,8,1
          > >
          > > for the port I have. What do I use?
          > >
          > > Thanks
        Your message has been successfully submitted and would be delivered to recipients shortly.