Skip to content

Instantly share code, notes, and snippets.

@corecode
Created June 9, 2019 16:56
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save corecode/4b6d47e26830fcb2f3a5ff3542189647 to your computer and use it in GitHub Desktop.
Save corecode/4b6d47e26830fcb2f3a5ff3542189647 to your computer and use it in GitHub Desktop.
module top
(
input en,
input rgbleden,
input r_in,
input g_in,
input b_in,
output r_led,
output g_led,
output b_led);
SB_LED_DRV_CUR
LED_DRV_CUR(.EN(en),
.LEDPU(ledpu));
SB_RGB_DRV
RGB_DRV(.RGBLEDEN(rgbleden),
.RGBPU(ledpu),
.RGB0PWM(r_in),
.RGB1PWM(g_in),
.RGB2PWM(b_in),
.RGB0(r_led),
.RGB1(g_led),
.RGB2(b_led));
defparam RGB_DRV.RGB0_CURRENT = "0b000011";
defparam RGB_DRV.RGB1_CURRENT = "0b001111";
defparam RGB_DRV.RGB2_CURRENT = "0b111111";
endmodule
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment