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’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PhyVersoBSP: Implemented request_stop_transaction via external push buttons connected to SOM GPIOs #791

Merged
merged 1 commit into from
Sep 5, 2024

Conversation

rckstrh
Copy link
Contributor

@rckstrh rckstrh commented Jul 24, 2024

Describe your changes

These changes were implemented to be able to request a stop of a charging session by applying a digital signal to one of the 5V tolerant buffered SOM inputs. GPIO banks/pins as well as signal polarity are configurable via EVerest config parameters. The request_stop_transaction functionality via GPIO is by default disabled because input pins are floating due to missing pull resistors on phyVERSO HW revision 1. The GPIO inputs are getting debounced in software with currently ~160ms duration needed to register a stable state.

Issue ticket number and link

Checklist before requesting a review

  • I have performed a self-review of my code
  • I have made corresponding changes to the documentation
  • I read the contribution documentation and made sure that my changes meet its requirements

Copy link
Contributor

@golovasteek golovasteek left a comment

Choose a reason for hiding this comment

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

Approving the bazel part

@rckstrh rckstrh force-pushed the driver/phyverso-bsp-hw-rev1 branch from 26bcd5a to cd73733 Compare July 29, 2024 07:08
@rckstrh rckstrh force-pushed the driver/phyverso-bsp-hw-rev1 branch from cd73733 to 26bcd5a Compare July 29, 2024 07:21
Copy link
Contributor

@corneliusclaussen corneliusclaussen left a comment

Choose a reason for hiding this comment

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

Looks good from my side, but please check the comments about the gpio device name and squash everything into one commit with a proper commit description.

modules/PhyVersoBSP/connector_1/evse_board_supportImpl.cpp Outdated Show resolved Hide resolved
modules/PhyVersoBSP/connector_2/evse_board_supportImpl.cpp Outdated Show resolved Hide resolved
modules/PhyVersoBSP/phyverso_gpio/evGpio.cpp Outdated Show resolved Hide resolved
@corneliusclaussen corneliusclaussen force-pushed the driver/phyverso-bsp-hw-rev1 branch from 4056b10 to 4b3ece0 Compare September 5, 2024 10:41
rcd_1 and rcd_2 raise ac_rcd errors instead of EVLOG_info printing

Implemented request_stop_transaction on external push buttons connected to SOM GPIOs
* Connector 1 and 2 can be configured to use external connected push buttons to request stop transaction
* Push buttons need external pull resistors
* request_stop_transaction functionality disabled by default because inputs would be floating as PhyVerso has no pull resistors on board
* GPIO pin number and bank can be configured, by default connector 1 uses IN_1 (X43 pin 5) and connector 2 uses IN_2 (X43 pin 7); 5V tolerant inputs
* button logic levels can be inverted in EVerest config

Signed-off-by: Jonas Rockstroh <[email protected]>
@corneliusclaussen corneliusclaussen force-pushed the driver/phyverso-bsp-hw-rev1 branch from 4b3ece0 to 93d11a1 Compare September 5, 2024 10:50
@corneliusclaussen corneliusclaussen merged commit bf48700 into main Sep 5, 2024
10 of 11 checks passed
@corneliusclaussen corneliusclaussen deleted the driver/phyverso-bsp-hw-rev1 branch September 5, 2024 13:12
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