-
Notifications
You must be signed in to change notification settings - Fork 17.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
AP_LOGGER: flash nand incorrect behaviour #26900
Comments
So a big part of what you are seeing here is a result of logging too much data. The FMT messages are sent out on arming but can be severely delayed if there is a lot of logging going on. This is not a problem with the driver per se but the speed of the device. One solution is to to set a logging rate that matches the speed of the chip. |
Tested with log_bitmask set to only log medium atti. And used gcs to force arm the drone to start logging, the problem persists. First log still says no FMT and after reboot, erase, then the second log is not downloadable. It then disappears after another reboot. *Log medium atti only is really a slow process, W25Q128 used about 30 min until chip full message appears. |
@BloodSakura3774 could you retry with master, please? I've pushed through a fairly sweeping change of the way we get formats out to files. This feels like a problem somewhere lower, however. If master hasn't fixed the problems I can look at ordering a FoxeerH743 to try to replicate locally. |
My Foxeer H743 is under use, but I'll take a look with the custom one (with w25n02/01) tomorrow |
@peterbarker This issues persists. Tested with the custom fc with w25n02, didn't test w25n01 or w25q128/256 |
Bug report
Tested on W25N01 with our custom board and original driver, W25N02 with our driver, and W25Q128 with Foxeer H743 and original driver.
After a full write (Until GCS says "chip full, logging stopped"), the log downloaded has no FMT data and can not be opened with MP's log viewer. And after a reboot of the FC, it will erase itself, which I believe should not happen according to wiki (https://ardupilot.org/copter/docs/common-downloading-and-analyzing-data-logs-in-mission-planner.html)
Then after another manual erase, the GCS would say "No last page of log X at top=Y or bot=Y" when opening log download page but the log is indeed continuing to be written.
Full Procedure to make it happen
Enable LOG_DISARMED, set LOG_BITMASK to 3588093, set INS_RAW_LOG_OPT to 10, set INS_LOG_BAT_OPT to 5, set INS_LOG_BAT_MASK to 3, and other remains to default. (I don't think these are required but I set them to speed up the test)
Reboot and Manual erase the chip.
Wait until GCS says "chip full, logging stopped"
Download the log and open it, it should say No FMT data.
Reboot and the previous log should already be erased by itself and then do another Manual erase.
After erase complete message, open the log downloading page and there should be a very small log (246 on W25Q128 and 20xx on W25N01/02) and GCS message tab says "No last page of log X at top=Y or bot=Y", with X stays the same the Y changing every time you open the download page.
Do another reboot before GCS says "chip full, logging stopped", and the log generated from step 6 should appear and downloading it and opening it should have no error.
Version
At least on ArduCopter V4.6.0-dev (338f492)
Not tested with prior version
Platform
[ ] All
[ ] AntennaTracker
[X] Copter
[ ] Plane
[ ] Rover
[ ] Submarine
Only tested with copter firmware but I believe it will happen to other platforms since its logger related.
Airframe type
N/A
Hardware type
Custom board with STM32H743 and Foxeer H743
Should happen with and FC that uses W25N01/W25N02/W25Q128 flash nand chip (At least this three nand)
Logs
N/A
The text was updated successfully, but these errors were encountered: