Accessing (the i4b) device driver
Bjoern A. Zeeb
bzeeb-lists at lists.zabbadoz.net
Fri Apr 30 12:40:11 PDT 2004
On Fri, 30 Apr 2004, Martin Moeller wrote:
> I'm totally new to FreeBSD programming, so please forgive my troll-like
> question! I'd like to write a nifty little program showing if somebody is
> calling me via an ISDN line. In the far future, the program should show the
> caller's telephone number.
I am using this ince-quickly-hacked script with c4b and isdnd:
tail -100f /var/log/isdnd.log | perl bin/parse-isdnd-log.pl
--- cut ---
#!/usr/bin/perl
$|=1;
while (<>) {
s/^(\w+ \d+ \d+:\d+:\d+) \w+ \w+\[\d+\]/$1/;
if (/CHD/) {
s/CHD \d+ //;
print $_;
}
}
# End;
--- cut ---
Gives me s.th. like this:
Apr 28 16:30:35: <unknown> incoming call from NotAvailable to 41 ctrl 3
or
Apr 28 17:23:30: <unknown> incoming call from 01234567890 to 41 ctrl 3
--
Bjoern A. Zeeb bzeeb at Zabbadoz dot NeT
56 69 73 69 74 http://www.zabbadoz.net/
More information about the freebsd-hackers
mailing list