Archive for April, 2007

3G high speed data with a Huawei USB modem and Linux

Monday, April 30th, 2007

Danish mobile operator 3 recently launched high speed mobile data for pretty reasonable prices. You can get up to 3 Mbit/s!. They both have PCMCIA cards and USB versions. In Windows the USB device also acts as a storage device containing drivers and a dialer, so it is pretty easy to get working. In Linux it’s a bit more difficult to get working, but it can be done!

First, the minimum required kernel version seems to be 2.6.20. With 2.6.18 the storage device was detected, but not the serial devices. With 2.6.20 the storage device is ignored but 3 serial devices are detected. 3 devices you say? Yes, it makes it possible to use the modem to send text messages, use high speed data and GPRS – all at the same time.

Sometimes the devices are not detected correctly, this can be solved by simply removing the driver and loading it again (rmmod usbserial option && modprobe usbserial && modprobe option).

Each time to modem is connected to your USB port it must be initialized with your PIN-code. It will only accept it once though. Use this perlscript to send pincode to USB modem.

After that, the following wvdial.conf should get you online:

[Dialer Defaults]
Modem = /dev/ttyUSB0
Baud = 460800
SetVolume = 0
Dial Command = ATDT
Init1 = ATZ
Init2 = ATM0
FlowControl = NOFLOW

Username = VFD2
Password = WAP
Phone = *99***1#
Stupid Mode = 1
Init3 = AT+CGDCONT=1,”IP”,”data.tre.dk”
Dial Attempts = 3
Inherits = ModemUMTS

DVB-C card for digital TV on my mediacenter

Sunday, April 1st, 2007

I was not happy with the quality of my analogue TV signal, so i finally decided to buy a DVB-C card to receive digital TV from my provider in Denmark, TDC Kabel TV.

To receive the signal you need a DVB-C card. To receive non-free-to-air channels you need a Common Interface (CI) and a CAM (Common Access Module) to decode the signal. In the CAM you must insert a decoder card bought from your provider.

I ended up ordering the following at dvbshop.net:

  • Technotrend Premium C-2300 Hybrid
  • Technotrend Premium 3.5″ CI incl. TT-remotecontrol
  • Viaccess I/II CAM (V484)

I have no use for the remote control, but could not find a CI for the C-2300 card without it.

The card was pretty easy to get working in Linux. When I first booted after inserting the card, the kernel log showed:

[ 57.704473] dvb-ttpci: could not load firmware, file not found: dvb-ttpci-01.fw
[ 57.704509] dvb-ttpci: usually this should be in /usr/lib/hotplug/firmware or /lib/firmware
[ 57.704550] dvb-ttpci: and can be downloaded from http://www.linuxtv.org/download/dvb/firmware/


So i downloaded http://www.linuxtv.org/download/dvb/firmware/dvb-ttpci-01.fw-2622 and saved it as /lib/firmware/dvb-ttpci-01.fw and reloaded the driver:

# rmmod dvb-ttpci
# modprobe dvb-ttpci

and the card was now detected and initialized just fine:

[ 571.805460] saa7146: register extension 'dvb'.
[ 571.806038] PCI: Enabling device 0000:05:07.0 (0000 -> 0002)
[ 571.806223] saa7146: found saa7146 @ mem ffffc20000070000 (revision 1, irq 3) (0x13c2,0x000a).
[ 571.812619] DVB: registering new adapter (Technotrend/Hauppauge WinTV Nexus-CA rev1.X).
[ 571.846734] adapter has MAC addr = 00:d0:5c:04:ae:d4
[ 572.052113] dvb-ttpci: gpioirq unknown type=0 len=0
[ 572.077680] dvb-ttpci: info @ card 0: firm f0240009, rtsl b0250018, vid 71010068, app 80002622
[ 572.077683] dvb-ttpci: firmware @ card 0 supports CI link layer interface
[ 572.725120] dvb-ttpci: DVB-C analog module @ card 0 detected, initializing MSP3415
[ 573.072477] dvb_ttpci: saa7113 not accessible.
[ 573.133828] saa7146_vv: saa7146 (0): registered device video2 [v4l2]
[ 573.134080] saa7146_vv: saa7146 (0): registered device vbi2 [v4l2]
[ 573.134357] DVB: registering frontend 0 (ST STV0297 DVB-C)...
[ 573.134549] input: DVB on-card IR receiver as /class/input/input3
[ 573.134630] dvb-ttpci: found av7110-0.
[ 577.936266] spurious 8259A interrupt: IRQ7.

To test and scan for channels I created a file called dk-TDCKabelTV containing the frequences used by TDC Kabel TV in Copenhagen:

C 143000000 6875000 NONE QAM64
C 156000000 6875000 NONE QAM64
C 490000000 6875000 NONE QAM64
C 498000000 6875000 NONE QAM64
C 506000000 6875000 NONE QAM64
C 514000000 6875000 NONE QAM64
C 522000000 6875000 NONE QAM64
C 530000000 6875000 NONE QAM64
C 538000000 6875000 NONE QAM64
C 546000000 6875000 NONE QAM64
C 554000000 6875000 NONE QAM64
C 578000000 6875000 NONE QAM64
C 586000000 6875000 NONE QAM64
C 602000000 6875000 NONE QAM64
C 610000000 6875000 NONE QAM64
C 618000000 6875000 NONE QAM64
C 626000000 6875000 NONE QAM64
C 674000000 6875000 NONE QAM64

I then used scan dk-TDCKabelTV > channels.conf to scan for channels. I later used the generated file when setting up the tuner card in MythTV. I had to delete a lot of channels though. It looks like MythTV cannot handle the radio channels – and I haven’t bought access to all 100 channels or so available with TDCs Selector…