<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://www.3dbrew.org/w/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Gericom</id>
	<title>3dbrew - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://www.3dbrew.org/w/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Gericom"/>
	<link rel="alternate" type="text/html" href="https://www.3dbrew.org/wiki/Special:Contributions/Gericom"/>
	<updated>2026-04-06T21:03:10Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.43.1</generator>
	<entry>
		<id>https://www.3dbrew.org/w/index.php?title=GPIO_Registers&amp;diff=21053</id>
		<title>GPIO Registers</title>
		<link rel="alternate" type="text/html" href="https://www.3dbrew.org/w/index.php?title=GPIO_Registers&amp;diff=21053"/>
		<updated>2019-09-29T15:23:08Z</updated>

		<summary type="html">&lt;p&gt;Gericom: /* RTC_CNT (0x10147100) */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Registers =&lt;br /&gt;
&lt;br /&gt;
== GPIO ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Name&lt;br /&gt;
!  Address&lt;br /&gt;
!  Width&lt;br /&gt;
!  GPIO [[GPIO_Services|bitmasks]] associated with this register&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA0&lt;br /&gt;
| 0x10147000&lt;br /&gt;
| 2&lt;br /&gt;
| 0x1, 0x2, 0x4&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA1&lt;br /&gt;
| [[#0x10147010|0x10147010]]&lt;br /&gt;
| 4&lt;br /&gt;
| 0x8, 0x10&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA2&lt;br /&gt;
| 0x10147014&lt;br /&gt;
| 2&lt;br /&gt;
| 0x20&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA3&lt;br /&gt;
| 0x10147020&lt;br /&gt;
| 2&lt;br /&gt;
| 0x40, 0x80, 0x100, 0x200, 0x400, 0x800, 0x1000, 0x2000, 0x4000, 0x8000, 0x10000, 0x20000&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA3_INTERRUPT_CLEAR&lt;br /&gt;
| 0x10147022&lt;br /&gt;
| 2&lt;br /&gt;
| 0x40, 0x80, 0x100, 0x200, 0x400, 0x800, 0x1000, 0x2000, 0x4000, 0x8000, 0x10000, 0x20000&lt;br /&gt;
|-&lt;br /&gt;
| ??&lt;br /&gt;
| 0x10147024&lt;br /&gt;
| 2&lt;br /&gt;
| 0x40, 0x80, 0x100, 0x200, 0x400, 0x800, 0x1000, 0x2000, 0x4000, 0x8000, 0x10000, 0x20000&lt;br /&gt;
|-&lt;br /&gt;
| ?&lt;br /&gt;
| [[#0x10147026|0x10147026]]&lt;br /&gt;
| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA4&lt;br /&gt;
| 0x10147028&lt;br /&gt;
| 2&lt;br /&gt;
| 0x40000&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Legacy RTC ==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Name&lt;br /&gt;
!  Address&lt;br /&gt;
!  Width&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| [[#RTC_CNT_(0x10147100)|RTC_CNT]]&lt;br /&gt;
| 0x10147100&lt;br /&gt;
| 2&lt;br /&gt;
| Control register&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_STAT1&lt;br /&gt;
| 0x10147110&lt;br /&gt;
| 1&lt;br /&gt;
| Rtc status register 1 (command 0). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_STAT2&lt;br /&gt;
| 0x10147111&lt;br /&gt;
| 1&lt;br /&gt;
| Rtc status register 2 (command 1). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_CLKADJ&lt;br /&gt;
| 0x10147112&lt;br /&gt;
| 1&lt;br /&gt;
| Rtc clock adjustment register (command 6). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_FREE&lt;br /&gt;
| 0x10147113&lt;br /&gt;
| 1&lt;br /&gt;
| The free general purpose rtc register (command 7). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_TIME1&lt;br /&gt;
| 0x10147120&lt;br /&gt;
| 4&lt;br /&gt;
| Byte-wise bit-swapped (bit7 is bit0, etc.) BCD RTC (byte0 = seconds, byte1 = minutes, byte2 = hours, byte3 = day of week)&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_TIME2&lt;br /&gt;
| 0x10147124&lt;br /&gt;
| 4 (3?)&lt;br /&gt;
| Day, month and year all byte-wise bit-swapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_ALRMTIM1&lt;br /&gt;
| 0x10147130&lt;br /&gt;
| 4 (3?)&lt;br /&gt;
| Rtc alarm time register 1 (command 4). Byte-wise bit-swapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_ALRMTIM2&lt;br /&gt;
| 0x10147134&lt;br /&gt;
| 4 (3?)&lt;br /&gt;
| Rtc alarm time register 2 (command 5). Byte-wise bit-swapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_COUNT&lt;br /&gt;
| 0x10147140&lt;br /&gt;
| 4 (3?)&lt;br /&gt;
| Rtc dsi counter register (ex command 0). Byte-wise bit-swapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_FOUT1&lt;br /&gt;
| 0x10147150&lt;br /&gt;
| 1&lt;br /&gt;
| Rtc dsi fout register 1 (ex command 1). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_FOUT2&lt;br /&gt;
| 0x10147151&lt;br /&gt;
| 1&lt;br /&gt;
| Rtc dsi fout register 2 (ex command 2). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_ALRMDAT1&lt;br /&gt;
| 0x10147160&lt;br /&gt;
| 4 (3?)&lt;br /&gt;
| Rtc dsi alarm date register 1 (ex command 4). Byte-wise bit-swapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_ALRMDAT2&lt;br /&gt;
| 0x10147164&lt;br /&gt;
| 4 (3?)&lt;br /&gt;
| Rtc dsi alarm date register 2 (ex command 5). Byte-wise bit-swapped&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
= Descriptions =&lt;br /&gt;
&lt;br /&gt;
== 0x10147010 ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 24&lt;br /&gt;
| Enable/disable? GPIO interrupt 0x64 (bitmask 0x8)&lt;br /&gt;
|-&lt;br /&gt;
| 25&lt;br /&gt;
| Enable/disable? GPIO interrupt 0x66 (bitmask 0x10)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== 0x10147026 ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0-8&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 9&lt;br /&gt;
| Enable/disable interrupt 0x71.&lt;br /&gt;
|-&lt;br /&gt;
| 10-15&lt;br /&gt;
| ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== GPIO_DATA ==&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA0 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0-2&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x7.&lt;br /&gt;
|-&lt;br /&gt;
| 1&lt;br /&gt;
| DS EXTKEYIN Pen down (0 = touching, 1 = not touching)&lt;br /&gt;
|-&lt;br /&gt;
| 3&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|-&lt;br /&gt;
| 4&lt;br /&gt;
| Only used by [[Bootloader|Boot11]].&lt;br /&gt;
|-&lt;br /&gt;
| 5-15&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA1 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0-1&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x18.&lt;br /&gt;
|-&lt;br /&gt;
| 2-31&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA2 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x20.&lt;br /&gt;
|-&lt;br /&gt;
| 1-15&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA3 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0-11&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x3FFC0.&lt;br /&gt;
|-&lt;br /&gt;
| 12-31&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA4 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x40000.&lt;br /&gt;
|-&lt;br /&gt;
| 1-15&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Legacy RTC ==&lt;br /&gt;
=== RTC_CNT (0x10147100) ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0&lt;br /&gt;
| Latch STAT1&lt;br /&gt;
|-&lt;br /&gt;
| 1&lt;br /&gt;
| Latch STAT2&lt;br /&gt;
|-&lt;br /&gt;
| 2&lt;br /&gt;
| Latch CLKADJ&lt;br /&gt;
|-&lt;br /&gt;
| 3&lt;br /&gt;
| Latch FREE&lt;br /&gt;
|-&lt;br /&gt;
| 4&lt;br /&gt;
| Latch TIME&lt;br /&gt;
|-&lt;br /&gt;
| 5&lt;br /&gt;
| Latch ALRMTIM1&lt;br /&gt;
|-&lt;br /&gt;
| 6&lt;br /&gt;
| Latch ALRMTIM2&lt;br /&gt;
|-&lt;br /&gt;
| 7&lt;br /&gt;
| Latch COUNT&lt;br /&gt;
|-&lt;br /&gt;
| 8&lt;br /&gt;
| Latch FOUT1&lt;br /&gt;
|-&lt;br /&gt;
| 9&lt;br /&gt;
| Latch FOUT2&lt;br /&gt;
|-&lt;br /&gt;
| 10&lt;br /&gt;
| Latch ALRMDAT1&lt;br /&gt;
|-&lt;br /&gt;
| 11&lt;br /&gt;
| Latch ALRMDAT2&lt;br /&gt;
|-&lt;br /&gt;
| 12&lt;br /&gt;
| ARM7 Busy? This may be chipselect&lt;br /&gt;
|-&lt;br /&gt;
| 13&lt;br /&gt;
| ARM7 write command received? (writing 1 clears it seems)&lt;br /&gt;
|-&lt;br /&gt;
| 14&lt;br /&gt;
| ARM7 read command recieved? (writing 1 clears it seems)&lt;br /&gt;
|-&lt;br /&gt;
| 15&lt;br /&gt;
| DS SIO SI pin (rtc irq pin)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
= Default values =&lt;br /&gt;
&lt;br /&gt;
After bootrom initialization, these are the values of the registers:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Address&lt;br /&gt;
!  Value&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147000&lt;br /&gt;
| 0x0003&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147010&lt;br /&gt;
| 0x00000002&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147014&lt;br /&gt;
| 0x0000&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147020&lt;br /&gt;
| 0x00000DFB&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147024&lt;br /&gt;
| 0x00000000&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147028&lt;br /&gt;
| 0x0000&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Gericom</name></author>
	</entry>
	<entry>
		<id>https://www.3dbrew.org/w/index.php?title=GPIO_Registers&amp;diff=21052</id>
		<title>GPIO Registers</title>
		<link rel="alternate" type="text/html" href="https://www.3dbrew.org/w/index.php?title=GPIO_Registers&amp;diff=21052"/>
		<updated>2019-09-29T15:19:06Z</updated>

		<summary type="html">&lt;p&gt;Gericom: Oops&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Registers =&lt;br /&gt;
&lt;br /&gt;
== GPIO ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Name&lt;br /&gt;
!  Address&lt;br /&gt;
!  Width&lt;br /&gt;
!  GPIO [[GPIO_Services|bitmasks]] associated with this register&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA0&lt;br /&gt;
| 0x10147000&lt;br /&gt;
| 2&lt;br /&gt;
| 0x1, 0x2, 0x4&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA1&lt;br /&gt;
| [[#0x10147010|0x10147010]]&lt;br /&gt;
| 4&lt;br /&gt;
| 0x8, 0x10&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA2&lt;br /&gt;
| 0x10147014&lt;br /&gt;
| 2&lt;br /&gt;
| 0x20&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA3&lt;br /&gt;
| 0x10147020&lt;br /&gt;
| 2&lt;br /&gt;
| 0x40, 0x80, 0x100, 0x200, 0x400, 0x800, 0x1000, 0x2000, 0x4000, 0x8000, 0x10000, 0x20000&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA3_INTERRUPT_CLEAR&lt;br /&gt;
| 0x10147022&lt;br /&gt;
| 2&lt;br /&gt;
| 0x40, 0x80, 0x100, 0x200, 0x400, 0x800, 0x1000, 0x2000, 0x4000, 0x8000, 0x10000, 0x20000&lt;br /&gt;
|-&lt;br /&gt;
| ??&lt;br /&gt;
| 0x10147024&lt;br /&gt;
| 2&lt;br /&gt;
| 0x40, 0x80, 0x100, 0x200, 0x400, 0x800, 0x1000, 0x2000, 0x4000, 0x8000, 0x10000, 0x20000&lt;br /&gt;
|-&lt;br /&gt;
| ?&lt;br /&gt;
| [[#0x10147026|0x10147026]]&lt;br /&gt;
| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA4&lt;br /&gt;
| 0x10147028&lt;br /&gt;
| 2&lt;br /&gt;
| 0x40000&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Legacy RTC ==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Name&lt;br /&gt;
!  Address&lt;br /&gt;
!  Width&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| [[#RTC_CNT_(0x10147100)|RTC_CNT]]&lt;br /&gt;
| 0x10147100&lt;br /&gt;
| 2&lt;br /&gt;
| Control register&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_STAT1&lt;br /&gt;
| 0x10147110&lt;br /&gt;
| 1&lt;br /&gt;
| Rtc status register 1 (command 0). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_STAT2&lt;br /&gt;
| 0x10147111&lt;br /&gt;
| 1&lt;br /&gt;
| Rtc status register 2 (command 1). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_CLKADJ&lt;br /&gt;
| 0x10147112&lt;br /&gt;
| 1&lt;br /&gt;
| Rtc clock adjustment register (command 6). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_FREE&lt;br /&gt;
| 0x10147113&lt;br /&gt;
| 1&lt;br /&gt;
| The free general purpose rtc register (command 7). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_TIME1&lt;br /&gt;
| 0x10147120&lt;br /&gt;
| 4&lt;br /&gt;
| Byte-wise bit-swapped (bit7 is bit0, etc.) BCD RTC (byte0 = seconds, byte1 = minutes, byte2 = hours, byte3 = day of week)&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_TIME2&lt;br /&gt;
| 0x10147124&lt;br /&gt;
| 4 (3?)&lt;br /&gt;
| Day, month and year all byte-wise bit-swapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_ALRMTIM1&lt;br /&gt;
| 0x10147130&lt;br /&gt;
| 4 (3?)&lt;br /&gt;
| Rtc alarm time register 1 (command 4). Byte-wise bit-swapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_ALRMTIM2&lt;br /&gt;
| 0x10147134&lt;br /&gt;
| 4 (3?)&lt;br /&gt;
| Rtc alarm time register 2 (command 5). Byte-wise bit-swapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_COUNT&lt;br /&gt;
| 0x10147140&lt;br /&gt;
| 4 (3?)&lt;br /&gt;
| Rtc dsi counter register (ex command 0). Byte-wise bit-swapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_FOUT1&lt;br /&gt;
| 0x10147150&lt;br /&gt;
| 1&lt;br /&gt;
| Rtc dsi fout register 1 (ex command 1). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_FOUT2&lt;br /&gt;
| 0x10147151&lt;br /&gt;
| 1&lt;br /&gt;
| Rtc dsi fout register 2 (ex command 2). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_ALRMDAT1&lt;br /&gt;
| 0x10147160&lt;br /&gt;
| 4 (3?)&lt;br /&gt;
| Rtc dsi alarm date register 1 (ex command 4). Byte-wise bit-swapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_ALRMDAT2&lt;br /&gt;
| 0x10147164&lt;br /&gt;
| 4 (3?)&lt;br /&gt;
| Rtc dsi alarm date register 2 (ex command 5). Byte-wise bit-swapped&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
= Descriptions =&lt;br /&gt;
&lt;br /&gt;
== 0x10147010 ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 24&lt;br /&gt;
| Enable/disable? GPIO interrupt 0x64 (bitmask 0x8)&lt;br /&gt;
|-&lt;br /&gt;
| 25&lt;br /&gt;
| Enable/disable? GPIO interrupt 0x66 (bitmask 0x10)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== 0x10147026 ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0-8&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 9&lt;br /&gt;
| Enable/disable interrupt 0x71.&lt;br /&gt;
|-&lt;br /&gt;
| 10-15&lt;br /&gt;
| ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== GPIO_DATA ==&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA0 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0-2&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x7.&lt;br /&gt;
|-&lt;br /&gt;
| 1&lt;br /&gt;
| DS EXTKEYIN Pen down (0 = touching, 1 = not touching)&lt;br /&gt;
|-&lt;br /&gt;
| 3&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|-&lt;br /&gt;
| 4&lt;br /&gt;
| Only used by [[Bootloader|Boot11]].&lt;br /&gt;
|-&lt;br /&gt;
| 5-15&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA1 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0-1&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x18.&lt;br /&gt;
|-&lt;br /&gt;
| 2-31&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA2 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x20.&lt;br /&gt;
|-&lt;br /&gt;
| 1-15&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA3 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0-11&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x3FFC0.&lt;br /&gt;
|-&lt;br /&gt;
| 12-31&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA4 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x40000.&lt;br /&gt;
|-&lt;br /&gt;
| 1-15&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Legacy RTC ==&lt;br /&gt;
=== RTC_CNT (0x10147100) ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0&lt;br /&gt;
| Latch STAT1&lt;br /&gt;
|-&lt;br /&gt;
| 1&lt;br /&gt;
| Latch STAT2&lt;br /&gt;
|-&lt;br /&gt;
| 2&lt;br /&gt;
| Latch CLKADJ&lt;br /&gt;
|-&lt;br /&gt;
| 3&lt;br /&gt;
| Latch FREE&lt;br /&gt;
|-&lt;br /&gt;
| 4&lt;br /&gt;
| Latch TIME&lt;br /&gt;
|-&lt;br /&gt;
| 5&lt;br /&gt;
| Latch ALRMTIM1&lt;br /&gt;
|-&lt;br /&gt;
| 6&lt;br /&gt;
| Latch ALRMTIM2&lt;br /&gt;
|-&lt;br /&gt;
| 7&lt;br /&gt;
| Latch COUNT&lt;br /&gt;
|-&lt;br /&gt;
| 8&lt;br /&gt;
| Latch FOUT1&lt;br /&gt;
|-&lt;br /&gt;
| 9&lt;br /&gt;
| Latch FOUT2&lt;br /&gt;
|-&lt;br /&gt;
| 10&lt;br /&gt;
| Latch ALRMDAT1&lt;br /&gt;
|-&lt;br /&gt;
| 11&lt;br /&gt;
| Latch ALRMDAT2&lt;br /&gt;
|-&lt;br /&gt;
| 12&lt;br /&gt;
| ARM7 Busy? This may be chipselect&lt;br /&gt;
|-&lt;br /&gt;
| 13&lt;br /&gt;
| ARM7 read command received? (writing 1 clears it seems)&lt;br /&gt;
|-&lt;br /&gt;
| 14&lt;br /&gt;
| ARM7 write command recieved? (writing 1 clears it seems)&lt;br /&gt;
|-&lt;br /&gt;
| 15&lt;br /&gt;
| DS SIO SI pin (rtc irq pin)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
= Default values =&lt;br /&gt;
&lt;br /&gt;
After bootrom initialization, these are the values of the registers:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Address&lt;br /&gt;
!  Value&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147000&lt;br /&gt;
| 0x0003&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147010&lt;br /&gt;
| 0x00000002&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147014&lt;br /&gt;
| 0x0000&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147020&lt;br /&gt;
| 0x00000DFB&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147024&lt;br /&gt;
| 0x00000000&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147028&lt;br /&gt;
| 0x0000&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Gericom</name></author>
	</entry>
	<entry>
		<id>https://www.3dbrew.org/w/index.php?title=GPIO_Registers&amp;diff=21051</id>
		<title>GPIO Registers</title>
		<link rel="alternate" type="text/html" href="https://www.3dbrew.org/w/index.php?title=GPIO_Registers&amp;diff=21051"/>
		<updated>2019-09-29T15:18:30Z</updated>

		<summary type="html">&lt;p&gt;Gericom: Updated RTC_CNT information&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Registers =&lt;br /&gt;
&lt;br /&gt;
== GPIO ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Name&lt;br /&gt;
!  Address&lt;br /&gt;
!  Width&lt;br /&gt;
!  GPIO [[GPIO_Services|bitmasks]] associated with this register&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA0&lt;br /&gt;
| 0x10147000&lt;br /&gt;
| 2&lt;br /&gt;
| 0x1, 0x2, 0x4&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA1&lt;br /&gt;
| [[#0x10147010|0x10147010]]&lt;br /&gt;
| 4&lt;br /&gt;
| 0x8, 0x10&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA2&lt;br /&gt;
| 0x10147014&lt;br /&gt;
| 2&lt;br /&gt;
| 0x20&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA3&lt;br /&gt;
| 0x10147020&lt;br /&gt;
| 2&lt;br /&gt;
| 0x40, 0x80, 0x100, 0x200, 0x400, 0x800, 0x1000, 0x2000, 0x4000, 0x8000, 0x10000, 0x20000&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA3_INTERRUPT_CLEAR&lt;br /&gt;
| 0x10147022&lt;br /&gt;
| 2&lt;br /&gt;
| 0x40, 0x80, 0x100, 0x200, 0x400, 0x800, 0x1000, 0x2000, 0x4000, 0x8000, 0x10000, 0x20000&lt;br /&gt;
|-&lt;br /&gt;
| ??&lt;br /&gt;
| 0x10147024&lt;br /&gt;
| 2&lt;br /&gt;
| 0x40, 0x80, 0x100, 0x200, 0x400, 0x800, 0x1000, 0x2000, 0x4000, 0x8000, 0x10000, 0x20000&lt;br /&gt;
|-&lt;br /&gt;
| ?&lt;br /&gt;
| [[#0x10147026|0x10147026]]&lt;br /&gt;
| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA4&lt;br /&gt;
| 0x10147028&lt;br /&gt;
| 2&lt;br /&gt;
| 0x40000&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Legacy RTC ==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Name&lt;br /&gt;
!  Address&lt;br /&gt;
!  Width&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| [[#RTC_CNT|RTC_CNT]]&lt;br /&gt;
| 0x10147100&lt;br /&gt;
| 2&lt;br /&gt;
| Control register&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_STAT1&lt;br /&gt;
| 0x10147110&lt;br /&gt;
| 1&lt;br /&gt;
| Rtc status register 1 (command 0). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_STAT2&lt;br /&gt;
| 0x10147111&lt;br /&gt;
| 1&lt;br /&gt;
| Rtc status register 2 (command 1). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_CLKADJ&lt;br /&gt;
| 0x10147112&lt;br /&gt;
| 1&lt;br /&gt;
| Rtc clock adjustment register (command 6). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_FREE&lt;br /&gt;
| 0x10147113&lt;br /&gt;
| 1&lt;br /&gt;
| The free general purpose rtc register (command 7). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_TIME1&lt;br /&gt;
| 0x10147120&lt;br /&gt;
| 4&lt;br /&gt;
| Byte-wise bit-swapped (bit7 is bit0, etc.) BCD RTC (byte0 = seconds, byte1 = minutes, byte2 = hours, byte3 = day of week)&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_TIME2&lt;br /&gt;
| 0x10147124&lt;br /&gt;
| 4 (3?)&lt;br /&gt;
| Day, month and year all byte-wise bit-swapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_ALRMTIM1&lt;br /&gt;
| 0x10147130&lt;br /&gt;
| 4 (3?)&lt;br /&gt;
| Rtc alarm time register 1 (command 4). Byte-wise bit-swapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_ALRMTIM2&lt;br /&gt;
| 0x10147134&lt;br /&gt;
| 4 (3?)&lt;br /&gt;
| Rtc alarm time register 2 (command 5). Byte-wise bit-swapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_COUNT&lt;br /&gt;
| 0x10147140&lt;br /&gt;
| 4 (3?)&lt;br /&gt;
| Rtc dsi counter register (ex command 0). Byte-wise bit-swapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_FOUT1&lt;br /&gt;
| 0x10147150&lt;br /&gt;
| 1&lt;br /&gt;
| Rtc dsi fout register 1 (ex command 1). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_FOUT2&lt;br /&gt;
| 0x10147151&lt;br /&gt;
| 1&lt;br /&gt;
| Rtc dsi fout register 2 (ex command 2). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_ALRMDAT1&lt;br /&gt;
| 0x10147160&lt;br /&gt;
| 4 (3?)&lt;br /&gt;
| Rtc dsi alarm date register 1 (ex command 4). Byte-wise bit-swapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_ALRMDAT2&lt;br /&gt;
| 0x10147164&lt;br /&gt;
| 4 (3?)&lt;br /&gt;
| Rtc dsi alarm date register 2 (ex command 5). Byte-wise bit-swapped&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
= Descriptions =&lt;br /&gt;
&lt;br /&gt;
== 0x10147010 ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 24&lt;br /&gt;
| Enable/disable? GPIO interrupt 0x64 (bitmask 0x8)&lt;br /&gt;
|-&lt;br /&gt;
| 25&lt;br /&gt;
| Enable/disable? GPIO interrupt 0x66 (bitmask 0x10)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== 0x10147026 ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0-8&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 9&lt;br /&gt;
| Enable/disable interrupt 0x71.&lt;br /&gt;
|-&lt;br /&gt;
| 10-15&lt;br /&gt;
| ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== GPIO_DATA ==&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA0 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0-2&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x7.&lt;br /&gt;
|-&lt;br /&gt;
| 1&lt;br /&gt;
| DS EXTKEYIN Pen down (0 = touching, 1 = not touching)&lt;br /&gt;
|-&lt;br /&gt;
| 3&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|-&lt;br /&gt;
| 4&lt;br /&gt;
| Only used by [[Bootloader|Boot11]].&lt;br /&gt;
|-&lt;br /&gt;
| 5-15&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA1 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0-1&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x18.&lt;br /&gt;
|-&lt;br /&gt;
| 2-31&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA2 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x20.&lt;br /&gt;
|-&lt;br /&gt;
| 1-15&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA3 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0-11&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x3FFC0.&lt;br /&gt;
|-&lt;br /&gt;
| 12-31&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA4 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x40000.&lt;br /&gt;
|-&lt;br /&gt;
| 1-15&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Legacy RTC ==&lt;br /&gt;
=== RTC_CNT (0x10147100) ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0&lt;br /&gt;
| Latch STAT1&lt;br /&gt;
|-&lt;br /&gt;
| 1&lt;br /&gt;
| Latch STAT2&lt;br /&gt;
|-&lt;br /&gt;
| 2&lt;br /&gt;
| Latch CLKADJ&lt;br /&gt;
|-&lt;br /&gt;
| 3&lt;br /&gt;
| Latch FREE&lt;br /&gt;
|-&lt;br /&gt;
| 4&lt;br /&gt;
| Latch TIME&lt;br /&gt;
|-&lt;br /&gt;
| 5&lt;br /&gt;
| Latch ALRMTIM1&lt;br /&gt;
|-&lt;br /&gt;
| 6&lt;br /&gt;
| Latch ALRMTIM2&lt;br /&gt;
|-&lt;br /&gt;
| 7&lt;br /&gt;
| Latch COUNT&lt;br /&gt;
|-&lt;br /&gt;
| 8&lt;br /&gt;
| Latch FOUT1&lt;br /&gt;
|-&lt;br /&gt;
| 9&lt;br /&gt;
| Latch FOUT2&lt;br /&gt;
|-&lt;br /&gt;
| 10&lt;br /&gt;
| Latch ALRMDAT1&lt;br /&gt;
|-&lt;br /&gt;
| 11&lt;br /&gt;
| Latch ALRMDAT2&lt;br /&gt;
|-&lt;br /&gt;
| 12&lt;br /&gt;
| ARM7 Busy? This may be chipselect&lt;br /&gt;
|-&lt;br /&gt;
| 13&lt;br /&gt;
| ARM7 read command received? (writing 1 clears it seems)&lt;br /&gt;
|-&lt;br /&gt;
| 14&lt;br /&gt;
| ARM7 write command recieved? (writing 1 clears it seems)&lt;br /&gt;
|-&lt;br /&gt;
| 15&lt;br /&gt;
| DS SIO SI pin (rtc irq pin)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
= Default values =&lt;br /&gt;
&lt;br /&gt;
After bootrom initialization, these are the values of the registers:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Address&lt;br /&gt;
!  Value&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147000&lt;br /&gt;
| 0x0003&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147010&lt;br /&gt;
| 0x00000002&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147014&lt;br /&gt;
| 0x0000&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147020&lt;br /&gt;
| 0x00000DFB&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147024&lt;br /&gt;
| 0x00000000&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147028&lt;br /&gt;
| 0x0000&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Gericom</name></author>
	</entry>
	<entry>
		<id>https://www.3dbrew.org/w/index.php?title=GPIO_Registers&amp;diff=21047</id>
		<title>GPIO Registers</title>
		<link rel="alternate" type="text/html" href="https://www.3dbrew.org/w/index.php?title=GPIO_Registers&amp;diff=21047"/>
		<updated>2019-09-21T11:25:59Z</updated>

		<summary type="html">&lt;p&gt;Gericom: /* Legacy RTC */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Registers =&lt;br /&gt;
&lt;br /&gt;
== GPIO ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Name&lt;br /&gt;
!  Address&lt;br /&gt;
!  Width&lt;br /&gt;
!  GPIO [[GPIO_Services|bitmasks]] associated with this register&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA0&lt;br /&gt;
| 0x10147000&lt;br /&gt;
| 2&lt;br /&gt;
| 0x1, 0x2, 0x4&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA1&lt;br /&gt;
| [[#0x10147010|0x10147010]]&lt;br /&gt;
| 4&lt;br /&gt;
| 0x8, 0x10&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA2&lt;br /&gt;
| 0x10147014&lt;br /&gt;
| 2&lt;br /&gt;
| 0x20&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA3&lt;br /&gt;
| 0x10147020&lt;br /&gt;
| 2&lt;br /&gt;
| 0x40, 0x80, 0x100, 0x200, 0x400, 0x800, 0x1000, 0x2000, 0x4000, 0x8000, 0x10000, 0x20000&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA3_INTERRUPT_CLEAR&lt;br /&gt;
| 0x10147022&lt;br /&gt;
| 2&lt;br /&gt;
| 0x40, 0x80, 0x100, 0x200, 0x400, 0x800, 0x1000, 0x2000, 0x4000, 0x8000, 0x10000, 0x20000&lt;br /&gt;
|-&lt;br /&gt;
| ??&lt;br /&gt;
| 0x10147024&lt;br /&gt;
| 2&lt;br /&gt;
| 0x40, 0x80, 0x100, 0x200, 0x400, 0x800, 0x1000, 0x2000, 0x4000, 0x8000, 0x10000, 0x20000&lt;br /&gt;
|-&lt;br /&gt;
| ?&lt;br /&gt;
| [[#0x10147026|0x10147026]]&lt;br /&gt;
| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA4&lt;br /&gt;
| 0x10147028&lt;br /&gt;
| 2&lt;br /&gt;
| 0x40000&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Legacy RTC ==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Name&lt;br /&gt;
!  Address&lt;br /&gt;
!  Width&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| RTC_CNT&lt;br /&gt;
| 0x10147100&lt;br /&gt;
| 2&lt;br /&gt;
| 0x8000 = enabled?, 0x4000 = latch, other bits are to-be-latched bits in order of the regs below, starting from bit 0. TIME1 and TIME2 are one bit (0x10) together&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_STAT1&lt;br /&gt;
| 0x10147110&lt;br /&gt;
| 1&lt;br /&gt;
| Rtc status register 1 (command 0). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_STAT2&lt;br /&gt;
| 0x10147111&lt;br /&gt;
| 1&lt;br /&gt;
| Rtc status register 2 (command 1). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_CLKADJ&lt;br /&gt;
| 0x10147112&lt;br /&gt;
| 1&lt;br /&gt;
| Rtc clock adjustment register (command 6). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_FREE&lt;br /&gt;
| 0x10147113&lt;br /&gt;
| 1&lt;br /&gt;
| The free general purpose rtc register (command 7). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_TIME1&lt;br /&gt;
| 0x10147120&lt;br /&gt;
| 4&lt;br /&gt;
| Byte-wise bit-swapped (bit7 is bit0, etc.) BCD RTC (byte0 = seconds, byte1 = minutes, byte2 = hours, byte3 = day of week)&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_TIME2&lt;br /&gt;
| 0x10147124&lt;br /&gt;
| 4 (3?)&lt;br /&gt;
| Day, month and year all byte-wise bit-swapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_ALRMTIM1&lt;br /&gt;
| 0x10147130&lt;br /&gt;
| 4 (3?)&lt;br /&gt;
| Rtc alarm time register 1 (command 4). Byte-wise bit-swapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_ALRMTIM2&lt;br /&gt;
| 0x10147134&lt;br /&gt;
| 4 (3?)&lt;br /&gt;
| Rtc alarm time register 2 (command 5). Byte-wise bit-swapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_COUNT&lt;br /&gt;
| 0x10147140&lt;br /&gt;
| 4 (3?)&lt;br /&gt;
| Rtc dsi counter register (ex command 0). Byte-wise bit-swapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_FOUT1&lt;br /&gt;
| 0x10147150&lt;br /&gt;
| 1&lt;br /&gt;
| Rtc dsi fout register 1 (ex command 1). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_FOUT2&lt;br /&gt;
| 0x10147151&lt;br /&gt;
| 1&lt;br /&gt;
| Rtc dsi fout register 2 (ex command 2). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_ALRMDAT1&lt;br /&gt;
| 0x10147160&lt;br /&gt;
| 4 (3?)&lt;br /&gt;
| Rtc dsi alarm date register 1 (ex command 4). Byte-wise bit-swapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_ALRMDAT2&lt;br /&gt;
| 0x10147164&lt;br /&gt;
| 4 (3?)&lt;br /&gt;
| Rtc dsi alarm date register 2 (ex command 5). Byte-wise bit-swapped&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
= Descriptions =&lt;br /&gt;
&lt;br /&gt;
== 0x10147010 ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 24&lt;br /&gt;
| Enable/disable? GPIO interrupt 0x64 (bitmask 0x8)&lt;br /&gt;
|-&lt;br /&gt;
| 25&lt;br /&gt;
| Enable/disable? GPIO interrupt 0x66 (bitmask 0x10)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== 0x10147026 ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0-8&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 9&lt;br /&gt;
| Enable/disable interrupt 0x71.&lt;br /&gt;
|-&lt;br /&gt;
| 10-15&lt;br /&gt;
| ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== GPIO_DATA ==&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA0 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0-2&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x7.&lt;br /&gt;
|-&lt;br /&gt;
| 1&lt;br /&gt;
| DS EXTKEYIN Pen down (0 = touching, 1 = not touching)&lt;br /&gt;
|-&lt;br /&gt;
| 3&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|-&lt;br /&gt;
| 4&lt;br /&gt;
| Only used by [[Bootloader|Boot11]].&lt;br /&gt;
|-&lt;br /&gt;
| 5-15&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA1 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0-1&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x18.&lt;br /&gt;
|-&lt;br /&gt;
| 2-31&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA2 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x20.&lt;br /&gt;
|-&lt;br /&gt;
| 1-15&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA3 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0-11&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x3FFC0.&lt;br /&gt;
|-&lt;br /&gt;
| 12-31&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA4 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x40000.&lt;br /&gt;
|-&lt;br /&gt;
| 1-15&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
= Default values =&lt;br /&gt;
&lt;br /&gt;
After bootrom initialization, these are the values of the registers:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Address&lt;br /&gt;
!  Value&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147000&lt;br /&gt;
| 0x0003&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147010&lt;br /&gt;
| 0x00000002&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147014&lt;br /&gt;
| 0x0000&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147020&lt;br /&gt;
| 0x00000DFB&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147024&lt;br /&gt;
| 0x00000000&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147028&lt;br /&gt;
| 0x0000&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Gericom</name></author>
	</entry>
	<entry>
		<id>https://www.3dbrew.org/w/index.php?title=GPIO_Registers&amp;diff=21046</id>
		<title>GPIO Registers</title>
		<link rel="alternate" type="text/html" href="https://www.3dbrew.org/w/index.php?title=GPIO_Registers&amp;diff=21046"/>
		<updated>2019-09-21T11:02:06Z</updated>

		<summary type="html">&lt;p&gt;Gericom: /* Legacy RTC */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Registers =&lt;br /&gt;
&lt;br /&gt;
== GPIO ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Name&lt;br /&gt;
!  Address&lt;br /&gt;
!  Width&lt;br /&gt;
!  GPIO [[GPIO_Services|bitmasks]] associated with this register&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA0&lt;br /&gt;
| 0x10147000&lt;br /&gt;
| 2&lt;br /&gt;
| 0x1, 0x2, 0x4&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA1&lt;br /&gt;
| [[#0x10147010|0x10147010]]&lt;br /&gt;
| 4&lt;br /&gt;
| 0x8, 0x10&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA2&lt;br /&gt;
| 0x10147014&lt;br /&gt;
| 2&lt;br /&gt;
| 0x20&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA3&lt;br /&gt;
| 0x10147020&lt;br /&gt;
| 2&lt;br /&gt;
| 0x40, 0x80, 0x100, 0x200, 0x400, 0x800, 0x1000, 0x2000, 0x4000, 0x8000, 0x10000, 0x20000&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA3_INTERRUPT_CLEAR&lt;br /&gt;
| 0x10147022&lt;br /&gt;
| 2&lt;br /&gt;
| 0x40, 0x80, 0x100, 0x200, 0x400, 0x800, 0x1000, 0x2000, 0x4000, 0x8000, 0x10000, 0x20000&lt;br /&gt;
|-&lt;br /&gt;
| ??&lt;br /&gt;
| 0x10147024&lt;br /&gt;
| 2&lt;br /&gt;
| 0x40, 0x80, 0x100, 0x200, 0x400, 0x800, 0x1000, 0x2000, 0x4000, 0x8000, 0x10000, 0x20000&lt;br /&gt;
|-&lt;br /&gt;
| ?&lt;br /&gt;
| [[#0x10147026|0x10147026]]&lt;br /&gt;
| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA4&lt;br /&gt;
| 0x10147028&lt;br /&gt;
| 2&lt;br /&gt;
| 0x40000&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Legacy RTC ==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Name&lt;br /&gt;
!  Address&lt;br /&gt;
!  Width&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| RTC_CNT&lt;br /&gt;
| 0x10147100&lt;br /&gt;
| 2&lt;br /&gt;
| 0x8000 = enabled?, 0x4000 = latch, other bits are to-be-latched bits in order of the regs below, starting from bit 0. TIME1 and TIME2 are one bit (0x10) together&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_STAT1&lt;br /&gt;
| 0x10147110&lt;br /&gt;
| 1&lt;br /&gt;
| Rtc status register 1 (command 0). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_STAT2&lt;br /&gt;
| 0x10147111&lt;br /&gt;
| 1&lt;br /&gt;
| Rtc status register 2 (command 1). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_CLKADJ&lt;br /&gt;
| 0x10147112&lt;br /&gt;
| 1&lt;br /&gt;
| Rtc clock adjustment register (command 6). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_FREE&lt;br /&gt;
| 0x10147113&lt;br /&gt;
| 1&lt;br /&gt;
| The free general purpose rtc register (command 7). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_TIME1&lt;br /&gt;
| 0x10147120&lt;br /&gt;
| 4&lt;br /&gt;
| Byte-wise bit-swapped (bit7 is bit0, etc.) BCD RTC (byte0 = seconds, byte1 = minutes, byte2 = hours, byte3 = day of week)&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_TIME2&lt;br /&gt;
| 0x10147124&lt;br /&gt;
| 4 (3?)&lt;br /&gt;
| Day, month and year all byte-wise bit-swapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_ALRMTIM1&lt;br /&gt;
| 0x10147130&lt;br /&gt;
| 4 (3?)&lt;br /&gt;
| Rtc alarm time register 1 (command 4). Byte-wise bit-swapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_ALRMTIM2&lt;br /&gt;
| 0x10147134&lt;br /&gt;
| 4 (3?)&lt;br /&gt;
| Rtc alarm time register 2 (command 5). Byte-wise bit-swapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_COUNT&lt;br /&gt;
| 0x10147140&lt;br /&gt;
| 4 (3?)&lt;br /&gt;
| Rtc dsi counter register (ex command 0). Byte-wise bit-swapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_FOUT1&lt;br /&gt;
| 0x10147150&lt;br /&gt;
| 1&lt;br /&gt;
| Rtc dsi fout register 1 (ex command 1). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_FOUT2&lt;br /&gt;
| 0x10147151&lt;br /&gt;
| 1&lt;br /&gt;
| Rtc dsi fout register 2 (ex command 2). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_ALRMDAT2&lt;br /&gt;
| 0x10147160&lt;br /&gt;
| 4 (3?)&lt;br /&gt;
| Rtc dsi alarm date register 1 (ex command 4). Byte-wise bit-swapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_ALRMDAT2&lt;br /&gt;
| 0x10147164&lt;br /&gt;
| 4 (3?)&lt;br /&gt;
| Rtc dsi alarm date register 2 (ex command 5). Byte-wise bit-swapped&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
= Descriptions =&lt;br /&gt;
&lt;br /&gt;
== 0x10147010 ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 24&lt;br /&gt;
| Enable/disable? GPIO interrupt 0x64 (bitmask 0x8)&lt;br /&gt;
|-&lt;br /&gt;
| 25&lt;br /&gt;
| Enable/disable? GPIO interrupt 0x66 (bitmask 0x10)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== 0x10147026 ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0-8&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 9&lt;br /&gt;
| Enable/disable interrupt 0x71.&lt;br /&gt;
|-&lt;br /&gt;
| 10-15&lt;br /&gt;
| ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== GPIO_DATA ==&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA0 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0-2&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x7.&lt;br /&gt;
|-&lt;br /&gt;
| 1&lt;br /&gt;
| DS EXTKEYIN Pen down (0 = touching, 1 = not touching)&lt;br /&gt;
|-&lt;br /&gt;
| 3&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|-&lt;br /&gt;
| 4&lt;br /&gt;
| Only used by [[Bootloader|Boot11]].&lt;br /&gt;
|-&lt;br /&gt;
| 5-15&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA1 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0-1&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x18.&lt;br /&gt;
|-&lt;br /&gt;
| 2-31&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA2 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x20.&lt;br /&gt;
|-&lt;br /&gt;
| 1-15&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA3 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0-11&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x3FFC0.&lt;br /&gt;
|-&lt;br /&gt;
| 12-31&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA4 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x40000.&lt;br /&gt;
|-&lt;br /&gt;
| 1-15&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
= Default values =&lt;br /&gt;
&lt;br /&gt;
After bootrom initialization, these are the values of the registers:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Address&lt;br /&gt;
!  Value&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147000&lt;br /&gt;
| 0x0003&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147010&lt;br /&gt;
| 0x00000002&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147014&lt;br /&gt;
| 0x0000&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147020&lt;br /&gt;
| 0x00000DFB&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147024&lt;br /&gt;
| 0x00000000&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147028&lt;br /&gt;
| 0x0000&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Gericom</name></author>
	</entry>
	<entry>
		<id>https://www.3dbrew.org/w/index.php?title=GPIO_Registers&amp;diff=21045</id>
		<title>GPIO Registers</title>
		<link rel="alternate" type="text/html" href="https://www.3dbrew.org/w/index.php?title=GPIO_Registers&amp;diff=21045"/>
		<updated>2019-09-21T10:19:46Z</updated>

		<summary type="html">&lt;p&gt;Gericom: /* Legacy RTC */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Registers =&lt;br /&gt;
&lt;br /&gt;
== GPIO ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Name&lt;br /&gt;
!  Address&lt;br /&gt;
!  Width&lt;br /&gt;
!  GPIO [[GPIO_Services|bitmasks]] associated with this register&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA0&lt;br /&gt;
| 0x10147000&lt;br /&gt;
| 2&lt;br /&gt;
| 0x1, 0x2, 0x4&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA1&lt;br /&gt;
| [[#0x10147010|0x10147010]]&lt;br /&gt;
| 4&lt;br /&gt;
| 0x8, 0x10&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA2&lt;br /&gt;
| 0x10147014&lt;br /&gt;
| 2&lt;br /&gt;
| 0x20&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA3&lt;br /&gt;
| 0x10147020&lt;br /&gt;
| 2&lt;br /&gt;
| 0x40, 0x80, 0x100, 0x200, 0x400, 0x800, 0x1000, 0x2000, 0x4000, 0x8000, 0x10000, 0x20000&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA3_INTERRUPT_CLEAR&lt;br /&gt;
| 0x10147022&lt;br /&gt;
| 2&lt;br /&gt;
| 0x40, 0x80, 0x100, 0x200, 0x400, 0x800, 0x1000, 0x2000, 0x4000, 0x8000, 0x10000, 0x20000&lt;br /&gt;
|-&lt;br /&gt;
| ??&lt;br /&gt;
| 0x10147024&lt;br /&gt;
| 2&lt;br /&gt;
| 0x40, 0x80, 0x100, 0x200, 0x400, 0x800, 0x1000, 0x2000, 0x4000, 0x8000, 0x10000, 0x20000&lt;br /&gt;
|-&lt;br /&gt;
| ?&lt;br /&gt;
| [[#0x10147026|0x10147026]]&lt;br /&gt;
| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA4&lt;br /&gt;
| 0x10147028&lt;br /&gt;
| 2&lt;br /&gt;
| 0x40000&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Legacy RTC ==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Name&lt;br /&gt;
!  Address&lt;br /&gt;
!  Width&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| RTC_CNT (?)&lt;br /&gt;
| 0x10147100&lt;br /&gt;
| 2&lt;br /&gt;
| ???&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_STAT1&lt;br /&gt;
| 0x10147110&lt;br /&gt;
| 1&lt;br /&gt;
| Rtc status register 1 (command 0). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_STAT2&lt;br /&gt;
| 0x10147111&lt;br /&gt;
| 1&lt;br /&gt;
| Rtc status register 2 (command 1). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_CLKADJ&lt;br /&gt;
| 0x10147112&lt;br /&gt;
| 1&lt;br /&gt;
| Rtc clock adjustment register (command 6). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_FREE&lt;br /&gt;
| 0x10147113&lt;br /&gt;
| 1&lt;br /&gt;
| The free general purpose rtc register (command 7). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_RAW&lt;br /&gt;
| 0x10147120&lt;br /&gt;
| 4&lt;br /&gt;
| Byte-wise bit-swapped (bit7 is bit0, etc.) BCD RTC (byte0 = seconds, byte1 = minutes, byte2 = hours, byte3 = day(?))&lt;br /&gt;
|-&lt;br /&gt;
| RTC_?&lt;br /&gt;
| 0x10147124&lt;br /&gt;
| 4&lt;br /&gt;
| RTC offset?&lt;br /&gt;
|-&lt;br /&gt;
| RTC_?&lt;br /&gt;
| 0x10147130&lt;br /&gt;
| 4&lt;br /&gt;
| ???&lt;br /&gt;
|-&lt;br /&gt;
| RTC_?&lt;br /&gt;
| 0x10147134&lt;br /&gt;
| 4&lt;br /&gt;
| ???&lt;br /&gt;
|-&lt;br /&gt;
| RTC_?&lt;br /&gt;
| 0x10147140&lt;br /&gt;
| 4&lt;br /&gt;
| Some sort of byte-wise bit-swapped seconds counter&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_FOUT1&lt;br /&gt;
| 0x10147150&lt;br /&gt;
| 1&lt;br /&gt;
| Rtc dsi fout register 1 (ex command 1). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_FOUT2&lt;br /&gt;
| 0x10147151&lt;br /&gt;
| 1&lt;br /&gt;
| Rtc dsi fout register 2 (ex command 2). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_?&lt;br /&gt;
| 0x10147160&lt;br /&gt;
| 4&lt;br /&gt;
| ???&lt;br /&gt;
|-&lt;br /&gt;
| RTC_?&lt;br /&gt;
| 0x10147164&lt;br /&gt;
| 4&lt;br /&gt;
| ???&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
= Descriptions =&lt;br /&gt;
&lt;br /&gt;
== 0x10147010 ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 24&lt;br /&gt;
| Enable/disable? GPIO interrupt 0x64 (bitmask 0x8)&lt;br /&gt;
|-&lt;br /&gt;
| 25&lt;br /&gt;
| Enable/disable? GPIO interrupt 0x66 (bitmask 0x10)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== 0x10147026 ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0-8&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 9&lt;br /&gt;
| Enable/disable interrupt 0x71.&lt;br /&gt;
|-&lt;br /&gt;
| 10-15&lt;br /&gt;
| ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== GPIO_DATA ==&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA0 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0-2&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x7.&lt;br /&gt;
|-&lt;br /&gt;
| 1&lt;br /&gt;
| DS EXTKEYIN Pen down (0 = touching, 1 = not touching)&lt;br /&gt;
|-&lt;br /&gt;
| 3&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|-&lt;br /&gt;
| 4&lt;br /&gt;
| Only used by [[Bootloader|Boot11]].&lt;br /&gt;
|-&lt;br /&gt;
| 5-15&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA1 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0-1&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x18.&lt;br /&gt;
|-&lt;br /&gt;
| 2-31&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA2 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x20.&lt;br /&gt;
|-&lt;br /&gt;
| 1-15&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA3 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0-11&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x3FFC0.&lt;br /&gt;
|-&lt;br /&gt;
| 12-31&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA4 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x40000.&lt;br /&gt;
|-&lt;br /&gt;
| 1-15&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
= Default values =&lt;br /&gt;
&lt;br /&gt;
After bootrom initialization, these are the values of the registers:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Address&lt;br /&gt;
!  Value&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147000&lt;br /&gt;
| 0x0003&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147010&lt;br /&gt;
| 0x00000002&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147014&lt;br /&gt;
| 0x0000&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147020&lt;br /&gt;
| 0x00000DFB&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147024&lt;br /&gt;
| 0x00000000&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147028&lt;br /&gt;
| 0x0000&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Gericom</name></author>
	</entry>
	<entry>
		<id>https://www.3dbrew.org/w/index.php?title=GPIO_Registers&amp;diff=21044</id>
		<title>GPIO Registers</title>
		<link rel="alternate" type="text/html" href="https://www.3dbrew.org/w/index.php?title=GPIO_Registers&amp;diff=21044"/>
		<updated>2019-09-21T09:08:00Z</updated>

		<summary type="html">&lt;p&gt;Gericom: /* Legacy RTC */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Registers =&lt;br /&gt;
&lt;br /&gt;
== GPIO ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Name&lt;br /&gt;
!  Address&lt;br /&gt;
!  Width&lt;br /&gt;
!  GPIO [[GPIO_Services|bitmasks]] associated with this register&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA0&lt;br /&gt;
| 0x10147000&lt;br /&gt;
| 2&lt;br /&gt;
| 0x1, 0x2, 0x4&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA1&lt;br /&gt;
| [[#0x10147010|0x10147010]]&lt;br /&gt;
| 4&lt;br /&gt;
| 0x8, 0x10&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA2&lt;br /&gt;
| 0x10147014&lt;br /&gt;
| 2&lt;br /&gt;
| 0x20&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA3&lt;br /&gt;
| 0x10147020&lt;br /&gt;
| 2&lt;br /&gt;
| 0x40, 0x80, 0x100, 0x200, 0x400, 0x800, 0x1000, 0x2000, 0x4000, 0x8000, 0x10000, 0x20000&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA3_INTERRUPT_CLEAR&lt;br /&gt;
| 0x10147022&lt;br /&gt;
| 2&lt;br /&gt;
| 0x40, 0x80, 0x100, 0x200, 0x400, 0x800, 0x1000, 0x2000, 0x4000, 0x8000, 0x10000, 0x20000&lt;br /&gt;
|-&lt;br /&gt;
| ??&lt;br /&gt;
| 0x10147024&lt;br /&gt;
| 2&lt;br /&gt;
| 0x40, 0x80, 0x100, 0x200, 0x400, 0x800, 0x1000, 0x2000, 0x4000, 0x8000, 0x10000, 0x20000&lt;br /&gt;
|-&lt;br /&gt;
| ?&lt;br /&gt;
| [[#0x10147026|0x10147026]]&lt;br /&gt;
| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA4&lt;br /&gt;
| 0x10147028&lt;br /&gt;
| 2&lt;br /&gt;
| 0x40000&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Legacy RTC ==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Name&lt;br /&gt;
!  Address&lt;br /&gt;
!  Width&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| RTC_CNT (?)&lt;br /&gt;
| 0x10147100&lt;br /&gt;
| 2&lt;br /&gt;
| ???&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_STAT1&lt;br /&gt;
| 0x10147110&lt;br /&gt;
| 1&lt;br /&gt;
| Rtc status register 1 (command 0). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_STAT2&lt;br /&gt;
| 0x10147111&lt;br /&gt;
| 1&lt;br /&gt;
| Rtc status register 2 (command 1). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_CLKADJ&lt;br /&gt;
| 0x10147112&lt;br /&gt;
| 1&lt;br /&gt;
| Rtc clock adjustment register (command 6). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_FREE&lt;br /&gt;
| 0x10147113&lt;br /&gt;
| 1&lt;br /&gt;
| The free general purpose rtc register (command 7). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_RAW&lt;br /&gt;
| 0x10147120&lt;br /&gt;
| 4&lt;br /&gt;
| Byte-wise bit-swapped (bit7 is bit0, etc.) BCD RTC (byte0 = seconds, byte1 = minutes, byte2 = hours, byte3 = day(?))&lt;br /&gt;
|-&lt;br /&gt;
| RTC_?&lt;br /&gt;
| 0x10147124&lt;br /&gt;
| 4&lt;br /&gt;
| RTC offset?&lt;br /&gt;
|-&lt;br /&gt;
| RTC_?&lt;br /&gt;
| 0x10147130&lt;br /&gt;
| 4&lt;br /&gt;
| ???&lt;br /&gt;
|-&lt;br /&gt;
| RTC_?&lt;br /&gt;
| 0x10147134&lt;br /&gt;
| 4&lt;br /&gt;
| ???&lt;br /&gt;
|-&lt;br /&gt;
| RTC_?&lt;br /&gt;
| 0x10147140&lt;br /&gt;
| 4&lt;br /&gt;
| Some sort of byte-wise bit-swapped seconds counter&lt;br /&gt;
|-&lt;br /&gt;
| RTC_?&lt;br /&gt;
| 0x10147150&lt;br /&gt;
| 1&lt;br /&gt;
| ???&lt;br /&gt;
|-&lt;br /&gt;
| RTC_?&lt;br /&gt;
| 0x10147151&lt;br /&gt;
| 1&lt;br /&gt;
| ???&lt;br /&gt;
|-&lt;br /&gt;
| RTC_?&lt;br /&gt;
| 0x10147160&lt;br /&gt;
| 4&lt;br /&gt;
| ???&lt;br /&gt;
|-&lt;br /&gt;
| RTC_?&lt;br /&gt;
| 0x10147164&lt;br /&gt;
| 4&lt;br /&gt;
| ???&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
= Descriptions =&lt;br /&gt;
&lt;br /&gt;
== 0x10147010 ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 24&lt;br /&gt;
| Enable/disable? GPIO interrupt 0x64 (bitmask 0x8)&lt;br /&gt;
|-&lt;br /&gt;
| 25&lt;br /&gt;
| Enable/disable? GPIO interrupt 0x66 (bitmask 0x10)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== 0x10147026 ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0-8&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 9&lt;br /&gt;
| Enable/disable interrupt 0x71.&lt;br /&gt;
|-&lt;br /&gt;
| 10-15&lt;br /&gt;
| ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== GPIO_DATA ==&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA0 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0-2&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x7.&lt;br /&gt;
|-&lt;br /&gt;
| 1&lt;br /&gt;
| DS EXTKEYIN Pen down (0 = touching, 1 = not touching)&lt;br /&gt;
|-&lt;br /&gt;
| 3&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|-&lt;br /&gt;
| 4&lt;br /&gt;
| Only used by [[Bootloader|Boot11]].&lt;br /&gt;
|-&lt;br /&gt;
| 5-15&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA1 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0-1&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x18.&lt;br /&gt;
|-&lt;br /&gt;
| 2-31&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA2 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x20.&lt;br /&gt;
|-&lt;br /&gt;
| 1-15&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA3 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0-11&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x3FFC0.&lt;br /&gt;
|-&lt;br /&gt;
| 12-31&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA4 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x40000.&lt;br /&gt;
|-&lt;br /&gt;
| 1-15&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
= Default values =&lt;br /&gt;
&lt;br /&gt;
After bootrom initialization, these are the values of the registers:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Address&lt;br /&gt;
!  Value&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147000&lt;br /&gt;
| 0x0003&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147010&lt;br /&gt;
| 0x00000002&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147014&lt;br /&gt;
| 0x0000&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147020&lt;br /&gt;
| 0x00000DFB&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147024&lt;br /&gt;
| 0x00000000&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147028&lt;br /&gt;
| 0x0000&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Gericom</name></author>
	</entry>
	<entry>
		<id>https://www.3dbrew.org/w/index.php?title=GPIO_Registers&amp;diff=21043</id>
		<title>GPIO Registers</title>
		<link rel="alternate" type="text/html" href="https://www.3dbrew.org/w/index.php?title=GPIO_Registers&amp;diff=21043"/>
		<updated>2019-09-21T08:56:49Z</updated>

		<summary type="html">&lt;p&gt;Gericom: Updated some rtc regs&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Registers =&lt;br /&gt;
&lt;br /&gt;
== GPIO ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Name&lt;br /&gt;
!  Address&lt;br /&gt;
!  Width&lt;br /&gt;
!  GPIO [[GPIO_Services|bitmasks]] associated with this register&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA0&lt;br /&gt;
| 0x10147000&lt;br /&gt;
| 2&lt;br /&gt;
| 0x1, 0x2, 0x4&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA1&lt;br /&gt;
| [[#0x10147010|0x10147010]]&lt;br /&gt;
| 4&lt;br /&gt;
| 0x8, 0x10&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA2&lt;br /&gt;
| 0x10147014&lt;br /&gt;
| 2&lt;br /&gt;
| 0x20&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA3&lt;br /&gt;
| 0x10147020&lt;br /&gt;
| 2&lt;br /&gt;
| 0x40, 0x80, 0x100, 0x200, 0x400, 0x800, 0x1000, 0x2000, 0x4000, 0x8000, 0x10000, 0x20000&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA3_INTERRUPT_CLEAR&lt;br /&gt;
| 0x10147022&lt;br /&gt;
| 2&lt;br /&gt;
| 0x40, 0x80, 0x100, 0x200, 0x400, 0x800, 0x1000, 0x2000, 0x4000, 0x8000, 0x10000, 0x20000&lt;br /&gt;
|-&lt;br /&gt;
| ??&lt;br /&gt;
| 0x10147024&lt;br /&gt;
| 2&lt;br /&gt;
| 0x40, 0x80, 0x100, 0x200, 0x400, 0x800, 0x1000, 0x2000, 0x4000, 0x8000, 0x10000, 0x20000&lt;br /&gt;
|-&lt;br /&gt;
| ?&lt;br /&gt;
| [[#0x10147026|0x10147026]]&lt;br /&gt;
| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| GPIO_DATA4&lt;br /&gt;
| 0x10147028&lt;br /&gt;
| 2&lt;br /&gt;
| 0x40000&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Legacy RTC ==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Name&lt;br /&gt;
!  Address&lt;br /&gt;
!  Width&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| RTC_CNT (?)&lt;br /&gt;
| 0x10147100&lt;br /&gt;
| 2&lt;br /&gt;
| ???&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_STAT1&lt;br /&gt;
| 0x10147110&lt;br /&gt;
| 1&lt;br /&gt;
| Rtc status register 1 (command 0). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_STAT2&lt;br /&gt;
| 0x10147111&lt;br /&gt;
| 1&lt;br /&gt;
| Rtc status register 2 (command 1). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_REG_FREE&lt;br /&gt;
| 0x10147113&lt;br /&gt;
| 1&lt;br /&gt;
| The free general purpose rtc register (command 7). Bitswapped&lt;br /&gt;
|-&lt;br /&gt;
| RTC_RAW&lt;br /&gt;
| 0x10147120&lt;br /&gt;
| 4&lt;br /&gt;
| Byte-wise bit-swapped (bit7 is bit0, etc.) BCD RTC (byte0 = seconds, byte1 = minutes, byte2 = hours, byte3 = day(?))&lt;br /&gt;
|-&lt;br /&gt;
| RTC_?&lt;br /&gt;
| 0x10147124&lt;br /&gt;
| 4&lt;br /&gt;
| RTC offset?&lt;br /&gt;
|-&lt;br /&gt;
| RTC_?&lt;br /&gt;
| 0x10147130&lt;br /&gt;
| 4&lt;br /&gt;
| ???&lt;br /&gt;
|-&lt;br /&gt;
| RTC_?&lt;br /&gt;
| 0x10147134&lt;br /&gt;
| 4&lt;br /&gt;
| ???&lt;br /&gt;
|-&lt;br /&gt;
| RTC_?&lt;br /&gt;
| 0x10147140&lt;br /&gt;
| 4&lt;br /&gt;
| Some sort of byte-wise bit-swapped seconds counter&lt;br /&gt;
|-&lt;br /&gt;
| RTC_?&lt;br /&gt;
| 0x10147150&lt;br /&gt;
| 1&lt;br /&gt;
| ???&lt;br /&gt;
|-&lt;br /&gt;
| RTC_?&lt;br /&gt;
| 0x10147151&lt;br /&gt;
| 1&lt;br /&gt;
| ???&lt;br /&gt;
|-&lt;br /&gt;
| RTC_?&lt;br /&gt;
| 0x10147160&lt;br /&gt;
| 4&lt;br /&gt;
| ???&lt;br /&gt;
|-&lt;br /&gt;
| RTC_?&lt;br /&gt;
| 0x10147164&lt;br /&gt;
| 4&lt;br /&gt;
| ???&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
= Descriptions =&lt;br /&gt;
&lt;br /&gt;
== 0x10147010 ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 24&lt;br /&gt;
| Enable/disable? GPIO interrupt 0x64 (bitmask 0x8)&lt;br /&gt;
|-&lt;br /&gt;
| 25&lt;br /&gt;
| Enable/disable? GPIO interrupt 0x66 (bitmask 0x10)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== 0x10147026 ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0-8&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 9&lt;br /&gt;
| Enable/disable interrupt 0x71.&lt;br /&gt;
|-&lt;br /&gt;
| 10-15&lt;br /&gt;
| ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== GPIO_DATA ==&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA0 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0-2&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x7.&lt;br /&gt;
|-&lt;br /&gt;
| 1&lt;br /&gt;
| DS EXTKEYIN Pen down (0 = touching, 1 = not touching)&lt;br /&gt;
|-&lt;br /&gt;
| 3&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|-&lt;br /&gt;
| 4&lt;br /&gt;
| Only used by [[Bootloader|Boot11]].&lt;br /&gt;
|-&lt;br /&gt;
| 5-15&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA1 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0-1&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x18.&lt;br /&gt;
|-&lt;br /&gt;
| 2-31&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA2 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x20.&lt;br /&gt;
|-&lt;br /&gt;
| 1-15&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA3 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0-11&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x3FFC0.&lt;br /&gt;
|-&lt;br /&gt;
| 12-31&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== GPIO_DATA4 ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Bit&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
| 0&lt;br /&gt;
| Used for GPIO [[GPIO_Services|bitmask]] 0x40000.&lt;br /&gt;
|-&lt;br /&gt;
| 1-15&lt;br /&gt;
| Unused by GPIO-sysmodule and TwlBg.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
= Default values =&lt;br /&gt;
&lt;br /&gt;
After bootrom initialization, these are the values of the registers:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
!  Address&lt;br /&gt;
!  Value&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147000&lt;br /&gt;
| 0x0003&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147010&lt;br /&gt;
| 0x00000002&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147014&lt;br /&gt;
| 0x0000&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147020&lt;br /&gt;
| 0x00000DFB&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147024&lt;br /&gt;
| 0x00000000&lt;br /&gt;
|-&lt;br /&gt;
| 0x10147028&lt;br /&gt;
| 0x0000&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Gericom</name></author>
	</entry>
	<entry>
		<id>https://www.3dbrew.org/w/index.php?title=CGFX&amp;diff=9813</id>
		<title>CGFX</title>
		<link rel="alternate" type="text/html" href="https://www.3dbrew.org/w/index.php?title=CGFX&amp;diff=9813"/>
		<updated>2014-09-09T08:30:03Z</updated>

		<summary type="html">&lt;p&gt;Gericom: /* DATA */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;CGFX is a container format used to store graphics resources. It can contain 3D models, textures and animation data.&lt;br /&gt;
&lt;br /&gt;
== CGFX ==&lt;br /&gt;
&lt;br /&gt;
CGFX header :&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Offset&lt;br /&gt;
! Length&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x0&lt;br /&gt;
| 0x4&lt;br /&gt;
| Magic &amp;quot;CGFX&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| 0x4&lt;br /&gt;
| 0x2&lt;br /&gt;
| Byte order mark: FFFE (little endian) or FEFF (big endian)&lt;br /&gt;
|-&lt;br /&gt;
| 0x6&lt;br /&gt;
| 0x4&lt;br /&gt;
| CGFX header size&lt;br /&gt;
|-&lt;br /&gt;
| 0xA&lt;br /&gt;
| 0x2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0xC&lt;br /&gt;
| 0x4&lt;br /&gt;
| File size (bytes)&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
| 0x4&lt;br /&gt;
| Number of entries&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
A typical CGFX file contains two main entries, beginning directly after the CGFX header: DATA and IMAG.&lt;br /&gt;
&lt;br /&gt;
== DATA ==&lt;br /&gt;
&lt;br /&gt;
DATA contains a list of DICT references.&lt;br /&gt;
&lt;br /&gt;
DATA header (for N = 0..15) :&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Offset&lt;br /&gt;
! Length&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x0&lt;br /&gt;
| 0x4&lt;br /&gt;
| Magic &amp;quot;DATA&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| 0x4&lt;br /&gt;
| 0x4&lt;br /&gt;
| DATA Size (in bytes)&lt;br /&gt;
|-&lt;br /&gt;
| 0x8 +(N*8)&lt;br /&gt;
| 0x4&lt;br /&gt;
| Number of entries in DICT N&lt;br /&gt;
|-&lt;br /&gt;
| 0xC +(N*8)&lt;br /&gt;
| 0x4&lt;br /&gt;
| Offset (self-relative) to DICT N&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
The DATA header contains the entry counts and offsets for each DICT entry. The number of entries can vary (probably based on the version?), but are always in the following order. Any unused entries are zeroed.&lt;br /&gt;
&lt;br /&gt;
Typical entries:&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! N&lt;br /&gt;
! Type&lt;br /&gt;
|-&lt;br /&gt;
| 0&lt;br /&gt;
| Models&lt;br /&gt;
|-&lt;br /&gt;
| 1&lt;br /&gt;
| Textures&lt;br /&gt;
|-&lt;br /&gt;
| 2&lt;br /&gt;
| LUTS (Material/Color/Shader look-up tables?)&lt;br /&gt;
|-&lt;br /&gt;
| 3&lt;br /&gt;
| Unknown&lt;br /&gt;
|-&lt;br /&gt;
| 4&lt;br /&gt;
| Unknown&lt;br /&gt;
|-&lt;br /&gt;
| 5&lt;br /&gt;
| Cameras&lt;br /&gt;
|-&lt;br /&gt;
| 6&lt;br /&gt;
| Lights&lt;br /&gt;
|-&lt;br /&gt;
| 7&lt;br /&gt;
| Fog&lt;br /&gt;
|-&lt;br /&gt;
| 8&lt;br /&gt;
| Environments&lt;br /&gt;
|-&lt;br /&gt;
| 9&lt;br /&gt;
| Skeleton animations&lt;br /&gt;
|-&lt;br /&gt;
| 10&lt;br /&gt;
| Texture animations&lt;br /&gt;
|-&lt;br /&gt;
| 11&lt;br /&gt;
| Unknown animations&lt;br /&gt;
|-&lt;br /&gt;
| 12&lt;br /&gt;
| Unknown&lt;br /&gt;
|-&lt;br /&gt;
| 13&lt;br /&gt;
| Unknown&lt;br /&gt;
|-&lt;br /&gt;
| 14&lt;br /&gt;
| Unknown&lt;br /&gt;
|-&lt;br /&gt;
| 15&lt;br /&gt;
| Unknown&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== DICT ==&lt;br /&gt;
&lt;br /&gt;
DICTs are generic structures used to store values (and associate them to a key ?). A DICT header is 0x1C bytes long.&lt;br /&gt;
&lt;br /&gt;
DICT header :&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Offset&lt;br /&gt;
! Length&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x0&lt;br /&gt;
| 0x4&lt;br /&gt;
| Magic &amp;quot;DICT&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| 0x4&lt;br /&gt;
| 0x4&lt;br /&gt;
| DICT size (in bytes)&lt;br /&gt;
|-&lt;br /&gt;
| 0x8&lt;br /&gt;
| 0x4&lt;br /&gt;
| Number of entries&lt;br /&gt;
|-&lt;br /&gt;
| 0xC&lt;br /&gt;
| 0x10&lt;br /&gt;
| ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
DICT entry:&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Offset&lt;br /&gt;
! Length&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x0&lt;br /&gt;
| 0x4&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x4&lt;br /&gt;
| 0x2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x6&lt;br /&gt;
| 0x2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x8&lt;br /&gt;
| 0x4&lt;br /&gt;
| Offset (self-relative) to symbol&lt;br /&gt;
|-&lt;br /&gt;
| 0xC&lt;br /&gt;
| 0x4&lt;br /&gt;
| Value (often offsets)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== CMDL ==&lt;br /&gt;
&lt;br /&gt;
CMDL is used to describe a 3D model.&lt;br /&gt;
&lt;br /&gt;
CMDL Header :&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Offset&lt;br /&gt;
! Length&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x0&lt;br /&gt;
| 0x4&lt;br /&gt;
| Flags (bit 7: hasSkeletonSobj)&lt;br /&gt;
|-&lt;br /&gt;
| 0x4&lt;br /&gt;
| 0x4&lt;br /&gt;
| Magic &amp;quot;CMDL&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| 0x8&lt;br /&gt;
| 0x4&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0xC&lt;br /&gt;
| 0x4&lt;br /&gt;
| Offset (self-relative) to model name&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
| 0x18&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x28&lt;br /&gt;
| 0x4&lt;br /&gt;
| Number of entries in Animation Types DICT&lt;br /&gt;
|-&lt;br /&gt;
| 0x2C&lt;br /&gt;
| 0x4&lt;br /&gt;
| Offset (self-relative) to Animation Types DICT&lt;br /&gt;
|-&lt;br /&gt;
| 0x30&lt;br /&gt;
| 0xC&lt;br /&gt;
| Global scale vector (3 floats : x, y, z)&lt;br /&gt;
|-&lt;br /&gt;
| 0x3C&lt;br /&gt;
| 0x18&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x54&lt;br /&gt;
| 0x30&lt;br /&gt;
| Matrix 1&lt;br /&gt;
|-&lt;br /&gt;
| 0x84&lt;br /&gt;
| 0x30&lt;br /&gt;
| Matrix 2&lt;br /&gt;
|-&lt;br /&gt;
| 0xB4&lt;br /&gt;
| 0x4&lt;br /&gt;
| Number of Vertex Info SOBJ entries&lt;br /&gt;
|-&lt;br /&gt;
| 0xB8&lt;br /&gt;
| 0x4&lt;br /&gt;
| Offset (self-relative) to Vertex Info SOBJ list&lt;br /&gt;
|-&lt;br /&gt;
| 0xBC&lt;br /&gt;
| 0x4&lt;br /&gt;
| Number of MTOB DICT entries&lt;br /&gt;
|-&lt;br /&gt;
| 0xC0&lt;br /&gt;
| 0x4&lt;br /&gt;
| Offset (self-relative) to MTOB DICT&lt;br /&gt;
|-&lt;br /&gt;
| 0xC4&lt;br /&gt;
| 0x4&lt;br /&gt;
| Number of Vertex Info SOBJ entries&lt;br /&gt;
|-&lt;br /&gt;
| 0xC8&lt;br /&gt;
| 0x4&lt;br /&gt;
| Offset (self-relative) to Vertex Info SOBJ list&lt;br /&gt;
|-&lt;br /&gt;
| 0xCC&lt;br /&gt;
| 0x4&lt;br /&gt;
| Number of Unknown DICT entries&lt;br /&gt;
|-&lt;br /&gt;
| 0xD0&lt;br /&gt;
| 0x4&lt;br /&gt;
| Offset (self-relative) to Unknown DICT&lt;br /&gt;
|-&lt;br /&gt;
| 0xD4&lt;br /&gt;
| 0xC&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0xE0&lt;br /&gt;
| 0x4&lt;br /&gt;
| Skeleton Info SOBJ offset (self-relative) [only present if flag bit 7 is set]&lt;br /&gt;
|-&lt;br /&gt;
| 0xB8+[0xB8]&lt;br /&gt;
| 0x4*N&lt;br /&gt;
| Vertex Info SOBJ self-relative offset list&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
A CMDL section refers to outside data; it can not be considered separately from the rest of the CGFX file.&lt;br /&gt;
The second DICT in the CMDL section contains offsets to MTOB objects.&lt;br /&gt;
&lt;br /&gt;
== SOBJ ==&lt;br /&gt;
&lt;br /&gt;
SOBJ structures can be used to describe 3D objects that are part of the model. If such is the case then they will follow this structure :&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Offset&lt;br /&gt;
! Length&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x0&lt;br /&gt;
| 0x3&lt;br /&gt;
| Flags ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x3&lt;br /&gt;
| 0x1&lt;br /&gt;
| SOBJ type ? (0x10 = model, 0x02 = skeleton)&lt;br /&gt;
|-&lt;br /&gt;
| 0x4&lt;br /&gt;
| 0x4&lt;br /&gt;
| Magic &amp;quot;SOBJ&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| 0x44&lt;br /&gt;
| 0x4&lt;br /&gt;
| Y = Offset (self-relative) to bone correspondance array&lt;br /&gt;
|-&lt;br /&gt;
| 0x48&lt;br /&gt;
| 0x4&lt;br /&gt;
| X = Offset (relative to SOBJ magic) to SOBJ data structure (wrong ?)&lt;br /&gt;
|-&lt;br /&gt;
| 0x44+Y+0x00&lt;br /&gt;
| 0x4&lt;br /&gt;
| N = Number of bone IDs in bone correspondance array&lt;br /&gt;
|-&lt;br /&gt;
| 0x44+Y+0x14&lt;br /&gt;
| 0x4*N&lt;br /&gt;
| Bone correspondance array&lt;br /&gt;
|-&lt;br /&gt;
| X+0x18&lt;br /&gt;
| 0x1&lt;br /&gt;
| Face data format (?) : 0x1 = u8, 0x3 = u16&lt;br /&gt;
|-&lt;br /&gt;
| X+0x20&lt;br /&gt;
| 0x4&lt;br /&gt;
| Face data section size (in bytes)&lt;br /&gt;
|-&lt;br /&gt;
| X+0x24&lt;br /&gt;
| 0x4&lt;br /&gt;
| Face data section offset (self-relative)&lt;br /&gt;
|-&lt;br /&gt;
| X+0x58&lt;br /&gt;
| 0x4&lt;br /&gt;
| Vertex data section size (in bytes)&lt;br /&gt;
|-&lt;br /&gt;
| X+0x5C&lt;br /&gt;
| 0x4&lt;br /&gt;
| Vertex data section offset (self-relative)&lt;br /&gt;
|-&lt;br /&gt;
| X+0x68&lt;br /&gt;
| 0x1&lt;br /&gt;
| Vertex data format size (in bytes)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Vertex format size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
| X (float), Y (float), Z (float), U (float), V (float)&lt;br /&gt;
|-&lt;br /&gt;
| 0x18&lt;br /&gt;
| X (float), Y (float), Z (float), Unk (u32?), U (float), V (float)&lt;br /&gt;
|-&lt;br /&gt;
| 0x20&lt;br /&gt;
| X (float), Y (float), Z (float), NX (float), NY (float), NZ (float), U (float), V (float)&lt;br /&gt;
|-&lt;br /&gt;
| 0x28v1&lt;br /&gt;
| X (float), Y (float), Z (float), NX (float), NY (float), NZ (float), U (float), V (float), (local) Bone IDs (4*u8), Bone weights (4*u8)&lt;br /&gt;
|-&lt;br /&gt;
| 0x28v2&lt;br /&gt;
| X (float), Y (float), Z (float), NX (float), NY (float), NZ (float), U (float), V (float), Unk1 (u32), (local) Bone IDs (2*u8), Bone weights (2*u8)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Vertex format 0x28 (and possibly others) supports multiple bone assignment. In this case, the sum of all bone weights is 0x64.&lt;br /&gt;
&lt;br /&gt;
== TXOB ==&lt;br /&gt;
&lt;br /&gt;
TXOBs are contained within MTOBs. They can describe textures; if such is the case, then their structure is as follows :&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Offset&lt;br /&gt;
! Length&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x0&lt;br /&gt;
| 0x4&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x4&lt;br /&gt;
| 0x4&lt;br /&gt;
| Magic &amp;quot;TXOB&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| 0xC&lt;br /&gt;
| 0x4&lt;br /&gt;
| Offset (self-relative) to symbol&lt;br /&gt;
|-&lt;br /&gt;
| 0x18&lt;br /&gt;
| 0x4&lt;br /&gt;
| Texture height&lt;br /&gt;
|-&lt;br /&gt;
| 0x1C&lt;br /&gt;
| 0x4&lt;br /&gt;
| Texture width&lt;br /&gt;
|-&lt;br /&gt;
| 0x28&lt;br /&gt;
| 0x4&lt;br /&gt;
| Mipmap levels&lt;br /&gt;
|-&lt;br /&gt;
| 0x34&lt;br /&gt;
| 0x4&lt;br /&gt;
| Texture format ID (see table below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x3C&lt;br /&gt;
| 0x4&lt;br /&gt;
| Texture height (?)&lt;br /&gt;
|-&lt;br /&gt;
| 0x40&lt;br /&gt;
| 0x4&lt;br /&gt;
| Texture width (?)&lt;br /&gt;
|-&lt;br /&gt;
| 0x44&lt;br /&gt;
| 0x4&lt;br /&gt;
| Texture data size&lt;br /&gt;
|-&lt;br /&gt;
| 0x48&lt;br /&gt;
| 0x4&lt;br /&gt;
| Texture data offset (self-relative)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Texture format ID&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
|0x0&lt;br /&gt;
|RGBA8&lt;br /&gt;
|-&lt;br /&gt;
|0x1&lt;br /&gt;
|RGB8&lt;br /&gt;
|-&lt;br /&gt;
|0x2&lt;br /&gt;
|RGBA5551&lt;br /&gt;
|-&lt;br /&gt;
|0x3&lt;br /&gt;
|RGB565&lt;br /&gt;
|-&lt;br /&gt;
|0x4&lt;br /&gt;
|RGBA4&lt;br /&gt;
|-&lt;br /&gt;
|0x5&lt;br /&gt;
|LA8&lt;br /&gt;
|-&lt;br /&gt;
|0x6&lt;br /&gt;
|HILO8&lt;br /&gt;
|-&lt;br /&gt;
|0x7&lt;br /&gt;
|L8&lt;br /&gt;
|-&lt;br /&gt;
|0x8&lt;br /&gt;
|A8&lt;br /&gt;
|-&lt;br /&gt;
|0x9&lt;br /&gt;
|LA4&lt;br /&gt;
|-&lt;br /&gt;
|0xA&lt;br /&gt;
|L4&lt;br /&gt;
|-&lt;br /&gt;
|0xB&lt;br /&gt;
|A4 ?&lt;br /&gt;
|-&lt;br /&gt;
|0xC&lt;br /&gt;
|ETC1 (see notes below)&lt;br /&gt;
|-&lt;br /&gt;
|0xD&lt;br /&gt;
|ETC1A4 ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Every texture format has its texture data divided into 8x8 tiles. See [[SMDH#Icon_graphics|SMDH]] for more information.&lt;br /&gt;
ETC1 is a compressed texture format which compresses blocks of 4x4 pixels into u64s. These u64 are traditionally stored in big endian; however, nintendo&#039;s implementation stores them in little endian. ETC1 textures are stored in 8x8 tiles; decompressed 4x4 therefore have to be organized accordingly. See [https://gist.github.com/smealum/8897237] for implementation example.&lt;br /&gt;
&lt;br /&gt;
== LUTS ==&lt;br /&gt;
&lt;br /&gt;
Appears to contain color lookup tables possibly for use with shaders.&lt;br /&gt;
&lt;br /&gt;
LUTS Header:&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Offset&lt;br /&gt;
! Length&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x0&lt;br /&gt;
| 0x4&lt;br /&gt;
| Magic &amp;quot;LUTS&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| 0x4&lt;br /&gt;
| 0x2&lt;br /&gt;
| Seems to adhere to powers of 2 (width/height/flags?)&lt;br /&gt;
|-&lt;br /&gt;
| 0x6&lt;br /&gt;
| 0x2&lt;br /&gt;
| Seems to adhere to powers of 2 (width/height/flags?)&lt;br /&gt;
|-&lt;br /&gt;
| 0x8&lt;br /&gt;
| 0x4&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0xC&lt;br /&gt;
| 0x8&lt;br /&gt;
| all zeroes ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
| 0x4&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x18&lt;br /&gt;
| 0x4&lt;br /&gt;
| Offset to DICT (self-relative) ?&lt;br /&gt;
|}&lt;br /&gt;
All observed instances have an otherwise unreferenced DICT section immediately afterward (the last LUTS value being a 0x4, which may describe the relative position of that DICT), which appears to describe material specularity.&lt;br /&gt;
&lt;br /&gt;
== Skeleton data ==&lt;br /&gt;
&lt;br /&gt;
Skeleton data is stored in an array. Each entry is 0xE0 bytes in length and organized this way :&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Offset&lt;br /&gt;
! Length&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x0&lt;br /&gt;
| 0x4&lt;br /&gt;
| Offset (self relative) to name symbol&lt;br /&gt;
|-&lt;br /&gt;
| 0x8&lt;br /&gt;
| 0x4&lt;br /&gt;
| Joint ID&lt;br /&gt;
|-&lt;br /&gt;
| 0xC&lt;br /&gt;
| 0x4&lt;br /&gt;
| Parent joint ID&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
| 0x4&lt;br /&gt;
| Signed offset (self-relative) to parent joint&lt;br /&gt;
|-&lt;br /&gt;
| 0x2C&lt;br /&gt;
| 0xC&lt;br /&gt;
| Angle vector (floats, x, y, z)&lt;br /&gt;
|-&lt;br /&gt;
| 0x38&lt;br /&gt;
| 0xC&lt;br /&gt;
| Position vector (floats, x, y, z)&lt;br /&gt;
|-&lt;br /&gt;
| 0x44&lt;br /&gt;
| 0x30&lt;br /&gt;
| Transformation matrix (4x3)&lt;br /&gt;
|-&lt;br /&gt;
| 0x70&lt;br /&gt;
| 0x30&lt;br /&gt;
| Identity matrix ? (4x3)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Each entry stores the joint transformation data twice; once as angle/position vectors and once as a transformation matrix. Each entry also stores a second matrix which appears to always be identity. (?)&lt;br /&gt;
&lt;br /&gt;
== CANM ==&lt;br /&gt;
&lt;br /&gt;
CANMs are used to store skeletal animation data.&lt;br /&gt;
&lt;br /&gt;
== Links ==&lt;br /&gt;
* Another CGFX Format Description: [http://florian.nouwt.com/wiki/index.php/CGFX_(File_Format) http://florian.nouwt.com/wiki/index.php/CGFX_(File_Format)]&lt;/div&gt;</summary>
		<author><name>Gericom</name></author>
	</entry>
	<entry>
		<id>https://www.3dbrew.org/w/index.php?title=CGFX&amp;diff=9759</id>
		<title>CGFX</title>
		<link rel="alternate" type="text/html" href="https://www.3dbrew.org/w/index.php?title=CGFX&amp;diff=9759"/>
		<updated>2014-09-05T18:13:51Z</updated>

		<summary type="html">&lt;p&gt;Gericom: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;CGFX is a container format used to store graphics resources. It can contain 3D models, textures and animation data.&lt;br /&gt;
&lt;br /&gt;
== CGFX ==&lt;br /&gt;
&lt;br /&gt;
CGFX header :&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Offset&lt;br /&gt;
! Length&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x0&lt;br /&gt;
| 0x4&lt;br /&gt;
| Magic &amp;quot;CGFX&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| 0x4&lt;br /&gt;
| 0xC&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
| 0x4&lt;br /&gt;
| Number of entries&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
A typical CGFX file contains two main entries, beginning directly after the CGFX header: DATA and IMAG.&lt;br /&gt;
&lt;br /&gt;
== DATA ==&lt;br /&gt;
&lt;br /&gt;
DATA contains a list of DICT references.&lt;br /&gt;
&lt;br /&gt;
DATA header (for N = 0..15) :&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Offset&lt;br /&gt;
! Length&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x0&lt;br /&gt;
| 0x4&lt;br /&gt;
| Magic &amp;quot;DATA&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| 0x4&lt;br /&gt;
| 0x4&lt;br /&gt;
| DATA Size (in bytes)&lt;br /&gt;
|-&lt;br /&gt;
| 0x8 +(N*8)&lt;br /&gt;
| 0x4&lt;br /&gt;
| Number of entries in DICT N&lt;br /&gt;
|-&lt;br /&gt;
| 0xC +(N*8)&lt;br /&gt;
| 0x4&lt;br /&gt;
| Offset (self-relative) to DICT N&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
The DATA header contains the entry counts and offsets for each DICT entry, and holds sixteen such references. Unused references are zero-padded.&lt;br /&gt;
&lt;br /&gt;
== DICT ==&lt;br /&gt;
&lt;br /&gt;
DICTs are generic structures used to store values (and associate them to a key ?). A DICT header is 0x1C bytes long.&lt;br /&gt;
&lt;br /&gt;
DICT header :&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Offset&lt;br /&gt;
! Length&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x0&lt;br /&gt;
| 0x4&lt;br /&gt;
| Magic &amp;quot;DICT&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| 0x4&lt;br /&gt;
| 0x4&lt;br /&gt;
| DICT size (in bytes)&lt;br /&gt;
|-&lt;br /&gt;
| 0x8&lt;br /&gt;
| 0x4&lt;br /&gt;
| Number of entries&lt;br /&gt;
|-&lt;br /&gt;
| 0xC&lt;br /&gt;
| 0x10&lt;br /&gt;
| ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
DICT entry:&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Offset&lt;br /&gt;
! Length&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x0&lt;br /&gt;
| 0x4&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x4&lt;br /&gt;
| 0x2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x6&lt;br /&gt;
| 0x2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x8&lt;br /&gt;
| 0x4&lt;br /&gt;
| Offset (self-relative) to symbol&lt;br /&gt;
|-&lt;br /&gt;
| 0xC&lt;br /&gt;
| 0x4&lt;br /&gt;
| Value (often offsets)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== CMDL ==&lt;br /&gt;
&lt;br /&gt;
CMDL is used to describe a 3D model.&lt;br /&gt;
&lt;br /&gt;
CMDL Header :&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Offset&lt;br /&gt;
! Length&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x0&lt;br /&gt;
| 0x4&lt;br /&gt;
| Magic &amp;quot;CMDL&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| 0x8&lt;br /&gt;
| 0x4&lt;br /&gt;
| CMDL section size (in bytes)&lt;br /&gt;
|-&lt;br /&gt;
| 0x24&lt;br /&gt;
| 0x4&lt;br /&gt;
| Number of entries in first DICT ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x28&lt;br /&gt;
| 0x4&lt;br /&gt;
| Offset (self-relative) to first DICT&lt;br /&gt;
|-&lt;br /&gt;
| 0x2C&lt;br /&gt;
| 0xC&lt;br /&gt;
| Global scale vector (3 floats : x, y, z)&lt;br /&gt;
|-&lt;br /&gt;
| 0xB0&lt;br /&gt;
| 0x4&lt;br /&gt;
| N/2, where N is the number of entries in SOBJ list&lt;br /&gt;
|-&lt;br /&gt;
| 0xB4&lt;br /&gt;
| 0x4&lt;br /&gt;
| Offset (self-relative) to SOBJ list&lt;br /&gt;
|-&lt;br /&gt;
| 0xBC&lt;br /&gt;
| 0x4&lt;br /&gt;
| Offset (self-relative) to MTOB DICT&lt;br /&gt;
|-&lt;br /&gt;
| 0xB4+[0xB4]&lt;br /&gt;
| 0x4*N*2&lt;br /&gt;
| SOBJ list; each word is an offset (self-relative) to an SOBJ structure&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
A CMDL section refers to outside data; it can not be considered separately from the rest of the CGFX file.&lt;br /&gt;
The second DICT in the CMDL section contains offsets to MTOB objects.&lt;br /&gt;
&lt;br /&gt;
== SOBJ ==&lt;br /&gt;
&lt;br /&gt;
SOBJ structures can be used to describe 3D objects that are part of the model. If such is the case then they will follow this structure :&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Offset&lt;br /&gt;
! Length&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x0&lt;br /&gt;
| 0x3&lt;br /&gt;
| Flags ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x3&lt;br /&gt;
| 0x1&lt;br /&gt;
| SOBJ type ? (0x10 = model, 0x02 = skeleton)&lt;br /&gt;
|-&lt;br /&gt;
| 0x4&lt;br /&gt;
| 0x4&lt;br /&gt;
| Magic &amp;quot;SOBJ&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| 0x44&lt;br /&gt;
| 0x4&lt;br /&gt;
| Y = Offset (self-relative) to bone correspondance array&lt;br /&gt;
|-&lt;br /&gt;
| 0x48&lt;br /&gt;
| 0x4&lt;br /&gt;
| X = Offset (relative to SOBJ magic) to SOBJ data structure (wrong ?)&lt;br /&gt;
|-&lt;br /&gt;
| 0x44+Y+0x00&lt;br /&gt;
| 0x4&lt;br /&gt;
| N = Number of bone IDs in bone correspondance array&lt;br /&gt;
|-&lt;br /&gt;
| 0x44+Y+0x14&lt;br /&gt;
| 0x4*N&lt;br /&gt;
| Bone correspondance array&lt;br /&gt;
|-&lt;br /&gt;
| X+0x18&lt;br /&gt;
| 0x1&lt;br /&gt;
| Face data format (?) : 0x1 = u8, 0x3 = u16&lt;br /&gt;
|-&lt;br /&gt;
| X+0x20&lt;br /&gt;
| 0x4&lt;br /&gt;
| Face data section size (in bytes)&lt;br /&gt;
|-&lt;br /&gt;
| X+0x24&lt;br /&gt;
| 0x4&lt;br /&gt;
| Face data section offset (self-relative)&lt;br /&gt;
|-&lt;br /&gt;
| X+0x58&lt;br /&gt;
| 0x4&lt;br /&gt;
| Vertex data section size (in bytes)&lt;br /&gt;
|-&lt;br /&gt;
| X+0x5C&lt;br /&gt;
| 0x4&lt;br /&gt;
| Vertex data section offset (self-relative)&lt;br /&gt;
|-&lt;br /&gt;
| X+0x68&lt;br /&gt;
| 0x1&lt;br /&gt;
| Vertex data format size (in bytes)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Vertex format size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
| X (float), Y (float), Z (float), U (float), V (float)&lt;br /&gt;
|-&lt;br /&gt;
| 0x18&lt;br /&gt;
| X (float), Y (float), Z (float), Unk (u32?), U (float), V (float)&lt;br /&gt;
|-&lt;br /&gt;
| 0x20&lt;br /&gt;
| X (float), Y (float), Z (float), NX (float), NY (float), NZ (float), U (float), V (float)&lt;br /&gt;
|-&lt;br /&gt;
| 0x28v1&lt;br /&gt;
| X (float), Y (float), Z (float), NX (float), NY (float), NZ (float), U (float), V (float), (local) Bone IDs (4*u8), Bone weights (4*u8)&lt;br /&gt;
|-&lt;br /&gt;
| 0x28v2&lt;br /&gt;
| X (float), Y (float), Z (float), NX (float), NY (float), NZ (float), U (float), V (float), Unk1 (u32), (local) Bone IDs (2*u8), Bone weights (2*u8)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Vertex format 0x28 (and possibly others) supports multiple bone assignment. In this case, the sum of all bone weights is 0x64.&lt;br /&gt;
&lt;br /&gt;
== TXOB ==&lt;br /&gt;
&lt;br /&gt;
TXOBs are contained within MTOBs. They can describe textures; if such is the case, then their structure is as follows :&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Offset&lt;br /&gt;
! Length&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x0&lt;br /&gt;
| 0x4&lt;br /&gt;
| Magic &amp;quot;TXOB&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
| 0x4&lt;br /&gt;
| Texture height&lt;br /&gt;
|-&lt;br /&gt;
| 0x18&lt;br /&gt;
| 0x4&lt;br /&gt;
| Texture width&lt;br /&gt;
|-&lt;br /&gt;
| 0x30&lt;br /&gt;
| 0x1&lt;br /&gt;
| Texture format ID (see table below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x38&lt;br /&gt;
| 0x4&lt;br /&gt;
| Texture height (?)&lt;br /&gt;
|-&lt;br /&gt;
| 0x3C&lt;br /&gt;
| 0x4&lt;br /&gt;
| Texture width (?)&lt;br /&gt;
|-&lt;br /&gt;
| 0x40&lt;br /&gt;
| 0x4&lt;br /&gt;
| Texture data size&lt;br /&gt;
|-&lt;br /&gt;
| 0x44&lt;br /&gt;
| 0x4&lt;br /&gt;
| Texture data offset (self-relative)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Texture format ID&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
|0x0&lt;br /&gt;
|RGBA8&lt;br /&gt;
|-&lt;br /&gt;
|0x1&lt;br /&gt;
|RGB8&lt;br /&gt;
|-&lt;br /&gt;
|0x2&lt;br /&gt;
|RGBA5551&lt;br /&gt;
|-&lt;br /&gt;
|0x3&lt;br /&gt;
|RGB565&lt;br /&gt;
|-&lt;br /&gt;
|0x4&lt;br /&gt;
|RGBA4&lt;br /&gt;
|-&lt;br /&gt;
|0x5&lt;br /&gt;
|LA8&lt;br /&gt;
|-&lt;br /&gt;
|0x6&lt;br /&gt;
|HILO8&lt;br /&gt;
|-&lt;br /&gt;
|0x7&lt;br /&gt;
|L8&lt;br /&gt;
|-&lt;br /&gt;
|0x8&lt;br /&gt;
|A8&lt;br /&gt;
|-&lt;br /&gt;
|0x9&lt;br /&gt;
|LA4&lt;br /&gt;
|-&lt;br /&gt;
|0xA&lt;br /&gt;
|L4&lt;br /&gt;
|-&lt;br /&gt;
|0xB&lt;br /&gt;
|A4 ?&lt;br /&gt;
|-&lt;br /&gt;
|0xC&lt;br /&gt;
|ETC1 (see notes below)&lt;br /&gt;
|-&lt;br /&gt;
|0xD&lt;br /&gt;
|ETC1A4 ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Every texture format has its texture data divided into 8x8 tiles. See [[SMDH#Icon_graphics|SMDH]] for more information.&lt;br /&gt;
ETC1 is a compressed texture format which compresses blocks of 4x4 pixels into u64s. These u64 are traditionally stored in big endian; however, nintendo&#039;s implementation stores them in little endian. ETC1 textures are stored in 8x8 tiles; decompressed 4x4 therefore have to be organized accordingly. See [https://gist.github.com/smealum/8897237] for implementation example.&lt;br /&gt;
&lt;br /&gt;
== LUTS ==&lt;br /&gt;
&lt;br /&gt;
Appears to contain color lookup tables possibly for use with shaders.&lt;br /&gt;
&lt;br /&gt;
LUTS Header:&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Offset&lt;br /&gt;
! Length&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x0&lt;br /&gt;
| 0x4&lt;br /&gt;
| Magic &amp;quot;LUTS&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| 0x4&lt;br /&gt;
| 0x2&lt;br /&gt;
| Seems to adhere to powers of 2 (width/height/flags?)&lt;br /&gt;
|-&lt;br /&gt;
| 0x6&lt;br /&gt;
| 0x2&lt;br /&gt;
| Seems to adhere to powers of 2 (width/height/flags?)&lt;br /&gt;
|-&lt;br /&gt;
| 0x8&lt;br /&gt;
| 0x4&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0xC&lt;br /&gt;
| 0x8&lt;br /&gt;
| all zeroes ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
| 0x4&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x18&lt;br /&gt;
| 0x4&lt;br /&gt;
| Offset to DICT (self-relative) ?&lt;br /&gt;
|}&lt;br /&gt;
All observed instances have an otherwise unreferenced DICT section immediately afterward (the last LUTS value being a 0x4, which may describe the relative position of that DICT), which appears to describe material specularity.&lt;br /&gt;
&lt;br /&gt;
== Skeleton data ==&lt;br /&gt;
&lt;br /&gt;
Skeleton data is stored in an array. Each entry is 0xE0 bytes in length and organized this way :&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Offset&lt;br /&gt;
! Length&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x0&lt;br /&gt;
| 0x4&lt;br /&gt;
| Offset (self relative) to name symbol&lt;br /&gt;
|-&lt;br /&gt;
| 0x8&lt;br /&gt;
| 0x4&lt;br /&gt;
| Joint ID&lt;br /&gt;
|-&lt;br /&gt;
| 0xC&lt;br /&gt;
| 0x4&lt;br /&gt;
| Parent joint ID&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
| 0x4&lt;br /&gt;
| Signed offset (self-relative) to parent joint&lt;br /&gt;
|-&lt;br /&gt;
| 0x2C&lt;br /&gt;
| 0xC&lt;br /&gt;
| Angle vector (floats, x, y, z)&lt;br /&gt;
|-&lt;br /&gt;
| 0x38&lt;br /&gt;
| 0xC&lt;br /&gt;
| Position vector (floats, x, y, z)&lt;br /&gt;
|-&lt;br /&gt;
| 0x44&lt;br /&gt;
| 0x30&lt;br /&gt;
| Transformation matrix (4x3)&lt;br /&gt;
|-&lt;br /&gt;
| 0x70&lt;br /&gt;
| 0x30&lt;br /&gt;
| Identity matrix ? (4x3)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Each entry stores the joint transformation data twice; once as angle/position vectors and once as a transformation matrix. Each entry also stores a second matrix which appears to always be identity. (?)&lt;br /&gt;
&lt;br /&gt;
== CANM ==&lt;br /&gt;
&lt;br /&gt;
CANMs are used to store skeletal animation data.&lt;br /&gt;
&lt;br /&gt;
== Links ==&lt;br /&gt;
* Another CGFX Format Description: [http://florian.nouwt.com/wiki/index.php/CGFX_(File_Format) http://florian.nouwt.com/wiki/index.php/CGFX_(File_Format)]&lt;/div&gt;</summary>
		<author><name>Gericom</name></author>
	</entry>
	<entry>
		<id>https://www.3dbrew.org/w/index.php?title=SHBIN&amp;diff=8737</id>
		<title>SHBIN</title>
		<link rel="alternate" type="text/html" href="https://www.3dbrew.org/w/index.php?title=SHBIN&amp;diff=8737"/>
		<updated>2014-02-26T15:58:51Z</updated>

		<summary type="html">&lt;p&gt;Gericom: /* Instructions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Category:File formats]]&lt;br /&gt;
== Overview ==&lt;br /&gt;
&lt;br /&gt;
The SHBIN (SHader BINary) file is used to contain compiled and linked shader programs. These can include vertex shaders (typically compiled from .vsh files) and geometry shaders (typically compiled from .gsh files, though .asm have been observed).&lt;br /&gt;
In commercial games/apps, SHBIN files can be found as standalone files with the extension .shbin, or contained within .bcsdr files. BCSDR files use CGFX as a container, but the underlying DVLB/DVLP/DVLE structure remains unchanged.&lt;br /&gt;
&lt;br /&gt;
A SHBIN&#039;s structure starts with a header, then a DVLP, then DVLE(s).&lt;br /&gt;
&lt;br /&gt;
== DVLB Header ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!  Offset&lt;br /&gt;
!  Size&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
|  0x0&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Magic &amp;quot;DVLB&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|  0x4&lt;br /&gt;
|  0x4&lt;br /&gt;
|  N = number of DVLEs in SHBIN&lt;br /&gt;
|-&lt;br /&gt;
|  0x8&lt;br /&gt;
|  0x4*N&lt;br /&gt;
|  DVLE offset table; each offset is a u32 relative to the start of the DVLB section&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
The DVLP file comes directly after the header.&lt;br /&gt;
&lt;br /&gt;
== DVLP ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!  Offset&lt;br /&gt;
!  Size&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
|  0x0&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Magic &amp;quot;DVLP&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|  0x4&lt;br /&gt;
|  0x4&lt;br /&gt;
|  ? (Maybe a version number?)&lt;br /&gt;
|-&lt;br /&gt;
|  0x8&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLP start) to the compiled shader binary blob&lt;br /&gt;
|-&lt;br /&gt;
|  0xC&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Size of compiled shader binary blob, in words&lt;br /&gt;
|-&lt;br /&gt;
|  0x10&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLP start) to shader instruction extension table&lt;br /&gt;
|-&lt;br /&gt;
|  0x14&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Number of shader instruction extension table entries (each entry is 8-byte long)&lt;br /&gt;
|-&lt;br /&gt;
|  0x18&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLP start) to filename symbol table&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Instructions ==&lt;br /&gt;
&lt;br /&gt;
=== Encoding ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!Name&lt;br /&gt;
!Description&lt;br /&gt;
!Encoding&lt;br /&gt;
|-&lt;br /&gt;
|DP3&lt;br /&gt;
|Dot product vec3*vec3&lt;br /&gt;
|0000 01DD DDDD ??AA AAAA BBBB BBXX XXXX&lt;br /&gt;
|-&lt;br /&gt;
|DP4&lt;br /&gt;
|Dot product vec4*vec4&lt;br /&gt;
|0000 10DD DDDD ??AA AAAA BBBB BBXX XXXX&lt;br /&gt;
|-&lt;br /&gt;
|MOV&lt;br /&gt;
|Move register&lt;br /&gt;
|0010 01DD DDDD ??AA AAAA 0000 00XX XXXX&lt;br /&gt;
|-&lt;br /&gt;
|?&lt;br /&gt;
|End 2&lt;br /&gt;
|1000 0100 0000 0000 0000 0000 0000 0000&lt;br /&gt;
|-&lt;br /&gt;
|?&lt;br /&gt;
|End 1&lt;br /&gt;
|1000 1000 0000 0000 0000 0000 0000 0000&lt;br /&gt;
|-&lt;br /&gt;
|CAL&lt;br /&gt;
|Call subroutine&lt;br /&gt;
|1001 00SS SSSS SSSS SSSS SSLL LLLL LLLL&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Fields ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!Name&lt;br /&gt;
!Description&lt;br /&gt;
|-&lt;br /&gt;
|D&lt;br /&gt;
|dest register&lt;br /&gt;
|-&lt;br /&gt;
|A&lt;br /&gt;
|opA register&lt;br /&gt;
|-&lt;br /&gt;
|B&lt;br /&gt;
|opB register&lt;br /&gt;
|-&lt;br /&gt;
|X&lt;br /&gt;
|extension id&lt;br /&gt;
|-&lt;br /&gt;
|S&lt;br /&gt;
|absolute offset for subroutine (in words)&lt;br /&gt;
|-&lt;br /&gt;
|L&lt;br /&gt;
|number of instructions to execute in subroutine&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== DVLE ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!  Offset&lt;br /&gt;
!  Size&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
|  0x0&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Magic &amp;quot;DVLE&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|  0x6&lt;br /&gt;
|  0x1&lt;br /&gt;
|  Shader type (0x0 = vertex shader, 0x1 = geometry shader; might contain other flags)&lt;br /&gt;
|-&lt;br /&gt;
|  0x8&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Program&#039;s main offset in binary blob (in words)&lt;br /&gt;
|-&lt;br /&gt;
|  0xC&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Program&#039;s endmain offset in binary blob (in words)&lt;br /&gt;
|-&lt;br /&gt;
|  0x18&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLE start) to unk1 table&lt;br /&gt;
|-&lt;br /&gt;
|  0x1C&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Number of entries in unk1 table (each entry is 0x14-byte long)&lt;br /&gt;
|-&lt;br /&gt;
|  0x20&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLE start) to label table&lt;br /&gt;
|-&lt;br /&gt;
|  0x24&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Number of entries in label table (each entry is 0x10-byte long)&lt;br /&gt;
|-&lt;br /&gt;
|  0x28&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLE start) to unk2 table&lt;br /&gt;
|-&lt;br /&gt;
|  0x2C&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Number of entries in unk2 table (each entry is 0x8-byte long)&lt;br /&gt;
|-&lt;br /&gt;
|  0x30&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLE start) to variable (?) table&lt;br /&gt;
|-&lt;br /&gt;
|  0x34&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Number of entries in variable table (each entry is 0x8-byte long)&lt;br /&gt;
|-&lt;br /&gt;
|  0x38&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLE start) to symbol table&lt;br /&gt;
|-&lt;br /&gt;
|  0x3C&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Size of symbol table (in bytes)&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Label table entry :&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!  Offset&lt;br /&gt;
!  Size&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
|  0x0&lt;br /&gt;
|  0x1&lt;br /&gt;
|  Label ID&lt;br /&gt;
|-&lt;br /&gt;
|  0x4&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to shader program blob start) to label&#039;s location, in words&lt;br /&gt;
|-&lt;br /&gt;
|  0x8&lt;br /&gt;
|  0x4&lt;br /&gt;
|  ?&lt;br /&gt;
|-&lt;br /&gt;
|  0xC&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLE symbol table start) to label&#039;s symbol&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Variable table entry :&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!  Offset&lt;br /&gt;
!  Size&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
|  0x0&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLE symbol table start) to variable&#039;s symbol&lt;br /&gt;
|-&lt;br /&gt;
|  0x4&lt;br /&gt;
|  0x2&lt;br /&gt;
|  Variable start register&lt;br /&gt;
|-&lt;br /&gt;
|  0x6&lt;br /&gt;
|  0x2&lt;br /&gt;
|  Variable end register&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Each DVLE is associated to an individual shader shader program contained in the binary blob. A single shader binary blob may contain multiple shader programs of the same kind.&lt;br /&gt;
&lt;br /&gt;
The data contained in unk1 table is sent over to the GPU.&lt;/div&gt;</summary>
		<author><name>Gericom</name></author>
	</entry>
	<entry>
		<id>https://www.3dbrew.org/w/index.php?title=SHBIN&amp;diff=8736</id>
		<title>SHBIN</title>
		<link rel="alternate" type="text/html" href="https://www.3dbrew.org/w/index.php?title=SHBIN&amp;diff=8736"/>
		<updated>2014-02-26T15:57:11Z</updated>

		<summary type="html">&lt;p&gt;Gericom: /* Encoding */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Category:File formats]]&lt;br /&gt;
== Overview ==&lt;br /&gt;
&lt;br /&gt;
The SHBIN (SHader BINary) file is used to contain compiled and linked shader programs. These can include vertex shaders (typically compiled from .vsh files) and geometry shaders (typically compiled from .gsh files, though .asm have been observed).&lt;br /&gt;
In commercial games/apps, SHBIN files can be found as standalone files with the extension .shbin, or contained within .bcsdr files. BCSDR files use CGFX as a container, but the underlying DVLB/DVLP/DVLE structure remains unchanged.&lt;br /&gt;
&lt;br /&gt;
A SHBIN&#039;s structure starts with a header, then a DVLP, then DVLE(s).&lt;br /&gt;
&lt;br /&gt;
== DVLB Header ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!  Offset&lt;br /&gt;
!  Size&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
|  0x0&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Magic &amp;quot;DVLB&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|  0x4&lt;br /&gt;
|  0x4&lt;br /&gt;
|  N = number of DVLEs in SHBIN&lt;br /&gt;
|-&lt;br /&gt;
|  0x8&lt;br /&gt;
|  0x4*N&lt;br /&gt;
|  DVLE offset table; each offset is a u32 relative to the start of the DVLB section&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
The DVLP file comes directly after the header.&lt;br /&gt;
&lt;br /&gt;
== DVLP ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!  Offset&lt;br /&gt;
!  Size&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
|  0x0&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Magic &amp;quot;DVLP&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|  0x4&lt;br /&gt;
|  0x4&lt;br /&gt;
|  ? (Maybe a version number?)&lt;br /&gt;
|-&lt;br /&gt;
|  0x8&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLP start) to the compiled shader binary blob&lt;br /&gt;
|-&lt;br /&gt;
|  0xC&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Size of compiled shader binary blob, in words&lt;br /&gt;
|-&lt;br /&gt;
|  0x10&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLP start) to shader instruction extension table&lt;br /&gt;
|-&lt;br /&gt;
|  0x14&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Number of shader instruction extension table entries (each entry is 8-byte long)&lt;br /&gt;
|-&lt;br /&gt;
|  0x18&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLP start) to filename symbol table&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Instructions ==&lt;br /&gt;
&lt;br /&gt;
=== Encoding ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!Name&lt;br /&gt;
!Description&lt;br /&gt;
!Encoding&lt;br /&gt;
|-&lt;br /&gt;
|DP3&lt;br /&gt;
|Dot product vec3*vec3&lt;br /&gt;
|0000 01DD DDDD ??AA AAAA BBBB BBXX XXXX&lt;br /&gt;
|-&lt;br /&gt;
|DP4&lt;br /&gt;
|Dot product vec4*vec4&lt;br /&gt;
|0000 10DD DDDD ??AA AAAA BBBB BBXX XXXX&lt;br /&gt;
|-&lt;br /&gt;
|MOV&lt;br /&gt;
|Move register&lt;br /&gt;
|0010 01DD DDDD ??AA AAAA 0000 00XX XXXX&lt;br /&gt;
|-&lt;br /&gt;
|CAL&lt;br /&gt;
|Call subroutine&lt;br /&gt;
|1001 00SS SSSS SSSS SSSS SSLL LLLL LLLL&lt;br /&gt;
|-&lt;br /&gt;
|?&lt;br /&gt;
|End 2&lt;br /&gt;
|1000 0100 0000 0000 0000 0000 0000 0000&lt;br /&gt;
|-&lt;br /&gt;
|?&lt;br /&gt;
|End 1&lt;br /&gt;
|1000 1000 0000 0000 0000 0000 0000 0000&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Fields ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!Name&lt;br /&gt;
!Description&lt;br /&gt;
|-&lt;br /&gt;
|D&lt;br /&gt;
|dest register&lt;br /&gt;
|-&lt;br /&gt;
|A&lt;br /&gt;
|opA register&lt;br /&gt;
|-&lt;br /&gt;
|B&lt;br /&gt;
|opB register&lt;br /&gt;
|-&lt;br /&gt;
|X&lt;br /&gt;
|extension id&lt;br /&gt;
|-&lt;br /&gt;
|S&lt;br /&gt;
|absolute offset for subroutine (in words)&lt;br /&gt;
|-&lt;br /&gt;
|L&lt;br /&gt;
|number of instructions to execute in subroutine&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== DVLE ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!  Offset&lt;br /&gt;
!  Size&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
|  0x0&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Magic &amp;quot;DVLE&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|  0x6&lt;br /&gt;
|  0x1&lt;br /&gt;
|  Shader type (0x0 = vertex shader, 0x1 = geometry shader; might contain other flags)&lt;br /&gt;
|-&lt;br /&gt;
|  0x8&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Program&#039;s main offset in binary blob (in words)&lt;br /&gt;
|-&lt;br /&gt;
|  0xC&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Program&#039;s endmain offset in binary blob (in words)&lt;br /&gt;
|-&lt;br /&gt;
|  0x18&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLE start) to unk1 table&lt;br /&gt;
|-&lt;br /&gt;
|  0x1C&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Number of entries in unk1 table (each entry is 0x14-byte long)&lt;br /&gt;
|-&lt;br /&gt;
|  0x20&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLE start) to label table&lt;br /&gt;
|-&lt;br /&gt;
|  0x24&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Number of entries in label table (each entry is 0x10-byte long)&lt;br /&gt;
|-&lt;br /&gt;
|  0x28&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLE start) to unk2 table&lt;br /&gt;
|-&lt;br /&gt;
|  0x2C&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Number of entries in unk2 table (each entry is 0x8-byte long)&lt;br /&gt;
|-&lt;br /&gt;
|  0x30&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLE start) to variable (?) table&lt;br /&gt;
|-&lt;br /&gt;
|  0x34&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Number of entries in variable table (each entry is 0x8-byte long)&lt;br /&gt;
|-&lt;br /&gt;
|  0x38&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLE start) to symbol table&lt;br /&gt;
|-&lt;br /&gt;
|  0x3C&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Size of symbol table (in bytes)&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Label table entry :&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!  Offset&lt;br /&gt;
!  Size&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
|  0x0&lt;br /&gt;
|  0x1&lt;br /&gt;
|  Label ID&lt;br /&gt;
|-&lt;br /&gt;
|  0x4&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to shader program blob start) to label&#039;s location, in words&lt;br /&gt;
|-&lt;br /&gt;
|  0x8&lt;br /&gt;
|  0x4&lt;br /&gt;
|  ?&lt;br /&gt;
|-&lt;br /&gt;
|  0xC&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLE symbol table start) to label&#039;s symbol&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Variable table entry :&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!  Offset&lt;br /&gt;
!  Size&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
|  0x0&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLE symbol table start) to variable&#039;s symbol&lt;br /&gt;
|-&lt;br /&gt;
|  0x4&lt;br /&gt;
|  0x2&lt;br /&gt;
|  Variable start register&lt;br /&gt;
|-&lt;br /&gt;
|  0x6&lt;br /&gt;
|  0x2&lt;br /&gt;
|  Variable end register&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Each DVLE is associated to an individual shader shader program contained in the binary blob. A single shader binary blob may contain multiple shader programs of the same kind.&lt;br /&gt;
&lt;br /&gt;
The data contained in unk1 table is sent over to the GPU.&lt;/div&gt;</summary>
		<author><name>Gericom</name></author>
	</entry>
	<entry>
		<id>https://www.3dbrew.org/w/index.php?title=SHBIN&amp;diff=8735</id>
		<title>SHBIN</title>
		<link rel="alternate" type="text/html" href="https://www.3dbrew.org/w/index.php?title=SHBIN&amp;diff=8735"/>
		<updated>2014-02-26T15:54:11Z</updated>

		<summary type="html">&lt;p&gt;Gericom: Better use this for naming opcodes: http://www.renderguild.com/gpuguide.pdf&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Category:File formats]]&lt;br /&gt;
== Overview ==&lt;br /&gt;
&lt;br /&gt;
The SHBIN (SHader BINary) file is used to contain compiled and linked shader programs. These can include vertex shaders (typically compiled from .vsh files) and geometry shaders (typically compiled from .gsh files, though .asm have been observed).&lt;br /&gt;
In commercial games/apps, SHBIN files can be found as standalone files with the extension .shbin, or contained within .bcsdr files. BCSDR files use CGFX as a container, but the underlying DVLB/DVLP/DVLE structure remains unchanged.&lt;br /&gt;
&lt;br /&gt;
A SHBIN&#039;s structure starts with a header, then a DVLP, then DVLE(s).&lt;br /&gt;
&lt;br /&gt;
== DVLB Header ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!  Offset&lt;br /&gt;
!  Size&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
|  0x0&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Magic &amp;quot;DVLB&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|  0x4&lt;br /&gt;
|  0x4&lt;br /&gt;
|  N = number of DVLEs in SHBIN&lt;br /&gt;
|-&lt;br /&gt;
|  0x8&lt;br /&gt;
|  0x4*N&lt;br /&gt;
|  DVLE offset table; each offset is a u32 relative to the start of the DVLB section&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
The DVLP file comes directly after the header.&lt;br /&gt;
&lt;br /&gt;
== DVLP ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!  Offset&lt;br /&gt;
!  Size&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
|  0x0&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Magic &amp;quot;DVLP&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|  0x4&lt;br /&gt;
|  0x4&lt;br /&gt;
|  ? (Maybe a version number?)&lt;br /&gt;
|-&lt;br /&gt;
|  0x8&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLP start) to the compiled shader binary blob&lt;br /&gt;
|-&lt;br /&gt;
|  0xC&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Size of compiled shader binary blob, in words&lt;br /&gt;
|-&lt;br /&gt;
|  0x10&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLP start) to shader instruction extension table&lt;br /&gt;
|-&lt;br /&gt;
|  0x14&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Number of shader instruction extension table entries (each entry is 8-byte long)&lt;br /&gt;
|-&lt;br /&gt;
|  0x18&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLP start) to filename symbol table&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Instructions ==&lt;br /&gt;
&lt;br /&gt;
=== Encoding ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!Name&lt;br /&gt;
!Description&lt;br /&gt;
!Encoding&lt;br /&gt;
|-&lt;br /&gt;
|DP3&lt;br /&gt;
|Dot product vec3*vec3&lt;br /&gt;
|0000 01DD DDDD ??AA AAAA BBBB BBXX XXXX&lt;br /&gt;
|-&lt;br /&gt;
|DP4&lt;br /&gt;
|Dot product vec4*vec4&lt;br /&gt;
|0000 10DD DDDD ??AA AAAA BBBB BBXX XXXX&lt;br /&gt;
|-&lt;br /&gt;
|MOV&lt;br /&gt;
|Move register&lt;br /&gt;
|0010 01DD DDDD ??AA AAAA 0000 00XX XXXX&lt;br /&gt;
|-&lt;br /&gt;
|CAL&lt;br /&gt;
|Call subroutine&lt;br /&gt;
|1001 00SS SSSS SSSS SSSS SSLL LLLL LLLL&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Fields ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!Name&lt;br /&gt;
!Description&lt;br /&gt;
|-&lt;br /&gt;
|D&lt;br /&gt;
|dest register&lt;br /&gt;
|-&lt;br /&gt;
|A&lt;br /&gt;
|opA register&lt;br /&gt;
|-&lt;br /&gt;
|B&lt;br /&gt;
|opB register&lt;br /&gt;
|-&lt;br /&gt;
|X&lt;br /&gt;
|extension id&lt;br /&gt;
|-&lt;br /&gt;
|S&lt;br /&gt;
|absolute offset for subroutine (in words)&lt;br /&gt;
|-&lt;br /&gt;
|L&lt;br /&gt;
|number of instructions to execute in subroutine&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== DVLE ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!  Offset&lt;br /&gt;
!  Size&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
|  0x0&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Magic &amp;quot;DVLE&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|  0x6&lt;br /&gt;
|  0x1&lt;br /&gt;
|  Shader type (0x0 = vertex shader, 0x1 = geometry shader; might contain other flags)&lt;br /&gt;
|-&lt;br /&gt;
|  0x8&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Program&#039;s main offset in binary blob (in words)&lt;br /&gt;
|-&lt;br /&gt;
|  0xC&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Program&#039;s endmain offset in binary blob (in words)&lt;br /&gt;
|-&lt;br /&gt;
|  0x18&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLE start) to unk1 table&lt;br /&gt;
|-&lt;br /&gt;
|  0x1C&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Number of entries in unk1 table (each entry is 0x14-byte long)&lt;br /&gt;
|-&lt;br /&gt;
|  0x20&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLE start) to label table&lt;br /&gt;
|-&lt;br /&gt;
|  0x24&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Number of entries in label table (each entry is 0x10-byte long)&lt;br /&gt;
|-&lt;br /&gt;
|  0x28&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLE start) to unk2 table&lt;br /&gt;
|-&lt;br /&gt;
|  0x2C&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Number of entries in unk2 table (each entry is 0x8-byte long)&lt;br /&gt;
|-&lt;br /&gt;
|  0x30&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLE start) to variable (?) table&lt;br /&gt;
|-&lt;br /&gt;
|  0x34&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Number of entries in variable table (each entry is 0x8-byte long)&lt;br /&gt;
|-&lt;br /&gt;
|  0x38&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLE start) to symbol table&lt;br /&gt;
|-&lt;br /&gt;
|  0x3C&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Size of symbol table (in bytes)&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Label table entry :&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!  Offset&lt;br /&gt;
!  Size&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
|  0x0&lt;br /&gt;
|  0x1&lt;br /&gt;
|  Label ID&lt;br /&gt;
|-&lt;br /&gt;
|  0x4&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to shader program blob start) to label&#039;s location, in words&lt;br /&gt;
|-&lt;br /&gt;
|  0x8&lt;br /&gt;
|  0x4&lt;br /&gt;
|  ?&lt;br /&gt;
|-&lt;br /&gt;
|  0xC&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLE symbol table start) to label&#039;s symbol&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Variable table entry :&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!  Offset&lt;br /&gt;
!  Size&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
|  0x0&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLE symbol table start) to variable&#039;s symbol&lt;br /&gt;
|-&lt;br /&gt;
|  0x4&lt;br /&gt;
|  0x2&lt;br /&gt;
|  Variable start register&lt;br /&gt;
|-&lt;br /&gt;
|  0x6&lt;br /&gt;
|  0x2&lt;br /&gt;
|  Variable end register&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Each DVLE is associated to an individual shader shader program contained in the binary blob. A single shader binary blob may contain multiple shader programs of the same kind.&lt;br /&gt;
&lt;br /&gt;
The data contained in unk1 table is sent over to the GPU.&lt;/div&gt;</summary>
		<author><name>Gericom</name></author>
	</entry>
	<entry>
		<id>https://www.3dbrew.org/w/index.php?title=SHBIN&amp;diff=8733</id>
		<title>SHBIN</title>
		<link rel="alternate" type="text/html" href="https://www.3dbrew.org/w/index.php?title=SHBIN&amp;diff=8733"/>
		<updated>2014-02-26T14:32:29Z</updated>

		<summary type="html">&lt;p&gt;Gericom: /* DVLP */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Category:File formats]]&lt;br /&gt;
== Overview ==&lt;br /&gt;
&lt;br /&gt;
The SHBIN (SHader BINary) file is used to contain compiled and linked shader programs. These can include vertex shaders (typically compiled from .vsh files) and geometry shaders (typically compiled from .gsh files, though .asm have been observed).&lt;br /&gt;
In commercial games/apps, SHBIN files can be found as standalone files with the extension .shbin, or contained within .bcsdr files. BCSDR files use CGFX as a container, but the underlying DVLB/DVLP/DVLE structure remains unchanged.&lt;br /&gt;
&lt;br /&gt;
A SHBIN&#039;s structure starts with a header, then a DVLP, then DVLE(s).&lt;br /&gt;
&lt;br /&gt;
== DVLB Header ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!  Offset&lt;br /&gt;
!  Size&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
|  0x0&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Magic &amp;quot;DVLB&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|  0x4&lt;br /&gt;
|  0x4&lt;br /&gt;
|  N = number of DVLEs in SHBIN&lt;br /&gt;
|-&lt;br /&gt;
|  0x8&lt;br /&gt;
|  0x4*N&lt;br /&gt;
|  DVLE offset table; each offset is a u32 relative to the start of the DVLB section&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
The DVLP file comes directly after the header.&lt;br /&gt;
&lt;br /&gt;
== DVLP ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!  Offset&lt;br /&gt;
!  Size&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
|  0x0&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Magic &amp;quot;DVLP&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|  0x4&lt;br /&gt;
|  0x4&lt;br /&gt;
|  ? (Maybe a version number?)&lt;br /&gt;
|-&lt;br /&gt;
|  0x8&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLP start) to the compiled shader binary blob&lt;br /&gt;
|-&lt;br /&gt;
|  0xC&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Size of compiled shader binary blob, in words&lt;br /&gt;
|-&lt;br /&gt;
|  0x10&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLP start) to shader instruction extension table&lt;br /&gt;
|-&lt;br /&gt;
|  0x14&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Number of shader instruction extension table entries (each entry is 8-byte long)&lt;br /&gt;
|-&lt;br /&gt;
|  0x18&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLP start) to filename symbol table&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Opcodes ===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!Opcode&lt;br /&gt;
!Description&lt;br /&gt;
|-&lt;br /&gt;
|0x02&lt;br /&gt;
|DP4&lt;br /&gt;
|-&lt;br /&gt;
|0x13&lt;br /&gt;
|MOV&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== DVLE ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!  Offset&lt;br /&gt;
!  Size&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
|  0x0&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Magic &amp;quot;DVLE&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|  0x6&lt;br /&gt;
|  0x1&lt;br /&gt;
|  Shader type (0x0 = vertex shader, 0x1 = geometry shader; might contain other flags)&lt;br /&gt;
|-&lt;br /&gt;
|  0x8&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Program&#039;s main offset in binary blob (in words)&lt;br /&gt;
|-&lt;br /&gt;
|  0xC&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Program&#039;s endmain offset in binary blob (in words)&lt;br /&gt;
|-&lt;br /&gt;
|  0x18&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLE start) to unk1 table&lt;br /&gt;
|-&lt;br /&gt;
|  0x1C&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Number of entries in unk1 table (each entry is 0x14-byte long)&lt;br /&gt;
|-&lt;br /&gt;
|  0x20&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLE start) to label table&lt;br /&gt;
|-&lt;br /&gt;
|  0x24&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Number of entries in label table (each entry is 0x10-byte long)&lt;br /&gt;
|-&lt;br /&gt;
|  0x28&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLE start) to unk2 table&lt;br /&gt;
|-&lt;br /&gt;
|  0x2C&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Number of entries in unk2 table (each entry is 0x8-byte long)&lt;br /&gt;
|-&lt;br /&gt;
|  0x30&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLE start) to variable (?) table&lt;br /&gt;
|-&lt;br /&gt;
|  0x34&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Number of entries in variable table (each entry is 0x8-byte long)&lt;br /&gt;
|-&lt;br /&gt;
|  0x38&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLE start) to symbol table&lt;br /&gt;
|-&lt;br /&gt;
|  0x3C&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Size of symbol table (in bytes)&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Label table entry :&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!  Offset&lt;br /&gt;
!  Size&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
|  0x0&lt;br /&gt;
|  0x1&lt;br /&gt;
|  Label ID&lt;br /&gt;
|-&lt;br /&gt;
|  0x4&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to shader program blob start) to label&#039;s location, in words&lt;br /&gt;
|-&lt;br /&gt;
|  0x8&lt;br /&gt;
|  0x4&lt;br /&gt;
|  ?&lt;br /&gt;
|-&lt;br /&gt;
|  0xC&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLE symbol table start) to label&#039;s symbol&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Variable table entry :&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!  Offset&lt;br /&gt;
!  Size&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
|  0x0&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLE symbol table start) to variable&#039;s symbol&lt;br /&gt;
|-&lt;br /&gt;
|  0x4&lt;br /&gt;
|  0x2&lt;br /&gt;
|  Variable start register&lt;br /&gt;
|-&lt;br /&gt;
|  0x6&lt;br /&gt;
|  0x2&lt;br /&gt;
|  Variable end register&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Each DVLE is associated to an individual shader shader program contained in the binary blob. A single shader binary blob may contain multiple shader programs of the same kind.&lt;br /&gt;
&lt;br /&gt;
The data contained in unk1 table is sent over to the GPU.&lt;/div&gt;</summary>
		<author><name>Gericom</name></author>
	</entry>
	<entry>
		<id>https://www.3dbrew.org/w/index.php?title=SHBIN&amp;diff=8717</id>
		<title>SHBIN</title>
		<link rel="alternate" type="text/html" href="https://www.3dbrew.org/w/index.php?title=SHBIN&amp;diff=8717"/>
		<updated>2014-02-25T14:25:31Z</updated>

		<summary type="html">&lt;p&gt;Gericom: /* DVLP */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Category:File formats]]&lt;br /&gt;
== Overview ==&lt;br /&gt;
&lt;br /&gt;
The SHBIN (SHader BINary) file is used to contain compiled and linked shader programs. These can include vertex shaders (typically compiled from .vsh files) and geometry shaders (typically compiled from .gsh files, though .asm have been observed).&lt;br /&gt;
In commercial games/apps, SHBIN files can be found as standalone files with the extension .shbin, or contained within .bcsdr files. BCSDR files use CGFX as a container, but the underlying DVLB/DVLP/DVLE structure remains unchanged.&lt;br /&gt;
&lt;br /&gt;
A SHBIN&#039;s structure starts with a header, then a DVLP, then DVLE(s).&lt;br /&gt;
&lt;br /&gt;
== DVLB Header ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!  Offset&lt;br /&gt;
!  Size&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
|  0x0&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Magic &amp;quot;DVLB&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|  0x4&lt;br /&gt;
|  0x4&lt;br /&gt;
|  N = number of DVLEs in SHBIN&lt;br /&gt;
|-&lt;br /&gt;
|  0x8&lt;br /&gt;
|  0x4*N&lt;br /&gt;
|  DVLE offset table; each offset is a u32 relative to the start of the DVLB section&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
The DVLP file comes directly after the header.&lt;br /&gt;
&lt;br /&gt;
== DVLP ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!  Offset&lt;br /&gt;
!  Size&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
|  0x0&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Magic &amp;quot;DVLP&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|  0x4&lt;br /&gt;
|  0x4&lt;br /&gt;
|  ? (Maybe a version number?)&lt;br /&gt;
|-&lt;br /&gt;
|  0x8&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLP start) to shader program binary blob&lt;br /&gt;
|-&lt;br /&gt;
|  0xC&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Size of shader program binary blob, in words&lt;br /&gt;
|-&lt;br /&gt;
|  0x10&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLP start) to shader instruction extension table&lt;br /&gt;
|-&lt;br /&gt;
|  0x14&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Number of shader instruction extension table entries (each entry is 8-byte long)&lt;br /&gt;
|-&lt;br /&gt;
|  0x18&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLP start) to filename symbol table&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== DVLE ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!  Offset&lt;br /&gt;
!  Size&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
|  0x0&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Magic &amp;quot;DVLE&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|  0x18&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLE start) to unk1 table&lt;br /&gt;
|-&lt;br /&gt;
|  0x1C&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Number of entries in unk1 table (each entry is 0x14-byte long)&lt;br /&gt;
|-&lt;br /&gt;
|  0x20&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLE start) to label table&lt;br /&gt;
|-&lt;br /&gt;
|  0x24&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Number of entries in label table (each entry is 0x10-byte long)&lt;br /&gt;
|-&lt;br /&gt;
|  0x28&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLE start) to unk2 table&lt;br /&gt;
|-&lt;br /&gt;
|  0x2C&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Number of entries in unk2 table (each entry is 0x8-byte long)&lt;br /&gt;
|-&lt;br /&gt;
|  0x30&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLE start) to variable (?) table&lt;br /&gt;
|-&lt;br /&gt;
|  0x34&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Number of entries in variable table (each entry is 0x8-byte long)&lt;br /&gt;
|-&lt;br /&gt;
|  0x38&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLE start) to symbol table&lt;br /&gt;
|-&lt;br /&gt;
|  0x3C&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Size of symbol table (in bytes)&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Label table entry :&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!  Offset&lt;br /&gt;
!  Size&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
|  0x0&lt;br /&gt;
|  0x1&lt;br /&gt;
|  Label ID&lt;br /&gt;
|-&lt;br /&gt;
|  0x4&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to shader program blob start) to label&#039;s location, in words&lt;br /&gt;
|-&lt;br /&gt;
|  0x8&lt;br /&gt;
|  0x4&lt;br /&gt;
|  ?&lt;br /&gt;
|-&lt;br /&gt;
|  0xC&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLE symbol table start) to label&#039;s symbol&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Variable table entry :&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!  Offset&lt;br /&gt;
!  Size&lt;br /&gt;
!  Description&lt;br /&gt;
|-&lt;br /&gt;
|  0x0&lt;br /&gt;
|  0x4&lt;br /&gt;
|  Offset (relative to DVLE symbol table start) to variable&#039;s symbol&lt;br /&gt;
|-&lt;br /&gt;
|  0x4&lt;br /&gt;
|  0x2&lt;br /&gt;
|  Variable start register&lt;br /&gt;
|-&lt;br /&gt;
|  0x6&lt;br /&gt;
|  0x2&lt;br /&gt;
|  Variable end register&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Each DVLE is associated to an individual shader pipeline stage. Typically, the first DVLE is associated to the program&#039;s vertex shader and the second is associated to the program&#039;s geometry shader.&lt;/div&gt;</summary>
		<author><name>Gericom</name></author>
	</entry>
	<entry>
		<id>https://www.3dbrew.org/w/index.php?title=Language_selection&amp;diff=3333</id>
		<title>Language selection</title>
		<link rel="alternate" type="text/html" href="https://www.3dbrew.org/w/index.php?title=Language_selection&amp;diff=3333"/>
		<updated>2012-06-19T14:57:12Z</updated>

		<summary type="html">&lt;p&gt;Gericom: Looks a little bit more nice.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Main page box|Language|Main Page/Language_selection}}&lt;br /&gt;
&amp;lt;div style=&amp;quot;margin: -.3em -1em -1em -1em;&amp;quot;&amp;gt;&lt;br /&gt;
{| width=&amp;quot;30%&amp;quot; bgcolor=&amp;quot;#fff&amp;quot; border=&amp;quot;0&amp;quot; cellpadding=&amp;quot;2px&amp;quot; cellspacing=&amp;quot;2px&amp;quot; style=&amp;quot;margin:auto;&amp;quot;&lt;br /&gt;
|- align=&amp;quot;center&amp;quot; bgcolor=&amp;quot;#e7eef6&amp;quot;&lt;br /&gt;
|- valign=&amp;quot;top&amp;quot; style=&amp;quot;background: #F5FAFF;&amp;quot;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;!--&amp;lt;div style=&amp;quot;margin-left:38%&amp;quot;&amp;gt;--&amp;gt;&lt;br /&gt;
[[File:FRFLAG.jpg|alt=&amp;quot;French Flag&amp;quot;|link=Main_Page/Fr|50px]] [[File:JPFLAG.gif|50px| alt=&amp;quot;Japan Flag&amp;quot;| link=メインページ]] [[File:USFLAG.gif|50px| alt=&amp;quot;USA Flag&amp;quot;| link=Main_Page]] [[File:ESFLAG.jpg|alt=&amp;quot;Spain Flag&amp;quot;|link=Main_Page/es|50px]] [[File:Drapeau chine.gif|alt=&amp;quot;China Flag&amp;quot;|link=首页|50px]]&lt;br /&gt;
&amp;lt;!--&amp;lt;/div&amp;gt;--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* [[Translation_Info]]&lt;br /&gt;
&lt;br /&gt;
{{box-footer-empty}}&lt;/div&gt;</summary>
		<author><name>Gericom</name></author>
	</entry>
	<entry>
		<id>https://www.3dbrew.org/w/index.php?title=Games&amp;diff=3332</id>
		<title>Games</title>
		<link rel="alternate" type="text/html" href="https://www.3dbrew.org/w/index.php?title=Games&amp;diff=3332"/>
		<updated>2012-06-19T14:54:56Z</updated>

		<summary type="html">&lt;p&gt;Gericom: Sortable&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page lists off many 3DS games and info about them, as well info about the product code and serial format. If the list is missing a game, and you have info about it, feel free to add it to the list.&lt;br /&gt;
&lt;br /&gt;
Some of these games also have a savegame dumped, which can be downloaded under the Savegame column of the table. Info about the savegames&#039; filesystem can be found on the [[Savegames]] page.&lt;br /&gt;
&lt;br /&gt;
== Game list ==&lt;br /&gt;
Note the [DEMO] in the title name denotes that the game is a demo. Also, when adding games, please keep them in alphabetical order, keeping demos at the start of the list.&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable sortable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! width=&amp;quot;35%&amp;quot; | Title&lt;br /&gt;
! width=&amp;quot;12%&amp;quot; | [[Serials|Serial]]&lt;br /&gt;
! width=&amp;quot;12% | Product Code&lt;br /&gt;
! width=&amp;quot;5%&amp;quot; | EUR (P)&lt;br /&gt;
! width=&amp;quot;5%&amp;quot; | USA (E)&lt;br /&gt;
! width=&amp;quot;5%&amp;quot; | JPN (J)&lt;br /&gt;
! width=&amp;quot;5%&amp;quot; | ROM Size&lt;br /&gt;
! width=&amp;quot;5%&amp;quot; | FLASH Size&lt;br /&gt;
! width=&amp;quot;5%&amp;quot; | FLASH ID&lt;br /&gt;
! width=&amp;quot;5%&amp;quot; | FLASH Chip #&lt;br /&gt;
! width=&amp;quot;6%&amp;quot; | Savegame&lt;br /&gt;
|-&lt;br /&gt;
| [DEMO] Mario Kart 7 (E3)&lt;br /&gt;
| ?&lt;br /&gt;
| CTR-P-AMKU&lt;br /&gt;
| No&lt;br /&gt;
| No&lt;br /&gt;
| No&lt;br /&gt;
| ?&lt;br /&gt;
| ?&lt;br /&gt;
| ?&lt;br /&gt;
| ?&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| [DEMO] Nintendogs+Cats (Kiosk)&lt;br /&gt;
| LNZ-CTR-ADAX&lt;br /&gt;
| CTR-P-ADAX&lt;br /&gt;
| Yes&lt;br /&gt;
| ?&lt;br /&gt;
| ?&lt;br /&gt;
| ?&lt;br /&gt;
| 128kByte&lt;br /&gt;
| 0xC22211&lt;br /&gt;
| 25L1001&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| [DEMO] Steel Diver &lt;br /&gt;
| LNZ-CTR-ASDX&lt;br /&gt;
| CTR-P-ASDX&lt;br /&gt;
| Yes&lt;br /&gt;
| No&lt;br /&gt;
| No&lt;br /&gt;
| ?&lt;br /&gt;
| ?&lt;br /&gt;
| ?&lt;br /&gt;
| ?&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| [DEMO] Super Mario 3D Land &lt;br /&gt;
| LNZ-CTR-AREX&lt;br /&gt;
| CTR-P-AREX &lt;br /&gt;
| Yes&lt;br /&gt;
| No&lt;br /&gt;
| ?&lt;br /&gt;
| ?&lt;br /&gt;
| ?&lt;br /&gt;
| ?&lt;br /&gt;
| ?&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| [DEMO] Super Mario 3D Land (E3)&lt;br /&gt;
| ?&lt;br /&gt;
| CTR-P-CTAP&lt;br /&gt;
| No&lt;br /&gt;
| No&lt;br /&gt;
| No&lt;br /&gt;
| ?&lt;br /&gt;
| ?&lt;br /&gt;
| ?&lt;br /&gt;
| ?&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| [DEMO] The Legend of Zelda: Ocarina of Time 3D&lt;br /&gt;
| LNZ-CTR-AQEX&lt;br /&gt;
| CTR-P-AQEX&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| ?&lt;br /&gt;
| ?&lt;br /&gt;
| ?&lt;br /&gt;
| ?&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| Asphalt 3D&lt;br /&gt;
| LNA-CTR-ASFX&lt;br /&gt;
| CTR-P-ASFX&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| ?&lt;br /&gt;
| 128kByte&lt;br /&gt;
| ?&lt;br /&gt;
| ?&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| Cubic Ninja&lt;br /&gt;
| LNA-CTR-AQNX&lt;br /&gt;
| CTR-P-AQNX&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| ?&lt;br /&gt;
| 128kByte&lt;br /&gt;
| ?&lt;br /&gt;
| ?&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| Dead or Alive - Dimensions&lt;br /&gt;
| LNA-CTR-ADDX&lt;br /&gt;
| CTR-P-ADDX&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| ?&lt;br /&gt;
| 128kByte&lt;br /&gt;
| 0xC22211&lt;br /&gt;
| 25L1001&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| Lego Star Wars III: The Clone Wars&lt;br /&gt;
| LNA-CTR-ALGX&lt;br /&gt;
| CTR-P-ALGX&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| No&lt;br /&gt;
| 4GBit&lt;br /&gt;
| 128kByte&lt;br /&gt;
| 0xC22211&lt;br /&gt;
| 25L1001&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| Mario Kart 7&lt;br /&gt;
| LNA-CTR-AMKX&lt;br /&gt;
| CTR-P-AMKX&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| 8GBit&lt;br /&gt;
| 512kByte&lt;br /&gt;
| ?&lt;br /&gt;
| ?&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| Nintendogs+Cats: French Bulldog &amp;amp; New Friends&lt;br /&gt;
| LNA-CTR-ADBX&lt;br /&gt;
| CTR-P-ADBX&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| ?&lt;br /&gt;
| 512kByte&lt;br /&gt;
| 0xC22213&lt;br /&gt;
| 25L4001&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| One Piece: Unlimited Cruise SP&lt;br /&gt;
| LNA-CTR-ALFX&lt;br /&gt;
| CTR-P-ALFX&lt;br /&gt;
| No&lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
| ?&lt;br /&gt;
| 128kByte&lt;br /&gt;
| 0xC22211&lt;br /&gt;
| 25L1001&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| Pilotwings Resort&lt;br /&gt;
| LNA-CTR-AWAX&lt;br /&gt;
| CTR-P-AWAX&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| ?&lt;br /&gt;
| 128kByte&lt;br /&gt;
| 0xC22211&lt;br /&gt;
| 25L1001&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| Puzzle Bobble Universe&lt;br /&gt;
| LNA-CTR-ABBX&lt;br /&gt;
| CTR-P-ABBX&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| ?&lt;br /&gt;
| 128kByte&lt;br /&gt;
| 0xC22211&lt;br /&gt;
| 25L1001&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| [[Raving Rabbids: Travel in Time 3D]]&lt;br /&gt;
| LNA-CTR-ARBX&lt;br /&gt;
| CTR-P-ARBX&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| ?&lt;br /&gt;
| 128kByte&lt;br /&gt;
| 0xC22211&lt;br /&gt;
| 25L1001&lt;br /&gt;
| [http://dl.dropbox.com/u/7830918/3DS%20Upload/decrypted.bin de]/[http://dl.dropbox.com/u/7830918/3DS%20Upload/encrypted.bin en]&lt;br /&gt;
|-&lt;br /&gt;
| Ridge Racer 3D&lt;br /&gt;
| LNA-CTR-ARRX&lt;br /&gt;
| CTR-P-ARRX&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| 8GBit&lt;br /&gt;
| 512kByte&lt;br /&gt;
| 0xC22213&lt;br /&gt;
| 25L4001&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| Samurai Warriors - Chronicles&lt;br /&gt;
| LNA-CTR-A66X&lt;br /&gt;
| CTR-P-A66X&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| ?&lt;br /&gt;
| 512kByte&lt;br /&gt;
| 0xC22213&lt;br /&gt;
| 25L4001&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| Splinter Cell 3D&lt;br /&gt;
| LNA-CTR-ASCX&lt;br /&gt;
| CTR-P-ASCX&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| 16Gbit&lt;br /&gt;
| 128kByte&lt;br /&gt;
| 0xC22211&lt;br /&gt;
| 25L1001&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| Steel Diver&lt;br /&gt;
| LNA-CTR-ASDX&lt;br /&gt;
| CTR-P-ASDX&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| ?&lt;br /&gt;
| 512kByte&lt;br /&gt;
| 0xC22213&lt;br /&gt;
| 25L4001&lt;br /&gt;
| [http://dl.dropbox.com/u/32759832/3DS_saves/Steel_Diver/decrypted.sav de]/[http://dl.dropbox.com/u/32759832/3DS_saves/Steel_Diver/encrypted.sav en]&lt;br /&gt;
|-&lt;br /&gt;
| Super Mario 3D Land&lt;br /&gt;
| LNA-CTR-AREX&lt;br /&gt;
| CTR-P-AREX&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| ?&lt;br /&gt;
| 128kByte&lt;br /&gt;
| 0xC22211&lt;br /&gt;
| 25L1001&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| Super Monkey Ball 3D PAL&lt;br /&gt;
| LNA-CTR-ASMX&lt;br /&gt;
| CTR-P-ASMX&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| 2GBit&lt;br /&gt;
| 128kByte&lt;br /&gt;
| 0xC22211&lt;br /&gt;
| 25L1001&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| Super Street Fighter IV - 3D Edition&lt;br /&gt;
| LNA-CTR-ASSX&lt;br /&gt;
| CTR-P-ASSX&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| ?&lt;br /&gt;
| 128kByte&lt;br /&gt;
| 0xC22211&lt;br /&gt;
| 25L1001&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| [[The Legend of Zelda: Ocarina of Time 3D]]&lt;br /&gt;
| LNA-CTR-AQEX&lt;br /&gt;
| CTR-P-AQEX&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| ?&lt;br /&gt;
| 128kByte&lt;br /&gt;
| 0xC22211&lt;br /&gt;
| 25L1001&lt;br /&gt;
| [http://dl.dropbox.com/u/32759832/3DS_saves/Zelda_OoT/decrypted.sav de]/[http://dl.dropbox.com/u/32759832/3DS_saves/Zelda_OoT/encrypted.sav en]&lt;br /&gt;
|-&lt;br /&gt;
| The Sims 3&lt;br /&gt;
| LNA-CTR-AS3X&lt;br /&gt;
| CTR-P-AS3X&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| 4GBit&lt;br /&gt;
| 512kByte&lt;br /&gt;
| 0xC22213&lt;br /&gt;
| 25L4001&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| Tom Clancy&#039;s Ghost Recon: Shadow Wars&lt;br /&gt;
| LNA-CTR-AGRX&lt;br /&gt;
| CTR-P-ARGX&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| 2GBit&lt;br /&gt;
| 128kByte&lt;br /&gt;
| 0xC22211&lt;br /&gt;
| 25L1001&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Elisherer&#039;s Savefile collection: [http://sherer.co.il/saves http://sherer.co.il/saves]&lt;/div&gt;</summary>
		<author><name>Gericom</name></author>
	</entry>
	<entry>
		<id>https://www.3dbrew.org/w/index.php?title=4.0.0-7&amp;diff=2969</id>
		<title>4.0.0-7</title>
		<link rel="alternate" type="text/html" href="https://www.3dbrew.org/w/index.php?title=4.0.0-7&amp;diff=2969"/>
		<updated>2012-05-04T10:33:31Z</updated>

		<summary type="html">&lt;p&gt;Gericom: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&#039;&#039;&#039;Ability to add folders&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Probably the biggest new feature, this lets you organise your Home Menu with folders. Here&#039;s how they work.&lt;br /&gt;
Select an unoccupied tile and select &amp;quot;Create Folder&amp;quot;.&lt;br /&gt;
Tap &amp;quot;Edit Settings&amp;quot; if you want to name your folder, but remember: only the first letter shows up on its Home Menu icon. The full name appears on the top screen when you tap the folder.&lt;br /&gt;
Press your stylus onto an icon for a second and you&#039;ll &#039;pick it up&#039;.&lt;br /&gt;
Drag it over to the folder and take your stylus off the screen to &#039;drop&#039; the icon into the folder.&lt;br /&gt;
That&#039;s pretty much all there is to it. You can&#039;t put folders inside other folders, so don&#039;t try to nest them.&lt;br /&gt;
&lt;br /&gt;
Video: http://youtube.com/Uo8cm9rpAA4&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;eShop Revamp&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
The other most noticeable improvement is to the eShop. Here&#039;s what&#039;s new:&lt;br /&gt;
New layout — now split into two rows, the bottom is for easy access to 3DS Download Software, 3DS Virtual Console, DSiWare and 3DS Demos, while the top row is for the usual curated list and &#039;themes&#039;. The search bar is now at the top, too.&lt;br /&gt;
QR Code option — the 3DS has been able to scan QR codes for ever, but now the eShop gives you a bespoke option. Tap this in the Settings/Other menu, scan a QR code and it&#039;ll open the relevant page in the eShop.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Ability to patch games&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
This is a big one. Nintendo has added the ability for games — both retail and download — to receive updates in the form of patches or free add-on content. Here&#039;s what will be available in future.&lt;br /&gt;
Mario Kart 7 will get an update to address glitches. This update will be released in May, so don&#039;t go looking for it now.&lt;br /&gt;
Mighty Switch Force! will get five extra levels and a quick-retry button, all for free.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Supercards Block&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Obviously, it blocks some supercards (like R4, M3, G6, RTS, DSTT, etc.)&lt;br /&gt;
For that you need the Firmware upgrade of your flashcard&lt;/div&gt;</summary>
		<author><name>Gericom</name></author>
	</entry>
	<entry>
		<id>https://www.3dbrew.org/w/index.php?title=Talk:BCWAV&amp;diff=2411</id>
		<title>Talk:BCWAV</title>
		<link rel="alternate" type="text/html" href="https://www.3dbrew.org/w/index.php?title=Talk:BCWAV&amp;diff=2411"/>
		<updated>2012-02-27T10:24:27Z</updated>

		<summary type="html">&lt;p&gt;Gericom: Created page with &amp;quot;Are there some example files available?--~~~~&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Are there some example files available?--[[User:Gericom|Gericom]] 12:24, 27 February 2012 (CET)&lt;/div&gt;</summary>
		<author><name>Gericom</name></author>
	</entry>
	<entry>
		<id>https://www.3dbrew.org/w/index.php?title=Talk:3DSExplorer&amp;diff=1796</id>
		<title>Talk:3DSExplorer</title>
		<link rel="alternate" type="text/html" href="https://www.3dbrew.org/w/index.php?title=Talk:3DSExplorer&amp;diff=1796"/>
		<updated>2011-12-13T13:00:34Z</updated>

		<summary type="html">&lt;p&gt;Gericom: /* *FS#.bin decrypt */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Now I figured that I didn&#039;t explain the target of this app... It&#039;s suppose to be an Explorer like program to see inside the different filesystems that the 3ds has. Now it&#039;s the ExeFS, RomFS and SAVE. As knownledge keep flowing i&#039;ll continue to develop the application. With the goal of making a full functional drag&amp;amp;drop file explorer for image files. --[[User:Elisherer|Elisherer]] 18:35, 15 September 2011 (CEST)&lt;br /&gt;
&lt;br /&gt;
It fails showing the tmd file content. Have you finshed working on this feature?--[[User:Lazymarek9614|Lazymarek9614]] 15:49, 20 September 2011 (CEST)&lt;br /&gt;
:No, I don&#039;t have time to work on it..it&#039;s not interesting enough --[[User:Elisherer|Elisherer]] 15:36, 21 September 2011 (CEST)&lt;br /&gt;
::Yeah, the 3DS doesn&#039;t care when the tmd file was modified... it&#039;s not useful for hacking.--[[User:Lazymarek9614|Lazymarek9614]] 21:09, 21 September 2011 (CEST)&lt;br /&gt;
&lt;br /&gt;
I downloaded the sources,but I can&#039;t  find Save.cs and reference &amp;quot;System.Development&amp;quot;. Matyapiro31&lt;br /&gt;
:You are right... I fixed it.. notice that the source is not the released version it has some experimental stuff in it... --[[User:Elisherer|Elisherer]] 10:53, 30 September 2011 (CEST)&lt;br /&gt;
&lt;br /&gt;
Do you know [http://monodevelop.com/ Mono Develop]?&lt;br /&gt;
You can release it as multi-patform,such as Linux,Machitosh,etc.&lt;br /&gt;
:I did not know that until now. But I don&#039;t have time to make the transition. I&#039;m happy with VS2008 and it&#039;s relatively easy to make changes and new features for the app. The source is open and you can make a linux port if you want. --[[User:Elisherer|Elisherer]] 18:16, 30 September 2011 (CEST)&lt;br /&gt;
:You need no change.mono can run c# program like Java VM. Matyapiro31&lt;br /&gt;
::I tried to compile it,but That was old one,and there is &amp;quot;System.development.&amp;quot;&lt;br /&gt;
:::[http://stackoverflow.com/questions/5865060/c-on-os-x-and-linux This] says that I need to fix stuff after I convert my project. and then work with the mono app which I don&#039;t find very convinient... and about the reference I don&#039;t know what it&#039;s about..I don&#039;t know a namespace called System.Development --[[User:Elisherer|Elisherer]] 17:42, 2 October 2011 (CEST) (P.s you can sign your messages with the quick signature button or 4 tildes: &#039;~&#039; 4 times)&lt;br /&gt;
&lt;br /&gt;
lblBrew_Click() had no exception handler,&lt;br /&gt;
&lt;br /&gt;
you have to change this method in fmExplorer.cs to&lt;br /&gt;
    private void lblBrew_Click(object sender, EventArgs e)&lt;br /&gt;
        {&lt;br /&gt;
            try&lt;br /&gt;
            {&lt;br /&gt;
                System.Diagnostics.Process.Start(lblBrew.Text);&lt;br /&gt;
            }&lt;br /&gt;
            catch (Exception ex)&lt;br /&gt;
            {&lt;br /&gt;
                MessageBox.Show(&amp;quot;Cannot open link that was clicled.\n&amp;quot;+ ex.Message);&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
&lt;br /&gt;
Matyapiro31&lt;br /&gt;
&lt;br /&gt;
The algorithm for the Image Hash might be either MD2 or MD4. I found out by using HxD and Notepad. --[[User:Kiddyshaq34|Kiddyshaq34]]&lt;br /&gt;
:Ok, but of what? (i know it&#039;s suppose to be 128 bit) And why not MD-5? --[[User:Elisherer|Elisherer]] 07:10, 9 October 2011 (CEST)&lt;br /&gt;
::Because MD5 is longer and the Image Hash has the same number of bytes as MD2 and MD4.&lt;br /&gt;
:::MD2, 4 &amp;amp; 5 are all 128bit which is 0x10 bytes... --[[User:Elisherer|Elisherer]] 20:28, 9 October 2011 (CEST)&lt;br /&gt;
::::Oh, I&#039;ve forgotten about MD5. You are right.&lt;br /&gt;
&lt;br /&gt;
3DS include RSA Securuty &#039;s [http://www.rsa.com/node.aspx?id=1204 BSafe]&lt;br /&gt;
&lt;br /&gt;
from 3DS manual. Matyapiro31&lt;br /&gt;
:Thanks Matyapiro31 but I think RSA is used for encryption and *not* hashing. So the RSA might be used for ROMs and WiFi... --[[User:Elisherer|Elisherer]] 14:48, 9 October 2011 (CEST)&lt;br /&gt;
&lt;br /&gt;
あほ。RSA BSafe support all security method.See [http://www.rsa.com/japan/products/bsafe/CRYPTOCJ_DS_1101-J.pdf this.] &lt;br /&gt;
&lt;br /&gt;
I cannot find English version,sorry.&lt;br /&gt;
Matyapiro31&lt;br /&gt;
:I guess if you mean [http://www.rsa.com/node.aspx?id=3063 this] then the digest algorithms are the ones that we know of..we havn&#039;t tried HMAC yet or CNG but from experience we see that nintendo uses regular digest algorithms like CRC16-Modbus and SHA-256. I&#039;ll add the HMAC ones to the brute force hash tool to see if it finds something... --[[User:Elisherer|Elisherer]] 22:36, 12 October 2011 (CEST)&lt;br /&gt;
&lt;br /&gt;
I&#039;ve tried to decrypt &#039;Super Mario 3D Land&#039; but your tool shows me an &#039;Corrupt Save File&#039; error.--[[User:Lazymarek9614|Lazymarek9614]] 18:36, 18 November 2011 (CET)&lt;br /&gt;
:Corrupted save file might be from 2 reasons: * Size is not right (128K or 512k) * CRC on wearleveling wrong. Both problems occur from NDS adapter plus malfunctioning...try blowing on the cart and the adapter and download the savefile again... --[[User:Elisherer|Elisherer]] 20:16, 18 November 2011 (CET)&lt;br /&gt;
::I actually don&#039;t use the useless NDS Adapter Plus, but I used DSM and I&#039;ve tried it two times (always the same data).. I hope Nintendo doesn&#039;t use a new encryption now! Shall I send you the sav file?--[[User:Lazymarek9614|Lazymarek9614]] 20:27, 18 November 2011 (CET)&lt;br /&gt;
:::Yes please, I could check it within the application... --[[User:Elisherer|Elisherer]] 20:35, 18 November 2011 (CET)&lt;br /&gt;
::::Have you found anything?--[[User:Lazymarek9614|Lazymarek9614]] 21:25, 18 November 2011 (CET)&lt;br /&gt;
:::::No..it&#039;s seems that the key found isn&#039;t the right key (even that it appears 4 times in the file). we need to figure out how to decrypt the save files without searching blindly for the key. --[[User:Elisherer|Elisherer]] 21:33, 18 November 2011 (CET)&lt;br /&gt;
:::::I got an idea. Xor the image&#039;s 0x100-0x103 with every (0x200 block)&#039;s 0x100-0x103 to see if it produces &#039;DISA&#039; ..it should work with the already known files and might be faster to find. i&#039;ll try it tomorrow.. --[[User:Elisherer|Elisherer]] 21:40, 18 November 2011 (CET)&lt;br /&gt;
::::::Mind linking to a SM3DL save here so I could look at it?(Btw, you&#039;re not looking for a &amp;quot;key&amp;quot;, you&#039;re looking for an AES-CTR xorpad.) --[[User:Yellows8|Yellows8]] 06:03, 22 November 2011 (CET)&lt;br /&gt;
:::::::I&#039;ll ask for permission. In the meanwhile, can we talk about it at n-dev.net? I made a [http://n-dev.net/showthread.php?tid=4 thread] there. --[[User:Elisherer|Elisherer]] 16:26, 22 November 2011 (CET)&lt;br /&gt;
::::::::Yes, you can share them!--[[User:Lazymarek9614|Lazymarek9614]] 17:24, 22 November 2011 (CET)&lt;br /&gt;
:::::::Catch the files on my server [http://www.sherer.co.il/saves http://www.sherer.co.il/saves] (Super Mario 3D Land).--[[User:Elisherer|Elisherer]] 17:43, 22 November 2011 (CET)&lt;br /&gt;
::::::::I&#039;m stumped too. Since some chunks of data appears several times in these saves, in theory the CTR should still be repeating.(CTR seems to repeat &amp;gt;0x200 bytes now, not sure.) Didn&#039;t really manage to decrypt much via xor. --[[User:Yellows8|Yellows8]] 22:08, 22 November 2011 (CET)&lt;br /&gt;
::::::::I would guess they finally fixed the bug that limited the xor stream to just 0x200 bytes repeating, and now it behaves more like the data saved to SD cards? --[[User:Neimod|Neimod]] 01:30, 25 November 2011 (CET)&lt;br /&gt;
::::::::But you can see that same blocks share the same xorpad in the file...the DISA header is in the file 4 times and encrypted the same all the 4 times.. so the key may not repeat but maybe every block has it&#039;s own xorpad based on its offset in the image (my speculation) --[[User:Elisherer|Elisherer]] 09:02, 25 November 2011 (CET)&lt;br /&gt;
&lt;br /&gt;
== *FS#.bin decrypt ==&lt;br /&gt;
Maybe I found the key: I think it&#039;s the unknown value at Rom. It&#039;s 16 characters long.&lt;br /&gt;
When I use it, it doesn&#039;t give a error or something.&lt;br /&gt;
--[[User:Gericom|Gericom]] 16:06, 12 December 2011 (CET)&lt;/div&gt;</summary>
		<author><name>Gericom</name></author>
	</entry>
	<entry>
		<id>https://www.3dbrew.org/w/index.php?title=Talk:3DSExplorer&amp;diff=1786</id>
		<title>Talk:3DSExplorer</title>
		<link rel="alternate" type="text/html" href="https://www.3dbrew.org/w/index.php?title=Talk:3DSExplorer&amp;diff=1786"/>
		<updated>2011-12-12T14:06:41Z</updated>

		<summary type="html">&lt;p&gt;Gericom: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Now I figured that I didn&#039;t explain the target of this app... It&#039;s suppose to be an Explorer like program to see inside the different filesystems that the 3ds has. Now it&#039;s the ExeFS, RomFS and SAVE. As knownledge keep flowing i&#039;ll continue to develop the application. With the goal of making a full functional drag&amp;amp;drop file explorer for image files. --[[User:Elisherer|Elisherer]] 18:35, 15 September 2011 (CEST)&lt;br /&gt;
&lt;br /&gt;
It fails showing the tmd file content. Have you finshed working on this feature?--[[User:Lazymarek9614|Lazymarek9614]] 15:49, 20 September 2011 (CEST)&lt;br /&gt;
:No, I don&#039;t have time to work on it..it&#039;s not interesting enough --[[User:Elisherer|Elisherer]] 15:36, 21 September 2011 (CEST)&lt;br /&gt;
::Yeah, the 3DS doesn&#039;t care when the tmd file was modified... it&#039;s not useful for hacking.--[[User:Lazymarek9614|Lazymarek9614]] 21:09, 21 September 2011 (CEST)&lt;br /&gt;
&lt;br /&gt;
I downloaded the sources,but I can&#039;t  find Save.cs and reference &amp;quot;System.Development&amp;quot;. Matyapiro31&lt;br /&gt;
:You are right... I fixed it.. notice that the source is not the released version it has some experimental stuff in it... --[[User:Elisherer|Elisherer]] 10:53, 30 September 2011 (CEST)&lt;br /&gt;
&lt;br /&gt;
Do you know [http://monodevelop.com/ Mono Develop]?&lt;br /&gt;
You can release it as multi-patform,such as Linux,Machitosh,etc.&lt;br /&gt;
:I did not know that until now. But I don&#039;t have time to make the transition. I&#039;m happy with VS2008 and it&#039;s relatively easy to make changes and new features for the app. The source is open and you can make a linux port if you want. --[[User:Elisherer|Elisherer]] 18:16, 30 September 2011 (CEST)&lt;br /&gt;
:You need no change.mono can run c# program like Java VM. Matyapiro31&lt;br /&gt;
::I tried to compile it,but That was old one,and there is &amp;quot;System.development.&amp;quot;&lt;br /&gt;
:::[http://stackoverflow.com/questions/5865060/c-on-os-x-and-linux This] says that I need to fix stuff after I convert my project. and then work with the mono app which I don&#039;t find very convinient... and about the reference I don&#039;t know what it&#039;s about..I don&#039;t know a namespace called System.Development --[[User:Elisherer|Elisherer]] 17:42, 2 October 2011 (CEST) (P.s you can sign your messages with the quick signature button or 4 tildes: &#039;~&#039; 4 times)&lt;br /&gt;
&lt;br /&gt;
lblBrew_Click() had no exception handler,&lt;br /&gt;
&lt;br /&gt;
you have to change this method in fmExplorer.cs to&lt;br /&gt;
    private void lblBrew_Click(object sender, EventArgs e)&lt;br /&gt;
        {&lt;br /&gt;
            try&lt;br /&gt;
            {&lt;br /&gt;
                System.Diagnostics.Process.Start(lblBrew.Text);&lt;br /&gt;
            }&lt;br /&gt;
            catch (Exception ex)&lt;br /&gt;
            {&lt;br /&gt;
                MessageBox.Show(&amp;quot;Cannot open link that was clicled.\n&amp;quot;+ ex.Message);&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
&lt;br /&gt;
Matyapiro31&lt;br /&gt;
&lt;br /&gt;
The algorithm for the Image Hash might be either MD2 or MD4. I found out by using HxD and Notepad. --[[User:Kiddyshaq34|Kiddyshaq34]]&lt;br /&gt;
:Ok, but of what? (i know it&#039;s suppose to be 128 bit) And why not MD-5? --[[User:Elisherer|Elisherer]] 07:10, 9 October 2011 (CEST)&lt;br /&gt;
::Because MD5 is longer and the Image Hash has the same number of bytes as MD2 and MD4.&lt;br /&gt;
:::MD2, 4 &amp;amp; 5 are all 128bit which is 0x10 bytes... --[[User:Elisherer|Elisherer]] 20:28, 9 October 2011 (CEST)&lt;br /&gt;
::::Oh, I&#039;ve forgotten about MD5. You are right.&lt;br /&gt;
&lt;br /&gt;
3DS include RSA Securuty &#039;s [http://www.rsa.com/node.aspx?id=1204 BSafe]&lt;br /&gt;
&lt;br /&gt;
from 3DS manual. Matyapiro31&lt;br /&gt;
:Thanks Matyapiro31 but I think RSA is used for encryption and *not* hashing. So the RSA might be used for ROMs and WiFi... --[[User:Elisherer|Elisherer]] 14:48, 9 October 2011 (CEST)&lt;br /&gt;
&lt;br /&gt;
あほ。RSA BSafe support all security method.See [http://www.rsa.com/japan/products/bsafe/CRYPTOCJ_DS_1101-J.pdf this.] &lt;br /&gt;
&lt;br /&gt;
I cannot find English version,sorry.&lt;br /&gt;
Matyapiro31&lt;br /&gt;
:I guess if you mean [http://www.rsa.com/node.aspx?id=3063 this] then the digest algorithms are the ones that we know of..we havn&#039;t tried HMAC yet or CNG but from experience we see that nintendo uses regular digest algorithms like CRC16-Modbus and SHA-256. I&#039;ll add the HMAC ones to the brute force hash tool to see if it finds something... --[[User:Elisherer|Elisherer]] 22:36, 12 October 2011 (CEST)&lt;br /&gt;
&lt;br /&gt;
I&#039;ve tried to decrypt &#039;Super Mario 3D Land&#039; but your tool shows me an &#039;Corrupt Save File&#039; error.--[[User:Lazymarek9614|Lazymarek9614]] 18:36, 18 November 2011 (CET)&lt;br /&gt;
:Corrupted save file might be from 2 reasons: * Size is not right (128K or 512k) * CRC on wearleveling wrong. Both problems occur from NDS adapter plus malfunctioning...try blowing on the cart and the adapter and download the savefile again... --[[User:Elisherer|Elisherer]] 20:16, 18 November 2011 (CET)&lt;br /&gt;
::I actually don&#039;t use the useless NDS Adapter Plus, but I used DSM and I&#039;ve tried it two times (always the same data).. I hope Nintendo doesn&#039;t use a new encryption now! Shall I send you the sav file?--[[User:Lazymarek9614|Lazymarek9614]] 20:27, 18 November 2011 (CET)&lt;br /&gt;
:::Yes please, I could check it within the application... --[[User:Elisherer|Elisherer]] 20:35, 18 November 2011 (CET)&lt;br /&gt;
::::Have you found anything?--[[User:Lazymarek9614|Lazymarek9614]] 21:25, 18 November 2011 (CET)&lt;br /&gt;
:::::No..it&#039;s seems that the key found isn&#039;t the right key (even that it appears 4 times in the file). we need to figure out how to decrypt the save files without searching blindly for the key. --[[User:Elisherer|Elisherer]] 21:33, 18 November 2011 (CET)&lt;br /&gt;
:::::I got an idea. Xor the image&#039;s 0x100-0x103 with every (0x200 block)&#039;s 0x100-0x103 to see if it produces &#039;DISA&#039; ..it should work with the already known files and might be faster to find. i&#039;ll try it tomorrow.. --[[User:Elisherer|Elisherer]] 21:40, 18 November 2011 (CET)&lt;br /&gt;
::::::Mind linking to a SM3DL save here so I could look at it?(Btw, you&#039;re not looking for a &amp;quot;key&amp;quot;, you&#039;re looking for an AES-CTR xorpad.) --[[User:Yellows8|Yellows8]] 06:03, 22 November 2011 (CET)&lt;br /&gt;
:::::::I&#039;ll ask for permission. In the meanwhile, can we talk about it at n-dev.net? I made a [http://n-dev.net/showthread.php?tid=4 thread] there. --[[User:Elisherer|Elisherer]] 16:26, 22 November 2011 (CET)&lt;br /&gt;
::::::::Yes, you can share them!--[[User:Lazymarek9614|Lazymarek9614]] 17:24, 22 November 2011 (CET)&lt;br /&gt;
:::::::Catch the files on my server [http://www.sherer.co.il/saves http://www.sherer.co.il/saves] (Super Mario 3D Land).--[[User:Elisherer|Elisherer]] 17:43, 22 November 2011 (CET)&lt;br /&gt;
::::::::I&#039;m stumped too. Since some chunks of data appears several times in these saves, in theory the CTR should still be repeating.(CTR seems to repeat &amp;gt;0x200 bytes now, not sure.) Didn&#039;t really manage to decrypt much via xor. --[[User:Yellows8|Yellows8]] 22:08, 22 November 2011 (CET)&lt;br /&gt;
::::::::I would guess they finally fixed the bug that limited the xor stream to just 0x200 bytes repeating, and now it behaves more like the data saved to SD cards? --[[User:Neimod|Neimod]] 01:30, 25 November 2011 (CET)&lt;br /&gt;
::::::::But you can see that same blocks share the same xorpad in the file...the DISA header is in the file 4 times and encrypted the same all the 4 times.. so the key may not repeat but maybe every block has it&#039;s own xorpad based on its offset in the image (my speculation) --[[User:Elisherer|Elisherer]] 09:02, 25 November 2011 (CET)&lt;br /&gt;
&lt;br /&gt;
== *FS#.bin decrypt ==&lt;br /&gt;
Maybe I have found the key: I think it&#039;s the unknown value at Rom. It&#039;s 16 characters long.&lt;br /&gt;
When I use it, it doesn&#039;t give a error or something.&lt;br /&gt;
--[[User:Gericom|Gericom]] 16:06, 12 December 2011 (CET)&lt;/div&gt;</summary>
		<author><name>Gericom</name></author>
	</entry>
</feed>