Search:

Type: Posts; User: Rango

Search: Search took 0.17 seconds.

  1. Thread: Need logic help

    by Rango
    Replies
    27
    Views
    1,422

    Re: Need logic help

    I forgot to say thanks I got it all up and good thanks for the support it helped open my mind
  2. Thread: Need logic help

    by Rango
    Replies
    27
    Views
    1,422

    Re: Need logic help

    package gettingstarted;




    //Add Phidgets Library | You added a file called phidget22 when configuring your project. Import gives you access to the Phidgets library code inside that file. ...
  3. Thread: Need logic help

    by Rango
    Replies
    27
    Views
    1,422

    Re: Need logic help

    so the change I made in the code is I added the count!=0 in the conditional but I'm unsure if it works because of how the numbers count down I get this in the print


    So count never =0 so I assume...
  4. Thread: Need logic help

    by Rango
    Replies
    27
    Views
    1,422

    Re: Need logic help

    ye the code I suggested gives an error where it counts below 0



    package gettingstarted;




    //Add Phidgets Library | You added a file called phidget22 when configuring your project....
  5. Thread: Need logic help

    by Rango
    Replies
    27
    Views
    1,422

    Re: Need logic help

    would this require any change in my current code or would i just add this to what i have


    if (count!=0) {
    incrementCount=false;
    } else {
    count=0;

    }
  6. Thread: Need logic help

    by Rango
    Replies
    27
    Views
    1,422

    Re: Need logic help

    since
    count-=.1 is what will be executing every time would the if statement be after the conditional where i need to make it so that its

    if (count == 0) {
    // i want count to stop...
  7. Thread: Need logic help

    by Rango
    Replies
    27
    Views
    1,422

    Re: Need logic help

    So technically the code is correct because the increment is .1 but for avoiding the error I should put .9. And if I want it to end after decrementing would how would i do that with a boolean or do i...
  8. Thread: Need logic help

    by Rango
    Replies
    27
    Views
    1,422

    Re: Need logic help

    would this be a code problem or IDE problem
  9. Thread: Need logic help

    by Rango
    Replies
    27
    Views
    1,422

    Re: Need logic help

    package gettingstarted;




    //Add Phidgets Library | You added a file called phidget22 when configuring your project. Import gives you access to the Phidgets library code inside that file. ...
  10. Thread: Need logic help

    by Rango
    Replies
    27
    Views
    1,422

    Re: Need logic help

    package gettingstarted;




    //Add Phidgets Library | You added a file called phidget22 when configuring your project. Import gives you access to the Phidgets library code inside that file. ...
  11. Thread: Need logic help

    by Rango
    Replies
    27
    Views
    1,422

    Re: Need logic help

    package gettingstarted;




    //Add Phidgets Library | You added a file called phidget22 when configuring your project. Import gives you access to the Phidgets library code inside that file. ...
  12. Thread: Need logic help

    by Rango
    Replies
    27
    Views
    1,422

    Re: Need logic help

    Just to make sure the incrementCount boolean is true so it counts up and once it reaches the boundary in this case 1 it becomes false therfore in the the second if, increment Count is no longer true...
  13. Thread: Need logic help

    by Rango
    Replies
    27
    Views
    1,422

    Re: I need help to write code where i want the count in redLED.setDutyCycle(count); to start at 0 and go up by.1 and when it reaches 1 go down by .1 then stay at zero

    I changed the format, if I were to use a boolean variable would it affect it where once I've met the condition where count == 1 that the count down would start and count up would be false where since...
  14. Thread: Need logic help

    by Rango
    Replies
    27
    Views
    1,422

    Need logic help

    I need help to write code where i want the count in redLED.setDutyCycle(count); to start at 0 and go up by.1 and when it reaches 1 go down by .1 then stay at zero


    package gettingstarted;


    ...
Results 1 to 14 of 14