Okay, I want to dial a modem. Pretty simple. Here's my code:
#!/usr/local/bin/perl # Modem test use Device::SerialPort; $PortName="/dev/ttyS1"; $modem=new Device::SerialPort ($PortName); print "Modem Test...\n"; $modem->error_msg(ON); $modem->baudrate(115200); $modem->parity("none"); $modem->databits(8); $modem->stopbits(1); $modem->are_match("BUSY","CONNECT","OK","NO DIALTONE","ERROR","RING", "NO CARRIER","NO ANSWER"); #$modem->write("ATZ\r") || die "Could Not Reset\n"; $number="8885555555"; $modem->read_const_time(30000); $modem->write("ATDT$number\n\r") || die "Could Not Dial\n"; sleep 5; $modem->write("ATH\r") || die "Could Not Dial\n";
Upon running it, I get this:

Device::Serial could not find ioctl definitions! disabling ioctl methods - constants not found

Ugh. This is Redhat 7.3. I've already run h2ph, and I do have asm/termios.ph. Anyone have any ideas? Or even better, some reliable way that I can send stuff to the modem without this module? BTW, notice that I don't ever read from the serial port, I just need to dial the number, send a string, and hang up.

As always, thanks.

Declarent

Edit by tye, add READMORE


In reply to Device::SerialPort Blues by Declarent

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.