Closed gausby closed 8 years ago
I'll try this out, but would you prefer to send me a pull request so that github gives you credit for the contribution?
Thanks. I can make it into a PR tomorrow. I got to catch some z's now.
Do you think the example is clear enough?
This rocks. I'm going to close this issue since this PR (https://github.com/pavlos/gen_fsm/pull/4) addresses it
For the readme we could probably do a quick door example that can have locked/unlocked states and can be locked, unlocked and entered. I don't know if that would make for a shorter example. The turnstile could be moved to an examples/-folder.
I've been working on a turnstile example for the Readme. It implement the logic for a turnstile that accept money. When a coin is inserted it will go to unlocked and when it is entered it will go back to the locked state. There is a functionality to see and reset the number of coins that has been inserted.
I had some trouble doing a sync call, but it could be due to my brain needs sleep right now. See if you like it and improve on it :)