Netduino home hardware projects downloads community

Jump to content


The Netduino forums have been replaced by new forums at community.wildernesslabs.co. This site has been preserved for archival purposes only and the ability to make new accounts or posts has been turned off.
Photo

Toggle an output - quickly

Timing

  • Please log in to reply
No replies to this topic

#1 Man_in_UK

Man_in_UK

    New Member

  • Members
  • Pip
  • 1 posts

Posted 03 October 2016 - 08:25 PM

I'm looking for a simple replacement for this code that is not really doing the job right.

I have got an output pin being toggled using .........................

 

Thread.Sleep(3);

clk = !clk;

 

You can see that the output named clk turns on and off dependent on how long it takes for the rest of the program to cycle through 3 times.

I would like it to toggle every 2.38ms (420hz) regardless of the rest of the program.

 

Is there simple solution to this?

 

P.S My knowledge of programming is strictly beginner. 







0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users

home    hardware    projects    downloads    community    where to buy    contact Copyright © 2016 Wilderness Labs Inc.  |  Legal   |   CC BY-SA
This webpage is licensed under a Creative Commons Attribution-ShareAlike License.