Ardupilot-NMEA协议的GNSS处理优化

2023-05-16

Ardupilot-NMEA协议的GNSS处理优化

  • Ardupilot-NMEA协议的GNSS处理优化
    • 原固件存在的问题
    • 解决办法

Ardupilot-NMEA协议的GNSS处理优化

原固件存在的问题

1、当所使用的GNSS模块数据反馈频率不到10Hz时,存在锁定GNSS一会又自动把它删除。
原因如下:检测新消息需要判断RMC 和GGA消息包不大于150ms,返回false,然后在update_instance函数中进入超时未收到数据包而误判无GNSS,所有把端口删除, delete drivers[instance]

/*
  see if we have a new set of NMEA messages
 */
bool AP_GPS_NMEA::_have_new_message()
{
    if (_last_RMC_ms == 0 ||
        _last_GGA_ms == 0) {
        return false;
    }
    uint32_t now = AP_HAL::millis();
    if (now - _last_RMC_ms > 150 ||
        now - _last_GGA_ms > 150) {
        return false;
    }
    if (_last_VTG_ms != 0 && 
        now - _last_VTG_ms > 150) {
        return false;
    }
    // prevent these messages being used again
    if (_last_VTG_ms != 0) {
        _last_VTG_ms = 1;
    }

    if (now - _last_HDT_ms > 300) {
        // we have lost GPS yaw
        state.have_gps_yaw = false;
    }

    _last_GGA_ms = 1;
    _last_RMC_ms = 1;
    return true;
}


/*
  update one GPS instance. This should be called at 10Hz or greater
 */
void AP_GPS::update_instance(uint8_t instance)
{
    if (_type[instance] == GPS_TYPE_HIL) {
        // in HIL, leave info alone
        return;
    }
    if (_type[instance] == GPS_TYPE_NONE) {
        // not enabled
        state[instance].status = NO_GPS;
        state[instance].hdop = GPS_UNKNOWN_DOP;
        state[instance].vdop = GPS_UNKNOWN_DOP;
        return;
    }
    if (locked_ports & (1U<<instance)) {
        // the port is locked by another driver
        return;
    }

    if (drivers[instance] == nullptr) {
        // we don't yet know the GPS type of this one, or it has timed
        // out and needs to be re-initialised
        detect_instance(instance);
        return;
    }

    if (_auto_config == GPS_AUTO_CONFIG_ENABLE) {
        send_blob_update(instance);
    }

    // we have an active driver for this instance
    bool result = drivers[instance]->read();
    uint32_t tnow = AP_HAL::millis();

    // if we did not get a message, and the idle timer of 2 seconds
    // has expired, re-initialise the GPS. This will cause GPS
    // detection to run again
    bool data_should_be_logged = false;
    if (!result) {
        if (tnow - timing[instance].last_message_time_ms > GPS_TIMEOUT_MS) {
            memset((void *)&state[instance], 0, sizeof(state[instance]));
            state[instance].instance = instance;
            state[instance].hdop = GPS_UNKNOWN_DOP;
            state[instance].vdop = GPS_UNKNOWN_DOP;
            timing[instance].last_message_time_ms = tnow;
            timing[instance].delta_time_ms = GPS_TIMEOUT_MS;
            // do not try to detect again if type is MAV
            if (_type[instance] == GPS_TYPE_MAV) {
                state[instance].status = NO_FIX;
            } else {
                // free the driver before we run the next detection, so we
                // don't end up with two allocated at any time
                delete drivers[instance];
                drivers[instance] = nullptr;
                state[instance].status = NO_GPS;
            }
            // log this data as a "flag" that the GPS is no longer
            // valid (see PR#8144)
            data_should_be_logged = true;
        }
    } else {
        if (state[instance].uart_timestamp_ms != 0) {
            // set the timestamp for this messages based on
            // set_uart_timestamp() in backend, if available
            tnow = state[instance].uart_timestamp_ms;
            state[instance].uart_timestamp_ms = 0;
        }
        // delta will only be correct after parsing two messages
        timing[instance].delta_time_ms = tnow - timing[instance].last_message_time_ms;
        timing[instance].last_message_time_ms = tnow;
        if (state[instance].status >= GPS_OK_FIX_2D) {
            timing[instance].last_fix_time_ms = tnow;
        }

        data_should_be_logged = true;
    }

#if GPS_MAX_RECEIVERS > 1
    if (drivers[instance] && _type[instance] == GPS_TYPE_UBLOX_RTK_BASE) {
        // see if a moving baseline base has some RTCMv3 data
        // which we need to pass along to the rover
        const uint8_t *rtcm_data;
        uint16_t rtcm_len;
        if (drivers[instance]->get_RTCMV3(rtcm_data, rtcm_len)) {
            for (uint8_t i=0; i< GPS_MAX_RECEIVERS; i++) {
                if (i != instance && _type[i] == GPS_TYPE_UBLOX_RTK_ROVER) {
                    // pass the data to the rover
                    inject_data(i, rtcm_data, rtcm_len);
                    drivers[instance]->clear_RTCMV3();
                    break;
                }
            }
        }
    }
#endif

    if (data_should_be_logged) {
        // keep count of delayed frames and average frame delay for health reporting
        const uint16_t gps_max_delta_ms = 245; // 200 ms (5Hz) + 45 ms buffer
        GPS_timing &t = timing[instance];

        if (t.delta_time_ms > gps_max_delta_ms) {
            t.delayed_count++;
        } else {
            t.delayed_count = 0;
        }
        if (t.delta_time_ms < 2000) {
            if (t.average_delta_ms <= 0) {
                t.average_delta_ms = t.delta_time_ms;
            } else {
                t.average_delta_ms = 0.98f * t.average_delta_ms + 0.02f * t.delta_time_ms;
            }
        }
    }
    
#ifndef HAL_BUILD_AP_PERIPH
    if (data_should_be_logged &&
        (should_log() || AP::ahrs().have_ekf_logging())) {
        AP::logger().Write_GPS(instance);
    }

    if (state[instance].status >= GPS_OK_FIX_3D) {
        const uint64_t now = time_epoch_usec(instance);
        if (now != 0) {
            AP::rtc().set_utc_usec(now, AP_RTC::SOURCE_GPS);
        }
    }
#else
    (void)data_should_be_logged;
#endif
}

2、GNSS未定位时不更新收到RMC消息包的时间戳_last_RMC_ms

// Processes a just-completed term
// Returns true if new sentence has just passed checksum test and is validated
bool AP_GPS_NMEA::_term_complete()
{
    // handle the last term in a message
    if (_is_checksum_term) {
        uint8_t nibble_high = 0;
        uint8_t nibble_low  = 0;
        if (!hex_to_uint8(_term[0], nibble_high) || !hex_to_uint8(_term[1], nibble_low)) {
            return false;
        }
        const uint8_t checksum = (nibble_high << 4u) | nibble_low;
        if (checksum == _parity) {
            if (_gps_data_good) {
                uint32_t now = AP_HAL::millis();
                switch (_sentence_type) {
                case _GPS_SENTENCE_RMC:
                    _last_RMC_ms = now;
                    //time                        = _new_time;
                    //date                        = _new_date;
                    state.location.lat     = _new_latitude;
                    state.location.lng     = _new_longitude;
                    state.ground_speed     = _new_speed*0.01f;
                    state.ground_course    = wrap_360(_new_course*0.01f);
                    make_gps_time(_new_date, _new_time * 10);
                    set_uart_timestamp(_sentence_length);
                    state.last_gps_time_ms = now;
                    fill_3d_velocity();
                    break;
                case _GPS_SENTENCE_GGA:
                    _last_GGA_ms = now;
                    state.location.alt  = _new_altitude;
                    state.location.lat  = _new_latitude;
                    state.location.lng  = _new_longitude;
                    state.num_sats      = _new_satellite_count;
                    state.hdop          = _new_hdop;
                    switch(_new_quality_indicator) {
                    case 0: // Fix not available or invalid
                        state.status = AP_GPS::NO_FIX;
                        break;
                    case 1: // GPS SPS Mode, fix valid
                        state.status = AP_GPS::GPS_OK_FIX_3D;
                        break;
                    case 2: // Differential GPS, SPS Mode, fix valid
                        state.status = AP_GPS::GPS_OK_FIX_3D_DGPS;
                        break;
                    case 3: // GPS PPS Mode, fix valid
                        state.status = AP_GPS::GPS_OK_FIX_3D;
                        break;
                    case 4: // Real Time Kinematic. System used in RTK mode with fixed integers
                        state.status = AP_GPS::GPS_OK_FIX_3D_RTK_FIXED;
                        break;
                    case 5: // Float RTK. Satellite system used in RTK mode, floating integers
                        state.status = AP_GPS::GPS_OK_FIX_3D_RTK_FLOAT;
                        break;
                    case 6: // Estimated (dead reckoning) Mode
                        state.status = AP_GPS::NO_FIX;
                        break;
                    default://to maintain compatibility with MAV_GPS_INPUT and others
                        state.status = AP_GPS::GPS_OK_FIX_3D;
                        break;
                    }
                    break;
                case _GPS_SENTENCE_VTG:
                    _last_VTG_ms = now;
                    state.ground_speed  = _new_speed*0.01f;
                    state.ground_course = wrap_360(_new_course*0.01f);
                    fill_3d_velocity();
                    // VTG has no fix indicator, can't change fix status
                    break;
                case _GPS_SENTENCE_HDT:
                    _last_HDT_ms = now;
                    state.gps_yaw = wrap_360(_new_gps_yaw*0.01f);
                    state.have_gps_yaw = true;
                    // remember that we are setup to provide yaw. With
                    // a NMEA GPS we can only tell if the GPS is
                    // configured to provide yaw when it first sends a
                    // HDT sentence.
                    state.gps_yaw_configured = true;
                    break;
                }
            } else {
                switch (_sentence_type) {
                case _GPS_SENTENCE_RMC:
                case _GPS_SENTENCE_GGA:
                    // Only these sentences give us information about
                    // fix status.
                    state.status = AP_GPS::NO_FIX;
                }
            }
            // see if we got a good message
            return _have_new_message();
        }
        // we got a bad message, ignore it
        return false;
    }

    // the first term determines the sentence type
    if (_term_number == 0) {
        /*
          The first two letters of the NMEA term are the talker
          ID. The most common is 'GP' but there are a bunch of others
          that are valid. We accept any two characters here.
         */
        if (_term[0] < 'A' || _term[0] > 'Z' ||
            _term[1] < 'A' || _term[1] > 'Z') {
            _sentence_type = _GPS_SENTENCE_OTHER;
            return false;
        }
        const char *term_type = &_term[2];
        if (strcmp(term_type, "RMC") == 0) {
            _sentence_type = _GPS_SENTENCE_RMC;
        } else if (strcmp(term_type, "GGA") == 0) {
            _sentence_type = _GPS_SENTENCE_GGA;
        } else if (strcmp(term_type, "HDT") == 0) {
            _sentence_type = _GPS_SENTENCE_HDT;
            // HDT doesn't have a data qualifier
            _gps_data_good = true;
        } else if (strcmp(term_type, "VTG") == 0) {
            _sentence_type = _GPS_SENTENCE_VTG;
            // VTG may not contain a data qualifier, presume the solution is good
            // unless it tells us otherwise.
            _gps_data_good = true;
        } else {
            _sentence_type = _GPS_SENTENCE_OTHER;
        }
        return false;
    }

    // 32 = RMC, 64 = GGA, 96 = VTG, 128 = HDT
    if (_sentence_type != _GPS_SENTENCE_OTHER && _term[0]) {
        switch (_sentence_type + _term_number) {
        // operational status
        //
        case _GPS_SENTENCE_RMC + 2: // validity (RMC)
            _gps_data_good = _term[0] == 'A';
            break;
        case _GPS_SENTENCE_GGA + 6: // Fix data (GGA)
            _gps_data_good = _term[0] > '0';
            _new_quality_indicator = _term[0] - '0';
            break;
        case _GPS_SENTENCE_VTG + 9: // validity (VTG) (we may not see this field)
            _gps_data_good = _term[0] != 'N';
            break;
        case _GPS_SENTENCE_GGA + 7: // satellite count (GGA)
            _new_satellite_count = atol(_term);
            break;
        case _GPS_SENTENCE_GGA + 8: // HDOP (GGA)
            _new_hdop = (uint16_t)_parse_decimal_100(_term);
            break;

        // time and date
        //
        case _GPS_SENTENCE_RMC + 1: // Time (RMC)
        case _GPS_SENTENCE_GGA + 1: // Time (GGA)
            _new_time = _parse_decimal_100(_term);
            break;
        case _GPS_SENTENCE_RMC + 9: // Date (GPRMC)
            _new_date = atol(_term);
            break;

        // location
        //
        case _GPS_SENTENCE_RMC + 3: // Latitude
        case _GPS_SENTENCE_GGA + 2:
            _new_latitude = _parse_degrees();
            break;
        case _GPS_SENTENCE_RMC + 4: // N/S
        case _GPS_SENTENCE_GGA + 3:
            if (_term[0] == 'S')
                _new_latitude = -_new_latitude;
            break;
        case _GPS_SENTENCE_RMC + 5: // Longitude
        case _GPS_SENTENCE_GGA + 4:
            _new_longitude = _parse_degrees();
            break;
        case _GPS_SENTENCE_RMC + 6: // E/W
        case _GPS_SENTENCE_GGA + 5:
            if (_term[0] == 'W')
                _new_longitude = -_new_longitude;
            break;
        case _GPS_SENTENCE_GGA + 9: // Altitude (GPGGA)
            _new_altitude = _parse_decimal_100(_term);
            break;

        // course and speed
        //
        case _GPS_SENTENCE_RMC + 7: // Speed (GPRMC)
        case _GPS_SENTENCE_VTG + 5: // Speed (VTG)
            _new_speed = (_parse_decimal_100(_term) * 514) / 1000;       // knots-> m/sec, approximiates * 0.514
            break;
        case _GPS_SENTENCE_HDT + 1: // Course (HDT)
            _new_gps_yaw = _parse_decimal_100(_term);
            break;
        case _GPS_SENTENCE_RMC + 8: // Course (GPRMC)
        case _GPS_SENTENCE_VTG + 1: // Course (VTG)
            _new_course = _parse_decimal_100(_term);
            break;
        }
    }

    return false;
}

解决办法

1、在 bool AP_GPS_NMEA::_have_new_message() 函数中把消息包更新间隔时间允许不大于250ms,可认为是支持5Hz数据输出的GNSS。

/*
  see if we have a new set of NMEA messages
 */
bool AP_GPS_NMEA::_have_new_message()
{
    if (_last_RMC_ms == 0 ||
        _last_GGA_ms == 0) {
        return false;
    }
    //GNSS is required to reach a frequency of at least 5Hz
    uint32_t now = AP_HAL::millis();
    if (now - _last_RMC_ms > 250 ||
        now - _last_GGA_ms > 250) {
        return false;
    }
    if (_last_VTG_ms != 0 && 
        now - _last_VTG_ms > 250) {
        return false;
    }
    // prevent these messages being used again
    if (_last_VTG_ms != 0) {
        _last_VTG_ms = 1;
    }

    if (now - _last_HDT_ms > 300) {
        // we have lost GPS yaw
        state.have_gps_yaw = false;
    }

    _last_GGA_ms = 1;
    _last_RMC_ms = 1;
    return true;
}

2、未定位时添加RMS和GGA收包时间
将这两行加入_term_complete()函数

 _last_RMC_ms = AP_HAL::millis();    //Correct package received when not located, refresh time
 _last_GGA_ms = AP_HAL::millis();    //Correct package received when not located, refresh time
// Processes a just-completed term
// Returns true if new sentence has just passed checksum test and is validated
bool AP_GPS_NMEA::_term_complete()
{
    // handle the last term in a message
    if (_is_checksum_term) {
        uint8_t nibble_high = 0;
        uint8_t nibble_low  = 0;
        if (!hex_to_uint8(_term[0], nibble_high) || !hex_to_uint8(_term[1], nibble_low)) {
            return false;
        }
        const uint8_t checksum = (nibble_high << 4u) | nibble_low;
        if (checksum == _parity) {
            if (_gps_data_good) {
                uint32_t now = AP_HAL::millis();
                switch (_sentence_type) {
                case _GPS_SENTENCE_RMC:
                    _last_RMC_ms = now;
                    //time                        = _new_time;
                    //date                        = _new_date;
                    state.location.lat     = _new_latitude;
                    state.location.lng     = _new_longitude;
                    state.ground_speed     = _new_speed*0.01f;
                    state.ground_course    = wrap_360(_new_course*0.01f);
                    make_gps_time(_new_date, _new_time * 10);
                    set_uart_timestamp(_sentence_length);
                    state.last_gps_time_ms = now;
                    fill_3d_velocity();
                    break;
                case _GPS_SENTENCE_GGA:
                    _last_GGA_ms = now;
                    state.location.alt  = _new_altitude;
                    state.location.lat  = _new_latitude;
                    state.location.lng  = _new_longitude;
                    state.num_sats      = _new_satellite_count;
                    state.hdop          = _new_hdop;
                    switch(_new_quality_indicator) {
                    case 0: // Fix not available or invalid
                        state.status = AP_GPS::NO_FIX;
                        break;
                    case 1: // GPS SPS Mode, fix valid
                        state.status = AP_GPS::GPS_OK_FIX_3D;
                        break;
                    case 2: // Differential GPS, SPS Mode, fix valid
                        state.status = AP_GPS::GPS_OK_FIX_3D_DGPS;
                        break;
                    case 3: // GPS PPS Mode, fix valid
                        state.status = AP_GPS::GPS_OK_FIX_3D;
                        break;
                    case 4: // Real Time Kinematic. System used in RTK mode with fixed integers
                        state.status = AP_GPS::GPS_OK_FIX_3D_RTK_FIXED;
                        break;
                    case 5: // Float RTK. Satellite system used in RTK mode, floating integers
                        state.status = AP_GPS::GPS_OK_FIX_3D_RTK_FLOAT;
                        break;
                    case 6: // Estimated (dead reckoning) Mode
                        state.status = AP_GPS::NO_FIX;
                        break;
                    default://to maintain compatibility with MAV_GPS_INPUT and others
                        state.status = AP_GPS::GPS_OK_FIX_3D;
                        break;
                    }
                    break;
                case _GPS_SENTENCE_VTG:
                    _last_VTG_ms = now;
                    state.ground_speed  = _new_speed*0.01f;
                    state.ground_course = wrap_360(_new_course*0.01f);
                    fill_3d_velocity();
                    // VTG has no fix indicator, can't change fix status
                    break;
                case _GPS_SENTENCE_HDT:
                    _last_HDT_ms = now;
                    state.gps_yaw = wrap_360(_new_gps_yaw*0.01f);
                    state.have_gps_yaw = true;
                    // remember that we are setup to provide yaw. With
                    // a NMEA GPS we can only tell if the GPS is
                    // configured to provide yaw when it first sends a
                    // HDT sentence.
                    state.gps_yaw_configured = true;
                    break;
                }
            } else {
                switch (_sentence_type) {
                case _GPS_SENTENCE_RMC:
                    _last_RMC_ms = AP_HAL::millis();    //Correct package received when not located, refresh time
                case _GPS_SENTENCE_GGA:
                    _last_GGA_ms = AP_HAL::millis();    //Correct package received when not located, refresh time
                    // Only these sentences give us information about
                    // fix status.
                    state.status = AP_GPS::NO_FIX;
                }
            }
            // see if we got a good message
            return _have_new_message();
        }
        // we got a bad message, ignore it
        return false;
    }

    // the first term determines the sentence type
    if (_term_number == 0) {
        /*
          The first two letters of the NMEA term are the talker
          ID. The most common is 'GP' but there are a bunch of others
          that are valid. We accept any two characters here.
         */
        if (_term[0] < 'A' || _term[0] > 'Z' ||
            _term[1] < 'A' || _term[1] > 'Z') {
            _sentence_type = _GPS_SENTENCE_OTHER;
            return false;
        }
        const char *term_type = &_term[2];
        if (strcmp(term_type, "RMC") == 0) {
            _sentence_type = _GPS_SENTENCE_RMC;
        } else if (strcmp(term_type, "GGA") == 0) {
            _sentence_type = _GPS_SENTENCE_GGA;
        } else if (strcmp(term_type, "HDT") == 0) {
            _sentence_type = _GPS_SENTENCE_HDT;
            // HDT doesn't have a data qualifier
            _gps_data_good = true;
        } else if (strcmp(term_type, "VTG") == 0) {
            _sentence_type = _GPS_SENTENCE_VTG;
            // VTG may not contain a data qualifier, presume the solution is good
            // unless it tells us otherwise.
            _gps_data_good = true;
        } else {
            _sentence_type = _GPS_SENTENCE_OTHER;
        }
        return false;
    }

    // 32 = RMC, 64 = GGA, 96 = VTG, 128 = HDT
    if (_sentence_type != _GPS_SENTENCE_OTHER && _term[0]) {
        switch (_sentence_type + _term_number) {
        // operational status
        //
        case _GPS_SENTENCE_RMC + 2: // validity (RMC)
            _gps_data_good = _term[0] == 'A';
            break;
        case _GPS_SENTENCE_GGA + 6: // Fix data (GGA)
            _gps_data_good = _term[0] > '0';
            _new_quality_indicator = _term[0] - '0';
            break;
        case _GPS_SENTENCE_VTG + 9: // validity (VTG) (we may not see this field)
            _gps_data_good = _term[0] != 'N';
            break;
        case _GPS_SENTENCE_GGA + 7: // satellite count (GGA)
            _new_satellite_count = atol(_term);
            break;
        case _GPS_SENTENCE_GGA + 8: // HDOP (GGA)
            _new_hdop = (uint16_t)_parse_decimal_100(_term);
            break;

        // time and date
        //
        case _GPS_SENTENCE_RMC + 1: // Time (RMC)
        case _GPS_SENTENCE_GGA + 1: // Time (GGA)
            _new_time = _parse_decimal_100(_term);
            break;
        case _GPS_SENTENCE_RMC + 9: // Date (GPRMC)
            _new_date = atol(_term);
            break;

        // location
        //
        case _GPS_SENTENCE_RMC + 3: // Latitude
        case _GPS_SENTENCE_GGA + 2:
            _new_latitude = _parse_degrees();
            break;
        case _GPS_SENTENCE_RMC + 4: // N/S
        case _GPS_SENTENCE_GGA + 3:
            if (_term[0] == 'S')
                _new_latitude = -_new_latitude;
            break;
        case _GPS_SENTENCE_RMC + 5: // Longitude
        case _GPS_SENTENCE_GGA + 4:
            _new_longitude = _parse_degrees();
            break;
        case _GPS_SENTENCE_RMC + 6: // E/W
        case _GPS_SENTENCE_GGA + 5:
            if (_term[0] == 'W')
                _new_longitude = -_new_longitude;
            break;
        case _GPS_SENTENCE_GGA + 9: // Altitude (GPGGA)
            _new_altitude = _parse_decimal_100(_term);
            break;

        // course and speed
        //
        case _GPS_SENTENCE_RMC + 7: // Speed (GPRMC)
        case _GPS_SENTENCE_VTG + 5: // Speed (VTG)
            _new_speed = (_parse_decimal_100(_term) * 514) / 1000;       // knots-> m/sec, approximiates * 0.514
            break;
        case _GPS_SENTENCE_HDT + 1: // Course (HDT)
            _new_gps_yaw = _parse_decimal_100(_term);
            break;
        case _GPS_SENTENCE_RMC + 8: // Course (GPRMC)
        case _GPS_SENTENCE_VTG + 1: // Course (VTG)
            _new_course = _parse_decimal_100(_term);
            break;
        }
    }

    return false;
}

由此解决了频率5Hz的GNSS使用NMEA协议时,出现的连接上GNSS后过4秒又出现NO GPS,然后又检测到的问题

本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)

Ardupilot-NMEA协议的GNSS处理优化 的相关文章

  • 启动golang项目编译的exe可执行文件获取windows管理员权限(UAC)

    背景 xff1a go代码启动以后里面涉及到修改ip地址等操作 xff0c 需要管理员权限 打包好的exe文件双击执行默认是没有管理员权限的 xff0c 那么修改ip就会提示需要管理员权限 解决方法1 xff1a 右键以管理员权限运行exe
  • k8s外部访问pod内部容器的端口-NodePort

    一 如何从外部网络访问 Kubernetes的Pod IP和Cluster IP都只能在集群内部访问 xff0c 而我们通常需要从外部网络上访问集群中的某些服务 xff0c Kubernetes提供了下述几种方式来为集群提供外部流量入口 二
  • python断点下载文件

    使用pytohn编码实现文件的断点下载 span class token keyword import span os span class token keyword import span json span class token k
  • 异常检测(1)—初识异常检测

    1 概念 异常一般是指与标准值 xff08 预期值 xff09 有偏离的样本点 xff0c 也就是跟绝大部分数据 长的不一样 异常往往是 有价值 的事情 xff0c 我们对异常的成因感兴趣 2 类别 有监督 xff1a 数据集有标签无监督
  • 【git】在GitHub上下载历史版本

    GitHub上的项目很多都是从简单到复杂 xff0c 一点点迭代的 当我们需要看懂别人的代码时 xff0c 按照别人commit的历史版本一步一步跟踪 xff0c 或许是个好办法 这时候我们就要用到下载历史版本功能了 1 git clone
  • 实时操作系统UCOS学习笔记1----UCOSII简介

    前面我们所有的实验都是跑的裸机程序 xff08 裸奔 xff09 xff0c 从本章开始 xff0c 我们开始介绍UCOSII xff08 实时多任务操作系统内核 xff09 UCOSII简介 UCOSII的前身是UCOS xff0c 最早
  • 欢聚时代YY/测试实习面试

    去到YY大楼 xff0c 虽然在番禺但是附近很多楼在施工中了 大楼就在万达后面 前台登记 xff0c 小姐姐会让你出示邀请邮件 xff0c 然后直接上去就行了 达到楼层 xff0c 二维码签到 然后找地方坐一下等待面试 一轮是技术面 xff
  • 基于卡尔曼滤波的气压计高度解算

    ax ay az为归一化的加速度数据 1代表重力加速度 gx gy gz 为加速度数据 单位rad s altitude为气压计测量得到的海拔数据 欧拉角 float pitch roll yaw 世界坐标系下机体加速度 float ax
  • Kali安装Xfce4

    Kali安装Xface4 一 配置kali源并更新二 解决报错1 签名无效2 依赖报错 三 安装xfce4 一 配置kali源并更新 此处使用的是gedit编辑器 xff0c gedit etc apt sources list xff0c
  • 串口转WIFI的工作方式理解

    串口无线 AP xff08 COM AP xff09 串口无线 STA xff08 COM STA xff09 和 串口无线 AP 43 STA xff08 COM AP 43 STA xff09 3 个模式 串口WIFI模块是基于Uart
  • 典型环节的频率特性(建议收藏)

    自控笔记 5 3典型环节频率特性 控制系统种类繁多 xff0c 传递函数复杂 xff0c 但任何形式的传递函数都是由有限的典型环节组成 因此 xff0c 掌握典型环节的频率特性是使用频域法分析系统的基础 如下表所示 xff0c 构成系统的最
  • 【WINAPI】CreateSemaphore_信号量

    WINAPI CreateSemaphore 信号量 1 注册信号量函数1 1 参数1 2 返回值 2 释放信号量函数2 1 参数2 2 返回值 3 WaitForSingleObject3 2 参数3 3 返回值 4 例子4 1 运行结果
  • MAVROS二次开发(一)MAVROS的安装

    MAVROS二次开发 一 MAVROS的安装 1 参考网址 https dev px4 io v1 10 en ros mavros installation html https github com mavlink mavros tre
  • MAVROS二次开发(二)(三)添加自定义消息

    MAVROS二次开发 二 MAVROS消息添加 1 自定义rostopic消息 路径 xff1a catkin ws src mavros mavros msgs msg 自定义消息文件名称 xff1a CrawlControlStatus
  • MAVROS二次开发(四)添加消息处理插件

    MAVROS二次开发 四 添加消息处理插件 mavros插件所在路径 xff1a catkin ws src mavros mavros src plugins 1 自定义消息处理插件的编写 参考代码 xff1a catkin ws src
  • MAVROS二次开发(五)进行测试

    MAVROS二次开发 五 进行测试 1 测试环境 PX4 xff1a v1 10 1 xff08 含自定义mavlink消息收发 xff09 ROS xff1a KineticUbuntu xff1a 16 04LTSQGC xff1a S
  • ROS2+PX4开发环境配置

    一 ROS2安装 Ubuntu18 04的ros2版本 xff1a Eloquent 参考网址 xff1a https docs ros org en eloquent Installation Linux Install Debians
  • Windows10下Airsim+PX4(WSL2)+MAVROS仿真环境搭建

    一 Windows10下WSL2安装 1 1 WSL2的安装与配置 首先在Windows10下启用WSL xff0c 以管理员身份打开 PowerShell 工具并运行以下命令 dism span class token punctuati
  • Windows10通过vcpkg快速配置PCL库

    1 安装C 43 43 包管理工具vcpkg https github com microsoft vcpkg span class token function git span clone https github com micros
  • 微软Chromium版Edge浏览器正式稳定版

    微软Chromium版Edge浏览器正式稳定版 近期微软Chromium版Edge浏览器正式稳定版下载已经泄露 xff0c 版本77 0 235 9 此版本没有div什么的那些 xff0c 和之前的图标一样 当安装新Edge稳定版之后 xf

随机推荐

  • C++疑难问题

    acwing中的算法疑惑 1 为什么确定范围 要 43 10 在使用归并排序和快速排序等方法时有效率问题 xff0c 确定范围在1e6 但是选择的是1e 43 10 2 C 43 43 除二乘2简单方法以及算法效率问题 算法效率速度排行 x
  • 用python的scipy中的odeint来解常微分方程中的一些细节问题(适用于小白)

    用python的scipy中的odeint来解常微分方程中的一些细节问题 xff08 适用于小白 xff09 写在前面 最近有些需要解决常微分方程的问题 xff0c 网上查了很多教程都不是很明晰 xff0c 便自己研究了一段时间 xff0c
  • VsCode使用Git连接Gitee和GitHub

    VsCode连接GitHub和Gitee VsCode连接GitHub和Gitee一 软件安装1 安装git2 vscode 二 在Github或者Gitee上创建空的仓库 项目1 在Github创建空的仓库 项目2 在Gitee创建新项目
  • Julia配置【使用VScode中的Jupyter编写Julia的方法】

    简略目录 安装Julia切换国内源安装Ijulia插件VSCode配置 首次编写日期 xff1a 2021 07 10 安装Julia 官网 xff0c 一路默认即可 xff0c 记得添加PATH xff0c 安装位置可以自定义 切换国内源
  • VSCode配置C++环境(MSVC)

    VSCode配置C 43 43 环境 xff08 MSVC xff09 最近心血来潮 xff0c 想用一下微软的VSCode写一下C 43 43 xff0c 然而第一步就卡住了 xff0c 竟然不会配置C 43 43 环境 xff0c 陆陆
  • GTSAM理解

    1 xff1a GTSAM是什么 参考博文 xff1a gtsam xff1a 从入门到使用 1 xff1a 是什么 xff1a GTSAM是用于计算机视觉和多传感器融合方面用于平滑和建图的C 43 43 库 xff0c GTSAM采用因子
  • tag与branch的区别

    1 什么是tag 什么时候应该创建一个tag 项目的版本管理中 每当一个release版本发布时 需要做一个记录 以便以后需要的时候能查找特定的版本 这时候就用到tag这个功能 Git中的tag指向一次commit的id xff0c 通常用
  • 简历中“项目经历“该如何写?

    前言 找工作 xff0c 简历是最关键的一步 xff0c 只有通过了简历筛查才能往下继续进行 很多人写简历 xff0c 都是在记录流水账 xff0c 看来没有任何平淡寡味 其实简历的核心价值就在于游说 hr 和面试官 xff1a 看我 xf
  • 深度学习解释:Precision、Recall、IoU、Ap/mAp

    深度学习的指标都是 xff08 APAverage Precision xff09 二分类情况下的Precision xff08 查重率 xff09 和Recall xff08 查全率 xff09 对于二分类问题 xff0c 可将样例根据其
  • input上传文件图片本地预览

    lt form gt lt input type 61 34 file 34 id 61 34 avatar 34 name 61 34 avatar 34 gt lt button gt 点击上传 lt button gt lt form
  • colmap pthread 错误

    Looking for include file pthread h Looking for include file pthread h found Looking for pthread create Looking for pthre
  • 全球系留无人机系统行业调研及趋势分析报告

    本文调研和分析全球系留无人机系统发展现状及未来趋势 xff0c 核心内容如下 xff1a xff08 1 xff09 全球市场总体规模 xff0c 分别按销量和按收入进行了统计分析 xff0c 历史数据2017 2021年 xff0c 预测
  • 安装arm-none-eabi版本添加环境变了还是出错问题解决

    安装arm none eabi版本添加环境变了还是出错问题解决 问题解决 问题 已经在 profile文件里面添加了如下命令 span class token keyword export span span class token con
  • 基于ubuntu16.04 塔建PX4编译环境

    基于ubuntu16 04 塔建PX4编译环境 基于ubuntu16 04 塔建PX4编译环境环境塔建官网网址 xff1a 权限设定删除modemmanager更新软件包列表 xff0c 并为所有PX4构建目标安装以下依赖项 安装pyulo
  • APM编译记录-基于OMNIBUSF4-V3飞控板

    APM编译记录 基于OMNIBUSF4 V3飞控板 APM编译记录Bootloader问题固件编译 APM编译记录 初次使用APM xff0c 根据博客文章以及结合官方教程摸索 xff0c 发现和PX4还是有挺大差别的 xff0c 目前系统
  • ubuntu16.04基于eclipse搭建px4编译环境+Jlink调式

    ubuntu16 04基于eclipse搭建px4编译环境 43 Jlink调式 xff09 ubuntu16 04基于eclipse搭建px4编译环境 43 Jlink调式一 工具获取1 eclipse2 jlink3 jdk4 arm
  • Ardupilot通过mavlink + 4way_protocol对BLHeli_s电调的读写

    Ardupilot通过mavlink 43 4way protocol对BLHeli s电调的读写 前言上位机1 Mission Planner2 BLHeliSuite3 BLHeliSuite32 Ardupilot 源码编译1 启动B
  • C/C++中 float与uint16类型转换方法

    C C 43 43 中 float与uint16类型转换方法 为什么要做float与uint16互相转换方法一 xff1a 方法二 xff1a 为什么要做float与uint16互相转换 此需求在串口通信时常常会被用到 xff0c 串口只能
  • Keil V5仿真出现*** error 65: access violation at 0x40021000 : no ‘read‘ permission 解决办法

    Keil V5仿真出现 error 65 access violation at 0x40021000 no 39 read 39 permission 解决办法 问题解决办法1 进入debug的map设置地址2 新建debug ini配置
  • Ardupilot-NMEA协议的GNSS处理优化

    Ardupilot NMEA协议的GNSS处理优化 Ardupilot NMEA协议的GNSS处理优化原固件存在的问题解决办法 Ardupilot NMEA协议的GNSS处理优化 原固件存在的问题 1 当所使用的GNSS模块数据反馈频率不到