Sponsored Content
Full Discussion: Carrier Detection in FreeBSD
Operating Systems BSD Carrier Detection in FreeBSD Post 302820975 by rstor on Thursday 13th of June 2013 05:54:00 PM
Old 06-13-2013
Carrier Detection in FreeBSD

Regarding carrier detection on FreeBSD 9.1 being run within Virtual Box:

I used a usb-serial dongle which shows up as ttyu0 on the BSD machine. Carrier detection appears to work. When I establish a null modem connection I receive a login prompt. If I login, and then unplug and plug back the cable, I get the login prompt again and the old session does not continue. This is the correct behaviour to my understanding however I am curious of the way the getty process behaves, esp. on bootup in FreeBSD.

Question:

The line in my /etc/ttys file is as follows:

Code:
ttyu0   "/usr/libexec/getty std.300"   dialup on

I then issued the command "kill -HUP 1" and restarted the system with nothing plugged into the serial port.

Reading the documentation online, it is my understanding that when the system starts up and no carrier is detected, when issuing the ps ax command, the result I am supposed to see should be something as follows:

Code:
  114 ??  I      0:00.10 /usr/libexec/getty std.300 ttyu0

However I instead see a similar output to the above but the question marks are replaced by letters. Per the documentation online it indicates that if something like this is displayed it means that "getty has completed its open on the communications port. This could indicate a problem with the cabling or a misconfigured modem, because getty should not be able to open the communications port until carrier detect has been asserted by the modem."

I figured that since nothing is connected into the serial port, perhaps the voltage levels may be floating, instead of being held at the negative voltage which would indicate no carrier. I therefore applied a negative voltage to the CD line and restarted the system. Upon restart I issuing the ps -ax command and the result was as before, letters instead of the question marks. I then manually applied a positive voltage to the CD line and then a negative voltage again. I had to do it a couple times however eventually it showed up with question marks. I then was able to toggle back and forth, positive voltage resulted in letters, negative voltage on CD line resulted in question marks.

Why is it that when a negative voltage is applied to the CD line, upon system start-up, getty indicates via the ps -ax command that it has opened the port? [i.e. letters appear instead of question marks] I would expect that with a negative voltage applied to the CD line, upon restart it would show up with ??

I need to toggle the voltage between negative to positive and then back to negative (sometimes I need to do it a couple times) for it to eventually show up with ?? and then it would toggle back and forth as I switch the voltages thereafter.

Last edited by Scott; 06-13-2013 at 07:06 PM.. Reason: Please use code tags for code, data and terminal output
 

8 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

no carrier

I'm getting a error le0: No Carrier - transceiver cable problem? Tried looking around to see what is the best way to fix this error. Can anyone help me I can't find anything. (2 Replies)
Discussion started by: merlin
2 Replies

2. UNIX for Dummies Questions & Answers

virus detection

IS there virus software for unix? I worked in a Solaris environment and dont remember having anything. I also ask because the current enviroment i am working on is Microsoft and they argue that they do not use unix because of virus detection. Any input would be greatly appreciated. (1 Reply)
Discussion started by: pbonilla
1 Replies

3. IP Networking

modem detection

How to get information that where is my modem configured in /dev. I have two modems configured in my device .. one is USB and other is PCI modem.. USB is detected as /dev/USB0. but how to see about PCI modem? (0 Replies)
Discussion started by: s123.radha
0 Replies

4. Programming

Application crashes in FreeBSD 7.1 while working ok in FreeBSD 6.3

Hello there, My mulithreaded application (which is too large to represent the source code here) is crashing after installing FreeBSD 7.1-RELEASE/amd64. It worked properly on others machines (Dual Cores with 4GB of RAM - FreeBSD 6.2-RELEASE/i386). The current machine has 2x Core 2 Duo... (1 Reply)
Discussion started by: Seenquev
1 Replies

5. Shell Programming and Scripting

NAT detection

hellou, can anybody help me with nat detection in real time ? i prefer some detection script because i try some nat detection program's for example p0f or i'm using tcpdump, but i would get contain of specific packet. Some ideas? (1 Reply)
Discussion started by: TheTechnic
1 Replies

6. Programming

Parallel Processing Detection and Program Return Value Detection

Hey, for the purpose of a research project I need to know if a specific type of parallel processing is being utilized by any user-run programs. Is there a way to detect whether a program either returns a value to another program at the end of execution, or just utilizes any form of parallel... (4 Replies)
Discussion started by: azar.zorn
4 Replies

7. UNIX for Dummies Questions & Answers

Power Line Carrier (PLC)

hi, i am going to know if i can use n.s for power line simulating? Best Regards, (2 Replies)
Discussion started by: mohsenmahoor
2 Replies

8. Solaris

Carrier Detection in Solaris 8 for Dial in and Null Modem Connections

I am having troubles with carrier detection for dialing in via a modem or direct connection via a null modem connection under Solaris 8 (i.e. login session remains active after the modem disconnects). I tried two different dumb modems (which do not respond to AT commands) on the machine that I am... (6 Replies)
Discussion started by: rstor
6 Replies
UBSA(4) 						   BSD Kernel Interfaces Manual 						   UBSA(4)

NAME
ubsa -- USB support for Belkin serial adapters SYNOPSIS
To compile this driver into the kernel, place the following lines in your kernel configuration file: device usb device ucom device ubsa Alternatively, to load the driver as a module at boot time, place the following line in loader.conf(5): ubsa_load="YES" DESCRIPTION
The ubsa driver provides support for the USB-to-RS232 Bridge chip used by a variety of serial adapters from Belkin and other vendors. The device is accessed through the ucom(4) driver which makes it behave like a tty(4). HARDWARE
The ubsa driver supports the following adapters: o AnyData ADU-500A EV-DO modem o AnyData ADU-E100A (no EV-DO mode support) o Belkin F5U103 o Belkin F5U120 o e-Tek Labs Kwik232 o GoHubs GoCOM232 o Peracom single port serial adapter SEE ALSO
tty(4), ucom(4), usb(4) HISTORY
The ubsa driver appeared in FreeBSD 5.0. The uplcom(4) manual page was adopted from NetBSD by Tom Rhodes <trhodes@FreeBSD.org> in April 2002 and modified for the ubsa driver by Alexander Kabaev <kan@FreeBSD.org> in October 2002. AUTHORS
The ubsa driver was written by Alexander Kabaev <kan@FreeBSD.org>. BSD
November 20, 2011 BSD
All times are GMT -4. The time now is 05:37 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy