diff --git a/srsue/src/stack/rrc/rrc_cell.cc b/srsue/src/stack/rrc/rrc_cell.cc index e12e52410..cdd0b6693 100644 --- a/srsue/src/stack/rrc/rrc_cell.cc +++ b/srsue/src/stack/rrc/rrc_cell.cc @@ -71,6 +71,12 @@ void meas_cell_eutra::set_sib13(const asn1::rrc::sib_type13_r9_s& sib13_) has_valid_sib13 = true; } +void meas_cell_nr::set_sib1(const asn1::rrc_nr::sib1_s& sib1_) +{ + sib1 = sib1_; + has_valid_sib1 = true; +} + bool meas_cell::is_sib_scheduled(uint32_t sib_index) const { return sib_info_map.find(sib_index) != sib_info_map.end(); diff --git a/srsue/src/stack/rrc_nr/rrc_nr.cc b/srsue/src/stack/rrc_nr/rrc_nr.cc index 0b14f61a5..951f2d0cd 100644 --- a/srsue/src/stack/rrc_nr/rrc_nr.cc +++ b/srsue/src/stack/rrc_nr/rrc_nr.cc @@ -340,6 +340,11 @@ void rrc_nr::handle_sib1(const sib1_s& sib1) { logger.info("SIB1 received, CellID=%d", meas_cells.serving_cell().get_cell_id() & 0xfff); + meas_cells.serving_cell().set_sib1(sib1); + + // TODO: config basic config and remove early exit + return; + // clang-format off // unhandled fields: // - cellSelectionInfo diff --git a/srsue/src/stack/rrc_nr/rrc_nr_procedures.cc b/srsue/src/stack/rrc_nr/rrc_nr_procedures.cc index a17a302d4..63a8c2fa8 100644 --- a/srsue/src/stack/rrc_nr/rrc_nr_procedures.cc +++ b/srsue/src/stack/rrc_nr/rrc_nr_procedures.cc @@ -427,6 +427,17 @@ rrc_nr::cell_selection_proc::handle_cell_search_result(const rrc_interface_phy_n // until cell selection is done, update PHY config to take the last found PCI rrc_handle.phy_cfg.carrier.pci = result.pci; + // Until SI acquisition is implemented, provide hard-coded SIB for now + uint8_t msg[] = {0x74, 0x81, 0x01, 0x70, 0x10, 0x40, 0x04, 0x02, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x33, 0x60, 0x38, + 0x05, 0x01, 0x00, 0x40, 0x1a, 0x00, 0x00, 0x06, 0x6c, 0x6d, 0x92, 0x21, 0xf3, 0x70, 0x40, 0x20, + 0x00, 0x00, 0x80, 0x80, 0x00, 0x41, 0x06, 0x80, 0xa0, 0x90, 0x9c, 0x20, 0x08, 0x55, 0x19, 0x40, + 0x00, 0x00, 0x33, 0xa1, 0xc6, 0xd9, 0x22, 0x40, 0x00, 0x00, 0x20, 0xb8, 0x94, 0x63, 0xc0, 0x09, + 0x28, 0x44, 0x1b, 0x7e, 0xad, 0x8e, 0x1d, 0x00, 0x9e, 0x2d, 0xa3, 0x0a}; + srsran::unique_byte_buffer_t pdu = srsran::make_byte_buffer(); + memcpy(pdu->msg, msg, sizeof(msg)); + pdu->N_bytes = sizeof(msg); + rrc_handle.write_pdu_bcch_dlsch(std::move(pdu)); + if (not rrc_handle.phy->start_cell_select(cs_args)) { Error("Could not set start cell search."); return proc_outcome_t::error;