Smooth LED fading via PWM


Results 1 to 40 of 55

Threaded View

  1. #34
    Join Date
    May 2006
    Location
    Del Rio, TX, USA
    Posts
    343


    Did you find this post helpful? Yes | No

    Default Re: Smooth LED fading via PWM

    My math was a little off, the line for the reading of the EEPROM should be

    Code:
    READ count1-26, duty
    As a side note, you could make it really simple just by leaving the original table as-is and using this:

    Code:
    Smooth_fade: 
         IF Count1 = 0 THEN 
              duty = 0 
         ELSE 
              Read Count1, duty 
         ENDIF
    RETURN
    
    WriteUserByte: 
         WRITE 0, UserByte 
         RETURN
    
    ReadUserByte: 
         READ 0, UserByte 
         RETURN
    Last edited by SteveB; - 20th September 2011 at 05:03.

Members who have read this thread : 0

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts