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

add fsm example traffic light #623

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

Conversation

huerni
Copy link

@huerni huerni commented Jun 1, 2023

add fsm examples traffic light test

What this PR does / why we need it:
Add traffic light shifudevice to fsm examples, you can communicate with traffic light shifudevice through nginx
Will this PR make the community happier?

Which issue this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close that issue when PR gets merged): fixes #
fixes #547
How is this PR tested

  • unit test
  • e2e test
  • other (please specify)

Special notes for your reviewer:

Release note:

add fsm examples traffic light test
@kris21he
Copy link
Contributor

kris21he commented Jun 4, 2023

@huerni I think you've done a great job for a mocking the traffic light behavior with well format readme file.
The team is evaluating this PR, thank you so much for your contribution!

@BtXin
Copy link
Contributor

BtXin commented Jun 5, 2023

Hi @huerni the overall PR looks good, however, we actually was hoping this issue to be done after the previous FSM implementation issue: #542. Sorry for the confusion here.
It would be great if you can try to finish issue 542 first and use this PR as a example of the FSM implementation. Feel free to ask us any questions.
Thanks!

PROCEED string = "PROCEED"
)

type TrafficLight struct {
Copy link
Contributor

Choose a reason for hiding this comment

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

@huerni, to be more specific, assume the trafficlight is the edgedevice, the question would turn to - how can the FSM control this edge device?

Here you wrote a mock device that have the feature we've described while our final goal is try to make the FSM can be applied to any edge device.

Copy link
Author

Choose a reason for hiding this comment

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

I apologize for the confusion, I'm not very familiar with edge devices and FSM either. To clarify, are you asking if it's possible to write an FSM controller that can be used for any edge device? Or are you suggesting that each edge device should be able to quickly build its own FSM?

Copy link
Contributor

Choose a reason for hiding this comment

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

We are going to have a proper design for the FSM feature in the following weeks. You can refer to the design for implementation details.

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.

The traffic light FSM implementation for deviceShifu
6 participants