[asterisk-bugs] [DAHDI-tools 0015553]: Dahdi_scan gives you wrong information about signaling when specify the span number

Asterisk Bug Tracker noreply at bugs.digium.com
Thu Jul 23 06:42:17 CDT 2009


A NOTE has been added to this issue. 
====================================================================== 
https://issues.asterisk.org/view.php?id=15553 
====================================================================== 
Reported By:                tony
Assigned To:                
====================================================================== 
Project:                    DAHDI-tools
Issue ID:                   15553
Category:                   Utilities
Reproducibility:            always
Severity:                   major
Priority:                   normal
Status:                     new
====================================================================== 
Date Submitted:             2009-07-22 05:30 CDT
Last Modified:              2009-07-23 06:42 CDT
====================================================================== 
Summary:                    Dahdi_scan gives you wrong information about
signaling when specify the span number
Description: 
when i try to specify the span number, and fetch the channels information,
it returns wrong data.

example: 
dahdi_scan [ without span number specify] :

[1]
active=yes
alarms=OK
description=Wildcard TDM400P REV E/F Board 5
name=WCTDM/4
manufacturer=Digium
devicetype=Wildcard TDM400P REV E/F
location=PCI Bus 01 Slot 08
basechan=1
totchans=4
irq=17
type=analog
port=1,FXO
port=2,FXO
port=3,FXO
port=4,FXO

[2]
active=yes
alarms=OK
description=Wildcard TDM400P REV E/F Board 5
name=WCTDM/4
manufacturer=Digium
devicetype=Wildcard TDM400P REV E/F
location=PCI Bus 08 Slot 01
basechan=5
totchans=4
irq=16
type=analog
port=5,FXS
port=6,FXO
port=7,none
port=8,none

dahdi_scan 1 [for spam 1]: 
[1]
active=yes
alarms=OK
description=Wildcard TDM400P REV E/F Board 5
name=WCTDM/4
manufacturer=Digium
devicetype=Wildcard TDM400P REV E/F
location=PCI Bus 01 Slot 08
basechan=1
totchans=4
irq=17
type=analog
port=1,FXO
port=2,FXO
port=3,FXO
port=4,FXO

dahdi_scan 2 [for spam 2]: 
[2]
active=yes
alarms=OK
description=Wildcard TDM400P REV E/F Board 5
name=WCTDM/4
manufacturer=Digium
devicetype=Wildcard TDM400P REV E/F
location=PCI Bus 08 Slot 01
basechan=1
totchans=4
irq=16
type=analog
port=1,FXO
port=2,FXO
port=3,FXO
port=4,FXO

The problem is that the port signaling is equal in both spans.


====================================================================== 

---------------------------------------------------------------------- 
 (0108112) tony (reporter) - 2009-07-23 06:42
 https://issues.asterisk.org/view.php?id=15553#c108112 
---------------------------------------------------------------------- 
Is necessary to re-calculate the initial channel for span we want to dump.

diff -Nur dahdi-tools-2.2.0-orig/dahdi_scan.c
dahdi-tools-2.2.0/dahdi_scan.c
--- dahdi-tools-2.2.0-orig/dahdi_scan.c	2009-07-23 13:23:57.000000000
+0200
+++ dahdi-tools-2.2.0/dahdi_scan.c	2009-07-23 13:24:13.000000000 +0200
@@ -71,6 +71,11 @@
 				}
 			}
 			if (!match) {
+				/*re-calculate  the basechannel for analog ports*/	
+				memset(&s, 0, sizeof(s));
+				s.spanno = x;
+				if (ioctl(ctl, DAHDI_SPANSTAT, &s)) continue;
+				basechan += s.totalchans;
 				continue;
 			}
 		} 

Issue History 
Date Modified    Username       Field                    Change               
====================================================================== 
2009-07-23 06:42 tony           Note Added: 0108112                          
======================================================================




More information about the asterisk-bugs mailing list