NTSC Receiver

Hello,

I’ve completed a prototype for an NTSC decoder blockset for gnu radio.
It’s not very sophisticated but it lets you see video on the screen
using gr-video-sdl. My development platform is Ubuntu 6.10 x86.

The signal starts out by using a custom AGC which simply scales the
samples by dividing all samples by a local maximum. This puts most of
the samples in the 0 to 1.0 range. Then the frame detector uses a simple
threshold method to determine when pulses begin and end. The length of
time between pulses is used to determine the type of pulse. A simple
state machine keeps the output buffered correctly so the screen doesn’t
get out of whack.

Current features:

  • Black/White reception (vertical and horizontal sync)
  • Contrast/Brightness adjustment (still a little buggy)

Planned features:

  • automatic black level
  • color
  • stereo audio
  • better sync detection
  • documentation

Any feedback would be appreciated.

http://www.danielgarcia.info/thesis/
http://www.danielgarcia.info/thesis/files/gr-video-analog.tgz

-Daniel

Daniel G. schrieb:

Hello,

I’ve completed a prototype for an NTSC decoder blockset for gnu radio.
It’s not very sophisticated but it lets you see video on the screen
using gr-video-sdl. My development platform is Ubuntu 6.10 x86.

All I got was a black window. I know there is an analog TV station on
the channel because my current work
is using the USRP + fft to monitor the spectrum. When I display the FFT
there is clearly a analog TV chanel
with a ‘classic’ signature… i.e. clearly deliniated peaks for all
signal elements, Video, Chomanence, and Audio.

What could be going wrong with my setup.

John C…

Hi -
Tried to run with following error output … thoughts?
thanks, Doug
./usrp_tv_rcv_testingNTSC.py -R A -d 8 -f 76
Using RX d’board A: TV Rx Rev 3
width:508
height:262
d_output_buffer_size:133096
LEADING_EDGE_DETECTION_THRESHOLD: 0.9
TRAILING_EDGE_DETECTION_THRESHOLD: 0.3
SDL screen_mode 32 bits-per-pixel
SDL overlay_mode 842094169
Traceback (most recent call last):
File “./usrp_tv_rcv_testingNTSC.py”, line 400, in ?
app = stdgui.stdapp (tv_rx_graph, “USRP TV RX black-and-white”)
File
“/usr/local/lib/python2.4/site-packages/gnuradio/wxgui/stdgui.py”,
line 36, in init
wx.App.init (self, redirect=False)
File
“/usr/lib/python2.4/site-packages/wx-2.6-gtk2-unicode/wx/_core.py”,
line 7700, in init
self._BootstrapApp()
File
“/usr/lib/python2.4/site-packages/wx-2.6-gtk2-unicode/wx/_core.py”,
line 7352, in _BootstrapApp
return core.PyApp__BootstrapApp(*args, **kwargs)
File
“/usr/local/lib/python2.4/site-packages/gnuradio/wxgui/stdgui.py”,
line 39, in OnInit
frame = stdframe (self.flow_graph_maker, self.title, self._nstatus)
File
“/usr/local/lib/python2.4/site-packages/gnuradio/wxgui/stdgui.py”,
line 60, in init
self.panel = stdpanel (self, self, flow_graph_maker)
File
“/usr/local/lib/python2.4/site-packages/gnuradio/wxgui/stdgui.py”,
line 81, in init
self.fg = flow_graph_maker (frame, self, vbox, sys.argv)
File “./usrp_tv_rcv_testingNTSC.py”, line 188, in init
self.connect (self.src, self.am_demod, self.agc,
self.ntsc_detector,self.dst)
File
“/usr/local/lib/python2.4/site-packages/gnuradio/gr/basic_flow_graph.py”,
line 115, in connect
self._connect (points[i-1], points[i])
File
“/usr/local/lib/python2.4/site-packages/gnuradio/gr/basic_flow_graph.py”,
line 120, in _connect
self._connect_prim (s, d)
File
“/usr/local/lib/python2.4/site-packages/gnuradio/gr/basic_flow_graph.py”,
line 126, in _connect_prim
self._check_valid_dst_port (dst_endpoint)
File
“/usr/local/lib/python2.4/site-packages/gnuradio/gr/basic_flow_graph.py”,
line 225, in _check_valid_dst_port
self._check_port (dst_endpoint.block.input_signature(),
dst_endpoint.port)
File
“/usr/local/lib/python2.4/site-packages/gnuradio/gr/basic_flow_graph.py”,
line 230, in _check_port
if signature.max_streams () == -1: # infinite
AttributeError: ‘PySwigObject’ object has no attribute ‘max_streams’
swig/python detected a memory leak of type ‘gr_io_signature_sptr *’, no
destructor found.

Daniel G.-5 wrote:

samples in the 0 to 1.0 range. Then the frame detector uses a simple

http://www.danielgarcia.info/thesis/
Everyone is raving about the all-new Yahoo! Mail beta.
http://new.mail.yahoo.com


Discuss-gnuradio mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio


View this message in context:
http://www.nabble.com/NTSC-Receiver-tf3280240.html#a9136974
Sent from the GnuRadio mailing list archive at Nabble.com.

On Sat, Feb 24, 2007 at 11:21:08AM -0800, DJCarlson wrote:

TRAILING_EDGE_DETECTION_THRESHOLD: 0.3
swig/python detected a memory leak of type ‘gr_io_signature_sptr *’, no
destructor found.

As far as I know, every occurence of this has been a result of partial
stale installations of GNU Radio, or multiple overlapping
installations.

My suggestions:

$ rm -fr /usr/local/lib/python2.4/site-packages/gnuradio
$ rm -fr /usr/local/lib/python2.4/site-packages/usrp*
$ rm /usr/local/lib/libgnuradio*
$ rm /usr/local/lib/libusrp*

Then start with a fresh check out from svn into AN EMPTY DIRECTORY, or
unpack the latest tarball into AN EMPTY DIRECTORY.

See http://gnuradio.org/trac/wiki for directions on getting the code.

Also, check your PYTHONPATH and make sure that it’s reasonable.
Most folks have something like:

[[email protected] mail]$ echo $PYTHONPATH
/usr/local/lib/python2.4/site-packages

Eric

Eric B. wrote:

As far as I know, every occurence of this has been a result of partial
stale installations of GNU Radio, or multiple overlapping
installations.

My suggestions:

$ rm -fr /usr/local/lib/python2.4/site-packages/gnuradio
$ rm -fr /usr/local/lib/python2.4/site-packages/usrp*
$ rm /usr/local/lib/libgnuradio*
$ rm /usr/local/lib/libusrp*

This is the utility of the ‘make uninstall’ command, which not only
removes the lib stuff but the installed headers, documentation etc.

But ever things get out of sync (like installing the release branch over
an install from the trunk, etc.), it won’t work, and you’d need to do
the above at a minimum.


Johnathan C.
Corgan Enterprises LLC
http://corganenterprises.com

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs