|
From: | Kyeong Su Shin |
Subject: | Re: [Discuss-gnuradio] extract value of signal |
Date: | Sun, 23 Jun 2019 17:09:45 +0000 |
Hello Jafar:
The "Embedded Python Block" is named as "Python Block" on GNU Radio Companion; it is not called "Embedded Python Block" there. If you cannot find that either, then you may have to get GNU Radio source codes and build them manually.. which could be a bit annoying (There are a few tutorials on the GNU Radio wiki regarding that). Instead of that, you can write your own custom Python GNU Radio blocks (without using the Embedded Python Blocks) by following the Python programming tutorials on the GNU Radio wiki:
https://wiki.gnuradio.org/index.php/Guided_Tutorial_GNU_Radio_in_Python (Sec. 3.2 and later). In your case, this is probably the best practice.
If you want to use TCP, then you can simply add a TCP sink to your flowgraphs, and connect it to the data stream which you wish to output. Now you can connect your Python programs to the TCP sink by using a TCP socket. You will have to study the TCP socket programming if you haven't already. Your program will receive a series of numbers, in binary (interleaved 4-byte floats, if your numbers are in complex format; 4-byte floats, if your numbers are in float). You may have to convert their types to the appropriate one.
ZMQ works in much the same way; you simply add ZMQ sinks to your GNU Radio flowgraphs, and add codes in your Python programs to handle the ZMQ connection. Tutorials for ZMQ are available at http://zeromq.org/intro:read-the-manual . ZMQ is a bit more 'appropriate way', but a pure TCP socket will also do the trick.
*Please note that the TCP/UDP source/sink blocks that are bundled with GNU Radio are deprecated; you may want to use a third-party module instead ( https://github.com/ghostop14/gr-grnet ) .
Regards, Kyeong Su Shin
보낸 사람: jafar jafari <address@hidden>
보낸 날짜: 2019년 6월 23일 일요일 오후 4:11:40 받는 사람: Kyeong Su Shin 제목: Re: [Discuss-gnuradio] extract value of signal hi Kyeong
-I use GRC on raspberry but this version has not embedded python block can i retrieve this block?
-can i use TCP,ZMQ for real time ? if yes how can i use?
best regards
On Mon, Jun 17, 2019 at 6:47 PM Kyeong Su Shin <address@hidden> wrote:
|
[Prev in Thread] | Current Thread | [Next in Thread] |