Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

updates firmware to support SevSeg 3.7.0 #25

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

chaduhduh
Copy link

@chaduhduh chaduhduh commented Mar 5, 2024

This existing firmware is designed to be used with a separately maintained fork of SevSeg and the APIs are now incompatible. It appears at some point after you all created this firmware and the SevSeg fork that Dean resumed development on it and gave it a proper license. See the SevSeg repo. These updates address the issue by updating various calls to use the newer API.

This change is probably useful for others since folks using library managers will likely end up with the other version. I already had SevSeg installed for some other projects and when I needed to customize the Serial7SegmentDisplay firmware I ran into compatibility issues. I think this is what another person mentioned in issue #24

Note that this has only been tested on the S7S board layout. Open segment and 7 segment shield were updated but are untested (since I don't have them 馃憖 ).

A summary of the updates are as follows:

  • adjusted all existing API calls to lowercase format
  • updates all calls matching the signature DisplayString(digits, decimals); to the SegSev method setNumber(digits, decimals)
  • updates all begin calls to be compatible with new signature: begin(uint8_t hardwareConfig, uint8_t numDigitsIn, const uint8_t digitPinsIn[], const uint8_t segmentPinsIn[], bool resOnSegmentsIn, bool updateWithDelaysIn, bool leadingZerosIn, bool disableDecPoint)
  • Calls refreshDisplay() as appropriate (See Readme)

Feel free to close this or test and incorporate at your discretion. If you don't want to incorporate this, I can continue to use my fork for my own projects that need custom firmware.

Thanks for providing all of this code to support your products. It is all really great 馃帄

This old firmware is designed to be used with a separately maintained
and released fork of SegSev and the APIs now appear to differ.
These updates address this by updating various calls to the new API
and making the necessary refresh calls.

This change is probably useful for others since folks using library
managers will likely end up with the other version.

Note that this has only been tested on the S7S board layout. Open segment
and 7 segment shield were updated but are untested.
@chaduhduh chaduhduh changed the title updates firmware to support SegSev 3.7.0 updates firmware to support SevSeg 3.7.0 Mar 5, 2024
@nseidle
Copy link
Member

nseidle commented Mar 12, 2024

This is awesome! Thank you for the PR.

I am not going to merge as this looks to be a API change with no underlying functional changes. It's risk vs reward: It's not trivial to change our production scripts to use a new binary. I just don't want to break it!

I'll leave this PR open though. If we ever have a reason to revisit this code base your changes will significantly help us to get up to speed on the newer API.

@chaduhduh
Copy link
Author

This is awesome! Thank you for the PR.

I am not going to merge as this looks to be a API change with no underlying functional changes. It's risk vs reward: It's not trivial to change our production scripts to use a new binary. I just don't want to break it!

I'll leave this PR open though. If we ever have a reason to revisit this code base your changes will significantly help us to get up to speed on the newer API.

I completely understand. No sense in updating the install when there aren't functional changes to the firmware itself. It is probably a small number of folks who will actually encounter a problem (although for me updating the firmware eliminated an extra chip!). Also I think you all have newer boards that are replacing these.

Anything you want to do with this is fine. Since I made the updates on my end I figured I would share with you all 馃.

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.

None yet

2 participants