-
Notifications
You must be signed in to change notification settings - Fork 1.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
gr-filter: Polyphase Arbitrary Resampler Block filter taps #6894
base: main
Are you sure you want to change the base?
Conversation
As a guess, this was a way of stripping off |
@basti-schr We can't change the example to C++, though. Could you remove the changes to the grc file? |
I noticed this still not works in all cases!
in this version only the second scenario is working. As i am new to the yaml code i will try to understand this better and try to make it work in both scenarios. |
Now the block will work for the two scenarios described. I had to manually import the firdes file when defining the filter taps as strings in the resampler block. I would appreciate some feedback as I am new to contributing to gnuradio. |
@basti-schr For muliple commits, unless they are meant to be separable, squash to one commit and force push. |
Tried this out. I think the I tried Decimating FIR Filter and it does not strip, so variable names work, brackets or raw lists of numbers do not. FFT Filter failed for another reason. Interpolating FIR Filter does strip, so a bracketed list works but a variable name does not. Let's look for some opinions on this and try to make everything work at once. I would suggest that allowing the user to specify taps the same way for Python and C++ would be good, and Python has always used list format with brackets. Obviously, we shouldn't strip off the beginning and end of variable names. |
- removes the trimming of the first and last character in taps - fixes issue gnuradio#6103 - changed gr-analog fm_tx example filter taps - and enabled cpp code generation - include filter/firdes header file - adapt vaiables for cpp - add replace rules for [] -> {} Signed-off-by: Sebastian Schröder <github@basti.rocks>
4415842
to
0848f3e
Compare
Thank you for taking a look. I tweaked it a bit more so that it now works with a list. But it looks a bit messy and I think there might be a nicer solution. If you use other filter types, you need to import them as well. However, in my opinion, it would be a bit more of a mess to import all kinds of filters in this template. |
That works. Maybe there's a cleaner way, but it now works better than the other blocks. Do you have any inclination to look through all the other filter blocks that support C++? |
- Interpolating and Decimating FIR Filter - filter taps adaption for cpp generation Signed-off-by: Sebastian Schröder <github@basti.rocks>
Yes, I started with the FIR filters as they were quite simple. The other filters have some problems that I need to look at more closely. I have identified ten more blocks to work on and added them to the comment above as checklist. Do you see another one? I have a question about testing: when installing gnuradio the classic way (cmake .. / make / sudo make install) the modified yaml files are not copied to the /usr/local/share/gnuradio/grc/blocks/ directory. So my solution is to manually copy the *.block.yml files to that location. Is this intended? |
The yml blocks should be installed. Make sure you hit the refresh blocks button on GRC (or restart it) after installing so it reads the new yml files. Have you tested |
Description
The Polyphase Arbitrary Resampler Block trimmed of the first and last character in taps. Therfore the Example gr-analog/fm_tx.grc failed cpp code generation as described in #6103.
Related Issue
Fixes #6103
Fixes #3638
Which blocks/areas does this affect?
Testing Done
In the gr-analog fm_tx Example example i run cpp code generation.
Checklist