Logs and Events
Overview
The Log view displays system messages, hardware events, debug information, and error notifications. This is essential for troubleshooting issues, monitoring system health, and understanding hardware behavior.
Accessing Logs
- Click Log in the navigation panel
- Log view displays all recent messages
- Auto-scrolls to newest messages (configurable)
Log Message Types
Message Categories
Information:
- Normal operational messages
- System status updates
- Connection established/closed
- Module loaded/unloaded
Warnings:
- Non-critical issues
- Performance degradation
- Configuration oddities
- Deprecated feature usage
Errors:
- Operation failures
- Communication errors
- Hardware faults
- Exception messages
Debug:
- Detailed diagnostic information
- Internal state information
- Development/troubleshooting data
Message Sources
Application:
- Accordion Pilot operations
- UI events
- User actions
Hardware:
- Device notifications
- Telemetry events
- Channel value changes
- Configuration changes
Communication:
- Network events
- Protocol errors
- Timeout messages
Modules:
- Module loading/unloading
- Module errors
- Custom module messages
Log View Interface
Log Grid
Columns:
| Column | Description |
|---|---|
| Timestamp | Date and time of message |
| Level | Info, Warning, Error, Debug |
| Source | Origin of message (App, Hardware, Module) |
| Category | Message category |
| Message | Log message text |
| Details | Additional information (expandable) |
Color Coding
Messages color-coded by severity:
- Blue/Black: Information
- Yellow: Warning
- Red: Error
- Gray: Debug
Auto-Scroll
Enable/Disable Auto-Scroll:
- Checkbox in toolbar
- Or button to toggle
Behavior:
- Enabled: Log automatically scrolls to newest message
- Disabled: Stay at current position for reading
Use Cases:
- Enable: Real-time monitoring
- Disable: Review past messages
Log Filtering
Filter by Level
Show specific severity levels:
Click level filter dropdown
Check/uncheck levels:
- ☑ Information
- ☑ Warning
- ☑ Error
- ☐ Debug (often disabled by default)
Only selected levels shown
Example:
Show only Warnings and Errors for troubleshooting
Filter by Source
Show messages from specific source:
- Click source filter
- Select sources:
- Application
- Hardware
- Communication
- Modules
- Specific module names
Filter by Text
Search for specific content:
- Enter search text in filter box
- Log filters to show only matching messages
- Case-insensitive search
- Supports partial matching
Example:
Filter: "I2C" → Shows all I2C-related messages
Filter: "timeout" → Shows timeout errors
Filter: "PMBus" → Shows PMBus module messages
Time Range Filter
Show messages in specific time period:
- Set start time
- Set end time
- Apply filter
- Only messages in range shown
Log Management
Clear Log
Remove all log messages:
- Click "Clear Log" button
- Or right-click log → "Clear All"
- Confirm if prompted
- New messages continue to appear
Use Cases:
- Start fresh before test
- Remove old noise
- Focus on new events
Export Log
Save log to file:
- Right-click log area
- Select "Export to File"
- Choose format:
- Text (.txt)
- CSV (.csv)
- Excel (.xlsx) if supported
- Select filename
- Click Save
Exported Log Format (CSV):
Timestamp,Level,Source,Message,Details
2024-01-15 14:30:00,Info,Application,Connected to 192.168.1.100,
2024-01-15 14:30:05,Warning,Hardware,Channel polling slow,Poll took 150ms
2024-01-15 14:30:10,Error,Communication,I2C NACK,Address 0x3C
Use Cases:
- Archive troubleshooting sessions
- Share with support team
- Analyze trends
- Documentation
Log Retention
Automatic log limit:
- Log maintains recent messages (configurable)
- Oldest messages removed automatically
- Default: Keep last 1000-5000 messages
- Prevents memory issues
Configure Limit:
- Settings → Log Settings → Max Messages
Event Monitoring
Notification Events
Hardware notifications:
When notifications enabled (init --notification):
- Information messages from hardware
- Warning conditions
- Error states
- Status changes
Example Messages:
[Info] Module loaded: PMBusController
[Warning] Temperature high: 75°C
[Error] I2C communication timeout on bus 0
Telemetry Events
Hardware telemetry:
When telemetry enabled (init --telemetry):
- Configuration changes
- Value updates (if logged)
- Request/response logging
- State transitions
Example Messages:
[Telemetry] Channel CH_GPIO_01 direction changed to Output
[Telemetry] I2C transaction: Address 0x48, Read 2 bytes
[Telemetry] Module parameter updated: SampleRate = 1000
Enable/Disable Events
Configure event reception:
Via init command:
# Enable notifications only
AccordionShell init --host 192.168.1.100 --notification
# Enable telemetry only
AccordionShell init --host 192.168.1.100 --telemetry
# Enable both
AccordionShell init --host 192.168.1.100 --notification --telemetry
# Disable both (default)
AccordionShell init --host 192.168.1.100
Impact:
- Notifications: Important events, minimal traffic
- Telemetry: Detailed events, higher traffic
- Both: Complete visibility, highest traffic
Common Log Workflows
Troubleshoot Connection Issues
1. Clear log
2. Attempt connection
3. Watch for error messages
4. Look for:
- "Connection refused" → Service not running
- "Timeout" → Network issue or wrong IP
- "Authentication failed" → Credentials problem
5. Export log if needed for support
Debug I2C Communication
1. Enable telemetry (if not already):
AccordionShell init --host 192.168.1.100 --telemetry
2. Filter log: "I2C"
3. Perform I2C operation
4. Watch for:
- Transaction messages
- NACK errors
- Timeout errors
5. Analyze pattern:
- Repeated NACKs → Wrong address or device not responding
- Timeouts → Bus hung or clock issue
- Successful then fail → Intermittent issue
Monitor Module Loading
1. Filter Source: Modules
2. Load module:
AccordionShell module --module "MyModule" --file "config.xml"
3. Watch for:
- [Info] Module loaded: MyModule
- [Info] Channels registered: 15
- Or [Error] Module load failed: ...
4. Check for warnings about configuration
Capture Error for Support
1. Clear log
2. Reproduce issue
3. Export log immediately:
Right-click → Export to File
4. Save with descriptive name:
"error_i2c_timeout_20240115.txt"
5. Include in support ticket
Debug Mode
Enable Debug Messages
Show detailed debug information:
Debug messages typically disabled by default (too verbose).
Enable:
- Application settings → Enable Debug Logging
- Or environment variable / command-line flag
Debug messages include:
- Internal state changes
- Detailed protocol information
- Performance metrics
- Memory allocation events
⚠️ Warning: Debug mode generates significant log traffic. Use only when troubleshooting.
Log Analysis
Identify Patterns
Look for recurring messages:
- Repeated errors indicate systematic issue
- Periodic warnings may indicate timing issue
- Consistent error codes point to specific problem
Example:
[Error] I2C NACK at address 0x3C - Repeated 100 times
→ Device at 0x3C not responding or wrong address
Correlate with Actions
Match log messages to user actions:
- Note timestamp of action (or use marker)
- Find corresponding log messages
- Verify expected vs. actual behavior
Example:
14:30:00 - User: Set VOUT_1 = 3.3V
14:30:00 - [Telemetry] Set channel VOUT_1 to value 3.3
14:30:00 - [Info] I2C Write: Address 0x40, Data: 02 CD
14:30:01 - [Info] Voltage readback: 3.295V
→ Successful, slight difference within tolerance
Error Codes
Some messages include error codes:
[Error] Communication error: E_TIMEOUT (0x80070005)
Look up error codes:
- Accordion documentation
- System error code references
- Contact support with error code
Troubleshooting Logs
Log Not Updating
Problem: No new messages appearing
Solutions:
- Verify connection to device
- Check if application frozen
- Verify log not filtered too aggressively
- Check log retention limit not reached
- Try clearing log
Too Many Messages
Problem: Log fills too quickly
Solutions:
- Disable debug messages
- Disable telemetry if not needed
- Filter to show only warnings/errors
- Increase log retention limit
- Export and clear periodically
Missing Expected Messages
Problem: Expected log message doesn't appear
Solutions:
- Check message level filter (enable all)
- Verify notifications/telemetry enabled
- Check source filter
- Verify operation actually occurred
- Check device communication working
Best Practices
- Review Logs Regularly: Check for warnings/errors periodically
- Clear Before Tests: Start with clean log for clarity
- Export Important Sessions: Save logs showing errors for analysis
- Use Filters: Focus on relevant messages
- Enable Telemetry Wisely: Only when needed for debugging
- Document Error Patterns: Note recurring issues
- Include in Tickets: Always export log when reporting issues
See Also
- Channel Management - Channel-related log messages
- Bus Transactions - Transaction-specific logging
- System Settings - Configure logging
- Troubleshooting - Use logs for troubleshooting
- Firmware - Firmware update logs
Help Menu Setup
Overview
The Help Menu provides quick access to important documentation and support resources.
SetupHelpMenu Method
Purpose:
- Initialize and populate the Help menu
Where to Call:
- Call
SetupHelpMenu()in the constructor orFormMain_Loadmethod.
Menu Structure:
- 📖 Getting Started -
ap-index.md - 📊 Channels -
ap-channels.md - 🔍 Logs and Events -
ap-logs.md - 🔌 Bus Transactions -
ap-transactions.md - ⚡ Power Supplies -
ap-power-supplies.md - 📈 Charts -
ap-charts.md - 🔧 System Settings -
ap-system-settings.md - ❓ Troubleshooting -
ap-troubleshooting.md
Example Code
// Add to constructor or FormMain_Load:
SetupHelpMenu();
private void SetupHelpMenu()
{
var helpTopics = new[]
{
("📖 Getting Started", "ap-index.md"),
("📊 Channels", "ap-channels.md"),
("🔍 Logs and Events", "ap-logs.md"),
("🔌 Bus Transactions", "ap-transactions.md"),
("⚡ Power Supplies", "ap-power-supplies.md"),
("📈 Charts", "ap-charts.md"),
("🔧 System Settings", "ap-system-settings.md"),
("❓ Troubleshooting", "ap-troubleshooting.md")
};
foreach (var (title, file) in helpTopics)
{
var menuItem = new BarButtonItem
{
Caption = title,
Tag = file
};
menuItem.ItemClick += (s, e) =>
{
var fileName = (string)((BarButtonItem)s).Tag;
ShowHelpDocument(fileName);
};
popupMenuHelp.ItemLinks.Add(menuItem);
}
}