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.

knut.tveitane

Member Since 21 Jan 2014
Offline Last Active Oct 06 2015 11:40 AM
-----

#58282 trying to flash an LED and pluse a piezo in error state

Posted by knut.tveitane on 20 May 2014 - 02:27 PM

 

First, this line is redundant:

  1. i = i++;

Note - it is not just redundant, it is not doing what you (probably) want to achieve. The i++ construct increments the variable i *after* it has been referenced, but *before* the assignment is fullfilled. In other words, i will have the same old value after this statement as it had before.




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.