most of the test systems are not built to be used for on-air operations . the ones that offer such features must be used in Shield rooms where no signal gets in or out . these rooms are expensive but usually tech universities have some rental hours for their shield and antenna rooms . its expensive as well , otherwise you are probably going to have some conflict with local regulatory sooner or later<div>
regards<br><br><div class="gmail_quote">On Thu, May 19, 2011 at 9:04 PM, Gianni Tedesco <span dir="ltr"><<a href="mailto:gianni@scaramanga.co.uk">gianni@scaramanga.co.uk</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<div class="im">On Fri, 2011-05-13 at 15:00 +0430, Mohammad Hosein wrote:<br>
</div><div class="im">> you could use most GSM test systems for such purpose . on ebay you<br>
> might find very cheap ones<br>
> regards<br>
<br>
</div>I managed to track down a Racal 6103. It should arrive in next couple of<br>
days.<br>
<br>
As a followup question then, I guess that these are intended for wired<br>
rf connection or at least they transmit at very low power, and tell the<br>
phone to do the same.<br>
<br>
However, one would feel a lot better using a channel unused by other<br>
cells in my location. I've been using cell_log to put together a list of<br>
active ARFCN's that my handset receives broadcasts from. Script for<br>
parsing cell_log logs is attached.<br>
<br>
Am I to conclude that if cell_log hasn't dumped:<br>
<br>
[sysinfo]<br>
arfcn 99<br>
<br>
for example, after running for a reasonably long period of time (say<br>
24hrs) that operating test equipment on channel 99 should be safe?<br>
<br>
Gianni<br>
<br>
--<br>
<br>
#!/usr/bin/python<br>
<br>
def getline(f):<br>
while True:<br>
l = f.readline()<br>
if not l:<br>
raise StopIteration<br>
l = l.rstrip('\r\n')<br>
if not l:<br>
continue<br>
yield l<br>
def bsic(v):<br>
(a,b) = v.split(',')<br>
return (int(a),int(b))<br>
<br>
def hexdump(v):<br>
ret = bytearray()<br>
for x in v.split():<br>
ret.append(int(x, 16))<br>
return ret<br>
<br>
class Parser:<br>
pass<br>
<br>
class Power(Parser):<br>
def line(self, s):<br>
return<br>
<br>
class mcc:<br>
tbl = {0x234: 'UK and Northern Ireland'}<br>
def __init__(self, num):<br>
x = ((num & 0xf00) >> 8,<br>
(num & 0xf000) >> 12,<br>
(num & 0xf))<br>
self.val = (x[0] << 8) | x[1] << 4 | x[2]<br>
def __int__(self):<br>
return self.val<br>
def __str__(self):<br>
return self.tbl.get(self.val, '%.3x'%self.val)<br>
<br>
class mnc:<br>
tbl = {0x15: 'Vodafone',<br>
0x30: 'T-Mobile',<br>
0x10: 'O2',<br>
0x33: 'Orange',<br>
}<br>
def __init__(self, num):<br>
x = ((num & 0xf0) >> 4,<br>
(num & 0xf))<br>
self.val = (x[1] << 4) | x[0]<br>
def __int__(self):<br>
return self.val<br>
def __str__(self):<br>
return self.tbl.get(self.val, '%.2x'%self.val)<br>
<br>
class SystemInfo:<br>
pass<br>
<br>
class SystemInfo3(SystemInfo):<br>
def __init__(self, b):<br>
if isinstance(b, str):<br>
b = hexdump(b)<br>
assert(b[0] > 9) # len<br>
assert(b[1] == 0x06) # discr<br>
assert(b[2] == 0x1b) # sysinfo3<br>
self.cell = (b[3] << 8) | b[4]<br>
self.mcc = mcc((b[5] << 8) | b[6])<br>
self.mnc = mnc(b[7])<br>
self.lac = (b[8] << 8) | b[9]<br>
def __str__(self):<br>
return 'Cell(%s, %s)'%(self.mcc,self.mnc)<br>
<br>
class SystemInfo4(SystemInfo):<br>
def __init__(self, b):<br>
if isinstance(b, str):<br>
b = hexdump(b)<br>
assert(b[0] > 7) # len<br>
assert(b[1] == 0x06) # discr<br>
assert(b[2] == 0x1c) # sysinfo4<br>
self.cell = None<br>
self.mcc = mcc((b[3] << 8) | b[4])<br>
self.mnc = mnc(b[5])<br>
self.lac = (b[6] << 8) | b[7]<br>
def __str__(self):<br>
return 'Cell(%s, %s)'%(self.mcc,self.mnc)<br>
<br>
class Sysinfo(Parser):<br>
_keys = {'arfcn':int,<br>
'time':int,<br>
'rxlev':int,<br>
'bsic':bsic,<br>
'si1':hexdump,<br>
'si2':hexdump,<br>
'si2bis':hexdump,<br>
'si2ter':hexdump,<br>
'si3':SystemInfo3,<br>
'si4':SystemInfo4,<br>
'ta':int}<br>
def line(self, s):<br>
(k,v) = s.split(None, 1)<br>
if self._keys.has_key(k):<br>
setattr(self, k, self._keys[k](v))<br>
else:<br>
print k, v<br>
return<br>
<br>
class RFMap:<br>
arfcns = {}<br>
cells = {}<br>
def commit(self, obj):<br>
if isinstance(obj, Sysinfo):<br>
self.arfcns.setdefault(obj.arfcn, {})<br>
self.arfcns[obj.arfcn][str(obj.si3.mnc)] = None<br>
self.arfcns[obj.arfcn][str(obj.si4.mnc)] = None<br>
<br>
self.cells.setdefault(obj.si3.cell, {})<br>
self.cells[obj.si3.cell][str(obj.si3.mnc)] = None<br>
elif isinstance(obj, Power):<br>
return<br>
assert(isinstance(obj, Parser))<br>
<br>
def rf_map(f):<br>
smap = {'[power]':Power, '[sysinfo]':Sysinfo}<br>
obj = None<br>
m = RFMap()<br>
<br>
for x in getline(f):<br>
if x[0] == '[':<br>
if obj is not None:<br>
m.commit(obj)<br>
obj = smap[x]()<br>
continue<br>
if obj is None:<br>
raise ValueError, 'Bad state'<br>
obj.line(x)<br>
<br>
if obj is not None:<br>
m.commit(obj)<br>
<br>
print 'Active ARFCNs:'<br>
x = m.arfcns.keys()<br>
x.sort()<br>
for i in x:<br>
print ' %4d:'%i, ','.join(m.arfcns[i])<br>
print<br>
<br>
print 'Active Cells:'<br>
x = m.cells.keys()<br>
x.sort()<br>
for i in x:<br>
print ' 0x%.4x'%i, ','.join(m.cells[i])<br>
print<br>
<br>
def main(argv):<br>
if len(argv) > 1:<br>
infile = open(argv[1])<br>
else:<br>
from sys import stdin<br>
infile = stdin<br>
<br>
rf_map(infile)<br>
return 0<br>
<br>
if __name__ == '__main__':<br>
from sys import argv<br>
raise SystemExit, main(argv)<br>
<br>
<br>
</blockquote></div><br></div>