Giter VIP home page Giter VIP logo

betaflight / blackbox-tools Goto Github PK

View Code? Open in Web Editor NEW
61.0 15.0 37.0 42.47 MB

Tools for working with blackbox flight logs

License: GNU General Public License v3.0

Makefile 7.53% Roff 8.23% M4 0.43% Shell 2.57% C++ 0.36% C 68.13% HTML 9.74% CSS 0.03% Awk 0.02% JavaScript 0.04% C# 0.01% Smalltalk 1.64% Python 0.63% CMake 0.02% Perl 0.05% DIGITAL Command Language 0.13% sed 0.01% POV-Ray SDL 0.42%
betaflight hacktoberfest

blackbox-tools's Issues

Cannot find executables for windows

I want to run the decoder through python, so logically I should use the executables (unfortunately on a windows machine) but I cannot find them in the latest release.

Units of angle in converted csv file

While converting *.BFL file to *.csv in the headers of csv there are units of barometer (cm), rotational velocity in ex. (deg/s) and acceleration (m/s/s) if the units were selected by command line switches. But there in no command line switch to select units of attitude provided when --simulate-imu is activated.

The orientation angles are not raw values,, are in (deg). To have consistent file, the units of angle should be added to roll, pitch and yaw in headers

It is now:
accSmooth[0] (m/s/s) accSmooth[1] (m/s/s) accSmooth[2] (m/s/s) roll pitch heading

It should be:
accSmooth[0] (m/s/s) accSmooth[1] (m/s/s) accSmooth[2] (m/s/s) roll(deg) pitch(deg) heading(deg)

To see it, it is necessary to use --simulate-imu option

Reading IMU in quasi-realtime

Hi there,

I am trying to read the IMU in (close to) real-time using an Odroid (similar to Raspberry Pi). It's clearly possible to stream the IMU data as it's visualized in Betaflight Configurator. Is this something that is possible via the CLI or how can I generally access this data via either the usb port or outputting from my flight controller (via rx)?

Thanks for any tips!

Sean

Feature Request: Output Tuning Values to Text File from blackbox_decode

When decoding log files from blackbox_decode it would be great if the PID tuning values used during that log were output to a text file (rather than having to keep a manual log for optimising tuning). I think they're already decoded as part of blackbox_render but that makes it difficult to batch-analyse files

Increase max logs in file

In parser.h, FLIGHT_LOG_MAX_LOGS_IN_FILE is set to 31,
and I have seen log files with 97 logs. For example when using Betaflight F4 with Betaflight 3.5.5.
Tested to increase to 100 and it worked. (Why limit?)

Problems compiling for Windows

Hi
I try to compile the blackbox tools on windows but i get errors all the time.

File (Include) cannot be opened: "unistd.h": No such file or directory

only converting the first 31 files, even though more exist in onboard logger

Im not sure if this is an already solved issue, but I cant seem to convert logs above 31. even if I use --index, bb_decode only sees the first 31. Weird, because I know bb_decode successfully finds them whan called in plasmatree pid analyzer. not sure what they are doing to get these. any info would be greatly appreciated.

blackbox_decode.exe --index 32 filename

I get this error message:
Couldn't load log #32 from this file, because there are only 31 logs in total.

even though there are 41 in total in the combined log:
image

No .exe or installer files.

I don't see any executable or installer files under Releases. Is there someone who can create one for windows, please?

blackbox_encode process all flights in a log

blackbox_encode requires the user to specify a log which makes automation more difficult, my request is:

  1. If no --index is specified, process all flights
    or
  2. allow for -- Index ALL or 0 that processes all logs

Altitude in gps should be in meter and not in cm

Betaflight blackbox logs altitude in cm from gps and barometer, and this is exported as integer to gpx file field (ele), while comment in gpxwriter.c says "Altitude is in meters".
The standard unit for altitude in gpx file is meter, for example used by google earth viewer.
I also added a flag alt-offset to enable adjustment of altitude, if anyone interested.

compute RC rate and PID error

Currently, blackbox_decode does not compute RC rate and PID error (for anyone interested in doing offline analyses on these). My current workaround is to load the log in explorer and save an csv file from there which contains these variables, so presumably they are computed in explorer. I am trying to do offline Matlab analyses on PID error, and it'd be much less cumbersome, and easier to implement within Matlab scripts, if blackbox_decode did this.

Serial protocol

is it possible to know the protocol used for logging the blackbox via serial? I need to access the gyro data via Arduino. Currently I can communicate via serial but I do not know the protocol to access this data.
Is there a start and end iteration bit?

Thanks

blackbox log header structure contradicts blackbox_decode parser.c logic

Describe the bug
"features" field is described as "last field in the header":

if (strstr(fieldName,"features")) { // This is the last field in the header.
        *parserState = PARSER_STATE_TRANSITION;
}

but actual logs contains more fields after this field:

H features:939787272
H rc_smoothing_type:1
H rc_smoothing_debug_axis:0
H rc_smoothing_cutoffs:0, 0
H rc_smoothing_auto_factor:10
H rc_smoothing_filter_type:1, 2
H rc_smoothing_active_cutoffs:67, 67
H rc_smoothing_rx_average:6681
I.....

To Reproduce
Open any blackbox log.

Expected behavior
Additional fields should be written before "features"

Flight controller configuration
Doesn`t matter

Setup / Versions

Additional context

The .exe file is not working on windows

I have downloaded the executables, the software starts and immediately closes. I am unable to get it running, or see any confirmation it works. I would really appreciate some assistance on this, as I am depending on it on my project (visual and Inertial odometry) using a racing drone running betaflight.

Feature request: acceleration output in Earth coordinate system

In blackbox_decode the acceleration out in done in controller coordinate system. It would be useful to have possibility to output accelerations in the Earth coordinate system, with gravity removed (az-1g).
It is done in what way in blackbox_render, so it should be quite simply.
All functions already exists in the code blackbox_render.
It is just a matter of output these values to .csv file by blackbox_decode.

Proposed command line switch for blackbox_decode:
--acceleration-csys acceleration output coordinate system (controller|Earth), default is controller

Stick overlay improvements

Hey,
@j4y4r and I made some changes to the blackbox-tools over in the cleanflight repo => cleanflight/blackbox-tools#25 But now I am not sure if we should not have made them against this repo, the cleanflight repo seems rather dead - what do you think, should I make the PR against this repo?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.