Commit Graph

31 Commits

Author SHA1 Message Date
Peter Barker e25d6bb8e4 AP_Logger: rename HAL_SCHEDULER_ENABLED to AP_SCHEDULER_ENABLED
there's AP_HAL::Scheduler which confuses this
2023-02-28 11:26:04 +11:00
Peter Barker 96f359b4e3 AP_Logger: avoid logging duplicate FMT/UNIT/FMTU/MULT messages
Failing due to being out of time meant we wouldn't incremement the counter, even though we'd emitted the item.

it is important we try to send something, so move this check to be after we increment whichever counter we are using.
2023-01-18 10:09:43 +11:00
Andrew Tridgell ae84adf632 AP_Logger: prevent long loops due to parameter logging
ensure that the logging process() doesn't take more than 1ms
2022-12-04 18:08:40 +11:00
Andy Piper 38bc9bfab1 AP_Logger: on example sketches there is always time to write out FMT messages 2022-11-09 19:01:14 +11:00
Andy Piper 209dd15346 AP_Logger: need to be able to finish format messages even when there is no fence 2022-11-08 17:56:00 +11:00
Peter Barker 8e06d5cd36 AP_Logger: include required AP_Vehicle_Type header 2022-11-02 18:35:48 +11:00
Iampete1 c623ae8b82 AP_Logger: MessageWriter: SysInfo: write RCOut string 2022-10-18 11:53:59 +11:00
Yuri 32c38434a2 AP_Logger: increase short board names to 23 chars 2022-09-21 17:56:42 +10:00
Iampete1 47853383b1 AP_Logger: add fence message writer 2022-08-30 09:07:27 +10:00
Peter Barker bf5817e108 AP_Logger: rename HAL_MISSION_ENABLED to AP_MISSION_ENABLED 2022-08-18 22:49:10 +10:00
Iampete1 63e03622d4 AP_Logger: log default param values 2022-07-20 17:59:59 +10:00
Peter Barker 85b4ee289e AP_Logger: log VER - ArduPilot version information 2022-02-09 18:32:38 +11:00
Andrew Tridgell 94c117fe62 AP_Logger: log original fw string if available 2022-01-19 08:07:45 +11:00
Peter Barker b681dc940a AP_Logger: add support for AP_Logger into AP_Periph 2021-06-08 09:57:55 +10:00
Andrew Tridgell 09aff03edc AP_Logger: support new replay system
added allow_start_ekf and block write method for replay

Co-authored-by: Peter Barker <pbarker@barker.dropbear.id.au>
2020-11-10 16:15:45 +11:00
Andy Piper ccb583d092 AP_Logger: make block logger conform to mavlink expectations of numbering
add support for log time to block logger
refactor rotation into backed. Don't start logs when erasing
correct log start logic
separate read and write points so that requesting log information does not corrupt the current log
when starting a new log stop logging first
clear the write buffer when starting a new log
insert utc time when requesting info for the current log
stop logging and request formats again when starting a new log
cope with erase happening while we are logging
keep pushing out startup messages even when format messages are done
don't log to the gcs in the io thread
don't start new logs in the io thread
don't validate logs while erasing
flush logs when stopping logging
account for page header when calculating logs sizes
don't return data when asked for more data than in the log
optimize locking and use separate semaphore to mediate ring buffer access
stop logging when the chip is full and send a notification
calculate logs sizes correctly even when they wrap
read log data correctly even when it wraps
add stats support to block logger
reset dropped when starting a new log
fail logging when the chip is full
refactor critical bufferspace checks
increase messagewriter budget to 250us and to 300us for FMT
2020-09-05 10:20:39 +10:00
Peter Barker 908dfa58f3 AP_Logger: remove unused FORMATS stage in DFLogStart messagewriter 2020-04-17 21:42:15 +10:00
Peter Barker 678d6f43c5 AP_Logger: use existing LoggerMessageWriter to log uploaded missions
Instead of creating a MessageWriter explicitly to log uploaded missions
we fiddle the state of the one stored in the startup message writer.

This has the advantage of being much more likely to log the entire
mission (as the buffer constraint is removed), and with the addition of
a time-remaining check much less likely to cause a timing glitch.
2020-04-15 16:24:40 +10:00
chobits 63320f140a AP_Logger: constraints time spend in header writing, more complete 2020-04-09 19:17:17 +10:00
chobits b829384fdf AP_Logger: constraints time spended in header writing 2020-04-09 19:17:17 +10:00
Peter Barker 4d17a7cf89 AP_Logger: tidy MessageWriter stages using enum class 2019-10-05 16:37:43 +10:00
Peter Barker 78af091869 AP_Logger: log parameter space used as part of log open 2019-08-28 11:51:09 +10:00
Peter Barker 7bca6d5ec0 AP_Logger: log RC protocol each time a log is opened 2019-06-18 11:35:38 +10:00
Tom Pittenger 027f9afcf8 AP_logger: rename dataflash to logger and refactor the filename logger.bin 2019-03-28 16:40:58 +11:00
Michael du Breuil 3f1fbbf6c6 AP_Logger: simplify the message writers
Specifically:
  - Remove some unreachable nullptr checks
  - Remove a noop stage
  - Remove unneeded initilizers
2019-03-24 11:45:08 +11:00
Peter Barker 4e151197a8 AP_Logger: log units and multipliers correctly 2019-03-21 17:44:05 +11:00
Peter Barker 9108eeb8f5 AP_Logger: log rally points into dataflash on upload 2019-02-12 11:48:55 +11:00
Peter Barker 9a04ae5cf7 AP_Logger: use a MessageWriter to emit rally points 2019-02-12 11:48:55 +11:00
Peter Barker 6fc76a32af GLOBAL: use AP::logger() and strip redundant Log_ from methods 2019-01-18 18:08:20 +11:00
Peter Barker b47733142f GLOBAL: rename DataFlash_Class to AP_Logger 2019-01-18 18:08:20 +11:00
Peter Barker 6a59dd04a7 DataFlash: rename to AP_Logger 2019-01-18 18:08:20 +11:00