mirror of
https://github.com/portapack-mayhem/mayhem-firmware.git
synced 2025-12-09 04:41:55 +00:00
Create log files on heap.
...for imminent refactor where user can manually start/stop logging, and maybe even change the filename! *swoon*
This commit is contained in:
@@ -186,10 +186,12 @@ using TPMSRecentEntries = RecentEntries<tpms::Reading, TPMSRecentEntry>;
|
||||
|
||||
class TPMSLogger {
|
||||
public:
|
||||
TPMSLogger(const std::string& file_path);
|
||||
|
||||
void on_packet(const tpms::Packet& packet, const uint32_t target_frequency);
|
||||
|
||||
private:
|
||||
LogFile log_file { "tpms.txt" };
|
||||
LogFile log_file;
|
||||
};
|
||||
|
||||
namespace ui {
|
||||
@@ -217,7 +219,7 @@ private:
|
||||
static constexpr uint32_t baseband_bandwidth = 1750000;
|
||||
|
||||
TPMSRecentEntries recent;
|
||||
TPMSLogger logger;
|
||||
std::unique_ptr<TPMSLogger> logger;
|
||||
|
||||
TPMSRecentEntriesView recent_entries_view { recent };
|
||||
|
||||
|
||||
Reference in New Issue
Block a user