Constellation Encoder and Decoder
Adapted from GNU Radio's own example (gr-digital/examples/demod/constellation_encode_decode.grc). The random payload is a fixed repeating pattern.
- Author Josh Morman
- Category Digital
- Blocks 13
- Connections 8
- File
digital/constellation_encode_decode.grc
Blocks used
| Block | Module | Used |
|---|---|---|
| Variable | GNU Radio | 4 |
| Char To Float | GNU Radio | 2 |
| Constellation Decoder | GNU Radio | 1 |
| Constellation Encoder | GNU Radio | 1 |
| Constellation Object | GNU Radio | 1 |
| QT GUI Constellation Sink | GNU Radio | 1 |
| QT GUI Time Sink | GNU Radio | 1 |
| Throttle | GNU Radio | 1 |
| Vector Source | GNU Radio | 1 |
Flowgraph source
digital/constellation_encode_decode.grc
options:
parameters:
author: Josh Morman
catch_exceptions: 'True'
category: '[GRC Hier Blocks]'
cmake_opt: ''
comment: ''
copyright: ''
description: Adapted from GNU Radio's own example (gr-digital/examples/demod/constellation_encode_decode.grc). The random
payload is a fixed repeating pattern.
gen_cmake: 'On'
gen_linking: dynamic
generate_options: qt_gui
hier_block_src_path: '.:'
id: constellation_encode_decode
max_nouts: '0'
output_language: python
placement: (0,0)
qt_qss_theme: ''
realtime_scheduling: ''
run: 'True'
run_command: '{python} -u {filename}'
run_options: prompt
sizing_mode: fixed
thread_safe_setters: ''
title: Constellation Encoder and Decoder
window_size: (1000,1000)
states:
bus_sink: false
bus_source: false
bus_structure: null
coordinate: [10, 10]
rotation: 0
state: enabled
blocks:
- name: blocks_char_to_float_0
id: blocks_char_to_float
parameters:
affinity: ''
alias: ''
comment: ''
maxoutbuf: '0'
minoutbuf: '0'
scale: '1'
vlen: '1'
states:
bus_sink: false
bus_source: false
bus_structure: null
coordinate: [1350, 270]
rotation: 0
state: true
- name: blocks_char_to_float_0_0
id: blocks_char_to_float
parameters:
affinity: ''
alias: ''
comment: ''
maxoutbuf: '0'
minoutbuf: '0'
scale: '1'
vlen: '1'
states:
bus_sink: false
bus_source: false
bus_structure: null
coordinate: [1350, 370]
rotation: 0
state: true
- name: blocks_throttle2_0
id: blocks_throttle2
parameters:
affinity: ''
alias: ''
comment: ''
ignoretag: 'True'
limit: auto
maximum: '0.1'
maxoutbuf: '0'
minoutbuf: '0'
samples_per_second: samp_rate
type: byte
vlen: '1'
states:
bus_sink: false
bus_source: false
bus_structure: null
coordinate: [270, 250]
rotation: 0
state: enabled
- name: blocks_vector_source_x_0_0
id: blocks_vector_source_x
parameters:
affinity: ''
alias: ''
comment: ''
maxoutbuf: '0'
minoutbuf: '0'
repeat: 'True'
tags: '[]'
type: byte
vector: data
vlen: '1'
states:
bus_sink: false
bus_source: false
bus_structure: null
coordinate: [10, 260]
rotation: 0
state: enabled
- name: constel
id: variable_constellation
parameters:
comment: ''
const_points: '[1,-1]'
dims: '1'
normalization: digital.constellation.AMPLITUDE_NORMALIZATION
npwr: '1.0'
precision: '8'
rot_sym: '2'
soft_dec_lut: None
sym_map: '[0,1]'
type: bpsk
states:
bus_sink: false
bus_source: false
bus_structure: null
coordinate: [590, 10]
rotation: 0
state: enabled
- name: data
id: variable
parameters:
comment: ''
value: '[0, 1, 1, 0, 1, 0, 0, 1] * 125'
states:
bus_sink: false
bus_source: false
bus_structure: null
coordinate: [910, 10]
rotation: 0
state: enabled
- name: data_size
id: variable
parameters:
comment: ''
value: '1000'
states:
bus_sink: false
bus_source: false
bus_structure: null
coordinate: [1170, 10]
rotation: 0
state: enabled
- name: digital_constellation_decoder_cb_0
id: digital_constellation_decoder_cb
parameters:
affinity: ''
alias: ''
comment: ''
constellation: constel
maxoutbuf: '0'
minoutbuf: '0'
states:
bus_sink: false
bus_source: false
bus_structure: null
coordinate: [970, 270]
rotation: 0
state: true
- name: digital_constellation_encoder_bc_0
id: digital_constellation_encoder_bc
parameters:
affinity: ''
alias: ''
comment: ''
constellation: constel
maxoutbuf: '0'
minoutbuf: '0'
states:
bus_sink: false
bus_source: false
bus_structure: null
coordinate: [600, 270]
rotation: 0
state: true
- name: mod_order
id: variable
parameters:
comment: ''
value: '2'
states:
bus_sink: false
bus_source: false
bus_structure: null
coordinate: [1340, 10]
rotation: 0
state: enabled
- name: qtgui_const_sink_x_0
id: qtgui_const_sink_x
parameters:
affinity: ''
alias: ''
alpha1: '1.0'
alpha10: '1.0'
alpha2: '1.0'
alpha3: '1.0'
alpha4: '1.0'
alpha5: '1.0'
alpha6: '1.0'
alpha7: '1.0'
alpha8: '1.0'
alpha9: '1.0'
autoscale: 'False'
axislabels: 'True'
color1: '"blue"'
color10: '"red"'
color2: '"red"'
color3: '"red"'
color4: '"red"'
color5: '"red"'
color6: '"red"'
color7: '"red"'
color8: '"red"'
color9: '"red"'
comment: ''
grid: 'False'
gui_hint: ''
label1: ''
label10: ''
label2: ''
label3: ''
label4: ''
label5: ''
label6: ''
label7: ''
label8: ''
label9: ''
legend: 'True'
marker1: '0'
marker10: '0'
marker2: '0'
marker3: '0'
marker4: '0'
marker5: '0'
marker6: '0'
marker7: '0'
marker8: '0'
marker9: '0'
name: '""'
nconnections: '1'
size: '1024'
style1: '0'
style10: '0'
style2: '0'
style3: '0'
style4: '0'
style5: '0'
style6: '0'
style7: '0'
style8: '0'
style9: '0'
tr_chan: '0'
tr_level: '0.0'
tr_mode: qtgui.TRIG_MODE_FREE
tr_slope: qtgui.TRIG_SLOPE_POS
tr_tag: '""'
type: complex
update_time: '0.10'
width1: '1'
width10: '1'
width2: '1'
width3: '1'
width4: '1'
width5: '1'
width6: '1'
width7: '1'
width8: '1'
width9: '1'
xmax: '2'
xmin: '-2'
ymax: '2'
ymin: '-2'
states:
bus_sink: false
bus_source: false
bus_structure: null
coordinate: [970, 370]
rotation: 0
state: true
- name: qtgui_time_sink_x_0
id: qtgui_time_sink_x
parameters:
affinity: ''
alias: ''
alpha1: '1.0'
alpha10: '1.0'
alpha2: '1.0'
alpha3: '1.0'
alpha4: '1.0'
alpha5: '1.0'
alpha6: '1.0'
alpha7: '1.0'
alpha8: '1.0'
alpha9: '1.0'
autoscale: 'True'
axislabels: 'True'
color1: blue
color10: dark blue
color2: red
color3: green
color4: black
color5: cyan
color6: magenta
color7: yellow
color8: dark red
color9: dark green
comment: ''
ctrlpanel: 'False'
entags: 'True'
grid: 'False'
gui_hint: ''
label1: Signal 1
label10: Signal 10
label2: Signal 2
label3: Signal 3
label4: Signal 4
label5: Signal 5
label6: Signal 6
label7: Signal 7
label8: Signal 8
label9: Signal 9
legend: 'True'
marker1: '-1'
marker10: '-1'
marker2: '-1'
marker3: '-1'
marker4: '-1'
marker5: '-1'
marker6: '-1'
marker7: '-1'
marker8: '-1'
marker9: '-1'
name: '""'
nconnections: '2'
size: '1024'
stemplot: 'False'
style1: '1'
style10: '1'
style2: '1'
style3: '1'
style4: '1'
style5: '1'
style6: '1'
style7: '1'
style8: '1'
style9: '1'
tr_chan: '0'
tr_delay: '0'
tr_level: '0.0'
tr_mode: qtgui.TRIG_MODE_FREE
tr_slope: qtgui.TRIG_SLOPE_POS
tr_tag: '""'
type: float
update_time: '0.10'
width1: '1'
width10: '1'
width2: '1'
width3: '1'
width4: '1'
width5: '1'
width6: '1'
width7: '1'
width8: '1'
width9: '1'
ylabel: Amplitude
ymax: '1'
ymin: '-1'
yunit: '""'
samp_rate: '1'
states:
bus_sink: false
bus_source: false
bus_structure: null
coordinate: [90, 530]
rotation: 0
state: true
- name: samp_rate
id: variable
parameters:
comment: ''
value: '32000'
states:
bus_sink: false
bus_source: false
bus_structure: null
coordinate: [1510, 10]
rotation: 0
state: enabled
connections:
- [blocks_char_to_float_0, '0', qtgui_time_sink_x_0, '0']
- [blocks_char_to_float_0_0, '0', qtgui_time_sink_x_0, '1']
- [blocks_throttle2_0, '0', blocks_char_to_float_0, '0']
- [blocks_throttle2_0, '0', digital_constellation_encoder_bc_0, '0']
- [blocks_vector_source_x_0_0, '0', blocks_throttle2_0, '0']
- [digital_constellation_decoder_cb_0, '0', blocks_char_to_float_0_0, '0']
- [digital_constellation_encoder_bc_0, '0', digital_constellation_decoder_cb_0, '0']
- [digital_constellation_encoder_bc_0, '0', qtgui_const_sink_x_0, '0']
metadata:
file_format: 1
grc_version: 3.10.10.0