burst_sdcch_subslot_filter: implement and expose GET/SET API
This commit is contained in:
parent
ccc7183e42
commit
fbfd836fc2
|
@ -54,6 +54,13 @@ namespace gr {
|
|||
* creating new instances.
|
||||
*/
|
||||
static sptr make(subslot_filter_mode mode, unsigned int subslot);
|
||||
|
||||
/* External API */
|
||||
virtual unsigned int get_ss(void) = 0;
|
||||
virtual unsigned int set_ss(unsigned int ss) = 0;
|
||||
|
||||
virtual subslot_filter_mode get_mode(void) = 0;
|
||||
virtual subslot_filter_mode set_mode(subslot_filter_mode mode) = 0;
|
||||
};
|
||||
} // namespace gsm
|
||||
} // namespace gr
|
||||
|
|
|
@ -101,5 +101,37 @@ namespace gr {
|
|||
message_port_pub(pmt::mp("out"), msg);
|
||||
}
|
||||
}
|
||||
|
||||
/* External API */
|
||||
unsigned int
|
||||
burst_sdcch_subslot_filter_impl::get_ss(void)
|
||||
{
|
||||
return d_subslot;
|
||||
}
|
||||
|
||||
unsigned int
|
||||
burst_sdcch_subslot_filter_impl::set_ss(unsigned int ss)
|
||||
{
|
||||
if ((d_mode == SS_FILTER_SDCCH8 && ss < 8)
|
||||
|| (d_mode == SS_FILTER_SDCCH4 && ss < 4))
|
||||
d_subslot = ss;
|
||||
|
||||
return d_subslot;
|
||||
}
|
||||
|
||||
|
||||
subslot_filter_mode
|
||||
burst_sdcch_subslot_filter_impl::get_mode(void)
|
||||
{
|
||||
return d_mode;
|
||||
}
|
||||
|
||||
subslot_filter_mode
|
||||
burst_sdcch_subslot_filter_impl::set_mode(subslot_filter_mode mode)
|
||||
{
|
||||
d_mode = mode;
|
||||
return d_mode;
|
||||
}
|
||||
|
||||
} /* namespace gsm */
|
||||
} /* namespace gr */
|
||||
|
|
|
@ -37,6 +37,13 @@ namespace gr {
|
|||
burst_sdcch_subslot_filter_impl(subslot_filter_mode mode, unsigned int subslot);
|
||||
~burst_sdcch_subslot_filter_impl();
|
||||
void process_burst(pmt::pmt_t msg);
|
||||
|
||||
/* External API */
|
||||
unsigned int get_ss(void);
|
||||
unsigned int set_ss(unsigned int ss);
|
||||
|
||||
subslot_filter_mode get_mode(void);
|
||||
subslot_filter_mode set_mode(subslot_filter_mode mode);
|
||||
};
|
||||
|
||||
} // namespace gsm
|
||||
|
|
Loading…
Reference in New Issue