Ledstate13 10% HIGH and 90% LOW of interval How to do that?

Hello Gents,

I hope someone can help me to fix the Ledstate13 functions.

unsigned long currentMillis = millis();

if((currentMillis - previousMillis >= interval)){ // save the last time you blinked the LED
previousMillis = currentMillis; // if the LED is off turn it on and vice-versa:
if ((ledState13 == LOW)
ledState13 = HIGH; // ledstate13 should stay 10% of interval HIGH

else

ledState13 = LOW; // ledstate13 should stay 90% of interval LOW

digitalWrite(ledPin13, ledState13); // set the LED with the ledState of the variable:

Fix? What is wrong? You have posted an incomplete sketch, and posted it incorrectly.

Please read these two posts:

How to use this forum - please read.
and
Read this before posting a programming question ...
You may also find useful information that would answer your question here:
Useful links - check here for reference posts / tutorials

You have posted code without using code tags. The code tags make the code look

like this

when posting source code files. It makes it easier to read, and can be copied with a single mouse click. Also, if you don't do it, some of the character sequences in the code can be misinterpred by the forum code as italics or funny emoticons. The "Code: [Select]" feature allows someone to select the entire sketch so it can be easily copied and pasted into the IDE for testing.
If you have already posted without using code tags, open your message and select "modify" from the pull down menu labelled, "More", at the lower left corner of the message. Highlight your code by selecting it (it turns blue), and then click on the "</>" icon at the upper left hand corner. Click on the "Save" button. Code tags can also be inserted manually in the forum text using the code and /code metatags.

Unless the sketch is too large, it's better if you post your code, rather than attach it. When it's attached, we have to download it, create a folder then open your code in our IDE. And afterwards, the folder remains unless we navigate to the "Temp" folder and manually remove it. It's much easier to just view the code in your post.

Many questions can be answered by reading the documentation which is provided with the IDE, available under the help tab, or online here.

  if ((ledState13 == LOW)
    {  
      ledState13 = HIGH;           // ledstate13 should stay 10% of interval HIGH
      period = aSmallNumberOfMilliseconds;
    }
     
    else
    {    
      ledState13 = LOW;           // ledstate13 should stay 90% of interval LOW
      period = aLargeNumberOfMilliseconds;
    }