FW 0.12.10

Spectoda Firmware v0.12.10 Release Notes

Spectoda Firmware v0.12.10 Release Notes

Release Date: August 7, 2025 Version: 0.12.10

🚀 Major Features

EventStore Architecture Overhaul

This release introduces a complete refactoring of the EventStore system to support massive scalability and improved performance.

🔄 EventStore Chaining & Overflow System

  • New EventStores Class: Introduced a centralized EventStores<SIZE> template class that manages multiple EventStore instances

  • Automatic Overflow Handling: Events now automatically cascade to new EventStore instances when capacity is reached

  • Support for 2880+ Unique Events: Dramatically increased from previous single-store limitations with maximum of 244 events

  • Centralized Logic: All EventStore chaining logic moved from scattered code into dedicated eventStore.h

🏗️ Architectural Improvements

  • Template-Based Design: EventStore and EventStores now use consistent template parameters (EventStore<SIZE>, EventStores<SIZE>)

  • Memory Management: Proper use of std::unique_ptr for automatic resource management

  • Fingerprint Consistency: Enhanced SHA-256 fingerprint computation across multiple stores

  • Merging Capabilities: Robust merge operations between EventStores collections with proper event ordering

Enhanced Testing Framework

  • Comprehensive Unit Tests: Added extensive test suite for EventStores merging scenarios

  • Bug Detection: Tests specifically designed to catch merging bugs with 3+ EventStore indexes

  • PlatformIO Integration: Full compatibility with PlatformIO test framework

  • Debug Output: Enhanced logging for troubleshooting EventStore creation and merging

🔧 Technical Improvements

Performance Optimizations

  • Reduced BLE Connections: Changed from 3 to 2 concurrent BLE connections for improved stability

  • Device Context Optimization: Decreased MAXIMUM_DEVICE_CONTEXTS from 64 to 32 for better memory usage

  • Validation Efficiency: Store validation now only occurs during allocation, reducing runtime overhead

Code Quality Enhancements

  • Breaking Refactor: Clean separation of EventStore merging logic from controller code

  • Iterator Replacement: Replaced EventStore iterators with manual chain traversal for better control

  • Variable Naming: Consistent renaming from EVENTSTORE to STORE throughout codebase

  • Sync Firmware Refactoring: Moved sync firmware logic to dedicated m_evaluateSyncFirmware() method

🐛 Bug Fixes

EventStore System

  • Invalid Command Handling: Fixed issue with invalid commands causing system instability

  • Peer Firmware Update Priority: Fixed FW update prioritization after 60-second timeout

General Stability

  • Memory Leaks: Resolved potential memory leaks in EventStore management

  • Event Ordering: Fixed event ordering issues during complex merge operations

  • Fingerprint Computation: Corrected fingerprint calculation bugs in multi-store scenarios

📊 Testing & Validation

New Test Coverage

  • Basic Merge Operations: Validates fundamental EventStore merging functionality

  • Multiple Index Merging: Tests merging across multiple EventStore indexes

  • Historical Event Handling: Complex scenarios with overlapping timestamps

  • Identifier Collision: Proper handling of events with same identifiers

  • Stress Testing: High-volume operations with multiple EventStore collections

  • Edge Cases: Empty stores, non-existent indexes, rapid merges

  • Fingerprint Consistency: Ensures SHA-256 fingerprints remain consistent across operations

🔄 Migration Notes

Breaking Changes

  • EventStore synchronization: As the EventStore logic was changed, App v3 now only fully synchronizes EventStores properly with FW 0.12.10 and up. Thus installations using the App v3 should update to 0.12.10 for best user experience. For older FW the EventStores are synchronized only once right after connecting.

  • EventStore Backward Compatibility: Existing EventStore data are not compatible, thus the stored pre 0.12.10 EventStore is reset after OTA update.

Compatibility

  • API Consistency: New API maintains familiar patterns while providing enhanced functionality

  • Performance: Improved performance with no degradation in existing functionality

🚀 Performance Impact

Memory Usage

  • Optimized Allocation: Better memory management with reduced fragmentation

  • Scalable Storage: Support for thousands of events without total memory exhaustion

  • Efficient Merging: Reduced memory overhead during EventStore operations

Processing Speed

  • Faster Event Processing: Improved event insertion and retrieval performance

  • Efficient Fingerprinting: Optimized SHA-256 computation across multiple stores

  • Reduced BLE Overhead: Fewer concurrent connections improve overall system responsiveness

Known Limitations

  • Template Size Constraints: EventStore size must be defined at compile time

  • Memory Allocation: Large numbers of stores may require careful memory management - for example working with smaller TNGL to compensate

🙏 Acknowledgments

Special thanks to the development team for their contributions to this major architectural refactoring, particularly in the areas of:

  • EventStore chaining logic design

  • Comprehensive testing framework

  • Performance optimization

  • Code quality improvements

For technical support or questions about this release, please refer to the development documentation or contact the development team.

Last updated

Was this helpful?