Hi
I am having problems selecting the subdev with USRP1:
My USRP1 is populated with 2 LFRX and 2 LFTX.
I am trying the following code:
#!/usr/bin/python
from gnuradio import gr
from gnuradio import uhd
from gnuradio.eng_option import eng_option
class build_block(gr.top_block):
def init(self):
gr.top_block.init(self)
self.u_tx =
uhd.usrp_sink(“serial=47432785”,uhd.stream_args(‘fc32’))
self.u_tx.set_samp_rate(8.0e6)
self.tx_src0 =
gr.sig_source_c(self.u_tx.get_samp_rate(),gr.GR_CONST_WAVE,0, 1.0, 0)
self.u_tx.set_center_freq(10e6)
self.u_tx.set_subdev_spec(“A:AB”,0)
self.connect (self.tx_src0, self.u_tx)
def main ():
tb = build_block ()
tb.start ()
raw_input ('Press Enter to quit: ')
if name == ‘main’:
main ()
This way I get I- and Q- Signals out of TXB.
With the subdev_spec uncommented I get nothing - neither TXA, not TXB.
With self.u_tx.set_subdev_spec(“B:AB”,0) I again only get TXB.
What do I Have to configure to get signals only from TXA?
Thanks
Wolfgang
On Sa, 2013-05-25 at 10:56 -0400, Marcus D. Leech wrote:
def __init__(self):
self.connect (self.tx_src0, self.u_tx)
| Device: USRP1 Device
| | | RX DSP: 0
| | | /
| | | | RX Frontend: BA
| | | | Name: LFRX (A)
| | | | Antennas:
| | _____________________________________________________
| | | | Gain Elements: None
| | | | Connection Type: QI
| | | | Uses LO offset: No
| | | _____________________________________________________
| | | TX DSP: 1
| | | | Sensors:
| | | | Freq range: -32.000 to 32.000 Mhz
| | | | Gain Elements: None
| | | | Connection Type: Q
| | | _____________________________________________________
| | | /
| | | | TX Frontend: A
| | | | Name: LFTX (B)
| | | | Gain range pga: -20.0 to 0.0 step 0.1 dB
If you swap the TXA/TXB cards, what happens?
It looks I have just found the ‘solution’:
If I put the set_subdev_spec above the set_center-freq I can select
between TXA(I&Q) and TXB(I&Q).
I guess I really don’t understand how it all works.
Thanks
Wolfgang
On 05/25/2013 11:55 AM, Wolfgang Buesser wrote:
main ()
Wolfgang
_____________________________________________________
| | _____________________________________________________
| | | ID: LF RX (0x000f)
| | | _____________________________________________________
| | | /
| | | | RX Frontend: B
| | | | Name: ad9522
| | | | Sensors:
| | | | Freq range: -32.000 to 32.000 Mhz
| | | | Gain Elements: None
| | | | Connection Type: Q
| | _____________________________________________________
| | | | Name: LFTX (AB)
| | | | Antennas:
| | | | Sensors:
| | | | Freq range: -32.000 to 32.000 Mhz
| | | TX Dboard: B
| | | | Uses LO offset: No
| | | _____________________________________________________
| | | /
| | | | TX Codec: B
If you use GRC to do these things, it’ll get stuff in the right order,
which you can “crib” from, even if you don’t end up using the resulting
GRC-generated
flow-graph.
–
Marcus L.
Principal Investigator
Shirleys Bay Radio Astronomy Consortium