Difference between revisions of "Talk:Libwiilight"

From WiiBrew
Jump to navigation Jump to search
Line 17: Line 17:
 
{
 
{
 
     *(u32*)0xCD0000C0 |= 0x20;
 
     *(u32*)0xCD0000C0 |= 0x20;
}</source>--[[User:Crayon|Crayon]] ([[User talk:Crayon|talk]]) 23:29, 7 November 2009 (UTC)
+
}</source>
 +
 
 +
--[[User:Crayon|Crayon]] ([[User talk:Crayon|talk]]) 23:29, 7 November 2009 (UTC)
 +
 
 
:Thanks Crayon; How about setting the level of the LED? --[[User:DrTwox|DrTwox]] 20:56, 8 November 2009 (UTC)
 
:Thanks Crayon; How about setting the level of the LED? --[[User:DrTwox|DrTwox]] 20:56, 8 November 2009 (UTC)
 +
::Setting the level is allot more involved as it is not supported directly. libwiilight uses very fast pulses (toggling on and off) to simulate levels of intensity, its just an eye trick. I have a (slightly) modified version of libwiilight [http://code.google.com/p/mplayer-ce/source/browse/branches/newgui/libs/libprojectM/source/Renderer/Gekko.c here] --[[User:Rhys|Rhys]] 00:57, 9 November 2009 (UTC)

Revision as of 02:57, 9 November 2009

Source

Is the source available somewhere? --DrTwox 22:31, 7 November 2009 (UTC)

If you simply need on and off, here it is:
/**
 * Turn Wii light off.
 */
void WIILIGHT_TurnOff()
{
    *(u32*)0xCD0000C0 &= ~0x20;
}

/**
 * Turn Wii light on.
 */
void WIILIGHT_TurnOn()
{
    *(u32*)0xCD0000C0 |= 0x20;
}

--Crayon (talk) 23:29, 7 November 2009 (UTC)

Thanks Crayon; How about setting the level of the LED? --DrTwox 20:56, 8 November 2009 (UTC)
Setting the level is allot more involved as it is not supported directly. libwiilight uses very fast pulses (toggling on and off) to simulate levels of intensity, its just an eye trick. I have a (slightly) modified version of libwiilight here --Rhys 00:57, 9 November 2009 (UTC)