Skip to content

Conversation

JPF2209
Copy link

@JPF2209 JPF2209 commented Sep 4, 2025

Description

I have added the ADC functions defined to the Remote area of SplashKit where this can then be tested and used converting all of them to Remote GPIO friendly functions.

Please delete options that are not relevant.

  • [] Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as
    expected)
  • Documentation (update or new)

How Has This Been Tested?

Please describe the tests that you ran to verify your changes. Provide instructions so we can
reproduce. Please also list any relevant details for your test configuration

Testing Checklist

  • Tested with sktest
  • Tested with skunit_tests

Checklist

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have requested a review from ... on the Pull Request

@JPF2209 JPF2209 changed the title Remote adc Added Remote ADC Functions Sep 4, 2025
@JPF2209 JPF2209 marked this pull request as ready for review September 10, 2025 05:27
void remote_close_adc(const string &name)
{
// Find the device in the local map of remotely opened devices
auto it = remote_adc_devices.find(name);

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just a heads-up in remote_close_adc_device, the pointer stored in remote_adc_devices isn’t being freed before erase, which means the allocated _remote_adc_data will leak. You might want to delete it->second; before erasing, or even better switch the map to unique_ptr so cleanup happens automatically.

Copy link

@ayushindapure ayushindapure left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor: redundant \n in logs, and please confirm _get_ads7830_pin_address correctly matches datasheet channel addresses.

Otherwise the structure, logging, and test integration look really good.”

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants