Jump to content
Sign in to follow this  
VisSim Forum Archives

how to create while loop

Recommended Posts

Submitted by pete on Tue, 03/15/2016 - 10:06.

Hi Yogesh, Normally you would not use a for loop to burn time as it wastes CPU cycles needlessly. So one way to do this is to connect a pulse train block to the GPIO connected to the LED and run the diagram at 100kHz. Set the pulse interval to .06 sec. That will do exactly what you ask, but using interrupts so you can do a lot more with the remaining CPU cycles.

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
You are posting as a guest. If you have an account, please sign in.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

×
×
  • Create New...