1
0
mirror of https://github.com/gnss-sdr/gnss-sdr synced 2024-12-13 19:50:34 +00:00

Fix shift direction

This commit is contained in:
Carles Fernandez 2023-05-23 12:45:36 +02:00
parent 916dde2174
commit 29f43b72c5
No known key found for this signature in database
GPG Key ID: 4C583C52B0C3877D
2 changed files with 6 additions and 6 deletions

View File

@ -512,7 +512,7 @@ void galileo_telemetry_decoder_gs::decode_INAV_word(float *page_part_symbols, in
{
const std::shared_ptr<OSNMA_msg> tmp_obj = std::make_shared<OSNMA_msg>(d_inav_nav.get_osnma_msg());
this->message_port_pub(pmt::mp("OSNMA_from_TLM"), pmt::make_any(tmp_obj));
uint8_t nma_status = (tmp_obj->hkroot[0] & 0b11000000) << 6;
uint8_t nma_status = (tmp_obj->hkroot[0] & 0b11000000) >> 6;
std::string nma_status_string;
if (nma_status == 0)
{
@ -526,7 +526,7 @@ void galileo_telemetry_decoder_gs::decode_INAV_word(float *page_part_symbols, in
{
nma_status_string = std::string("(Operational mode)");
}
else if (nma_status == 3)
else
{
nma_status_string = std::string("(Do not use mode)");
}

View File

@ -110,15 +110,15 @@ void osnma_msg_receiver::process_osnma_message(const OSNMA_msg& osnma_msg)
void osnma_msg_receiver::read_nma_header(uint8_t nma_header)
{
d_osnma_data.d_nma_header.nmas = (nma_header & 0b11000000) << 6;
d_osnma_data.d_nma_header.cid = (nma_header & 0b00110000) << 4;
d_osnma_data.d_nma_header.cpks = (nma_header & 0b00001110) << 1;
d_osnma_data.d_nma_header.nmas = (nma_header & 0b11000000) >> 6;
d_osnma_data.d_nma_header.cid = (nma_header & 0b00110000) >> 4;
d_osnma_data.d_nma_header.cpks = (nma_header & 0b00001110) >> 1;
d_osnma_data.d_nma_header.reserved = ((nma_header & 0b00000001) ? true : false);
}
void osnma_msg_receiver::read_dsm_header(uint8_t dsm_header)
{
d_osnma_data.d_dsm_header.dsm_id = (dsm_header & 0b11110000) << 4;
d_osnma_data.d_dsm_header.dsm_id = (dsm_header & 0b11110000) >> 4;
d_osnma_data.d_dsm_header.dsm_block_id = dsm_header & 0b00001111;
}