Hey everyone!

I am currently working on a summer project. What I need to do is control two relay boards, and they are linked to a device which will hold and execute the program, which sends a 4 byte packed signal to the boards. I know that the program works, because I made it first linking the boards to a computer. I used a module called Win32::SerialPort, which made it quite easy to connect to the boards. For the device I would use Device::SerialPort, but for some complicated reason it is nearly impossible to add this module to the device. Thus, I need to open a port without using a module like Device::SerialPort.

I need the following settings for the port:

Baud: 19200

Data: 8 bits

Stop: 1 bit

Parity: no

Handshake signal: no

Then after opening the port, I need to send two 4 byte signals. The boards will then send two 4 byte signals back, which I need to read and evauate.

Any help will be greatly appreciated!

Thomas Brouwer


In reply to Open serial port without Device::SerialPort by ThomasBrouwer

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.