Gscanbus

Gscanbus is a utility for monitoring your firewire connections. You can also use it to run the camcorder. I find it incredibly helpful.

Guides and software

Installation history

On 11 Dec 01, I downloaded the gscanbus 0.7.1 tarball from its homepage and attempted a ./configure -- it requested GTK, which is the Gimp toolkit.

GTK

I got the GTK rpm from SuSE, but it gave the same error message. A site suggested I need to include gtk-config on my $PATH, and I read up on environment variables at http://www.linux-mag.com/2001-06/newbies_01.html. This is very useful information, but I couldn't find the gtk-config file in /etc so I can't include it in my $PATH -- which doesn't seem to exist anyway (the variable is empty). I went to http://www.gtk.org/ and read in the manual; it seems gtk should definitely generate gtk-config, and I may have something wrong from SuSE.

I downloaded the tarball for gtk+ 1.2.0 which is the version gscanbus asked for. When I first tried to uninstall the gtk 1.2.10 rpm, I got lots of dependencies messages saying programs needed libgtk 1.2 so 0, so I didn't uninstall it, even though this may well mean I already have 1.2.0. The downloaded package seems completely different from the SuSE package.

Glib

Now gtk+ required glib, so I went to get that too, although my Packager shows it's already installed. I should learn to find things! Anyway, for now I download, untar, ./configure, make, and make install glib. It takes ages to make! It's clearly implicated in lots of programs. It makes a path statement:

PATH="$PATH:/sbin" ldconfig -n /usr/local/lib

And says that

Libraries have been installed in: /usr/local/lib

If you ever happen to want to link against installed libraries in a given directory, LIBDIR, you must either use libtool, and specify the full pathname of the library, or use `-LLIBDIR' flag during linking and do at least one of the following:
- add LIBDIR to the `LD_LIBRARY_PATH' environment variable during execution
- add LIBDIR to the `LD_RUN_PATH' environment variable during linking
- use the `-Wl,--rpath -Wl,LIBDIR' linker flag
- have your system administrator add LIBDIR to `/etc/ld.so.conf'
See any operating system documentation about shared libraries for more information, such as the ld(1) and ld.so(8) manual pages.

Now I'm assuming this is telling me what I need to do to link the files! I can add /usr/local/lib to /etc/ld.so.conf. Now that file does in fact exist, and /usr/local/lib is already included! So hopefully gtk will now compile. I did a make clean first, and then went to configure gtk. GTK now configured fine, and made fine -- again, it took ages. It's clearly not at all the gtk I got from SuSE -- weird. Maybe it's actually safer to use targalls than RPMs? GTK installed fine.

GTK version conflict

Next: gscanbus! Now I got:

checking for gtk-config... /usr/local/bin/gtk-config
checking for GTK - version >= 1.2.0...
*** 'gtk-config --version' returned 1.2.0, but GTK+ (1.2.10)
*** was found! If gtk-config was correct, then it is best
*** to remove the old version of GTK+. You may also be able to fix the error
*** by modifying your LD_LIBRARY_PATH enviroment variable, or by editing
*** /etc/ld.so.conf. Make sure you have run ldconfig if that is
*** required on your system.
*** If gtk-config was wrong, set the environment variable GTK_CONFIG
*** to point to the correct copy of gtk-config, and remove the file config.cache
*** before re-running configure

So the double installation comes back to haunt me. So I did a quick make uninstall of the gtk 1.2.0, downloaded gtk 1.2.10 and installed it. I may have two of this now, but so what? Come to think of it, I should first try to configure gscanbus without installing 1.2.10. Well, I tried that, and suddently it couldn't find gtk at all! So I will reinstall. It's the gtk-config script it cannot find, nor can I! So perhaps gtk 1.2.10 is indeed installed, but in a truncated version. This seems to be related to the SuSE distribution; I may be better off with Debian, or possibly Slackware.

Incidentally, # echo $LD_LIBRARY_PATH gives

/opt/mozilla//:/opt/mozilla//components:/opt/kde/lib:/opt/mozilla//:/opt/mozilla//components:

Surely this is absurd? /opt/kde/lib is ok, but the rest is surely junk? Anyway, gscanbus finally configured correctly! I now have the latest versions of both glib and gtk, so I don't think I've caused any harm to the system.

Installing modules and testing

I then installed the four modules,

/sbin/modprobe ieee1394
/sbin/modprobe raw1394
/sbin/modprobe ohci1394
/sbin/modprobe video1394

-- leaving out attempt_root=1 in the case of ohci, which failed last time. It started up fine -- the videocam was playing all the while, and I even started dvgrab -- and gave this result:

error while reading from IEEE1394: : Resource temporarily unavailable
1/0x0000fffff0000400: read failed
1/0x0000fffff0000400: wrong bus info block length

So not much is right here. The card may be incorrectly defined, who knows. Not anywhere close to working. But a useful tool!

Building a new kernel

After this, I concluded gscanbus was likely correctly installed and switched my efforts to compiling a new kernel. Instead of defining firewire components as module, I included them in the kernel itself. Likely just as or more important, these were better drivers; 2.4.10 was known to be weak and buggy for firewire.

Testing the new build

Wow. Dvgrab doesn't work, but it doesn't freeze either -- it gives 'reset 1' and upwards... /sbin/lsmod shows that no modules are loaded: this should mean there's quite a bit more memory available, as the SuSE boot has lots of modules.

Gscanbus on the other hand works! It gives a lovely picture of the firewire drive and shows an attached videocamera device. And it says more -- click on the videocamera and get this:

SelfID Info
-----------
Physical ID: 1
Link active: Yes
Gap Count: 44
PHY Speed: S100
PHY Delay: <=144ns
IRM Capable: Yes
Power Class: None
Port 0: Connected to child node
Init. reset: Yes
Status: Playing

And then an interface for controlling play! I can successfully control the camera!! Then the Firewire port:

SelfID Info
-----------
Physical ID: 0
Link active: Yes
Gap Count: 44
PHY Speed: S400
PHY Delay: <=144ns
IRM Capable: Yes
Power Class: -1W
Port 0: Not connected
Port 1: Connected to parent node
Port 2: Not connected
Init. reset: No

CSR ROM Info
------------
GUID: 0x00308D010001A64C
Node Capabilities: 0x000083C0
Vendor ID: 0x0000005E
Unit Spec ID: 0x0000005E
Unit SW Version: 0x00000002
Model ID: 0x00000000
Nr. Textual Leafes: 1

Vendor: USC INFORMATION SCIENCES INST
Textual Leafes:
Linux 1394
AV/C Subunits
-------------
N/A

So this works -- I wonder why dvgrab is still not working? I'm getting error messages

1/0x0000fffff0000404: wrong magic quadlet:

So that's that. In fact, after I switched to root, gscanbus no longer sees the camcorder. Then there's a console error:

kernel: ohci1394_0: Error in reception of SelfID packets [0x80020004/0x000247d4]

This could be the same problem. But now I turn the Sony off and then on again, and gscanbus sees it and can again control it. I now see the second part of the SelfID Info:

CSR ROM Info
------------
GUID: 0x0800460102907D8A
Node Capabilities: 0x000083C0
Vendor ID: 0x00080046
Unit Spec ID: 0x0000A02D
Unit SW Version: 0x00010001
Model ID: 0x00000000
Nr. Textual Leafes: 1

Vendor: SONY CORPORATION LTD.
Textual Leafes:
Sony
AV/C Subunits
-------------
Tape Recorder: 1
Video Camera: 1

Pretty cool stuff. It's hard to convey my thrill at getting this far. So the selfID is now correct. Gscanbus now operates with no error messages. And dvgrab fucking works! Gscanbus has been extremely helpful; getting the information about the state of the system made it easier to persiste, and being able to control the camcorder is elegant and surprising.

 

 

 

top
Debate
Evolution
CogSci

Maintained by Francis F. Steen, Communication Studies, University of California Los Angeles


CogWeb