Linux Format forums Forum Index Linux Format forums
Help, discussion, magazine feedback and more
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

How do i create hardware nodes?

 
Post new topic   Reply to topic    Linux Format forums Forum Index -> Help!
View previous topic :: View next topic  
Author Message
AJB2K3
Guest





PostPosted: Sun May 22, 2005 9:25 am    Post subject: How do i create hardware nodes? Reply with quote

How do i create hardware nodes in Mandriva ltd ED
Im trying to create a hardware node Video0 for a tevion
TV7134RF video capture card so i can watch tv.
Can anyone help without ignoring me?
Why cant i log back in to edit my posts or check message? the forums are refusing my id a pasword but i have to valid ids?[/b]
Back to top
dandnsmith
LXF regular


Joined: Fri Apr 15, 2005 11:01 am
Posts: 305
Location: Berks, UK

PostPosted: Sun May 22, 2005 5:45 pm    Post subject: RE: How do i create hardware nodes? Reply with quote

I only know how to do it in a terminal window, as root

cd /dev
mknod ......

I suggest a quick look at the man page(s) for mknod and anything else related to get the right parameters.
Post again if there's still a problem, giving detail
_________________
Derek
Back to top
View user's profile Send private message
Guest






PostPosted: Sun May 22, 2005 6:59 pm    Post subject: RE: How do i create hardware nodes? Reply with quote

so i know ive got to do
mknod /dev/Video0 c 4 64
How ever thec 4 64 have to be altered to suit the device, but i dont understand the majour/minor number system.
and i know i need to do something chown for user root&adam, however i lose it her.
can you help?

Um LXF can you do an article on mknod some time please?
Back to top
dandnsmith
LXF regular


Joined: Fri Apr 15, 2005 11:01 am
Posts: 305
Location: Berks, UK

PostPosted: Tue May 24, 2005 12:05 pm    Post subject: RE: How do i create hardware nodes? Reply with quote

After your reply, I just had a quick look myself.
Since I last had occasion to use the mknod command, things have changed. There used to be a script to do it, with enough info to guide you - I cannot see where this is now.
Have a look at the man page for MAKEDEV (put it in CAPS, else it isn't found) and see if that helps at all.
Also devices.txt under /usr/share/doc/MAKEDEV....
_________________
Derek
Back to top
View user's profile Send private message
AJB2K3
Guest





PostPosted: Sun May 29, 2005 1:23 pm    Post subject: RE: How do i create hardware nodes? Reply with quote

Ive created the node using mknod c 81 0 , whick i am told is for capture devices but when i run xawtv in terminal i get
Code:

[adam@localhost ~]$ xawtv
This is xawtv-3.94, running on Linux/i686 (2.6.11-6mdk-i686-up-4GB)
can't open /dev/video0: No such device
v4l-conf had some trouble, trying to continue anyway
v4l2: open /dev/video0: No such device
v4l2: open /dev/video0: No such device
v4l: open /dev/video0: No such device
no video grabber device available
[adam@localhost ~]$

can anyone help me with this?
/dev/video0 does exist and adam has full access.
Back to top
nordle
LXF regular


Joined: Fri Apr 08, 2005 10:56 pm
Posts: 1500

PostPosted: Sun May 29, 2005 4:11 pm    Post subject: RE: How do i create hardware nodes? Reply with quote

Not quite the same, but may be of use:

#!/bin/sh
# Create device nodes for the Linux DVB API with DVB_API_VERSION 2.
# The devices created are suitable for most current PC DVB cards,
# i.e. cards having one frontend, one demux and optionally one
# MPEG decoder.
# The script creates devices for two cards by default.

if [ -e /dev/.devfsd ]; then
echo "It seems you are using devfs. Good!"
exit 0
fi

# get rid of old DVB API devices; do it twice for good measure...
rm -rf /dev/ost
rm -rf /dev/ost
rm -rf /dev/dvb
rm -rf /dev/dvb

mkdir /dev/dvb
chmod 755 /dev/dvb

for i in `seq 0 1`; do
echo "Creating DVB devices in /dev/dvb/adapter$i"
mkdir /dev/dvb/adapter$i
chmod 755 /dev/dvb/adapter$i
mknod -m 0660 /dev/dvb/adapter$i/video0 c 212 `expr 64 \* $i + 0`
mknod -m 0660 /dev/dvb/adapter$i/audio0 c 212 `expr 64 \* $i + 1`
mknod -m 0660 /dev/dvb/adapter$i/frontend0 c 212 `expr 64 \* $i + 3`
mknod -m 0660 /dev/dvb/adapter$i/demux0 c 212 `expr 64 \* $i + 4`
mknod -m 0660 /dev/dvb/adapter$i/dvr0 c 212 `expr 64 \* $i + 5`
mknod -m 0660 /dev/dvb/adapter$i/ca0 c 212 `expr 64 \* $i + 6`
mknod -m 0660 /dev/dvb/adapter$i/net0 c 212 `expr 64 \* $i + 7`
mknod -m 0660 /dev/dvb/adapter$i/osd0 c 212 `expr 64 \* $i + 8`
chown root.video /dev/dvb/adapter$i/*
done
_________________
I think, therefore I compile
Back to top
View user's profile Send private message
Guest






PostPosted: Mon May 30, 2005 9:59 am    Post subject: RE: How do i create hardware nodes? Reply with quote

huh i dont under stand ! i posted a terminal output and you post code .
can you explain.
Back to top
View previous topic :: View next topic  
Display posts from previous:   
Post new topic   Reply to topic    Linux Format forums Forum Index -> Help! All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Linux Format forums topic RSS feed 


Powered by phpBB © 2001, 2005 phpBB Group


Copyright 2011 Future Publishing, all rights reserved.


Web hosting by UKFast