Changing color background

Here is some code that I made that makes the background of your app change colors:

function setup()
    --displayMode(FULLSCREEN_NO_BUTTONS)
end

phase = 0

changingpace = .1

function changeBackground()
    bgr = 128+ 127 * math.sin(phase / (2*math.pi))
    bgg = 128+ 127 * math.sin(phase * 2/ (2*math.pi))
    bgb = 128+ 127 * math.sin(phase * 3/ (2*math.pi))
    
    phase = phase + changingpace
    
    if phase > (360 * 6) then
        phase = 0
    end
    background(bgr, bgg, bgb, 255)
end


function draw()
    changeBackground()
end