Skip to content

Lynx sensor module - #16

Merged
zachwaffle4 merged 10 commits into
NextFTC:developfrom
28shettr:LynxSensorModule
Jul 28, 2026
Merged

Lynx sensor module#16
zachwaffle4 merged 10 commits into
NextFTC:developfrom
28shettr:LynxSensorModule

Conversation

@28shettr

Copy link
Copy Markdown

digital and i2c compatability

@AchintyaAkula AchintyaAkula left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

You forgot analog sensors

class NextFeedbackCRServo @JvmOverloads constructor(
initializer: () -> CRServoImplEx,
feedbackName: String,
feedbackInitializer: () -> AnalogInput,

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

These should still use AnalogFeedback.

import dev.nextftc.units.measuretypes.Voltage
import dev.nextftc.units.volts

class NextAnalogInput @JvmOverloads constructor(

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

This should inherit from AnalogFeedback so it can be used more easily by the feedback (cr) servo classes.

}
}

fun get(): T {

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

This is unnecessary.

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

iirc, Rohit made the extra get function in order to keep the i2c buses all in one array, and avoid having to make 4 variables(one per bus)

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

its okay i js fixed, both should work i think mine just felt a little more intuitive for me

@zachwaffle4
zachwaffle4 merged commit feca1d7 into NextFTC:develop Jul 28, 2026
2 checks passed
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.

3 participants