Deleted Added
full compact
fwcontrol.8 (140442) fwcontrol.8 (163712)
1.\" Copyright (c) 2002 Hidetoshi Shimokawa
2.\" All rights reserved.
3.\"
4.\" Redistribution and use in source and binary forms, with or without
5.\" modification, are permitted provided that the following conditions
6.\" are met:
7.\" 1. Redistributions of source code must retain the above copyright
8.\" notice, this list of conditions and the following disclaimer.

--- 8 unchanged lines hidden (view full) ---

17.\" INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
18.\" (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
19.\" SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
20.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
21.\" STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
22.\" ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
23.\" POSSIBILITY OF SUCH DAMAGE.
24.\"
1.\" Copyright (c) 2002 Hidetoshi Shimokawa
2.\" All rights reserved.
3.\"
4.\" Redistribution and use in source and binary forms, with or without
5.\" modification, are permitted provided that the following conditions
6.\" are met:
7.\" 1. Redistributions of source code must retain the above copyright
8.\" notice, this list of conditions and the following disclaimer.

--- 8 unchanged lines hidden (view full) ---

17.\" INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
18.\" (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
19.\" SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
20.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
21.\" STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
22.\" ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
23.\" POSSIBILITY OF SUCH DAMAGE.
24.\"
25.\" $FreeBSD: head/usr.sbin/fwcontrol/fwcontrol.8 140442 2005-01-18 20:02:45Z ru $
25.\" $FreeBSD: head/usr.sbin/fwcontrol/fwcontrol.8 163712 2006-10-26 22:33:38Z imp $
26.\"
26.\"
27.Dd December 14, 2004
27.Dd October 24, 2006
28.Dt FWCONTROL 8
29.Os
30.Sh NAME
31.Nm fwcontrol
32.Nd FireWire control utility
33.Sh SYNOPSIS
34.Nm
35.Op Fl u Ar bus_num
36.Op Fl prt
37.Op Fl c Ar node
38.Op Fl d Ar node
39.Op Fl o Ar node
40.Op Fl s Ar node
41.Op Fl l Ar file
42.Op Fl g Ar gap_count
43.Op Fl b Ar pri_req
28.Dt FWCONTROL 8
29.Os
30.Sh NAME
31.Nm fwcontrol
32.Nd FireWire control utility
33.Sh SYNOPSIS
34.Nm
35.Op Fl u Ar bus_num
36.Op Fl prt
37.Op Fl c Ar node
38.Op Fl d Ar node
39.Op Fl o Ar node
40.Op Fl s Ar node
41.Op Fl l Ar file
42.Op Fl g Ar gap_count
43.Op Fl b Ar pri_req
44.Op Fl M Ar mode
44.Op Fl R Ar filename
45.Op Fl S Ar filename
46.Op Fl m Ar EUI64 | hostname
47.Sh DESCRIPTION
48The
49.Nm
50utility is designed to provide a way for users to access and control the
51.Fx

--- 27 unchanged lines hidden (view full) ---

79.It Fl g Ar gap_count
80Broadcast
81.Ar gap_count
82by phy_config packet.
83.It Fl i Ar pri_req
84Set the
85.Dv PRIORITY_BUDGET
86register on all supported nodes.
45.Op Fl R Ar filename
46.Op Fl S Ar filename
47.Op Fl m Ar EUI64 | hostname
48.Sh DESCRIPTION
49The
50.Nm
51utility is designed to provide a way for users to access and control the
52.Fx

--- 27 unchanged lines hidden (view full) ---

80.It Fl g Ar gap_count
81Broadcast
82.Ar gap_count
83by phy_config packet.
84.It Fl i Ar pri_req
85Set the
86.Dv PRIORITY_BUDGET
87register on all supported nodes.
88.It Fl M Ar mode
89Explicitly specify either
90.Ar dv
91or
92.Ar mpeg
93mode for the incoming stream.
94Only meaningful in case of and must preceed the
95.Fl R
96option. If not specified, the program will try to guess. If you get
97an error complaining about "format 0x20", try to force the "mpeg" mode.
87.It Fl R Ar filename
98.It Fl R Ar filename
88Receive DV stream and dump it to a file.
99Receive DV or MPEG TS stream and dump it to a file.
89Use Ctrl-C to stop the receiving.
90Some DV cameras seem not to send the stream if a bus manager exits.
91If you cannot get the stream, try the following commands:
92.Bd -literal -offset indent
93sysctl hw.firewire.try_bmr=0
94fwcontrol -r
95.Ed
96.Pp
97The resulting file contains raw DV data excluding isochronous header
98and CIP header.
99It can be handled by
100.Nm libdv
101in the
102.Fx
100Use Ctrl-C to stop the receiving.
101Some DV cameras seem not to send the stream if a bus manager exits.
102If you cannot get the stream, try the following commands:
103.Bd -literal -offset indent
104sysctl hw.firewire.try_bmr=0
105fwcontrol -r
106.Ed
107.Pp
108The resulting file contains raw DV data excluding isochronous header
109and CIP header.
110It can be handled by
111.Nm libdv
112in the
113.Fx
103Ports Collection.
114Ports Collection. Resulting MPEG TS stream can be played and sent over a
115network using the VideoLAN
116.Nm vlc
117tool in the
118.Fx
119Ports Collection. The stream can be piped directly to
120.Nm vlc,
121see EXAMPLES.
104.It Fl S Ar filename
105Send a DV file as isochronous stream.
106.It Fl m Ar EUI64 | hostname
107Set default fwmem target.
108Hostname will be converted to EUI64 using
109.Xr eui64 5 .
110.El
111.Sh FILES
112.Bl -tag
113.It Pa /dev/fw0.0
114.El
115.Sh EXAMPLES
116Each DV frame has a fixed size and it is easy to edit the frame order.
117.Pp
118.Dl "fwcontrol -R original.dv"
119.Pp
122.It Fl S Ar filename
123Send a DV file as isochronous stream.
124.It Fl m Ar EUI64 | hostname
125Set default fwmem target.
126Hostname will be converted to EUI64 using
127.Xr eui64 5 .
128.El
129.Sh FILES
130.Bl -tag
131.It Pa /dev/fw0.0
132.El
133.Sh EXAMPLES
134Each DV frame has a fixed size and it is easy to edit the frame order.
135.Pp
136.Dl "fwcontrol -R original.dv"
137.Pp
120Receive stream.
138Receive a DV stream with DV camera attached.
121.Pp
122.Dl "dd if=original.dv of=first.dv bs=120000 count=30"
123.Pp
124Get first 30 frames(NTSC).
125.Pp
126.Dl "dd if=original.dv of=second.dv bs=120000 skip=30 count=30"
127.Pp
128Get second 30 frames(NTSC).
129.Pp
130.Dl "cat second.dv first.dv | fwcontrol -S /dev/stdin"
131.Pp
132Swap first and second 30 frames and send them to DV recorder.
133.Pp
134For PAL, replace
135.Dq Li bs=120000
136with
137.Dq Li bs=144000 .
139.Pp
140.Dl "dd if=original.dv of=first.dv bs=120000 count=30"
141.Pp
142Get first 30 frames(NTSC).
143.Pp
144.Dl "dd if=original.dv of=second.dv bs=120000 skip=30 count=30"
145.Pp
146Get second 30 frames(NTSC).
147.Pp
148.Dl "cat second.dv first.dv | fwcontrol -S /dev/stdin"
149.Pp
150Swap first and second 30 frames and send them to DV recorder.
151.Pp
152For PAL, replace
153.Dq Li bs=120000
154with
155.Dq Li bs=144000 .
156.Pp
157.Dl "fwcontrol -R file.m2t
158.Pp
159Receive an MPEG TS stream from a camera producing MPEG transport stream. This
160has been tested with SONY HDR-FX1E camera that produces HD MPEG-2 stream at
16125 Mbps bandwidth.
162.Pp
163To send the stream from the camera over the network using TCP (which supprisingly works better with vlc), you can use
164.Dl "fwcontrol -R - | nc 192.168.10.11 9000
165with
166.Nm netcat
167from ports and to receive the stream, use
168.Dl nc -l -p 9000 | vlc -
169.Pp
170To netcast via UDP, you need to use
171.Nm buffer
172program from ports, since vlc is not fast enough to read UDP packets from
173buffers and thus it experiences dropouts when run directly. The sending side
174can use
175.Dl "fwcontrol -R - | nc 192.168.10.11 9000
176and to receive the stream, use
177.Dl nc -l -u -p 9000 | buffer -s 10k -b 1000 -m 20m -p 5 | vlc -
178.Pp
179
180.Pp
181For more information on how to work with
182.Nm vlc
183see its docs.
138.Sh SEE ALSO
139.Xr firewire 4 ,
140.Xr fwe 4 ,
141.Xr fwip 4 ,
142.Xr fwohci 4 ,
184.Sh SEE ALSO
185.Xr firewire 4 ,
186.Xr fwe 4 ,
187.Xr fwip 4 ,
188.Xr fwohci 4 ,
143.Xr sbp 4
189.Xr sbp 4 ,
190.Xr mplayer 1 ,
191.Xr vlc 1
144.Sh HISTORY
145The
146.Nm
147utility first appeared in
148.Fx 5.0 .
149.Sh AUTHORS
150.An Hidetoshi Shimokawa Aq simokawa@FreeBSD.org
192.Sh HISTORY
193The
194.Nm
195utility first appeared in
196.Fx 5.0 .
197.Sh AUTHORS
198.An Hidetoshi Shimokawa Aq simokawa@FreeBSD.org
199.An Petr Holub Aq hopet@ics.muni.cz
200- MPEG TS mode.
151.Sh BUGS
152This utility is still under development and provided for debugging purposes.
201.Sh BUGS
202This utility is still under development and provided for debugging purposes.
203Especially MPEG TS reception support is very rudimental and supports only
204high-bandwidth MPEG-2 streams (fn field in CIP header equals 3).