-
Notifications
You must be signed in to change notification settings - Fork 6
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 msg_blinker demo #17
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry, it looks like this was missed for a while. I just had a few comments, if you want to take care of those. We don't have any CI checks in place yet, but we should have you sign off on the commit. (Hint: git commit --amend --signoff
after you make the changes)
@@ -0,0 +1,7 @@ | |||
{erl_opts, [debug_info]}. | |||
{deps, [ | |||
{atomvm_lib, {git, "https://github.com/atomvm/atomvm_lib.git", {branch, "master"}}} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This dependency shouldn't be necessary for this demo.
@@ -0,0 +1,4 @@ | |||
[{<<"atomvm_lib">>, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See above comment.
|
||
send_messages() -> | ||
ReceiverPid = whereis(receiver), | ||
ReceiverPid ! on, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
receiver ! on,
works now if you want to make this a little cleaner, but that is up to you.
ReceiverPid = whereis(receiver), | ||
ReceiverPid ! on, | ||
timer:sleep(2000), | ||
ReceiverPid ! off, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same here.
added a demo that blinks the LED by passing messages between processes.