discuss-gnuradio
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Discuss-gnuradio] Writing To An IO FPGA Register


From: Ben Perry
Subject: [Discuss-gnuradio] Writing To An IO FPGA Register
Date: Mon, 9 Feb 2009 01:06:36 -0500

I am trying to write to an IO register on my FPGA to open the lines of
communication. Right now I am just using benchmark_tx.py as my test
case.

In transmit_path.py I added the following

self.u._write_fpga_reg(usrp.FR_OE_1,4227922944)
self.u._write_fpga_reg(usrp.FR_IO_1,4227922944)

I based this off of code I saw in other places, however I am getting
an error. My error is below:

Traceback (most recent call last):
  File "./benchmark_tx.py", line 138, in <module>
    main()
  File "./benchmark_tx.py", line 102, in main
    tb = my_top_block(mods[options.modulation], options)
  File "./benchmark_tx.py", line 42, in __init__
    self.txpath = transmit_path(modulator, options)
  File 
"/home/ben/Desktop/gnuradio/gnuradio-examples/python/digital/transmit_path.py",
line 68, in __init__
    self._setup_usrp_sink()
  File 
"/home/ben/Desktop/gnuradio/gnuradio-examples/python/digital/transmit_path.py",
line 119, in _setup_usrp_sink
    self.u._write_fpga_reg(usrp.FR_OE_1,4227922944)
  File "/usr/local/lib/python2.5/site-packages/gnuradio/usrp/usrp_swig.py",
line 2254, in _write_fpga_reg
    return _usrp_swig.usrp_sink_c_sptr__write_fpga_reg(*args, **kwargs)
TypeError: in method 'usrp_sink_c_sptr__write_fpga_reg', argument 3 of
type 'int'

Any help with this would be appreciated.

Also, I am new to Python. Is 0xFC00FC00 also correct for the register value?

-- 
Benjamin Perry
Georgia Tech, Undergraduate Computer Engineering
Vice President Scuba Tech
CS1371 TA
518.578.6207




reply via email to

[Prev in Thread] Current Thread [Next in Thread]