gb_8h.html (357281B)
1<!-- HTML header for doxygen 1.8.14--> 2<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> 3<html xmlns="http://www.w3.org/1999/xhtml"> 4<head> 5<meta http-equiv="cache-control" content="max-age=86400"/> 6<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/> 7<meta http-equiv="X-UA-Compatible" content="IE=9"/> 8<meta name="generator" content="Doxygen 1.8.20"/> 9<meta name="viewport" content="width=device-width, initial-scale=1"/> 10<title>GBDK 2020 Docs: gb/gb.h File Reference</title> 11<link href="tabs.css" rel="stylesheet" type="text/css"/> 12<script type="text/javascript" src="jquery.js"></script> 13<script type="text/javascript" src="dynsections.js"></script> 14<link href="navtree.css" rel="stylesheet" type="text/css"/> 15<script type="text/javascript" src="resize.js"></script> 16<script type="text/javascript" src="navtreedata.js"></script> 17<script type="text/javascript" src="navtree.js"></script> 18<link href="search/search.css" rel="stylesheet" type="text/css"/> 19<script type="text/javascript" src="search/searchdata.js"></script> 20<script type="text/javascript" src="search/search.js"></script> 21<link href="doxygen.css" rel="stylesheet" type="text/css" /> 22<link href="doxygen_extra.css" rel="stylesheet" type="text/css"/> 23</head> 24<body> 25<div id="top"><!-- do not remove this div, it is closed by doxygen! --> 26<div id="titlearea"> 27<table cellspacing="0" cellpadding="0"> 28 <tbody> 29 <tr style="height: 56px;"> 30 <td id="projectalign" style="padding-left: 0.5em;"> 31 <div id="projectname">GBDK 2020 Docs 32  <span id="projectnumber">4.0.6</span> 33 </div> 34 <div id="projectbrief">API Documentation for GBDK 2020</div> 35 </td> 36 </tr> 37 </tbody> 38</table> 39</div> 40<!-- end header part --> 41<!-- Generated by Doxygen 1.8.20 --> 42<script type="text/javascript"> 43/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */ 44var searchBox = new SearchBox("searchBox", "search",false,'Search'); 45/* @license-end */ 46</script> 47<script type="text/javascript" src="menudata.js"></script> 48<script type="text/javascript" src="menu.js"></script> 49<script type="text/javascript"> 50/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */ 51$(function() { 52 initMenu('',true,false,'search.php','Search'); 53 $(document).ready(function() { init_search(); }); 54}); 55/* @license-end */</script> 56<div id="main-nav"></div> 57</div><!-- top --> 58<div id="side-nav" class="ui-resizable side-nav-resizable"> 59 <div id="nav-tree"> 60 <div id="nav-tree-contents"> 61 <div id="nav-sync" class="sync"></div> 62 </div> 63 </div> 64 <div id="splitbar" style="-moz-user-select:none;" 65 class="ui-resizable-handle"> 66 </div> 67</div> 68<script type="text/javascript"> 69/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */ 70$(document).ready(function(){initNavTree('gb_8h.html',''); initResizable(); }); 71/* @license-end */ 72</script> 73<div id="doc-content"> 74<!-- window showing the filter options --> 75<div id="MSearchSelectWindow" 76 onmouseover="return searchBox.OnSearchSelectShow()" 77 onmouseout="return searchBox.OnSearchSelectHide()" 78 onkeydown="return searchBox.OnSearchSelectKey(event)"> 79</div> 80 81<!-- iframe showing the search results (closed by default) --> 82<div id="MSearchResultsWindow"> 83<iframe src="javascript:void(0)" frameborder="0" 84 name="MSearchResults" id="MSearchResults"> 85</iframe> 86</div> 87 88<div class="header"> 89 <div class="summary"> 90<a href="#nested-classes">Data Structures</a> | 91<a href="#define-members">Macros</a> | 92<a href="#typedef-members">Typedefs</a> | 93<a href="#func-members">Functions</a> | 94<a href="#var-members">Variables</a> </div> 95 <div class="headertitle"> 96<div class="title">gb.h File Reference</div> </div> 97</div><!--header--> 98<div class="contents"> 99<div class="textblock"><code>#include <types.h></code><br /> 100<code>#include <<a class="el" href="stdint_8h_source.html">stdint.h</a>></code><br /> 101<code>#include <<a class="el" href="version_8h_source.html">gbdk/version.h</a>></code><br /> 102<code>#include <<a class="el" href="gb_2hardware_8h_source.html">gb/hardware.h</a>></code><br /> 103</div> 104<p><a href="gb_8h_source.html">Go to the source code of this file.</a></p> 105<table class="memberdecls"> 106<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="nested-classes"></a> 107Data Structures</h2></td></tr> 108<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">struct  </td><td class="memItemRight" valign="bottom"><a class="el" href="structjoypads__t.html">joypads_t</a></td></tr> 109<tr class="separator:"><td class="memSeparator" colspan="2"> </td></tr> 110<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">struct  </td><td class="memItemRight" valign="bottom"><a class="el" href="struct_o_a_m__item__t.html">OAM_item_t</a></td></tr> 111<tr class="separator:"><td class="memSeparator" colspan="2"> </td></tr> 112</table><table class="memberdecls"> 113<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="define-members"></a> 114Macros</h2></td></tr> 115<tr class="memitem:a385397587c93683e8e11afb712e2960b"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a385397587c93683e8e11afb712e2960b">NINTENDO</a></td></tr> 116<tr class="separator:a385397587c93683e8e11afb712e2960b"><td class="memSeparator" colspan="2"> </td></tr> 117<tr class="memitem:af10046e88cba47031142a763a94210df"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#af10046e88cba47031142a763a94210df">GAMEBOY</a></td></tr> 118<tr class="separator:af10046e88cba47031142a763a94210df"><td class="memSeparator" colspan="2"> </td></tr> 119<tr class="memitem:a05ca817ab32f6da612c3ae26db5abf02"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a05ca817ab32f6da612c3ae26db5abf02">J_UP</a>   0x04U</td></tr> 120<tr class="separator:a05ca817ab32f6da612c3ae26db5abf02"><td class="memSeparator" colspan="2"> </td></tr> 121<tr class="memitem:ae032c5c544196e37ec0432f6cfad7904"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#ae032c5c544196e37ec0432f6cfad7904">J_DOWN</a>   0x08U</td></tr> 122<tr class="separator:ae032c5c544196e37ec0432f6cfad7904"><td class="memSeparator" colspan="2"> </td></tr> 123<tr class="memitem:ac70894fecac30c1ca9917f07373cf81c"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#ac70894fecac30c1ca9917f07373cf81c">J_LEFT</a>   0x02U</td></tr> 124<tr class="separator:ac70894fecac30c1ca9917f07373cf81c"><td class="memSeparator" colspan="2"> </td></tr> 125<tr class="memitem:a3bad91d11ae09ffcbb3cb0a81873d325"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a3bad91d11ae09ffcbb3cb0a81873d325">J_RIGHT</a>   0x01U</td></tr> 126<tr class="separator:a3bad91d11ae09ffcbb3cb0a81873d325"><td class="memSeparator" colspan="2"> </td></tr> 127<tr class="memitem:a31af766e3b598eb7a6b63f55a4988e7a"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a31af766e3b598eb7a6b63f55a4988e7a">J_A</a>   0x10U</td></tr> 128<tr class="separator:a31af766e3b598eb7a6b63f55a4988e7a"><td class="memSeparator" colspan="2"> </td></tr> 129<tr class="memitem:ae47e59a309120f9420993f26816b5e6d"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#ae47e59a309120f9420993f26816b5e6d">J_B</a>   0x20U</td></tr> 130<tr class="separator:ae47e59a309120f9420993f26816b5e6d"><td class="memSeparator" colspan="2"> </td></tr> 131<tr class="memitem:ab416a9d96d1582490828f4bac78a8b5b"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#ab416a9d96d1582490828f4bac78a8b5b">J_SELECT</a>   0x40U</td></tr> 132<tr class="separator:ab416a9d96d1582490828f4bac78a8b5b"><td class="memSeparator" colspan="2"> </td></tr> 133<tr class="memitem:ab769c6e20778298be8bc3321476ceb53"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#ab769c6e20778298be8bc3321476ceb53">J_START</a>   0x80U</td></tr> 134<tr class="separator:ab769c6e20778298be8bc3321476ceb53"><td class="memSeparator" colspan="2"> </td></tr> 135<tr class="memitem:acc9798fc62b5d626c91c8b0f20b522ff"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#acc9798fc62b5d626c91c8b0f20b522ff">M_DRAWING</a>   0x01U</td></tr> 136<tr class="separator:acc9798fc62b5d626c91c8b0f20b522ff"><td class="memSeparator" colspan="2"> </td></tr> 137<tr class="memitem:af0e30d6af308ffe5a025fbe85da40f6f"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#af0e30d6af308ffe5a025fbe85da40f6f">M_TEXT_OUT</a>   0x02U</td></tr> 138<tr class="separator:af0e30d6af308ffe5a025fbe85da40f6f"><td class="memSeparator" colspan="2"> </td></tr> 139<tr class="memitem:a908826e7180f94a5988ceb8633313a2e"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a908826e7180f94a5988ceb8633313a2e">M_TEXT_INOUT</a>   0x03U</td></tr> 140<tr class="separator:a908826e7180f94a5988ceb8633313a2e"><td class="memSeparator" colspan="2"> </td></tr> 141<tr class="memitem:a04382de20738146fe873ddfb0585052b"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a04382de20738146fe873ddfb0585052b">M_NO_SCROLL</a>   0x04U</td></tr> 142<tr class="separator:a04382de20738146fe873ddfb0585052b"><td class="memSeparator" colspan="2"> </td></tr> 143<tr class="memitem:aca2855edd2d28f66be551a0f7ec23f07"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#aca2855edd2d28f66be551a0f7ec23f07">M_NO_INTERP</a>   0x08U</td></tr> 144<tr class="separator:aca2855edd2d28f66be551a0f7ec23f07"><td class="memSeparator" colspan="2"> </td></tr> 145<tr class="memitem:a54572cf6791463b6d60623837e0bb5a6"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a54572cf6791463b6d60623837e0bb5a6">S_PALETTE</a>   0x10U</td></tr> 146<tr class="separator:a54572cf6791463b6d60623837e0bb5a6"><td class="memSeparator" colspan="2"> </td></tr> 147<tr class="memitem:ae97793b4039609f93b0f7f8bddb18011"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#ae97793b4039609f93b0f7f8bddb18011">S_FLIPX</a>   0x20U</td></tr> 148<tr class="separator:ae97793b4039609f93b0f7f8bddb18011"><td class="memSeparator" colspan="2"> </td></tr> 149<tr class="memitem:a4bbb9cd6c38b2317de5256d1d889c63b"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a4bbb9cd6c38b2317de5256d1d889c63b">S_FLIPY</a>   0x40U</td></tr> 150<tr class="separator:a4bbb9cd6c38b2317de5256d1d889c63b"><td class="memSeparator" colspan="2"> </td></tr> 151<tr class="memitem:a9506d04c2ec7d2442a52054f67d2b32f"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a9506d04c2ec7d2442a52054f67d2b32f">S_PRIORITY</a>   0x80U</td></tr> 152<tr class="separator:a9506d04c2ec7d2442a52054f67d2b32f"><td class="memSeparator" colspan="2"> </td></tr> 153<tr class="memitem:aa027abe630d44039f238034bcb2d2f36"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#aa027abe630d44039f238034bcb2d2f36">EMPTY_IFLAG</a>   0x00U</td></tr> 154<tr class="separator:aa027abe630d44039f238034bcb2d2f36"><td class="memSeparator" colspan="2"> </td></tr> 155<tr class="memitem:a2ca7720b9a5da9b2173e1f74dba85541"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a2ca7720b9a5da9b2173e1f74dba85541">VBL_IFLAG</a>   0x01U</td></tr> 156<tr class="separator:a2ca7720b9a5da9b2173e1f74dba85541"><td class="memSeparator" colspan="2"> </td></tr> 157<tr class="memitem:a61a9e2910380de6abb34df14ef634eb4"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a61a9e2910380de6abb34df14ef634eb4">LCD_IFLAG</a>   0x02U</td></tr> 158<tr class="separator:a61a9e2910380de6abb34df14ef634eb4"><td class="memSeparator" colspan="2"> </td></tr> 159<tr class="memitem:a604256210ec5b90b68185e1a18efab49"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a604256210ec5b90b68185e1a18efab49">TIM_IFLAG</a>   0x04U</td></tr> 160<tr class="separator:a604256210ec5b90b68185e1a18efab49"><td class="memSeparator" colspan="2"> </td></tr> 161<tr class="memitem:ad90564458646c5646b3880b93db3443e"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#ad90564458646c5646b3880b93db3443e">SIO_IFLAG</a>   0x08U</td></tr> 162<tr class="separator:ad90564458646c5646b3880b93db3443e"><td class="memSeparator" colspan="2"> </td></tr> 163<tr class="memitem:a2f829cf27d6e3e24c875e9b82dfcb280"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a2f829cf27d6e3e24c875e9b82dfcb280">JOY_IFLAG</a>   0x10U</td></tr> 164<tr class="separator:a2f829cf27d6e3e24c875e9b82dfcb280"><td class="memSeparator" colspan="2"> </td></tr> 165<tr class="memitem:ab311e53739c992294ae07ca506a924ad"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#ab311e53739c992294ae07ca506a924ad">DMG_BLACK</a>   0x03</td></tr> 166<tr class="separator:ab311e53739c992294ae07ca506a924ad"><td class="memSeparator" colspan="2"> </td></tr> 167<tr class="memitem:a45d13a674e169dd83df7e1f46513ccba"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a45d13a674e169dd83df7e1f46513ccba">DMG_DARK_GRAY</a>   0x02</td></tr> 168<tr class="separator:a45d13a674e169dd83df7e1f46513ccba"><td class="memSeparator" colspan="2"> </td></tr> 169<tr class="memitem:a8ccd6732d3bdf390cc0943e8567341f3"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a8ccd6732d3bdf390cc0943e8567341f3">DMG_LITE_GRAY</a>   0x01</td></tr> 170<tr class="separator:a8ccd6732d3bdf390cc0943e8567341f3"><td class="memSeparator" colspan="2"> </td></tr> 171<tr class="memitem:a11cedc2ee58acfbbfc48dfb2b9a551b3"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a11cedc2ee58acfbbfc48dfb2b9a551b3">DMG_WHITE</a>   0x00</td></tr> 172<tr class="separator:a11cedc2ee58acfbbfc48dfb2b9a551b3"><td class="memSeparator" colspan="2"> </td></tr> 173<tr class="memitem:a9727caafc483ba6ec65e9344b033d684"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a9727caafc483ba6ec65e9344b033d684">DMG_PALETTE</a>(C0, C1, C2, C3)   ((<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a>)((((C3) & 0x03) << 6) | (((C2) & 0x03) << 4) | (((C1) & 0x03) << 2) | ((C0) & 0x03)))</td></tr> 174<tr class="separator:a9727caafc483ba6ec65e9344b033d684"><td class="memSeparator" colspan="2"> </td></tr> 175<tr class="memitem:ada0cc738d27aad251151e69cb8d250e1"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#ada0cc738d27aad251151e69cb8d250e1">SCREENWIDTH</a>   <a class="el" href="sms_2hardware_8h.html#ad14c51cdfb347c34c364f54e67dc978d">DEVICE_SCREEN_PX_WIDTH</a></td></tr> 176<tr class="separator:ada0cc738d27aad251151e69cb8d250e1"><td class="memSeparator" colspan="2"> </td></tr> 177<tr class="memitem:ae189e98d0ef9263c37869ce1ff3710a5"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#ae189e98d0ef9263c37869ce1ff3710a5">SCREENHEIGHT</a>   <a class="el" href="sms_2hardware_8h.html#a7bd450aa268b881257089cf8cd6697ec">DEVICE_SCREEN_PX_HEIGHT</a></td></tr> 178<tr class="separator:ae189e98d0ef9263c37869ce1ff3710a5"><td class="memSeparator" colspan="2"> </td></tr> 179<tr class="memitem:a5a796bbf3e4347d914b83568350143a9"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a5a796bbf3e4347d914b83568350143a9">MINWNDPOSX</a>   0x07U</td></tr> 180<tr class="separator:a5a796bbf3e4347d914b83568350143a9"><td class="memSeparator" colspan="2"> </td></tr> 181<tr class="memitem:af3d632ba2d7cef6619df5dfea8730909"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#af3d632ba2d7cef6619df5dfea8730909">MINWNDPOSY</a>   0x00U</td></tr> 182<tr class="separator:af3d632ba2d7cef6619df5dfea8730909"><td class="memSeparator" colspan="2"> </td></tr> 183<tr class="memitem:a6dffb66ec1b1d9bb380a1af52a601ec5"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a6dffb66ec1b1d9bb380a1af52a601ec5">MAXWNDPOSX</a>   0xA6U</td></tr> 184<tr class="separator:a6dffb66ec1b1d9bb380a1af52a601ec5"><td class="memSeparator" colspan="2"> </td></tr> 185<tr class="memitem:ad57f2f8c54204687f02801d8ab1bd150"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#ad57f2f8c54204687f02801d8ab1bd150">MAXWNDPOSY</a>   0x8FU</td></tr> 186<tr class="separator:ad57f2f8c54204687f02801d8ab1bd150"><td class="memSeparator" colspan="2"> </td></tr> 187<tr class="memitem:a0031c07799247a6d6c1bfa3decac79d0"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a0031c07799247a6d6c1bfa3decac79d0">DMG_TYPE</a>   0x01</td></tr> 188<tr class="separator:a0031c07799247a6d6c1bfa3decac79d0"><td class="memSeparator" colspan="2"> </td></tr> 189<tr class="memitem:ae996ed4fd8bb6b308b9c8708a91df06b"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#ae996ed4fd8bb6b308b9c8708a91df06b">MGB_TYPE</a>   0xFF</td></tr> 190<tr class="separator:ae996ed4fd8bb6b308b9c8708a91df06b"><td class="memSeparator" colspan="2"> </td></tr> 191<tr class="memitem:aee435a3a0dde3dbd7b6112dbb456cde8"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#aee435a3a0dde3dbd7b6112dbb456cde8">CGB_TYPE</a>   0x11</td></tr> 192<tr class="separator:aee435a3a0dde3dbd7b6112dbb456cde8"><td class="memSeparator" colspan="2"> </td></tr> 193<tr class="memitem:aa311f84dd9fce6e136ba4881e7b0d98d"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#aa311f84dd9fce6e136ba4881e7b0d98d">GBA_NOT_DETECTED</a>   0x00</td></tr> 194<tr class="separator:aa311f84dd9fce6e136ba4881e7b0d98d"><td class="memSeparator" colspan="2"> </td></tr> 195<tr class="memitem:a6ccf5d0f34fb0af0b6e73b9df0ccd745"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a6ccf5d0f34fb0af0b6e73b9df0ccd745">GBA_DETECTED</a>   0x01</td></tr> 196<tr class="separator:a6ccf5d0f34fb0af0b6e73b9df0ccd745"><td class="memSeparator" colspan="2"> </td></tr> 197<tr class="memitem:a231ec05679809190782e61c6e8aaaba4"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a231ec05679809190782e61c6e8aaaba4">DEVICE_SUPPORTS_COLOR</a>   (<a class="el" href="gb_8h.html#a874b9bd95b0a05d6a6072feabc879e45">_cpu</a> == <a class="el" href="gb_8h.html#aee435a3a0dde3dbd7b6112dbb456cde8">CGB_TYPE</a>)</td></tr> 198<tr class="separator:a231ec05679809190782e61c6e8aaaba4"><td class="memSeparator" colspan="2"> </td></tr> 199<tr class="memitem:a268cc6c704e16f3fa02dd1cf0e17070a"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a268cc6c704e16f3fa02dd1cf0e17070a">IO_IDLE</a>   0x00U</td></tr> 200<tr class="separator:a268cc6c704e16f3fa02dd1cf0e17070a"><td class="memSeparator" colspan="2"> </td></tr> 201<tr class="memitem:ab69a3f7cd2c6b5eb4f518aefee099007"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#ab69a3f7cd2c6b5eb4f518aefee099007">IO_SENDING</a>   0x01U</td></tr> 202<tr class="separator:ab69a3f7cd2c6b5eb4f518aefee099007"><td class="memSeparator" colspan="2"> </td></tr> 203<tr class="memitem:aee03efddee0f2f6fbcaec789301aaa9b"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#aee03efddee0f2f6fbcaec789301aaa9b">IO_RECEIVING</a>   0x02U</td></tr> 204<tr class="separator:aee03efddee0f2f6fbcaec789301aaa9b"><td class="memSeparator" colspan="2"> </td></tr> 205<tr class="memitem:a5d4c9c7b61a0326a939f9109f96d7423"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a5d4c9c7b61a0326a939f9109f96d7423">IO_ERROR</a>   0x04U</td></tr> 206<tr class="separator:a5d4c9c7b61a0326a939f9109f96d7423"><td class="memSeparator" colspan="2"> </td></tr> 207<tr class="memitem:ae042588f20bf5a2349c8ad8716245233"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#ae042588f20bf5a2349c8ad8716245233">CURRENT_BANK</a>   <a class="el" href="gb_8h.html#a98b848953a95ce2fff6fda643575d74a">_current_bank</a></td></tr> 208<tr class="separator:ae042588f20bf5a2349c8ad8716245233"><td class="memSeparator" colspan="2"> </td></tr> 209<tr class="memitem:a42705001e2b9897f5167b67fb36c69dd"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a42705001e2b9897f5167b67fb36c69dd">BANK</a>(VARNAME)   ( (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a>) & __bank_ ## VARNAME )</td></tr> 210<tr class="separator:a42705001e2b9897f5167b67fb36c69dd"><td class="memSeparator" colspan="2"> </td></tr> 211<tr class="memitem:a086293f2afb4c7945460a4496b20aea3"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a086293f2afb4c7945460a4496b20aea3">BANKREF</a>(VARNAME)</td></tr> 212<tr class="separator:a086293f2afb4c7945460a4496b20aea3"><td class="memSeparator" colspan="2"> </td></tr> 213<tr class="memitem:a261bba55a07b802baf99346feadd9852"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a261bba55a07b802baf99346feadd9852">BANKREF_EXTERN</a>(VARNAME)   extern const void __bank_ ## VARNAME;</td></tr> 214<tr class="separator:a261bba55a07b802baf99346feadd9852"><td class="memSeparator" colspan="2"> </td></tr> 215<tr class="memitem:a3fca2d0a22aa2717e62fed659caf4743"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a3fca2d0a22aa2717e62fed659caf4743">SWITCH_ROM_MEGADUCK</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a>)    <a class="el" href="gb_8h.html#a98b848953a95ce2fff6fda643575d74a">_current_bank</a> = (<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a>), *(<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *)0x0001 = (<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a>)</td></tr> 216<tr class="separator:a3fca2d0a22aa2717e62fed659caf4743"><td class="memSeparator" colspan="2"> </td></tr> 217<tr class="memitem:a19558f5bbc9fea767f945001ae9cd13f"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a19558f5bbc9fea767f945001ae9cd13f">SWITCH_ROM_MBC1</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a>)    <a class="el" href="gb_8h.html#a98b848953a95ce2fff6fda643575d74a">_current_bank</a> = (<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a>), *(<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *)0x2000 = (<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a>)</td></tr> 218<tr class="separator:a19558f5bbc9fea767f945001ae9cd13f"><td class="memSeparator" colspan="2"> </td></tr> 219<tr class="memitem:a1e22a3b60368bb5f3705d625ac2d09cc"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a1e22a3b60368bb5f3705d625ac2d09cc">SWITCH_ROM</a>   <a class="el" href="gb_8h.html#a19558f5bbc9fea767f945001ae9cd13f">SWITCH_ROM_MBC1</a></td></tr> 220<tr class="separator:a1e22a3b60368bb5f3705d625ac2d09cc"><td class="memSeparator" colspan="2"> </td></tr> 221<tr class="memitem:a38ea3e4dfe02b8eae70df27f39d4a951"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a38ea3e4dfe02b8eae70df27f39d4a951">SWITCH_RAM_MBC1</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a>)    *(<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *)0x4000 = (<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a>)</td></tr> 222<tr class="separator:a38ea3e4dfe02b8eae70df27f39d4a951"><td class="memSeparator" colspan="2"> </td></tr> 223<tr class="memitem:a6e40dcc763efd953181c7400642a9f69"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a6e40dcc763efd953181c7400642a9f69">SWITCH_RAM</a>   <a class="el" href="gb_8h.html#a38ea3e4dfe02b8eae70df27f39d4a951">SWITCH_RAM_MBC1</a></td></tr> 224<tr class="separator:a6e40dcc763efd953181c7400642a9f69"><td class="memSeparator" colspan="2"> </td></tr> 225<tr class="memitem:ae202f64307ec00f6970ef9225e54646c"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#ae202f64307ec00f6970ef9225e54646c">ENABLE_RAM_MBC1</a>    *(<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *)0x0000 = 0x0A</td></tr> 226<tr class="separator:ae202f64307ec00f6970ef9225e54646c"><td class="memSeparator" colspan="2"> </td></tr> 227<tr class="memitem:a0e9c88657beaac946231a4801481b97f"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a0e9c88657beaac946231a4801481b97f">ENABLE_RAM</a>   <a class="el" href="gb_8h.html#ae202f64307ec00f6970ef9225e54646c">ENABLE_RAM_MBC1</a></td></tr> 228<tr class="separator:a0e9c88657beaac946231a4801481b97f"><td class="memSeparator" colspan="2"> </td></tr> 229<tr class="memitem:a177fadce938422926b186a8e42575d1d"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a177fadce938422926b186a8e42575d1d">DISABLE_RAM_MBC1</a>    *(<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *)0x0000 = 0x00</td></tr> 230<tr class="separator:a177fadce938422926b186a8e42575d1d"><td class="memSeparator" colspan="2"> </td></tr> 231<tr class="memitem:a649d27b5587de16a66176e03a1b8ebd5"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a649d27b5587de16a66176e03a1b8ebd5">DISABLE_RAM</a>   <a class="el" href="gb_8h.html#a177fadce938422926b186a8e42575d1d">DISABLE_RAM_MBC1</a></td></tr> 232<tr class="separator:a649d27b5587de16a66176e03a1b8ebd5"><td class="memSeparator" colspan="2"> </td></tr> 233<tr class="memitem:a0c689c5a814f1c347c4d98f28ed6c7d6"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a0c689c5a814f1c347c4d98f28ed6c7d6">SWITCH_16_8_MODE_MBC1</a>    *(<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *)0x6000 = 0x00</td></tr> 234<tr class="separator:a0c689c5a814f1c347c4d98f28ed6c7d6"><td class="memSeparator" colspan="2"> </td></tr> 235<tr class="memitem:aa5d64e386a00b373f22ffdc5a152c7ba"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#aa5d64e386a00b373f22ffdc5a152c7ba">SWITCH_4_32_MODE_MBC1</a>    *(<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *)0x6000 = 0x01</td></tr> 236<tr class="separator:aa5d64e386a00b373f22ffdc5a152c7ba"><td class="memSeparator" colspan="2"> </td></tr> 237<tr class="memitem:a92d040284342702026eb19dab59b586e"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a92d040284342702026eb19dab59b586e">SWITCH_ROM_MBC5</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a>)</td></tr> 238<tr class="separator:a92d040284342702026eb19dab59b586e"><td class="memSeparator" colspan="2"> </td></tr> 239<tr class="memitem:a6c15ebc660abd3a978137493ab63ffe9"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a6c15ebc660abd3a978137493ab63ffe9">SWITCH_ROM_MBC5_8M</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a>)</td></tr> 240<tr class="separator:a6c15ebc660abd3a978137493ab63ffe9"><td class="memSeparator" colspan="2"> </td></tr> 241<tr class="memitem:a361d5055a7ae880fc1c9d6e0d1164fd6"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a361d5055a7ae880fc1c9d6e0d1164fd6">SWITCH_RAM_MBC5</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a>)    *(<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *)0x4000 = (<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a>)</td></tr> 242<tr class="separator:a361d5055a7ae880fc1c9d6e0d1164fd6"><td class="memSeparator" colspan="2"> </td></tr> 243<tr class="memitem:a3f033f00c8d781637f9a665b06750937"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a3f033f00c8d781637f9a665b06750937">ENABLE_RAM_MBC5</a>    *(<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *)0x0000 = 0x0A</td></tr> 244<tr class="separator:a3f033f00c8d781637f9a665b06750937"><td class="memSeparator" colspan="2"> </td></tr> 245<tr class="memitem:a60191cdfa50ed9b88515f181747eaba2"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a60191cdfa50ed9b88515f181747eaba2">DISABLE_RAM_MBC5</a>    *(<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *)0x0000 = 0x00</td></tr> 246<tr class="separator:a60191cdfa50ed9b88515f181747eaba2"><td class="memSeparator" colspan="2"> </td></tr> 247<tr class="memitem:a5ae6b05b3e1559c97f0d1b2daaaa0ee4"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a5ae6b05b3e1559c97f0d1b2daaaa0ee4">DISPLAY_ON</a>    <a class="el" href="gb_2hardware_8h.html#a6515fdfaa50eeb7e63faeea54f77cd6b">LCDC_REG</a>|=<a class="el" href="gb_2hardware_8h.html#a1491fc03ed7f02e7309cc7b0c48b6c8a">LCDCF_ON</a></td></tr> 248<tr class="separator:a5ae6b05b3e1559c97f0d1b2daaaa0ee4"><td class="memSeparator" colspan="2"> </td></tr> 249<tr class="memitem:ad2ec9831813c5e7069917aa4455af682"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#ad2ec9831813c5e7069917aa4455af682">DISPLAY_OFF</a>    <a class="el" href="sms_8h.html#a7b09691f25fddd65f12ed199b3f88ef0">display_off</a>();</td></tr> 250<tr class="separator:ad2ec9831813c5e7069917aa4455af682"><td class="memSeparator" colspan="2"> </td></tr> 251<tr class="memitem:a0659212acd317ccdebc0ecf435df330f"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a0659212acd317ccdebc0ecf435df330f">HIDE_LEFT_COLUMN</a></td></tr> 252<tr class="separator:a0659212acd317ccdebc0ecf435df330f"><td class="memSeparator" colspan="2"> </td></tr> 253<tr class="memitem:a5497c2255a9474d397446710189eacbe"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a5497c2255a9474d397446710189eacbe">SHOW_LEFT_COLUMN</a></td></tr> 254<tr class="separator:a5497c2255a9474d397446710189eacbe"><td class="memSeparator" colspan="2"> </td></tr> 255<tr class="memitem:a8e3f36aa68ac036695816757f2a1322c"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a8e3f36aa68ac036695816757f2a1322c">SHOW_BKG</a>    <a class="el" href="gb_2hardware_8h.html#a6515fdfaa50eeb7e63faeea54f77cd6b">LCDC_REG</a>|=<a class="el" href="gb_2hardware_8h.html#a97ab19d938f05bffbcb4221824c3bfce">LCDCF_BGON</a></td></tr> 256<tr class="separator:a8e3f36aa68ac036695816757f2a1322c"><td class="memSeparator" colspan="2"> </td></tr> 257<tr class="memitem:a6d25f7c43b1cbbb48b95cda7ab2c3141"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a6d25f7c43b1cbbb48b95cda7ab2c3141">HIDE_BKG</a>    <a class="el" href="gb_2hardware_8h.html#a6515fdfaa50eeb7e63faeea54f77cd6b">LCDC_REG</a>&=~<a class="el" href="gb_2hardware_8h.html#a97ab19d938f05bffbcb4221824c3bfce">LCDCF_BGON</a></td></tr> 258<tr class="separator:a6d25f7c43b1cbbb48b95cda7ab2c3141"><td class="memSeparator" colspan="2"> </td></tr> 259<tr class="memitem:ab19da2ab719bb8897bc0843a84af28f8"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#ab19da2ab719bb8897bc0843a84af28f8">SHOW_WIN</a>    <a class="el" href="gb_2hardware_8h.html#a6515fdfaa50eeb7e63faeea54f77cd6b">LCDC_REG</a>|=<a class="el" href="gb_2hardware_8h.html#a13a5f08b9aae68f8fa57a8aa7705b732">LCDCF_WINON</a></td></tr> 260<tr class="separator:ab19da2ab719bb8897bc0843a84af28f8"><td class="memSeparator" colspan="2"> </td></tr> 261<tr class="memitem:aedb6e32c42d4b1d25ad11adccd7100c3"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#aedb6e32c42d4b1d25ad11adccd7100c3">HIDE_WIN</a>    <a class="el" href="gb_2hardware_8h.html#a6515fdfaa50eeb7e63faeea54f77cd6b">LCDC_REG</a>&=~<a class="el" href="gb_2hardware_8h.html#a13a5f08b9aae68f8fa57a8aa7705b732">LCDCF_WINON</a></td></tr> 262<tr class="separator:aedb6e32c42d4b1d25ad11adccd7100c3"><td class="memSeparator" colspan="2"> </td></tr> 263<tr class="memitem:a495bc9f405f916f02ad5d97e6e730134"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a495bc9f405f916f02ad5d97e6e730134">SHOW_SPRITES</a>    <a class="el" href="gb_2hardware_8h.html#a6515fdfaa50eeb7e63faeea54f77cd6b">LCDC_REG</a>|=<a class="el" href="gb_2hardware_8h.html#a6aef42158c90e8025b8341cdea2e3918">LCDCF_OBJON</a></td></tr> 264<tr class="separator:a495bc9f405f916f02ad5d97e6e730134"><td class="memSeparator" colspan="2"> </td></tr> 265<tr class="memitem:a69ef98aee664b8abd8d1a3d45f016dda"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a69ef98aee664b8abd8d1a3d45f016dda">HIDE_SPRITES</a>    <a class="el" href="gb_2hardware_8h.html#a6515fdfaa50eeb7e63faeea54f77cd6b">LCDC_REG</a>&=~<a class="el" href="gb_2hardware_8h.html#a6aef42158c90e8025b8341cdea2e3918">LCDCF_OBJON</a></td></tr> 266<tr class="separator:a69ef98aee664b8abd8d1a3d45f016dda"><td class="memSeparator" colspan="2"> </td></tr> 267<tr class="memitem:af91d252f07f4764996154820f970c101"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#af91d252f07f4764996154820f970c101">SPRITES_8x16</a>    <a class="el" href="gb_2hardware_8h.html#a6515fdfaa50eeb7e63faeea54f77cd6b">LCDC_REG</a>|=<a class="el" href="gb_2hardware_8h.html#a14eddd3d53d8e649f1754bd455b4863d">LCDCF_OBJ16</a></td></tr> 268<tr class="separator:af91d252f07f4764996154820f970c101"><td class="memSeparator" colspan="2"> </td></tr> 269<tr class="memitem:aa87bec0d134136fdb727f52cb773b792"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#aa87bec0d134136fdb727f52cb773b792">SPRITES_8x8</a>    <a class="el" href="gb_2hardware_8h.html#a6515fdfaa50eeb7e63faeea54f77cd6b">LCDC_REG</a>&=~<a class="el" href="gb_2hardware_8h.html#a14eddd3d53d8e649f1754bd455b4863d">LCDCF_OBJ16</a></td></tr> 270<tr class="separator:aa87bec0d134136fdb727f52cb773b792"><td class="memSeparator" colspan="2"> </td></tr> 271<tr class="memitem:a67f80e65620470b55a4950e2966eb868"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a67f80e65620470b55a4950e2966eb868">COMPAT_PALETTE</a>(C0, C1, C2, C3)   ((<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a>)(((C3) << 6) | ((C2) << 4) | ((C1) << 2) | (C0)))</td></tr> 272<tr class="separator:a67f80e65620470b55a4950e2966eb868"><td class="memSeparator" colspan="2"> </td></tr> 273<tr class="memitem:ab94bfec130df50d9cb808142f94603a5"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#ab94bfec130df50d9cb808142f94603a5">set_bkg_2bpp_data</a>   <a class="el" href="sms_8h.html#a8130306da1177f4fef89e699f8e2add4">set_bkg_data</a></td></tr> 274<tr class="separator:ab94bfec130df50d9cb808142f94603a5"><td class="memSeparator" colspan="2"> </td></tr> 275<tr class="memitem:a55f82ff980398dd97036fd936ebd727e"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a55f82ff980398dd97036fd936ebd727e">set_tile_map</a>   <a class="el" href="gb_8h.html#a6da9e2fa1bafd35363e84ee999909ec7">set_bkg_tiles</a></td></tr> 276<tr class="separator:a55f82ff980398dd97036fd936ebd727e"><td class="memSeparator" colspan="2"> </td></tr> 277<tr class="memitem:adb5d0970167b81401113812773c90838"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#adb5d0970167b81401113812773c90838">set_tile_submap</a>   <a class="el" href="sms_8h.html#a0cfd261bc7a94b1f6093f423bad30298">set_bkg_submap</a></td></tr> 278<tr class="separator:adb5d0970167b81401113812773c90838"><td class="memSeparator" colspan="2"> </td></tr> 279<tr class="memitem:a3b235c526c517fb02d20cdea780ee2c5"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a3b235c526c517fb02d20cdea780ee2c5">set_tile_xy</a>   <a class="el" href="gb_8h.html#a74ee8f0a3495508c90de4ce246b81060">set_bkg_tile_xy</a></td></tr> 280<tr class="separator:a3b235c526c517fb02d20cdea780ee2c5"><td class="memSeparator" colspan="2"> </td></tr> 281<tr class="memitem:a43b4f0ba65856deef626c0d9e7e41ed4"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a43b4f0ba65856deef626c0d9e7e41ed4">set_sprite_2bpp_data</a>   <a class="el" href="sms_8h.html#a216a3e3d320ee4d8cf4845600487ae39">set_sprite_data</a></td></tr> 282<tr class="separator:a43b4f0ba65856deef626c0d9e7e41ed4"><td class="memSeparator" colspan="2"> </td></tr> 283<tr class="memitem:a47607089a434dcda7a8583cfca03b604"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a47607089a434dcda7a8583cfca03b604">DISABLE_OAM_DMA</a>    <a class="el" href="sms_8h.html#a5435fd985412934e96a490e103c6bc49">_shadow_OAM_base</a> = 0</td></tr> 284<tr class="separator:a47607089a434dcda7a8583cfca03b604"><td class="memSeparator" colspan="2"> </td></tr> 285<tr class="memitem:abfd70bf31185a4900680977c9fb5a5ec"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#abfd70bf31185a4900680977c9fb5a5ec">DISABLE_VBL_TRANSFER</a>   <a class="el" href="gb_8h.html#a47607089a434dcda7a8583cfca03b604">DISABLE_OAM_DMA</a></td></tr> 286<tr class="separator:abfd70bf31185a4900680977c9fb5a5ec"><td class="memSeparator" colspan="2"> </td></tr> 287<tr class="memitem:a20895d53fe9caacb08ce8b071d57ce53"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a20895d53fe9caacb08ce8b071d57ce53">ENABLE_OAM_DMA</a>    <a class="el" href="sms_8h.html#a5435fd985412934e96a490e103c6bc49">_shadow_OAM_base</a> = (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a>)((<a class="el" href="stdint_8h.html#adf4d876453337156dde61095e1f20223">uint16_t</a>)&<a class="el" href="sms_8h.html#af02f9e73bd894cc25e03aedb0a10a91d">shadow_OAM</a> >> 8)</td></tr> 288<tr class="separator:a20895d53fe9caacb08ce8b071d57ce53"><td class="memSeparator" colspan="2"> </td></tr> 289<tr class="memitem:a77d516c9d3f86f100eddea5e0d133a76"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a77d516c9d3f86f100eddea5e0d133a76">ENABLE_VBL_TRANSFER</a>   <a class="el" href="gb_8h.html#a20895d53fe9caacb08ce8b071d57ce53">ENABLE_OAM_DMA</a></td></tr> 290<tr class="separator:a77d516c9d3f86f100eddea5e0d133a76"><td class="memSeparator" colspan="2"> </td></tr> 291<tr class="memitem:a8b77608c87a9aef65a03531482b2163b"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a8b77608c87a9aef65a03531482b2163b">MAX_HARDWARE_SPRITES</a>   40</td></tr> 292<tr class="separator:a8b77608c87a9aef65a03531482b2163b"><td class="memSeparator" colspan="2"> </td></tr> 293<tr class="memitem:a47865835d7d007d71b4bc8ae5cefb73a"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a47865835d7d007d71b4bc8ae5cefb73a">fill_rect</a>   <a class="el" href="gb_8h.html#a74c3f53fca019f7abcd1270650808849">fill_bkg_rect</a></td></tr> 294<tr class="separator:a47865835d7d007d71b4bc8ae5cefb73a"><td class="memSeparator" colspan="2"> </td></tr> 295</table><table class="memberdecls"> 296<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="typedef-members"></a> 297Typedefs</h2></td></tr> 298<tr class="memitem:a9508f919d9482d1d51534ccac212454d"><td class="memItemLeft" align="right" valign="top">typedef void(* </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a9508f919d9482d1d51534ccac212454d">int_handler</a>) (void) <a class="el" href="asm_2types_8h.html#a7ed081d8dfb6902784b2fc730bbb7f96">NONBANKED</a></td></tr> 299<tr class="separator:a9508f919d9482d1d51534ccac212454d"><td class="memSeparator" colspan="2"> </td></tr> 300<tr class="memitem:a8e5ea12b86bdfc812448c2f5c4336c03"><td class="memItemLeft" align="right" valign="top">typedef struct <a class="el" href="struct_o_a_m__item__t.html">OAM_item_t</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a8e5ea12b86bdfc812448c2f5c4336c03">OAM_item_t</a></td></tr> 301<tr class="separator:a8e5ea12b86bdfc812448c2f5c4336c03"><td class="memSeparator" colspan="2"> </td></tr> 302</table><table class="memberdecls"> 303<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a> 304Functions</h2></td></tr> 305<tr class="memitem:ad43fdfdb1e157b141f3fc48b78bf4386"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#ad43fdfdb1e157b141f3fc48b78bf4386">remove_VBL</a> (<a class="el" href="sms_8h.html#a9508f919d9482d1d51534ccac212454d">int_handler</a> <a class="el" href="sms_8h.html#a1f1dfeb2f802fe99f37fe91867b84456">h</a>) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a></td></tr> 306<tr class="separator:ad43fdfdb1e157b141f3fc48b78bf4386"><td class="memSeparator" colspan="2"> </td></tr> 307<tr class="memitem:a32683767caa2a263a1f494b3605786e7"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a32683767caa2a263a1f494b3605786e7">remove_LCD</a> (<a class="el" href="sms_8h.html#a9508f919d9482d1d51534ccac212454d">int_handler</a> <a class="el" href="sms_8h.html#a1f1dfeb2f802fe99f37fe91867b84456">h</a>) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a></td></tr> 308<tr class="separator:a32683767caa2a263a1f494b3605786e7"><td class="memSeparator" colspan="2"> </td></tr> 309<tr class="memitem:a142f6c7755fce8b1148faf658d8ec147"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a142f6c7755fce8b1148faf658d8ec147">remove_TIM</a> (<a class="el" href="sms_8h.html#a9508f919d9482d1d51534ccac212454d">int_handler</a> <a class="el" href="sms_8h.html#a1f1dfeb2f802fe99f37fe91867b84456">h</a>) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a></td></tr> 310<tr class="separator:a142f6c7755fce8b1148faf658d8ec147"><td class="memSeparator" colspan="2"> </td></tr> 311<tr class="memitem:a5b821b31215361265d8b7894a9ae7118"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a5b821b31215361265d8b7894a9ae7118">remove_SIO</a> (<a class="el" href="sms_8h.html#a9508f919d9482d1d51534ccac212454d">int_handler</a> <a class="el" href="sms_8h.html#a1f1dfeb2f802fe99f37fe91867b84456">h</a>) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a></td></tr> 312<tr class="separator:a5b821b31215361265d8b7894a9ae7118"><td class="memSeparator" colspan="2"> </td></tr> 313<tr class="memitem:a4a3e87e0917d5efb6bc7c94e9754fcd0"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a4a3e87e0917d5efb6bc7c94e9754fcd0">remove_JOY</a> (<a class="el" href="sms_8h.html#a9508f919d9482d1d51534ccac212454d">int_handler</a> <a class="el" href="sms_8h.html#a1f1dfeb2f802fe99f37fe91867b84456">h</a>) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a></td></tr> 314<tr class="separator:a4a3e87e0917d5efb6bc7c94e9754fcd0"><td class="memSeparator" colspan="2"> </td></tr> 315<tr class="memitem:a0d29659d08708143dd8bc720278e06b5"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a0d29659d08708143dd8bc720278e06b5">add_VBL</a> (<a class="el" href="sms_8h.html#a9508f919d9482d1d51534ccac212454d">int_handler</a> <a class="el" href="sms_8h.html#a1f1dfeb2f802fe99f37fe91867b84456">h</a>) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a></td></tr> 316<tr class="separator:a0d29659d08708143dd8bc720278e06b5"><td class="memSeparator" colspan="2"> </td></tr> 317<tr class="memitem:a9f9f77105099a34556247d5bb03368d1"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a9f9f77105099a34556247d5bb03368d1">add_LCD</a> (<a class="el" href="sms_8h.html#a9508f919d9482d1d51534ccac212454d">int_handler</a> <a class="el" href="sms_8h.html#a1f1dfeb2f802fe99f37fe91867b84456">h</a>) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a></td></tr> 318<tr class="separator:a9f9f77105099a34556247d5bb03368d1"><td class="memSeparator" colspan="2"> </td></tr> 319<tr class="memitem:a028d1a2e820951bb4f103d6469975ffb"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a028d1a2e820951bb4f103d6469975ffb">add_TIM</a> (<a class="el" href="sms_8h.html#a9508f919d9482d1d51534ccac212454d">int_handler</a> <a class="el" href="sms_8h.html#a1f1dfeb2f802fe99f37fe91867b84456">h</a>) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a></td></tr> 320<tr class="separator:a028d1a2e820951bb4f103d6469975ffb"><td class="memSeparator" colspan="2"> </td></tr> 321<tr class="memitem:a970f18857533e062f4780f6e1c407d69"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a970f18857533e062f4780f6e1c407d69">add_low_priority_TIM</a> (<a class="el" href="sms_8h.html#a9508f919d9482d1d51534ccac212454d">int_handler</a> <a class="el" href="sms_8h.html#a1f1dfeb2f802fe99f37fe91867b84456">h</a>) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a></td></tr> 322<tr class="separator:a970f18857533e062f4780f6e1c407d69"><td class="memSeparator" colspan="2"> </td></tr> 323<tr class="memitem:aa82422752016328ed0765879e286019f"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#aa82422752016328ed0765879e286019f">add_SIO</a> (<a class="el" href="sms_8h.html#a9508f919d9482d1d51534ccac212454d">int_handler</a> <a class="el" href="sms_8h.html#a1f1dfeb2f802fe99f37fe91867b84456">h</a>) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a></td></tr> 324<tr class="separator:aa82422752016328ed0765879e286019f"><td class="memSeparator" colspan="2"> </td></tr> 325<tr class="memitem:aa2f0235e78da2d1d94d3628d7a1afc30"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#aa2f0235e78da2d1d94d3628d7a1afc30">add_JOY</a> (<a class="el" href="sms_8h.html#a9508f919d9482d1d51534ccac212454d">int_handler</a> <a class="el" href="sms_8h.html#a1f1dfeb2f802fe99f37fe91867b84456">h</a>) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a></td></tr> 326<tr class="separator:aa2f0235e78da2d1d94d3628d7a1afc30"><td class="memSeparator" colspan="2"> </td></tr> 327<tr class="memitem:a695c6d0e8fd7cf11dae0d4c67bc058f9"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a695c6d0e8fd7cf11dae0d4c67bc058f9">nowait_int_handler</a> ()</td></tr> 328<tr class="separator:a695c6d0e8fd7cf11dae0d4c67bc058f9"><td class="memSeparator" colspan="2"> </td></tr> 329<tr class="memitem:acc9afd0cb72e763a1213d256b942a68f"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#acc9afd0cb72e763a1213d256b942a68f">wait_int_handler</a> ()</td></tr> 330<tr class="separator:acc9afd0cb72e763a1213d256b942a68f"><td class="memSeparator" colspan="2"> </td></tr> 331<tr class="memitem:ade5d4c955b871b0ed884273cc2b7215a"><td class="memItemLeft" align="right" valign="top"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#ade5d4c955b871b0ed884273cc2b7215a">cancel_pending_interrupts</a> ()</td></tr> 332<tr class="separator:ade5d4c955b871b0ed884273cc2b7215a"><td class="memSeparator" colspan="2"> </td></tr> 333<tr class="memitem:a3ea524204d839377cf39842eec23e202"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a3ea524204d839377cf39842eec23e202">mode</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> m) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a></td></tr> 334<tr class="separator:a3ea524204d839377cf39842eec23e202"><td class="memSeparator" colspan="2"> </td></tr> 335<tr class="memitem:a19969b36a6535fc6a966c0e5476baf9c"><td class="memItemLeft" align="right" valign="top"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a19969b36a6535fc6a966c0e5476baf9c">get_mode</a> () <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 336<tr class="separator:a19969b36a6535fc6a966c0e5476baf9c"><td class="memSeparator" colspan="2"> </td></tr> 337<tr class="memitem:ae339d7d8d7e0ebd6691b42608c416964"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#ae339d7d8d7e0ebd6691b42608c416964">send_byte</a> ()</td></tr> 338<tr class="separator:ae339d7d8d7e0ebd6691b42608c416964"><td class="memSeparator" colspan="2"> </td></tr> 339<tr class="memitem:a9a7fd7be44bb12bc85a144b732ce02f7"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a9a7fd7be44bb12bc85a144b732ce02f7">receive_byte</a> ()</td></tr> 340<tr class="separator:a9a7fd7be44bb12bc85a144b732ce02f7"><td class="memSeparator" colspan="2"> </td></tr> 341<tr class="memitem:a2afae202a1f8ca59a12a6455bb909c5d"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a2afae202a1f8ca59a12a6455bb909c5d">delay</a> (<a class="el" href="stdint_8h.html#adf4d876453337156dde61095e1f20223">uint16_t</a> <a class="el" href="sms_8h.html#a0a3d95ad0ab8ad213016101d2e9c3d3e">d</a>) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a></td></tr> 342<tr class="separator:a2afae202a1f8ca59a12a6455bb909c5d"><td class="memSeparator" colspan="2"> </td></tr> 343<tr class="memitem:a176c477d759b814664785f3a0ad5e253"><td class="memItemLeft" align="right" valign="top"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a176c477d759b814664785f3a0ad5e253">joypad</a> () <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 344<tr class="separator:a176c477d759b814664785f3a0ad5e253"><td class="memSeparator" colspan="2"> </td></tr> 345<tr class="memitem:aae433db7d8e3ee4c095c254b8abd7b8b"><td class="memItemLeft" align="right" valign="top"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#aae433db7d8e3ee4c095c254b8abd7b8b">waitpad</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> mask) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 346<tr class="separator:aae433db7d8e3ee4c095c254b8abd7b8b"><td class="memSeparator" colspan="2"> </td></tr> 347<tr class="memitem:a8484d346b788309ac702b7e0b1fca730"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a8484d346b788309ac702b7e0b1fca730">waitpadup</a> () <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(a</td></tr> 348<tr class="separator:a8484d346b788309ac702b7e0b1fca730"><td class="memSeparator" colspan="2"> </td></tr> 349<tr class="memitem:ab7e35e1eff44ed78ad8f0015c6e85b4e"><td class="memItemLeft" align="right" valign="top"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#ab7e35e1eff44ed78ad8f0015c6e85b4e">joypad_init</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> npads, <a class="el" href="structjoypads__t.html">joypads_t</a> *joypads) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a></td></tr> 350<tr class="separator:ab7e35e1eff44ed78ad8f0015c6e85b4e"><td class="memSeparator" colspan="2"> </td></tr> 351<tr class="memitem:a6e6f8eb1de2ae1ec9adeafbd7b9884db"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a6e6f8eb1de2ae1ec9adeafbd7b9884db">joypad_ex</a> (<a class="el" href="structjoypads__t.html">joypads_t</a> *joypads) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 352<tr class="separator:a6e6f8eb1de2ae1ec9adeafbd7b9884db"><td class="memSeparator" colspan="2"> </td></tr> 353<tr class="memitem:ae0b13f17609b26c86fc33944aeb6e867"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#ae0b13f17609b26c86fc33944aeb6e867">enable_interrupts</a> () <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(a</td></tr> 354<tr class="separator:ae0b13f17609b26c86fc33944aeb6e867"><td class="memSeparator" colspan="2"> </td></tr> 355<tr class="memitem:ad77796783b3a601b6f3781dfc3983499"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#ad77796783b3a601b6f3781dfc3983499">disable_interrupts</a> () <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(a</td></tr> 356<tr class="separator:ad77796783b3a601b6f3781dfc3983499"><td class="memSeparator" colspan="2"> </td></tr> 357<tr class="memitem:a9312e7ec34162d6b6ed0875631fa6fe3"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a9312e7ec34162d6b6ed0875631fa6fe3">set_interrupts</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> flags) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 358<tr class="separator:a9312e7ec34162d6b6ed0875631fa6fe3"><td class="memSeparator" colspan="2"> </td></tr> 359<tr class="memitem:ad20897c5c8bd47f5d4005989bead0e55"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#ad20897c5c8bd47f5d4005989bead0e55">reset</a> ()</td></tr> 360<tr class="separator:ad20897c5c8bd47f5d4005989bead0e55"><td class="memSeparator" colspan="2"> </td></tr> 361<tr class="memitem:acd186eb292d441f9389e77b545a55619"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#acd186eb292d441f9389e77b545a55619">wait_vbl_done</a> () <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 362<tr class="separator:acd186eb292d441f9389e77b545a55619"><td class="memSeparator" colspan="2"> </td></tr> 363<tr class="memitem:a04d57683cdd046dfa45e7e56d7c4ec4d"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a04d57683cdd046dfa45e7e56d7c4ec4d">display_off</a> () <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 364<tr class="separator:a04d57683cdd046dfa45e7e56d7c4ec4d"><td class="memSeparator" colspan="2"> </td></tr> 365<tr class="memitem:a2550e7b6b9fd7e1fc495872502311dbb"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a2550e7b6b9fd7e1fc495872502311dbb">refresh_OAM</a> () <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 366<tr class="separator:a2550e7b6b9fd7e1fc495872502311dbb"><td class="memSeparator" colspan="2"> </td></tr> 367<tr class="memitem:a97b9f2fc6ac7cae97656aca940d65d44"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a97b9f2fc6ac7cae97656aca940d65d44">hiramcpy</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> dst, const void *src, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> n) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 368<tr class="separator:a97b9f2fc6ac7cae97656aca940d65d44"><td class="memSeparator" colspan="2"> </td></tr> 369<tr class="memitem:a7080649e10765996c581e5b618e603b8"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a7080649e10765996c581e5b618e603b8">set_vram_byte</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *addr, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> v) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 370<tr class="separator:a7080649e10765996c581e5b618e603b8"><td class="memSeparator" colspan="2"> </td></tr> 371<tr class="memitem:aa33ba8b8d381df76edf15ea251ccb675"><td class="memItemLeft" align="right" valign="top"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#aa33ba8b8d381df76edf15ea251ccb675">get_vram_byte</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *addr) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 372<tr class="separator:aa33ba8b8d381df76edf15ea251ccb675"><td class="memSeparator" colspan="2"> </td></tr> 373<tr class="memitem:a9005b80d3315f50f0fb0e1728e7ee60f"><td class="memItemLeft" align="right" valign="top"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a9005b80d3315f50f0fb0e1728e7ee60f">get_bkg_xy_addr</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> x, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> y) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 374<tr class="separator:a9005b80d3315f50f0fb0e1728e7ee60f"><td class="memSeparator" colspan="2"> </td></tr> 375<tr class="memitem:aa224c9bac27c7fd268e62bdf33338a84"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#aa224c9bac27c7fd268e62bdf33338a84">set_2bpp_palette</a> (<a class="el" href="stdint_8h.html#adf4d876453337156dde61095e1f20223">uint16_t</a> palette)</td></tr> 376<tr class="separator:aa224c9bac27c7fd268e62bdf33338a84"><td class="memSeparator" colspan="2"> </td></tr> 377<tr class="memitem:a1f00bd35cd56aac84c108f5a802c3f9c"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a1f00bd35cd56aac84c108f5a802c3f9c">set_1bpp_colors_ex</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> fgcolor, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> bgcolor, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> <a class="el" href="sms_8h.html#a3ea524204d839377cf39842eec23e202">mode</a>) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a></td></tr> 378<tr class="separator:a1f00bd35cd56aac84c108f5a802c3f9c"><td class="memSeparator" colspan="2"> </td></tr> 379<tr class="memitem:adcb394299a1033616fc7d2faec8bd6ad"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#adcb394299a1033616fc7d2faec8bd6ad">set_1bpp_colors</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> fgcolor, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> bgcolor)</td></tr> 380<tr class="separator:adcb394299a1033616fc7d2faec8bd6ad"><td class="memSeparator" colspan="2"> </td></tr> 381<tr class="memitem:a1f5101f2b7bb0123c26a3e257f843626"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a1f5101f2b7bb0123c26a3e257f843626">set_bkg_data</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> first_tile, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> nb_tiles, const <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *data) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 382<tr class="separator:a1f5101f2b7bb0123c26a3e257f843626"><td class="memSeparator" colspan="2"> </td></tr> 383<tr class="memitem:a711fa26feecc76dc51482b0f77062859"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a711fa26feecc76dc51482b0f77062859">set_bkg_1bpp_data</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> first_tile, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> nb_tiles, const <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *data) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 384<tr class="separator:a711fa26feecc76dc51482b0f77062859"><td class="memSeparator" colspan="2"> </td></tr> 385<tr class="memitem:a5c13238dfec416439d75b133a272e6df"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a5c13238dfec416439d75b133a272e6df">get_bkg_data</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> first_tile, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> nb_tiles, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *data) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 386<tr class="separator:a5c13238dfec416439d75b133a272e6df"><td class="memSeparator" colspan="2"> </td></tr> 387<tr class="memitem:a6da9e2fa1bafd35363e84ee999909ec7"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a6da9e2fa1bafd35363e84ee999909ec7">set_bkg_tiles</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> x, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> y, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> w, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> <a class="el" href="sms_8h.html#a1f1dfeb2f802fe99f37fe91867b84456">h</a>, const <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *tiles) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 388<tr class="separator:a6da9e2fa1bafd35363e84ee999909ec7"><td class="memSeparator" colspan="2"> </td></tr> 389<tr class="memitem:a811c386cac0df2d260aacb5a43608be5"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a811c386cac0df2d260aacb5a43608be5">set_bkg_based_tiles</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> x, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> y, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> w, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> <a class="el" href="sms_8h.html#a1f1dfeb2f802fe99f37fe91867b84456">h</a>, const <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *tiles, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> base_tile)</td></tr> 390<tr class="separator:a811c386cac0df2d260aacb5a43608be5"><td class="memSeparator" colspan="2"> </td></tr> 391<tr class="memitem:adb21d1c7d533a7133bab36a845489780"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#adb21d1c7d533a7133bab36a845489780">set_bkg_submap</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> x, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> y, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> w, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> <a class="el" href="sms_8h.html#a1f1dfeb2f802fe99f37fe91867b84456">h</a>, const <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *map, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> map_w) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a></td></tr> 392<tr class="separator:adb21d1c7d533a7133bab36a845489780"><td class="memSeparator" colspan="2"> </td></tr> 393<tr class="memitem:abc8bc5808620a9717263b8c9ec2237f0"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#abc8bc5808620a9717263b8c9ec2237f0">set_bkg_based_submap</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> x, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> y, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> w, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> <a class="el" href="sms_8h.html#a1f1dfeb2f802fe99f37fe91867b84456">h</a>, const <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *map, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> map_w, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> base_tile)</td></tr> 394<tr class="separator:abc8bc5808620a9717263b8c9ec2237f0"><td class="memSeparator" colspan="2"> </td></tr> 395<tr class="memitem:aa6bcf24d97f93307b30f2906251f39a0"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#aa6bcf24d97f93307b30f2906251f39a0">get_bkg_tiles</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> x, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> y, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> w, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> <a class="el" href="sms_8h.html#a1f1dfeb2f802fe99f37fe91867b84456">h</a>, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *tiles) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 396<tr class="separator:aa6bcf24d97f93307b30f2906251f39a0"><td class="memSeparator" colspan="2"> </td></tr> 397<tr class="memitem:a74ee8f0a3495508c90de4ce246b81060"><td class="memItemLeft" align="right" valign="top"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a74ee8f0a3495508c90de4ce246b81060">set_bkg_tile_xy</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> x, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> y, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> t) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 398<tr class="separator:a74ee8f0a3495508c90de4ce246b81060"><td class="memSeparator" colspan="2"> </td></tr> 399<tr class="memitem:a55c6581dbe9300dc6df41730f090af51"><td class="memItemLeft" align="right" valign="top"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a55c6581dbe9300dc6df41730f090af51">get_bkg_tile_xy</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> x, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> y) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 400<tr class="separator:a55c6581dbe9300dc6df41730f090af51"><td class="memSeparator" colspan="2"> </td></tr> 401<tr class="memitem:a6261537edc74068e3f7f057e6a3e8a57"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a6261537edc74068e3f7f057e6a3e8a57">move_bkg</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> x, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> y)</td></tr> 402<tr class="separator:a6261537edc74068e3f7f057e6a3e8a57"><td class="memSeparator" colspan="2"> </td></tr> 403<tr class="memitem:a1f583f7a880daa6145ca78b086a209d1"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a1f583f7a880daa6145ca78b086a209d1">scroll_bkg</a> (<a class="el" href="stdint_8h.html#aef44329758059c91c76d334e8fc09700">int8_t</a> x, <a class="el" href="stdint_8h.html#aef44329758059c91c76d334e8fc09700">int8_t</a> y)</td></tr> 404<tr class="separator:a1f583f7a880daa6145ca78b086a209d1"><td class="memSeparator" colspan="2"> </td></tr> 405<tr class="memitem:aa8213cfad631865e3b6faec18e772cb4"><td class="memItemLeft" align="right" valign="top"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#aa8213cfad631865e3b6faec18e772cb4">get_win_xy_addr</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> x, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> y) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 406<tr class="separator:aa8213cfad631865e3b6faec18e772cb4"><td class="memSeparator" colspan="2"> </td></tr> 407<tr class="memitem:ac2bf0c4919c30d322fa5853c896e710f"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#ac2bf0c4919c30d322fa5853c896e710f">set_win_data</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> first_tile, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> nb_tiles, const <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *data) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 408<tr class="separator:ac2bf0c4919c30d322fa5853c896e710f"><td class="memSeparator" colspan="2"> </td></tr> 409<tr class="memitem:acd5ee7a94059e6edbe9223f291bc2b46"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#acd5ee7a94059e6edbe9223f291bc2b46">set_win_1bpp_data</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> first_tile, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> nb_tiles, const <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *data) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 410<tr class="separator:acd5ee7a94059e6edbe9223f291bc2b46"><td class="memSeparator" colspan="2"> </td></tr> 411<tr class="memitem:a7ef32e7c1669aba48f235500a495baba"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a7ef32e7c1669aba48f235500a495baba">get_win_data</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> first_tile, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> nb_tiles, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *data) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 412<tr class="separator:a7ef32e7c1669aba48f235500a495baba"><td class="memSeparator" colspan="2"> </td></tr> 413<tr class="memitem:a5c59b4ee6323af9832998906d087266b"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a5c59b4ee6323af9832998906d087266b">set_win_tiles</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> x, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> y, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> w, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> <a class="el" href="sms_8h.html#a1f1dfeb2f802fe99f37fe91867b84456">h</a>, const <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *tiles) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 414<tr class="separator:a5c59b4ee6323af9832998906d087266b"><td class="memSeparator" colspan="2"> </td></tr> 415<tr class="memitem:a739a212609ae60c9c56c095f96b4ea80"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a739a212609ae60c9c56c095f96b4ea80">set_win_based_tiles</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> x, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> y, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> w, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> <a class="el" href="sms_8h.html#a1f1dfeb2f802fe99f37fe91867b84456">h</a>, const <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *tiles, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> base_tile)</td></tr> 416<tr class="separator:a739a212609ae60c9c56c095f96b4ea80"><td class="memSeparator" colspan="2"> </td></tr> 417<tr class="memitem:af80befa3cad9cae361c7cf4fffb3a8de"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#af80befa3cad9cae361c7cf4fffb3a8de">set_win_submap</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> x, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> y, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> w, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> <a class="el" href="sms_8h.html#a1f1dfeb2f802fe99f37fe91867b84456">h</a>, const <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *map, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> map_w) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a></td></tr> 418<tr class="separator:af80befa3cad9cae361c7cf4fffb3a8de"><td class="memSeparator" colspan="2"> </td></tr> 419<tr class="memitem:a1b8a1026983cb2b2c0bd46334b4692a0"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a1b8a1026983cb2b2c0bd46334b4692a0">set_win_based_submap</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> x, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> y, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> w, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> <a class="el" href="sms_8h.html#a1f1dfeb2f802fe99f37fe91867b84456">h</a>, const <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *map, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> map_w, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> base_tile)</td></tr> 420<tr class="separator:a1b8a1026983cb2b2c0bd46334b4692a0"><td class="memSeparator" colspan="2"> </td></tr> 421<tr class="memitem:a8a469de4c6640f921254b336b5a6191a"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a8a469de4c6640f921254b336b5a6191a">get_win_tiles</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> x, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> y, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> w, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> <a class="el" href="sms_8h.html#a1f1dfeb2f802fe99f37fe91867b84456">h</a>, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *tiles) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 422<tr class="separator:a8a469de4c6640f921254b336b5a6191a"><td class="memSeparator" colspan="2"> </td></tr> 423<tr class="memitem:a0c70a53db1fbc0c99627da3f282befd8"><td class="memItemLeft" align="right" valign="top"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a0c70a53db1fbc0c99627da3f282befd8">set_win_tile_xy</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> x, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> y, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> t) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 424<tr class="separator:a0c70a53db1fbc0c99627da3f282befd8"><td class="memSeparator" colspan="2"> </td></tr> 425<tr class="memitem:a2e29fdca81c28c627c2591029722e71c"><td class="memItemLeft" align="right" valign="top"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a2e29fdca81c28c627c2591029722e71c">get_win_tile_xy</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> x, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> y) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 426<tr class="separator:a2e29fdca81c28c627c2591029722e71c"><td class="memSeparator" colspan="2"> </td></tr> 427<tr class="memitem:aeef17768c494bcd6b67f7591329f7ff5"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#aeef17768c494bcd6b67f7591329f7ff5">move_win</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> x, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> y)</td></tr> 428<tr class="separator:aeef17768c494bcd6b67f7591329f7ff5"><td class="memSeparator" colspan="2"> </td></tr> 429<tr class="memitem:a12c2b5ac249d01caf1561cbbf3962044"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a12c2b5ac249d01caf1561cbbf3962044">scroll_win</a> (<a class="el" href="stdint_8h.html#aef44329758059c91c76d334e8fc09700">int8_t</a> x, <a class="el" href="stdint_8h.html#aef44329758059c91c76d334e8fc09700">int8_t</a> y)</td></tr> 430<tr class="separator:a12c2b5ac249d01caf1561cbbf3962044"><td class="memSeparator" colspan="2"> </td></tr> 431<tr class="memitem:ae45b1c639698951b47e44fa8e89556f2"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#ae45b1c639698951b47e44fa8e89556f2">set_sprite_data</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> first_tile, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> nb_tiles, const <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *data) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 432<tr class="separator:ae45b1c639698951b47e44fa8e89556f2"><td class="memSeparator" colspan="2"> </td></tr> 433<tr class="memitem:ab3e60c92c9f8fbed855f8712187ea3ea"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#ab3e60c92c9f8fbed855f8712187ea3ea">set_sprite_1bpp_data</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> first_tile, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> nb_tiles, const <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *data) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 434<tr class="separator:ab3e60c92c9f8fbed855f8712187ea3ea"><td class="memSeparator" colspan="2"> </td></tr> 435<tr class="memitem:adcdec4034a14abc5be9bb88c29b947c9"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#adcdec4034a14abc5be9bb88c29b947c9">get_sprite_data</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> first_tile, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> nb_tiles, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *data) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 436<tr class="separator:adcdec4034a14abc5be9bb88c29b947c9"><td class="memSeparator" colspan="2"> </td></tr> 437<tr class="memitem:a7e0cdfd6b9a2ae1b7f30384f132d8687"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a7e0cdfd6b9a2ae1b7f30384f132d8687">SET_SHADOW_OAM_ADDRESS</a> (void *address)</td></tr> 438<tr class="separator:a7e0cdfd6b9a2ae1b7f30384f132d8687"><td class="memSeparator" colspan="2"> </td></tr> 439<tr class="memitem:a05bf0b9f1328de7b568a19a2a428bcfe"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a05bf0b9f1328de7b568a19a2a428bcfe">set_sprite_tile</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> nb, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> tile)</td></tr> 440<tr class="separator:a05bf0b9f1328de7b568a19a2a428bcfe"><td class="memSeparator" colspan="2"> </td></tr> 441<tr class="memitem:af5c0beff7d7a7d8641b51fd95c811b2a"><td class="memItemLeft" align="right" valign="top"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#af5c0beff7d7a7d8641b51fd95c811b2a">get_sprite_tile</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> nb)</td></tr> 442<tr class="separator:af5c0beff7d7a7d8641b51fd95c811b2a"><td class="memSeparator" colspan="2"> </td></tr> 443<tr class="memitem:a99ea3252469e3614e977cce2aa1d06f7"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a99ea3252469e3614e977cce2aa1d06f7">set_sprite_prop</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> nb, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> prop)</td></tr> 444<tr class="separator:a99ea3252469e3614e977cce2aa1d06f7"><td class="memSeparator" colspan="2"> </td></tr> 445<tr class="memitem:a6b873c807c9e2c90fb574951e85fdf88"><td class="memItemLeft" align="right" valign="top"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a6b873c807c9e2c90fb574951e85fdf88">get_sprite_prop</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> nb)</td></tr> 446<tr class="separator:a6b873c807c9e2c90fb574951e85fdf88"><td class="memSeparator" colspan="2"> </td></tr> 447<tr class="memitem:ab42c12c1d9aed3fd963248fbea9830cd"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#ab42c12c1d9aed3fd963248fbea9830cd">move_sprite</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> nb, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> x, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> y)</td></tr> 448<tr class="separator:ab42c12c1d9aed3fd963248fbea9830cd"><td class="memSeparator" colspan="2"> </td></tr> 449<tr class="memitem:a6c59aa9a4f9ea42bed6ca6940b2741fe"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a6c59aa9a4f9ea42bed6ca6940b2741fe">scroll_sprite</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> nb, <a class="el" href="stdint_8h.html#aef44329758059c91c76d334e8fc09700">int8_t</a> x, <a class="el" href="stdint_8h.html#aef44329758059c91c76d334e8fc09700">int8_t</a> y)</td></tr> 450<tr class="separator:a6c59aa9a4f9ea42bed6ca6940b2741fe"><td class="memSeparator" colspan="2"> </td></tr> 451<tr class="memitem:ad22c51635d052399bbbe1777999c794d"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#ad22c51635d052399bbbe1777999c794d">hide_sprite</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> nb)</td></tr> 452<tr class="separator:ad22c51635d052399bbbe1777999c794d"><td class="memSeparator" colspan="2"> </td></tr> 453<tr class="memitem:a650d2df96e69a40b70548ab468e00f25"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a650d2df96e69a40b70548ab468e00f25">set_data</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *vram_addr, const <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *data, <a class="el" href="stdint_8h.html#adf4d876453337156dde61095e1f20223">uint16_t</a> len) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 454<tr class="separator:a650d2df96e69a40b70548ab468e00f25"><td class="memSeparator" colspan="2"> </td></tr> 455<tr class="memitem:afd8fd71eaa36b0ddd54a2e8e516ed224"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#afd8fd71eaa36b0ddd54a2e8e516ed224">get_data</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *data, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *vram_addr, <a class="el" href="stdint_8h.html#adf4d876453337156dde61095e1f20223">uint16_t</a> len) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 456<tr class="separator:afd8fd71eaa36b0ddd54a2e8e516ed224"><td class="memSeparator" colspan="2"> </td></tr> 457<tr class="memitem:a36f9e5d95c2d7d58f203b5ac358e25e7"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a36f9e5d95c2d7d58f203b5ac358e25e7">vmemcpy</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *dest, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *sour, <a class="el" href="stdint_8h.html#adf4d876453337156dde61095e1f20223">uint16_t</a> len) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 458<tr class="separator:a36f9e5d95c2d7d58f203b5ac358e25e7"><td class="memSeparator" colspan="2"> </td></tr> 459<tr class="memitem:a9b205ee302f54cb96ee59aac6d53a91c"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a9b205ee302f54cb96ee59aac6d53a91c">set_tiles</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> x, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> y, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> w, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> <a class="el" href="sms_8h.html#a1f1dfeb2f802fe99f37fe91867b84456">h</a>, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *vram_addr, const <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *tiles) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 460<tr class="separator:a9b205ee302f54cb96ee59aac6d53a91c"><td class="memSeparator" colspan="2"> </td></tr> 461<tr class="memitem:abe4846d4570b4880b0e54b9e503f4d30"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#abe4846d4570b4880b0e54b9e503f4d30">set_tile_data</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> first_tile, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> nb_tiles, const <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *data, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> base) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 462<tr class="separator:abe4846d4570b4880b0e54b9e503f4d30"><td class="memSeparator" colspan="2"> </td></tr> 463<tr class="memitem:a728b9440accedc5fb3477be3d150323a"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a728b9440accedc5fb3477be3d150323a">get_tiles</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> x, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> y, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> w, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> <a class="el" href="sms_8h.html#a1f1dfeb2f802fe99f37fe91867b84456">h</a>, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *vram_addr, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *tiles) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 464<tr class="separator:a728b9440accedc5fb3477be3d150323a"><td class="memSeparator" colspan="2"> </td></tr> 465<tr class="memitem:a68651e50243349b48164a8ad983dca4e"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a68651e50243349b48164a8ad983dca4e">set_native_tile_data</a> (<a class="el" href="stdint_8h.html#adf4d876453337156dde61095e1f20223">uint16_t</a> first_tile, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> nb_tiles, const <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *data)</td></tr> 466<tr class="separator:a68651e50243349b48164a8ad983dca4e"><td class="memSeparator" colspan="2"> </td></tr> 467<tr class="memitem:af6ac67037de041eb0141ba3725b1db83"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#af6ac67037de041eb0141ba3725b1db83">init_win</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> <a class="el" href="sms_8h.html#a0b3366755f3276b0243c1e0497471b7a">c</a>) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 468<tr class="separator:af6ac67037de041eb0141ba3725b1db83"><td class="memSeparator" colspan="2"> </td></tr> 469<tr class="memitem:a46058204097dd305bf72bc20ea7f7a3b"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a46058204097dd305bf72bc20ea7f7a3b">init_bkg</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> <a class="el" href="sms_8h.html#a0b3366755f3276b0243c1e0497471b7a">c</a>) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 470<tr class="separator:a46058204097dd305bf72bc20ea7f7a3b"><td class="memSeparator" colspan="2"> </td></tr> 471<tr class="memitem:a97bab71effd5e4e386629cb6ca5816cf"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a97bab71effd5e4e386629cb6ca5816cf">vmemset</a> (void *s, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> <a class="el" href="sms_8h.html#a0b3366755f3276b0243c1e0497471b7a">c</a>, <a class="el" href="asm_2gbz80_2types_8h.html#a7c94ea6f8948649f8d181ae55911eeaf">size_t</a> n) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 472<tr class="separator:a97bab71effd5e4e386629cb6ca5816cf"><td class="memSeparator" colspan="2"> </td></tr> 473<tr class="memitem:a74c3f53fca019f7abcd1270650808849"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a74c3f53fca019f7abcd1270650808849">fill_bkg_rect</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> x, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> y, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> w, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> <a class="el" href="sms_8h.html#a1f1dfeb2f802fe99f37fe91867b84456">h</a>, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> tile) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 474<tr class="separator:a74c3f53fca019f7abcd1270650808849"><td class="memSeparator" colspan="2"> </td></tr> 475<tr class="memitem:ad5bc3dc922707507aa51ed7f5b4a21e3"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#ad5bc3dc922707507aa51ed7f5b4a21e3">fill_win_rect</a> (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> x, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> y, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> w, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> <a class="el" href="sms_8h.html#a1f1dfeb2f802fe99f37fe91867b84456">h</a>, <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> tile) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> <a class="el" href="asm_2types_8h.html#acb825e83a33fcc06482c59b4ab2cf961">PRESERVES_REGS</a>(<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 476<tr class="separator:ad5bc3dc922707507aa51ed7f5b4a21e3"><td class="memSeparator" colspan="2"> </td></tr> 477</table><table class="memberdecls"> 478<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="var-members"></a> 479Variables</h2></td></tr> 480<tr class="memitem:a0b3366755f3276b0243c1e0497471b7a"><td class="memItemLeft" align="right" valign="top"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a0b3366755f3276b0243c1e0497471b7a">c</a></td></tr> 481<tr class="separator:a0b3366755f3276b0243c1e0497471b7a"><td class="memSeparator" colspan="2"> </td></tr> 482<tr class="memitem:a874b9bd95b0a05d6a6072feabc879e45"><td class="memItemLeft" align="right" valign="top"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a874b9bd95b0a05d6a6072feabc879e45">_cpu</a></td></tr> 483<tr class="separator:a874b9bd95b0a05d6a6072feabc879e45"><td class="memSeparator" colspan="2"> </td></tr> 484<tr class="memitem:a539b7b45b1c2d6b2051553665c76fd36"><td class="memItemLeft" align="right" valign="top"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a539b7b45b1c2d6b2051553665c76fd36">_is_GBA</a></td></tr> 485<tr class="separator:a539b7b45b1c2d6b2051553665c76fd36"><td class="memSeparator" colspan="2"> </td></tr> 486<tr class="memitem:a78d2fd18666afec116f176d46debb4e7"><td class="memItemLeft" align="right" valign="top">volatile <a class="el" href="stdint_8h.html#adf4d876453337156dde61095e1f20223">uint16_t</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a78d2fd18666afec116f176d46debb4e7">sys_time</a></td></tr> 487<tr class="separator:a78d2fd18666afec116f176d46debb4e7"><td class="memSeparator" colspan="2"> </td></tr> 488<tr class="memitem:a2e3415ce2f7fb63427618bd9b9cb6635"><td class="memItemLeft" align="right" valign="top">volatile <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a2e3415ce2f7fb63427618bd9b9cb6635">_io_status</a></td></tr> 489<tr class="separator:a2e3415ce2f7fb63427618bd9b9cb6635"><td class="memSeparator" colspan="2"> </td></tr> 490<tr class="memitem:a02f3a1585ae654444e628c1aa98ef0cf"><td class="memItemLeft" align="right" valign="top">volatile <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a02f3a1585ae654444e628c1aa98ef0cf">_io_in</a></td></tr> 491<tr class="separator:a02f3a1585ae654444e628c1aa98ef0cf"><td class="memSeparator" colspan="2"> </td></tr> 492<tr class="memitem:acae13736da20f9fc53e8d38934aa2119"><td class="memItemLeft" align="right" valign="top">volatile <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#acae13736da20f9fc53e8d38934aa2119">_io_out</a></td></tr> 493<tr class="separator:acae13736da20f9fc53e8d38934aa2119"><td class="memSeparator" colspan="2"> </td></tr> 494<tr class="memitem:a98b848953a95ce2fff6fda643575d74a"><td class="memItemLeft" align="right" valign="top"><a class="el" href="gb_2hardware_8h.html#a0b42e4dadd74c927e8b801b4f42c0e44">__REG</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a98b848953a95ce2fff6fda643575d74a">_current_bank</a></td></tr> 495<tr class="separator:a98b848953a95ce2fff6fda643575d74a"><td class="memSeparator" colspan="2"> </td></tr> 496<tr class="memitem:a1f1dfeb2f802fe99f37fe91867b84456"><td class="memItemLeft" align="right" valign="top"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a1f1dfeb2f802fe99f37fe91867b84456">h</a></td></tr> 497<tr class="separator:a1f1dfeb2f802fe99f37fe91867b84456"><td class="memSeparator" colspan="2"> </td></tr> 498<tr class="memitem:af79b920bcb642bba2e652874c4f7eeff"><td class="memItemLeft" align="right" valign="top"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#af79b920bcb642bba2e652874c4f7eeff">l</a></td></tr> 499<tr class="separator:af79b920bcb642bba2e652874c4f7eeff"><td class="memSeparator" colspan="2"> </td></tr> 500<tr class="memitem:a4c2e4adef74067fdbb49005bc73de937"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td></tr> 501<tr class="separator:a4c2e4adef74067fdbb49005bc73de937"><td class="memSeparator" colspan="2"> </td></tr> 502<tr class="memitem:a0a3d95ad0ab8ad213016101d2e9c3d3e"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a0a3d95ad0ab8ad213016101d2e9c3d3e">d</a></td></tr> 503<tr class="separator:a0a3d95ad0ab8ad213016101d2e9c3d3e"><td class="memSeparator" colspan="2"> </td></tr> 504<tr class="memitem:aeda4515a31485c9688c4601ac5ce2d79"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#aeda4515a31485c9688c4601ac5ce2d79">e</a></td></tr> 505<tr class="separator:aeda4515a31485c9688c4601ac5ce2d79"><td class="memSeparator" colspan="2"> </td></tr> 506<tr class="memitem:a250f5339e05523912926be566e9eb8c0"><td class="memItemLeft" align="right" valign="top"><a class="el" href="stdint_8h.html#adf4d876453337156dde61095e1f20223">uint16_t</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a250f5339e05523912926be566e9eb8c0">_current_1bpp_colors</a></td></tr> 507<tr class="separator:a250f5339e05523912926be566e9eb8c0"><td class="memSeparator" colspan="2"> </td></tr> 508<tr class="memitem:aa82205e9629f984d0b3dc8055c211522"><td class="memItemLeft" align="right" valign="top"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#aa82205e9629f984d0b3dc8055c211522">_map_tile_offset</a></td></tr> 509<tr class="separator:aa82205e9629f984d0b3dc8055c211522"><td class="memSeparator" colspan="2"> </td></tr> 510<tr class="memitem:ab472d9bbb1bcfd141374f5babc71934c"><td class="memItemLeft" align="right" valign="top"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#ab472d9bbb1bcfd141374f5babc71934c">_submap_tile_offset</a></td></tr> 511<tr class="separator:ab472d9bbb1bcfd141374f5babc71934c"><td class="memSeparator" colspan="2"> </td></tr> 512<tr class="memitem:a3619f9cb1e3c92238a033ead79a0c551"><td class="memItemLeft" align="right" valign="top">volatile struct <a class="el" href="struct_o_a_m__item__t.html">OAM_item_t</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a3619f9cb1e3c92238a033ead79a0c551">shadow_OAM</a> []</td></tr> 513<tr class="separator:a3619f9cb1e3c92238a033ead79a0c551"><td class="memSeparator" colspan="2"> </td></tr> 514<tr class="memitem:a7b662ae4d83f9837bacb9fd580673054"><td class="memItemLeft" align="right" valign="top"><a class="el" href="gb_2hardware_8h.html#a0b42e4dadd74c927e8b801b4f42c0e44">__REG</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="gb_8h.html#a7b662ae4d83f9837bacb9fd580673054">_shadow_OAM_base</a></td></tr> 515<tr class="separator:a7b662ae4d83f9837bacb9fd580673054"><td class="memSeparator" colspan="2"> </td></tr> 516</table> 517<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2> 518<div class="textblock"><p>Gameboy specific functions. </p> 519</div><h2 class="groupheader">Macro Definition Documentation</h2> 520<a id="a385397587c93683e8e11afb712e2960b"></a> 521<h2 class="memtitle"><span class="permalink"><a href="#a385397587c93683e8e11afb712e2960b">◆ </a></span>NINTENDO</h2> 522 523<div class="memitem"> 524<div class="memproto"> 525 <table class="memname"> 526 <tr> 527 <td class="memname">#define NINTENDO</td> 528 </tr> 529 </table> 530</div><div class="memdoc"> 531 532</div> 533</div> 534<a id="af10046e88cba47031142a763a94210df"></a> 535<h2 class="memtitle"><span class="permalink"><a href="#af10046e88cba47031142a763a94210df">◆ </a></span>GAMEBOY</h2> 536 537<div class="memitem"> 538<div class="memproto"> 539 <table class="memname"> 540 <tr> 541 <td class="memname">#define GAMEBOY</td> 542 </tr> 543 </table> 544</div><div class="memdoc"> 545 546</div> 547</div> 548<a id="a05ca817ab32f6da612c3ae26db5abf02"></a> 549<h2 class="memtitle"><span class="permalink"><a href="#a05ca817ab32f6da612c3ae26db5abf02">◆ </a></span>J_UP</h2> 550 551<div class="memitem"> 552<div class="memproto"> 553 <table class="memname"> 554 <tr> 555 <td class="memname">#define J_UP   0x04U</td> 556 </tr> 557 </table> 558</div><div class="memdoc"> 559<p>Joypad bits. A logical OR of these is used in the wait_pad and joypad functions. For example, to see if the B button is pressed try</p> 560<p>uint8_t keys; keys = <a class="el" href="gb_8h.html#a176c477d759b814664785f3a0ad5e253">joypad()</a>; if (keys & J_B) { ... }</p> 561<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a176c477d759b814664785f3a0ad5e253">joypad</a> </dd></dl> 562 563</div> 564</div> 565<a id="ae032c5c544196e37ec0432f6cfad7904"></a> 566<h2 class="memtitle"><span class="permalink"><a href="#ae032c5c544196e37ec0432f6cfad7904">◆ </a></span>J_DOWN</h2> 567 568<div class="memitem"> 569<div class="memproto"> 570 <table class="memname"> 571 <tr> 572 <td class="memname">#define J_DOWN   0x08U</td> 573 </tr> 574 </table> 575</div><div class="memdoc"> 576 577</div> 578</div> 579<a id="ac70894fecac30c1ca9917f07373cf81c"></a> 580<h2 class="memtitle"><span class="permalink"><a href="#ac70894fecac30c1ca9917f07373cf81c">◆ </a></span>J_LEFT</h2> 581 582<div class="memitem"> 583<div class="memproto"> 584 <table class="memname"> 585 <tr> 586 <td class="memname">#define J_LEFT   0x02U</td> 587 </tr> 588 </table> 589</div><div class="memdoc"> 590 591</div> 592</div> 593<a id="a3bad91d11ae09ffcbb3cb0a81873d325"></a> 594<h2 class="memtitle"><span class="permalink"><a href="#a3bad91d11ae09ffcbb3cb0a81873d325">◆ </a></span>J_RIGHT</h2> 595 596<div class="memitem"> 597<div class="memproto"> 598 <table class="memname"> 599 <tr> 600 <td class="memname">#define J_RIGHT   0x01U</td> 601 </tr> 602 </table> 603</div><div class="memdoc"> 604 605</div> 606</div> 607<a id="a31af766e3b598eb7a6b63f55a4988e7a"></a> 608<h2 class="memtitle"><span class="permalink"><a href="#a31af766e3b598eb7a6b63f55a4988e7a">◆ </a></span>J_A</h2> 609 610<div class="memitem"> 611<div class="memproto"> 612 <table class="memname"> 613 <tr> 614 <td class="memname">#define J_A   0x10U</td> 615 </tr> 616 </table> 617</div><div class="memdoc"> 618 619</div> 620</div> 621<a id="ae47e59a309120f9420993f26816b5e6d"></a> 622<h2 class="memtitle"><span class="permalink"><a href="#ae47e59a309120f9420993f26816b5e6d">◆ </a></span>J_B</h2> 623 624<div class="memitem"> 625<div class="memproto"> 626 <table class="memname"> 627 <tr> 628 <td class="memname">#define J_B   0x20U</td> 629 </tr> 630 </table> 631</div><div class="memdoc"> 632 633</div> 634</div> 635<a id="ab416a9d96d1582490828f4bac78a8b5b"></a> 636<h2 class="memtitle"><span class="permalink"><a href="#ab416a9d96d1582490828f4bac78a8b5b">◆ </a></span>J_SELECT</h2> 637 638<div class="memitem"> 639<div class="memproto"> 640 <table class="memname"> 641 <tr> 642 <td class="memname">#define J_SELECT   0x40U</td> 643 </tr> 644 </table> 645</div><div class="memdoc"> 646 647</div> 648</div> 649<a id="ab769c6e20778298be8bc3321476ceb53"></a> 650<h2 class="memtitle"><span class="permalink"><a href="#ab769c6e20778298be8bc3321476ceb53">◆ </a></span>J_START</h2> 651 652<div class="memitem"> 653<div class="memproto"> 654 <table class="memname"> 655 <tr> 656 <td class="memname">#define J_START   0x80U</td> 657 </tr> 658 </table> 659</div><div class="memdoc"> 660 661</div> 662</div> 663<a id="acc9798fc62b5d626c91c8b0f20b522ff"></a> 664<h2 class="memtitle"><span class="permalink"><a href="#acc9798fc62b5d626c91c8b0f20b522ff">◆ </a></span>M_DRAWING</h2> 665 666<div class="memitem"> 667<div class="memproto"> 668 <table class="memname"> 669 <tr> 670 <td class="memname">#define M_DRAWING   0x01U</td> 671 </tr> 672 </table> 673</div><div class="memdoc"> 674<p>Screen modes. Normally used by internal functions only. </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a3ea524204d839377cf39842eec23e202">mode()</a> </dd></dl> 675 676</div> 677</div> 678<a id="af0e30d6af308ffe5a025fbe85da40f6f"></a> 679<h2 class="memtitle"><span class="permalink"><a href="#af0e30d6af308ffe5a025fbe85da40f6f">◆ </a></span>M_TEXT_OUT</h2> 680 681<div class="memitem"> 682<div class="memproto"> 683 <table class="memname"> 684 <tr> 685 <td class="memname">#define M_TEXT_OUT   0x02U</td> 686 </tr> 687 </table> 688</div><div class="memdoc"> 689 690</div> 691</div> 692<a id="a908826e7180f94a5988ceb8633313a2e"></a> 693<h2 class="memtitle"><span class="permalink"><a href="#a908826e7180f94a5988ceb8633313a2e">◆ </a></span>M_TEXT_INOUT</h2> 694 695<div class="memitem"> 696<div class="memproto"> 697 <table class="memname"> 698 <tr> 699 <td class="memname">#define M_TEXT_INOUT   0x03U</td> 700 </tr> 701 </table> 702</div><div class="memdoc"> 703 704</div> 705</div> 706<a id="a04382de20738146fe873ddfb0585052b"></a> 707<h2 class="memtitle"><span class="permalink"><a href="#a04382de20738146fe873ddfb0585052b">◆ </a></span>M_NO_SCROLL</h2> 708 709<div class="memitem"> 710<div class="memproto"> 711 <table class="memname"> 712 <tr> 713 <td class="memname">#define M_NO_SCROLL   0x04U</td> 714 </tr> 715 </table> 716</div><div class="memdoc"> 717<p>Set this in addition to the others to disable scrolling</p> 718<p>If scrolling is disabled, the cursor returns to (0,0) </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a3ea524204d839377cf39842eec23e202">mode()</a> </dd></dl> 719 720</div> 721</div> 722<a id="aca2855edd2d28f66be551a0f7ec23f07"></a> 723<h2 class="memtitle"><span class="permalink"><a href="#aca2855edd2d28f66be551a0f7ec23f07">◆ </a></span>M_NO_INTERP</h2> 724 725<div class="memitem"> 726<div class="memproto"> 727 <table class="memname"> 728 <tr> 729 <td class="memname">#define M_NO_INTERP   0x08U</td> 730 </tr> 731 </table> 732</div><div class="memdoc"> 733<p>Set this to disable interpretation </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a3ea524204d839377cf39842eec23e202">mode()</a> </dd></dl> 734 735</div> 736</div> 737<a id="a54572cf6791463b6d60623837e0bb5a6"></a> 738<h2 class="memtitle"><span class="permalink"><a href="#a54572cf6791463b6d60623837e0bb5a6">◆ </a></span>S_PALETTE</h2> 739 740<div class="memitem"> 741<div class="memproto"> 742 <table class="memname"> 743 <tr> 744 <td class="memname">#define S_PALETTE   0x10U</td> 745 </tr> 746 </table> 747</div><div class="memdoc"> 748<p>If this is set, sprite colours come from OBJ1PAL. Else they come from OBJ0PAL </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a99ea3252469e3614e977cce2aa1d06f7">set_sprite_prop()</a>. </dd></dl> 749 750</div> 751</div> 752<a id="ae97793b4039609f93b0f7f8bddb18011"></a> 753<h2 class="memtitle"><span class="permalink"><a href="#ae97793b4039609f93b0f7f8bddb18011">◆ </a></span>S_FLIPX</h2> 754 755<div class="memitem"> 756<div class="memproto"> 757 <table class="memname"> 758 <tr> 759 <td class="memname">#define S_FLIPX   0x20U</td> 760 </tr> 761 </table> 762</div><div class="memdoc"> 763<p>If set the sprite will be flipped horizontally. </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a99ea3252469e3614e977cce2aa1d06f7">set_sprite_prop()</a> </dd></dl> 764 765</div> 766</div> 767<a id="a4bbb9cd6c38b2317de5256d1d889c63b"></a> 768<h2 class="memtitle"><span class="permalink"><a href="#a4bbb9cd6c38b2317de5256d1d889c63b">◆ </a></span>S_FLIPY</h2> 769 770<div class="memitem"> 771<div class="memproto"> 772 <table class="memname"> 773 <tr> 774 <td class="memname">#define S_FLIPY   0x40U</td> 775 </tr> 776 </table> 777</div><div class="memdoc"> 778<p>If set the sprite will be flipped vertically. </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a99ea3252469e3614e977cce2aa1d06f7">set_sprite_prop()</a> </dd></dl> 779 780</div> 781</div> 782<a id="a9506d04c2ec7d2442a52054f67d2b32f"></a> 783<h2 class="memtitle"><span class="permalink"><a href="#a9506d04c2ec7d2442a52054f67d2b32f">◆ </a></span>S_PRIORITY</h2> 784 785<div class="memitem"> 786<div class="memproto"> 787 <table class="memname"> 788 <tr> 789 <td class="memname">#define S_PRIORITY   0x80U</td> 790 </tr> 791 </table> 792</div><div class="memdoc"> 793<p>If this bit is clear, then the sprite will be displayed on top of the background and window. </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a99ea3252469e3614e977cce2aa1d06f7">set_sprite_prop()</a> </dd></dl> 794 795</div> 796</div> 797<a id="aa027abe630d44039f238034bcb2d2f36"></a> 798<h2 class="memtitle"><span class="permalink"><a href="#aa027abe630d44039f238034bcb2d2f36">◆ </a></span>EMPTY_IFLAG</h2> 799 800<div class="memitem"> 801<div class="memproto"> 802 <table class="memname"> 803 <tr> 804 <td class="memname">#define EMPTY_IFLAG   0x00U</td> 805 </tr> 806 </table> 807</div><div class="memdoc"> 808<p>Disable calling of interrupt service routines </p> 809 810</div> 811</div> 812<a id="a2ca7720b9a5da9b2173e1f74dba85541"></a> 813<h2 class="memtitle"><span class="permalink"><a href="#a2ca7720b9a5da9b2173e1f74dba85541">◆ </a></span>VBL_IFLAG</h2> 814 815<div class="memitem"> 816<div class="memproto"> 817 <table class="memname"> 818 <tr> 819 <td class="memname">#define VBL_IFLAG   0x01U</td> 820 </tr> 821 </table> 822</div><div class="memdoc"> 823<p>VBlank Interrupt occurs at the start of the vertical blank.</p> 824<p>During this period the video ram may be freely accessed. </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a9312e7ec34162d6b6ed0875631fa6fe3">set_interrupts()</a>, </dd> 825<dd> 826<a class="el" href="gb_8h.html#a0d29659d08708143dd8bc720278e06b5">add_VBL</a> </dd></dl> 827 828</div> 829</div> 830<a id="a61a9e2910380de6abb34df14ef634eb4"></a> 831<h2 class="memtitle"><span class="permalink"><a href="#a61a9e2910380de6abb34df14ef634eb4">◆ </a></span>LCD_IFLAG</h2> 832 833<div class="memitem"> 834<div class="memproto"> 835 <table class="memname"> 836 <tr> 837 <td class="memname">#define LCD_IFLAG   0x02U</td> 838 </tr> 839 </table> 840</div><div class="memdoc"> 841<p>LCD Interrupt when triggered by the STAT register. </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a9312e7ec34162d6b6ed0875631fa6fe3">set_interrupts()</a>, </dd> 842<dd> 843<a class="el" href="gb_8h.html#a9f9f77105099a34556247d5bb03368d1">add_LCD</a> </dd></dl> 844 845</div> 846</div> 847<a id="a604256210ec5b90b68185e1a18efab49"></a> 848<h2 class="memtitle"><span class="permalink"><a href="#a604256210ec5b90b68185e1a18efab49">◆ </a></span>TIM_IFLAG</h2> 849 850<div class="memitem"> 851<div class="memproto"> 852 <table class="memname"> 853 <tr> 854 <td class="memname">#define TIM_IFLAG   0x04U</td> 855 </tr> 856 </table> 857</div><div class="memdoc"> 858<p>Timer Interrupt when the timer <a class="el" href="gb_2hardware_8h.html#a9d295bb437953de5ebcb3c12d65743aa">TIMA_REG</a> overflows. </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a9312e7ec34162d6b6ed0875631fa6fe3">set_interrupts()</a>, </dd> 859<dd> 860<a class="el" href="gb_8h.html#a028d1a2e820951bb4f103d6469975ffb">add_TIM</a> </dd></dl> 861 862</div> 863</div> 864<a id="ad90564458646c5646b3880b93db3443e"></a> 865<h2 class="memtitle"><span class="permalink"><a href="#ad90564458646c5646b3880b93db3443e">◆ </a></span>SIO_IFLAG</h2> 866 867<div class="memitem"> 868<div class="memproto"> 869 <table class="memname"> 870 <tr> 871 <td class="memname">#define SIO_IFLAG   0x08U</td> 872 </tr> 873 </table> 874</div><div class="memdoc"> 875<p>Serial Link Interrupt occurs when the serial transfer has completed. </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a9312e7ec34162d6b6ed0875631fa6fe3">set_interrupts()</a>, </dd> 876<dd> 877<a class="el" href="gb_8h.html#aa82422752016328ed0765879e286019f">add_SIO</a> </dd></dl> 878 879</div> 880</div> 881<a id="a2f829cf27d6e3e24c875e9b82dfcb280"></a> 882<h2 class="memtitle"><span class="permalink"><a href="#a2f829cf27d6e3e24c875e9b82dfcb280">◆ </a></span>JOY_IFLAG</h2> 883 884<div class="memitem"> 885<div class="memproto"> 886 <table class="memname"> 887 <tr> 888 <td class="memname">#define JOY_IFLAG   0x10U</td> 889 </tr> 890 </table> 891</div><div class="memdoc"> 892<p>Joypad Interrupt occurs on a transition of the keypad. </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a9312e7ec34162d6b6ed0875631fa6fe3">set_interrupts()</a>, </dd> 893<dd> 894<a class="el" href="gb_8h.html#aa2f0235e78da2d1d94d3628d7a1afc30">add_JOY</a> </dd></dl> 895 896</div> 897</div> 898<a id="ab311e53739c992294ae07ca506a924ad"></a> 899<h2 class="memtitle"><span class="permalink"><a href="#ab311e53739c992294ae07ca506a924ad">◆ </a></span>DMG_BLACK</h2> 900 901<div class="memitem"> 902<div class="memproto"> 903 <table class="memname"> 904 <tr> 905 <td class="memname">#define DMG_BLACK   0x03</td> 906 </tr> 907 </table> 908</div><div class="memdoc"> 909 910</div> 911</div> 912<a id="a45d13a674e169dd83df7e1f46513ccba"></a> 913<h2 class="memtitle"><span class="permalink"><a href="#a45d13a674e169dd83df7e1f46513ccba">◆ </a></span>DMG_DARK_GRAY</h2> 914 915<div class="memitem"> 916<div class="memproto"> 917 <table class="memname"> 918 <tr> 919 <td class="memname">#define DMG_DARK_GRAY   0x02</td> 920 </tr> 921 </table> 922</div><div class="memdoc"> 923 924</div> 925</div> 926<a id="a8ccd6732d3bdf390cc0943e8567341f3"></a> 927<h2 class="memtitle"><span class="permalink"><a href="#a8ccd6732d3bdf390cc0943e8567341f3">◆ </a></span>DMG_LITE_GRAY</h2> 928 929<div class="memitem"> 930<div class="memproto"> 931 <table class="memname"> 932 <tr> 933 <td class="memname">#define DMG_LITE_GRAY   0x01</td> 934 </tr> 935 </table> 936</div><div class="memdoc"> 937 938</div> 939</div> 940<a id="a11cedc2ee58acfbbfc48dfb2b9a551b3"></a> 941<h2 class="memtitle"><span class="permalink"><a href="#a11cedc2ee58acfbbfc48dfb2b9a551b3">◆ </a></span>DMG_WHITE</h2> 942 943<div class="memitem"> 944<div class="memproto"> 945 <table class="memname"> 946 <tr> 947 <td class="memname">#define DMG_WHITE   0x00</td> 948 </tr> 949 </table> 950</div><div class="memdoc"> 951 952</div> 953</div> 954<a id="a9727caafc483ba6ec65e9344b033d684"></a> 955<h2 class="memtitle"><span class="permalink"><a href="#a9727caafc483ba6ec65e9344b033d684">◆ </a></span>DMG_PALETTE</h2> 956 957<div class="memitem"> 958<div class="memproto"> 959 <table class="memname"> 960 <tr> 961 <td class="memname">#define DMG_PALETTE</td> 962 <td>(</td> 963 <td class="paramtype"> </td> 964 <td class="paramname">C0, </td> 965 </tr> 966 <tr> 967 <td class="paramkey"></td> 968 <td></td> 969 <td class="paramtype"> </td> 970 <td class="paramname">C1, </td> 971 </tr> 972 <tr> 973 <td class="paramkey"></td> 974 <td></td> 975 <td class="paramtype"> </td> 976 <td class="paramname">C2, </td> 977 </tr> 978 <tr> 979 <td class="paramkey"></td> 980 <td></td> 981 <td class="paramtype"> </td> 982 <td class="paramname">C3 </td> 983 </tr> 984 <tr> 985 <td></td> 986 <td>)</td> 987 <td></td><td>   ((<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a>)((((C3) & 0x03) << 6) | (((C2) & 0x03) << 4) | (((C1) & 0x03) << 2) | ((C0) & 0x03)))</td> 988 </tr> 989 </table> 990</div><div class="memdoc"> 991<p>Macro to create a DMG palette from 4 colors</p> 992<dl class="params"><dt>Parameters</dt><dd> 993 <table class="params"> 994 <tr><td class="paramname">C0</td><td>Color for Index 0 </td></tr> 995 <tr><td class="paramname">C1</td><td>Color for Index 1 </td></tr> 996 <tr><td class="paramname">C2</td><td>Color for Index 2 </td></tr> 997 <tr><td class="paramname">C3</td><td>Color for Index 3</td></tr> 998 </table> 999 </dd> 1000</dl> 1001<p>The resulting format is four greyscale colors packed into a single unsigned byte.</p> 1002<p>Example: </p><div class="fragment"><div class="line">REG_BGP = <a class="code" href="gb_8h.html#a9727caafc483ba6ec65e9344b033d684">DMG_PALETTE</a>(<a class="code" href="gb_8h.html#ab311e53739c992294ae07ca506a924ad">DMG_BLACK</a>, <a class="code" href="gb_8h.html#a45d13a674e169dd83df7e1f46513ccba">DMG_DARK_GRAY</a>, <a class="code" href="gb_8h.html#a8ccd6732d3bdf390cc0943e8567341f3">DMG_LITE_GRAY</a>, <a class="code" href="gb_8h.html#a11cedc2ee58acfbbfc48dfb2b9a551b3">DMG_WHITE</a>);</div> 1003</div><!-- fragment --><dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_2hardware_8h.html#a13f3e89f7b92258d825292e5058815c7">OBP0_REG</a>, <a class="el" href="gb_2hardware_8h.html#a9da545164e049ef773128f869daece13">OBP1_REG</a>, <a class="el" href="gb_2hardware_8h.html#af577ba87ec3d13d7415e4c4a53cdf997">BGP_REG</a> </dd> 1004<dd> 1005<a class="el" href="gb_8h.html#ab311e53739c992294ae07ca506a924ad">DMG_BLACK</a>, <a class="el" href="gb_8h.html#a45d13a674e169dd83df7e1f46513ccba">DMG_DARK_GRAY</a>, <a class="el" href="gb_8h.html#a8ccd6732d3bdf390cc0943e8567341f3">DMG_LITE_GRAY</a>, <a class="el" href="gb_8h.html#a11cedc2ee58acfbbfc48dfb2b9a551b3">DMG_WHITE</a> </dd></dl> 1006 1007</div> 1008</div> 1009<a id="ada0cc738d27aad251151e69cb8d250e1"></a> 1010<h2 class="memtitle"><span class="permalink"><a href="#ada0cc738d27aad251151e69cb8d250e1">◆ </a></span>SCREENWIDTH</h2> 1011 1012<div class="memitem"> 1013<div class="memproto"> 1014 <table class="memname"> 1015 <tr> 1016 <td class="memname">#define SCREENWIDTH   <a class="el" href="sms_2hardware_8h.html#ad14c51cdfb347c34c364f54e67dc978d">DEVICE_SCREEN_PX_WIDTH</a></td> 1017 </tr> 1018 </table> 1019</div><div class="memdoc"> 1020<p>Width of the visible screen in pixels. </p> 1021 1022</div> 1023</div> 1024<a id="ae189e98d0ef9263c37869ce1ff3710a5"></a> 1025<h2 class="memtitle"><span class="permalink"><a href="#ae189e98d0ef9263c37869ce1ff3710a5">◆ </a></span>SCREENHEIGHT</h2> 1026 1027<div class="memitem"> 1028<div class="memproto"> 1029 <table class="memname"> 1030 <tr> 1031 <td class="memname">#define SCREENHEIGHT   <a class="el" href="sms_2hardware_8h.html#a7bd450aa268b881257089cf8cd6697ec">DEVICE_SCREEN_PX_HEIGHT</a></td> 1032 </tr> 1033 </table> 1034</div><div class="memdoc"> 1035<p>Height of the visible screen in pixels. </p> 1036 1037</div> 1038</div> 1039<a id="a5a796bbf3e4347d914b83568350143a9"></a> 1040<h2 class="memtitle"><span class="permalink"><a href="#a5a796bbf3e4347d914b83568350143a9">◆ </a></span>MINWNDPOSX</h2> 1041 1042<div class="memitem"> 1043<div class="memproto"> 1044 <table class="memname"> 1045 <tr> 1046 <td class="memname">#define MINWNDPOSX   0x07U</td> 1047 </tr> 1048 </table> 1049</div><div class="memdoc"> 1050<p>The Minimum X position of the Window Layer (Left edge of screen) </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#aeef17768c494bcd6b67f7591329f7ff5">move_win()</a> </dd></dl> 1051 1052</div> 1053</div> 1054<a id="af3d632ba2d7cef6619df5dfea8730909"></a> 1055<h2 class="memtitle"><span class="permalink"><a href="#af3d632ba2d7cef6619df5dfea8730909">◆ </a></span>MINWNDPOSY</h2> 1056 1057<div class="memitem"> 1058<div class="memproto"> 1059 <table class="memname"> 1060 <tr> 1061 <td class="memname">#define MINWNDPOSY   0x00U</td> 1062 </tr> 1063 </table> 1064</div><div class="memdoc"> 1065<p>The Minimum Y position of the Window Layer (Top edge of screen) </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#aeef17768c494bcd6b67f7591329f7ff5">move_win()</a> </dd></dl> 1066 1067</div> 1068</div> 1069<a id="a6dffb66ec1b1d9bb380a1af52a601ec5"></a> 1070<h2 class="memtitle"><span class="permalink"><a href="#a6dffb66ec1b1d9bb380a1af52a601ec5">◆ </a></span>MAXWNDPOSX</h2> 1071 1072<div class="memitem"> 1073<div class="memproto"> 1074 <table class="memname"> 1075 <tr> 1076 <td class="memname">#define MAXWNDPOSX   0xA6U</td> 1077 </tr> 1078 </table> 1079</div><div class="memdoc"> 1080<p>The Maximum X position of the Window Layer (Right edge of screen) </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#aeef17768c494bcd6b67f7591329f7ff5">move_win()</a> </dd></dl> 1081 1082</div> 1083</div> 1084<a id="ad57f2f8c54204687f02801d8ab1bd150"></a> 1085<h2 class="memtitle"><span class="permalink"><a href="#ad57f2f8c54204687f02801d8ab1bd150">◆ </a></span>MAXWNDPOSY</h2> 1086 1087<div class="memitem"> 1088<div class="memproto"> 1089 <table class="memname"> 1090 <tr> 1091 <td class="memname">#define MAXWNDPOSY   0x8FU</td> 1092 </tr> 1093 </table> 1094</div><div class="memdoc"> 1095<p>The Maximum Y position of the Window Layer (Bottom edge of screen) </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#aeef17768c494bcd6b67f7591329f7ff5">move_win()</a> </dd></dl> 1096 1097</div> 1098</div> 1099<a id="a0031c07799247a6d6c1bfa3decac79d0"></a> 1100<h2 class="memtitle"><span class="permalink"><a href="#a0031c07799247a6d6c1bfa3decac79d0">◆ </a></span>DMG_TYPE</h2> 1101 1102<div class="memitem"> 1103<div class="memproto"> 1104 <table class="memname"> 1105 <tr> 1106 <td class="memname">#define DMG_TYPE   0x01</td> 1107 </tr> 1108 </table> 1109</div><div class="memdoc"> 1110<p>Hardware Model: Original GB or Super GB. </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a874b9bd95b0a05d6a6072feabc879e45">_cpu</a> </dd></dl> 1111 1112</div> 1113</div> 1114<a id="ae996ed4fd8bb6b308b9c8708a91df06b"></a> 1115<h2 class="memtitle"><span class="permalink"><a href="#ae996ed4fd8bb6b308b9c8708a91df06b">◆ </a></span>MGB_TYPE</h2> 1116 1117<div class="memitem"> 1118<div class="memproto"> 1119 <table class="memname"> 1120 <tr> 1121 <td class="memname">#define MGB_TYPE   0xFF</td> 1122 </tr> 1123 </table> 1124</div><div class="memdoc"> 1125<p>Hardware Model: Pocket GB or Super GB 2. </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a874b9bd95b0a05d6a6072feabc879e45">_cpu</a> </dd></dl> 1126 1127</div> 1128</div> 1129<a id="aee435a3a0dde3dbd7b6112dbb456cde8"></a> 1130<h2 class="memtitle"><span class="permalink"><a href="#aee435a3a0dde3dbd7b6112dbb456cde8">◆ </a></span>CGB_TYPE</h2> 1131 1132<div class="memitem"> 1133<div class="memproto"> 1134 <table class="memname"> 1135 <tr> 1136 <td class="memname">#define CGB_TYPE   0x11</td> 1137 </tr> 1138 </table> 1139</div><div class="memdoc"> 1140<p>Hardware Model: Color GB. </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a874b9bd95b0a05d6a6072feabc879e45">_cpu</a> </dd></dl> 1141 1142</div> 1143</div> 1144<a id="aa311f84dd9fce6e136ba4881e7b0d98d"></a> 1145<h2 class="memtitle"><span class="permalink"><a href="#aa311f84dd9fce6e136ba4881e7b0d98d">◆ </a></span>GBA_NOT_DETECTED</h2> 1146 1147<div class="memitem"> 1148<div class="memproto"> 1149 <table class="memname"> 1150 <tr> 1151 <td class="memname">#define GBA_NOT_DETECTED   0x00</td> 1152 </tr> 1153 </table> 1154</div><div class="memdoc"> 1155<p>Hardware Model: DMG, CGB or MGB. </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a874b9bd95b0a05d6a6072feabc879e45">_cpu</a>, <a class="el" href="gb_8h.html#a539b7b45b1c2d6b2051553665c76fd36">_is_GBA</a> </dd></dl> 1156 1157</div> 1158</div> 1159<a id="a6ccf5d0f34fb0af0b6e73b9df0ccd745"></a> 1160<h2 class="memtitle"><span class="permalink"><a href="#a6ccf5d0f34fb0af0b6e73b9df0ccd745">◆ </a></span>GBA_DETECTED</h2> 1161 1162<div class="memitem"> 1163<div class="memproto"> 1164 <table class="memname"> 1165 <tr> 1166 <td class="memname">#define GBA_DETECTED   0x01</td> 1167 </tr> 1168 </table> 1169</div><div class="memdoc"> 1170<p>Hardware Model: GBA. </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a874b9bd95b0a05d6a6072feabc879e45">_cpu</a>, <a class="el" href="gb_8h.html#a539b7b45b1c2d6b2051553665c76fd36">_is_GBA</a> </dd></dl> 1171 1172</div> 1173</div> 1174<a id="a231ec05679809190782e61c6e8aaaba4"></a> 1175<h2 class="memtitle"><span class="permalink"><a href="#a231ec05679809190782e61c6e8aaaba4">◆ </a></span>DEVICE_SUPPORTS_COLOR</h2> 1176 1177<div class="memitem"> 1178<div class="memproto"> 1179 <table class="memname"> 1180 <tr> 1181 <td class="memname">#define DEVICE_SUPPORTS_COLOR   (<a class="el" href="gb_8h.html#a874b9bd95b0a05d6a6072feabc879e45">_cpu</a> == <a class="el" href="gb_8h.html#aee435a3a0dde3dbd7b6112dbb456cde8">CGB_TYPE</a>)</td> 1182 </tr> 1183 </table> 1184</div><div class="memdoc"> 1185<p>Macro returns TRUE if device supports color </p> 1186 1187</div> 1188</div> 1189<a id="a268cc6c704e16f3fa02dd1cf0e17070a"></a> 1190<h2 class="memtitle"><span class="permalink"><a href="#a268cc6c704e16f3fa02dd1cf0e17070a">◆ </a></span>IO_IDLE</h2> 1191 1192<div class="memitem"> 1193<div class="memproto"> 1194 <table class="memname"> 1195 <tr> 1196 <td class="memname">#define IO_IDLE   0x00U</td> 1197 </tr> 1198 </table> 1199</div><div class="memdoc"> 1200<p>Serial Link IO is completed </p> 1201 1202</div> 1203</div> 1204<a id="ab69a3f7cd2c6b5eb4f518aefee099007"></a> 1205<h2 class="memtitle"><span class="permalink"><a href="#ab69a3f7cd2c6b5eb4f518aefee099007">◆ </a></span>IO_SENDING</h2> 1206 1207<div class="memitem"> 1208<div class="memproto"> 1209 <table class="memname"> 1210 <tr> 1211 <td class="memname">#define IO_SENDING   0x01U</td> 1212 </tr> 1213 </table> 1214</div><div class="memdoc"> 1215<p>Serial Link Sending data </p> 1216 1217</div> 1218</div> 1219<a id="aee03efddee0f2f6fbcaec789301aaa9b"></a> 1220<h2 class="memtitle"><span class="permalink"><a href="#aee03efddee0f2f6fbcaec789301aaa9b">◆ </a></span>IO_RECEIVING</h2> 1221 1222<div class="memitem"> 1223<div class="memproto"> 1224 <table class="memname"> 1225 <tr> 1226 <td class="memname">#define IO_RECEIVING   0x02U</td> 1227 </tr> 1228 </table> 1229</div><div class="memdoc"> 1230<p>Serial Link Receiving data </p> 1231 1232</div> 1233</div> 1234<a id="a5d4c9c7b61a0326a939f9109f96d7423"></a> 1235<h2 class="memtitle"><span class="permalink"><a href="#a5d4c9c7b61a0326a939f9109f96d7423">◆ </a></span>IO_ERROR</h2> 1236 1237<div class="memitem"> 1238<div class="memproto"> 1239 <table class="memname"> 1240 <tr> 1241 <td class="memname">#define IO_ERROR   0x04U</td> 1242 </tr> 1243 </table> 1244</div><div class="memdoc"> 1245<p>Serial Link Error </p> 1246 1247</div> 1248</div> 1249<a id="ae042588f20bf5a2349c8ad8716245233"></a> 1250<h2 class="memtitle"><span class="permalink"><a href="#ae042588f20bf5a2349c8ad8716245233">◆ </a></span>CURRENT_BANK</h2> 1251 1252<div class="memitem"> 1253<div class="memproto"> 1254 <table class="memname"> 1255 <tr> 1256 <td class="memname">#define CURRENT_BANK   <a class="el" href="gb_8h.html#a98b848953a95ce2fff6fda643575d74a">_current_bank</a></td> 1257 </tr> 1258 </table> 1259</div><div class="memdoc"> 1260 1261</div> 1262</div> 1263<a id="a42705001e2b9897f5167b67fb36c69dd"></a> 1264<h2 class="memtitle"><span class="permalink"><a href="#a42705001e2b9897f5167b67fb36c69dd">◆ </a></span>BANK</h2> 1265 1266<div class="memitem"> 1267<div class="memproto"> 1268 <table class="memname"> 1269 <tr> 1270 <td class="memname">#define BANK</td> 1271 <td>(</td> 1272 <td class="paramtype"> </td> 1273 <td class="paramname">VARNAME</td><td>)</td> 1274 <td>   ( (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a>) & __bank_ ## VARNAME )</td> 1275 </tr> 1276 </table> 1277</div><div class="memdoc"> 1278<p>Obtains the <b>bank number</b> of VARNAME</p> 1279<dl class="params"><dt>Parameters</dt><dd> 1280 <table class="params"> 1281 <tr><td class="paramname">VARNAME</td><td>Name of the variable which has a __bank_VARNAME companion symbol which is adjusted by bankpack</td></tr> 1282 </table> 1283 </dd> 1284</dl> 1285<p>Use this to obtain the bank number from a bank reference created with <a class="el" href="gb_8h.html#a086293f2afb4c7945460a4496b20aea3">BANKREF()</a>.</p> 1286<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a261bba55a07b802baf99346feadd9852">BANKREF_EXTERN()</a>, <a class="el" href="gb_8h.html#a086293f2afb4c7945460a4496b20aea3">BANKREF()</a> </dd></dl> 1287 1288</div> 1289</div> 1290<a id="a086293f2afb4c7945460a4496b20aea3"></a> 1291<h2 class="memtitle"><span class="permalink"><a href="#a086293f2afb4c7945460a4496b20aea3">◆ </a></span>BANKREF</h2> 1292 1293<div class="memitem"> 1294<div class="memproto"> 1295 <table class="memname"> 1296 <tr> 1297 <td class="memname">#define BANKREF</td> 1298 <td>(</td> 1299 <td class="paramtype"> </td> 1300 <td class="paramname">VARNAME</td><td>)</td> 1301 <td></td> 1302 </tr> 1303 </table> 1304</div><div class="memdoc"> 1305<b>Value:</b><div class="fragment"><div class="line"><span class="keywordtype">void</span> __func_ ## VARNAME() __banked __naked { \</div> 1306<div class="line">__asm \</div> 1307<div class="line"> .local b___func_ ## VARNAME \</div> 1308<div class="line"> ___bank_ ## VARNAME = b___func_ ## VARNAME \</div> 1309<div class="line"> .globl ___bank_ ## VARNAME \</div> 1310<div class="line">__endasm; \</div> 1311<div class="line">}</div> 1312</div><!-- fragment --><p>Creates a reference for retrieving the bank number of a variable or function</p> 1313<dl class="params"><dt>Parameters</dt><dd> 1314 <table class="params"> 1315 <tr><td class="paramname">VARNAME</td><td>Variable name to use, which may be an existing identifier</td></tr> 1316 </table> 1317 </dd> 1318</dl> 1319<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a42705001e2b9897f5167b67fb36c69dd">BANK()</a> for obtaining the bank number of the included data.</dd></dl> 1320<p>More than one <code><a class="el" href="gb_8h.html#a086293f2afb4c7945460a4496b20aea3">BANKREF()</a></code> may be created per file, but each call should always use a unique VARNAME.</p> 1321<p>Use <a class="el" href="gb_8h.html#a261bba55a07b802baf99346feadd9852">BANKREF_EXTERN()</a> within another source file to make the variable and it's data accesible there. </p> 1322 1323</div> 1324</div> 1325<a id="a261bba55a07b802baf99346feadd9852"></a> 1326<h2 class="memtitle"><span class="permalink"><a href="#a261bba55a07b802baf99346feadd9852">◆ </a></span>BANKREF_EXTERN</h2> 1327 1328<div class="memitem"> 1329<div class="memproto"> 1330 <table class="memname"> 1331 <tr> 1332 <td class="memname">#define BANKREF_EXTERN</td> 1333 <td>(</td> 1334 <td class="paramtype"> </td> 1335 <td class="paramname">VARNAME</td><td>)</td> 1336 <td>   extern const void __bank_ ## VARNAME;</td> 1337 </tr> 1338 </table> 1339</div><div class="memdoc"> 1340<p>Creates extern references for accessing a <a class="el" href="gb_8h.html#a086293f2afb4c7945460a4496b20aea3">BANKREF()</a> generated variable.</p> 1341<dl class="params"><dt>Parameters</dt><dd> 1342 <table class="params"> 1343 <tr><td class="paramname">VARNAME</td><td>Name of the variable used with <a class="el" href="gb_8h.html#a086293f2afb4c7945460a4496b20aea3">BANKREF()</a></td></tr> 1344 </table> 1345 </dd> 1346</dl> 1347<p>This makes a <a class="el" href="gb_8h.html#a086293f2afb4c7945460a4496b20aea3">BANKREF()</a> reference in another source file accessible in the current file for use with <a class="el" href="gb_8h.html#a42705001e2b9897f5167b67fb36c69dd">BANK()</a>.</p> 1348<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a086293f2afb4c7945460a4496b20aea3">BANKREF()</a>, <a class="el" href="gb_8h.html#a42705001e2b9897f5167b67fb36c69dd">BANK()</a> </dd></dl> 1349 1350</div> 1351</div> 1352<a id="a3fca2d0a22aa2717e62fed659caf4743"></a> 1353<h2 class="memtitle"><span class="permalink"><a href="#a3fca2d0a22aa2717e62fed659caf4743">◆ </a></span>SWITCH_ROM_MEGADUCK</h2> 1354 1355<div class="memitem"> 1356<div class="memproto"> 1357 <table class="memname"> 1358 <tr> 1359 <td class="memname">#define SWITCH_ROM_MEGADUCK</td> 1360 <td>(</td> 1361 <td class="paramtype"> </td> 1362 <td class="paramname"><a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td><td>)</td> 1363 <td>    <a class="el" href="gb_8h.html#a98b848953a95ce2fff6fda643575d74a">_current_bank</a> = (<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a>), *(<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *)0x0001 = (<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a>)</td> 1364 </tr> 1365 </table> 1366</div><div class="memdoc"> 1367<p>Makes MEGADUCK MBC switch the active ROM bank </p><dl class="params"><dt>Parameters</dt><dd> 1368 <table class="params"> 1369 <tr><td class="paramname">b</td><td>ROM bank to switch to </td></tr> 1370 </table> 1371 </dd> 1372</dl> 1373 1374</div> 1375</div> 1376<a id="a19558f5bbc9fea767f945001ae9cd13f"></a> 1377<h2 class="memtitle"><span class="permalink"><a href="#a19558f5bbc9fea767f945001ae9cd13f">◆ </a></span>SWITCH_ROM_MBC1</h2> 1378 1379<div class="memitem"> 1380<div class="memproto"> 1381 <table class="memname"> 1382 <tr> 1383 <td class="memname">#define SWITCH_ROM_MBC1</td> 1384 <td>(</td> 1385 <td class="paramtype"> </td> 1386 <td class="paramname"><a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td><td>)</td> 1387 <td>    <a class="el" href="gb_8h.html#a98b848953a95ce2fff6fda643575d74a">_current_bank</a> = (<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a>), *(<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *)0x2000 = (<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a>)</td> 1388 </tr> 1389 </table> 1390</div><div class="memdoc"> 1391<p>Makes MBC1 and other compatible MBCs switch the active ROM bank </p><dl class="params"><dt>Parameters</dt><dd> 1392 <table class="params"> 1393 <tr><td class="paramname">b</td><td>ROM bank to switch to </td></tr> 1394 </table> 1395 </dd> 1396</dl> 1397 1398</div> 1399</div> 1400<a id="a1e22a3b60368bb5f3705d625ac2d09cc"></a> 1401<h2 class="memtitle"><span class="permalink"><a href="#a1e22a3b60368bb5f3705d625ac2d09cc">◆ </a></span>SWITCH_ROM</h2> 1402 1403<div class="memitem"> 1404<div class="memproto"> 1405 <table class="memname"> 1406 <tr> 1407 <td class="memname">#define SWITCH_ROM   <a class="el" href="gb_8h.html#a19558f5bbc9fea767f945001ae9cd13f">SWITCH_ROM_MBC1</a></td> 1408 </tr> 1409 </table> 1410</div><div class="memdoc"> 1411<p>Makes default platform MBC switch the active ROM bank </p><dl class="params"><dt>Parameters</dt><dd> 1412 <table class="params"> 1413 <tr><td class="paramname">b</td><td>ROM bank to switch to (max 255)</td></tr> 1414 </table> 1415 </dd> 1416</dl> 1417<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a19558f5bbc9fea767f945001ae9cd13f">SWITCH_ROM_MBC1</a>, <a class="el" href="gb_8h.html#a92d040284342702026eb19dab59b586e">SWITCH_ROM_MBC5</a>, <a class="el" href="gb_8h.html#a3fca2d0a22aa2717e62fed659caf4743">SWITCH_ROM_MEGADUCK</a> </dd></dl> 1418 1419</div> 1420</div> 1421<a id="a38ea3e4dfe02b8eae70df27f39d4a951"></a> 1422<h2 class="memtitle"><span class="permalink"><a href="#a38ea3e4dfe02b8eae70df27f39d4a951">◆ </a></span>SWITCH_RAM_MBC1</h2> 1423 1424<div class="memitem"> 1425<div class="memproto"> 1426 <table class="memname"> 1427 <tr> 1428 <td class="memname">#define SWITCH_RAM_MBC1</td> 1429 <td>(</td> 1430 <td class="paramtype"> </td> 1431 <td class="paramname"><a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td><td>)</td> 1432 <td>    *(<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *)0x4000 = (<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a>)</td> 1433 </tr> 1434 </table> 1435</div><div class="memdoc"> 1436<p>Switches SRAM bank on MBC1 and other compaticle MBCs </p><dl class="params"><dt>Parameters</dt><dd> 1437 <table class="params"> 1438 <tr><td class="paramname">b</td><td>SRAM bank to switch to </td></tr> 1439 </table> 1440 </dd> 1441</dl> 1442 1443</div> 1444</div> 1445<a id="a6e40dcc763efd953181c7400642a9f69"></a> 1446<h2 class="memtitle"><span class="permalink"><a href="#a6e40dcc763efd953181c7400642a9f69">◆ </a></span>SWITCH_RAM</h2> 1447 1448<div class="memitem"> 1449<div class="memproto"> 1450 <table class="memname"> 1451 <tr> 1452 <td class="memname">#define SWITCH_RAM   <a class="el" href="gb_8h.html#a38ea3e4dfe02b8eae70df27f39d4a951">SWITCH_RAM_MBC1</a></td> 1453 </tr> 1454 </table> 1455</div><div class="memdoc"> 1456<p>Switches SRAM bank on MBC1 and other compaticle MBCs </p><dl class="params"><dt>Parameters</dt><dd> 1457 <table class="params"> 1458 <tr><td class="paramname">b</td><td>SRAM bank to switch to</td></tr> 1459 </table> 1460 </dd> 1461</dl> 1462<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a38ea3e4dfe02b8eae70df27f39d4a951">SWITCH_RAM_MBC1</a>, <a class="el" href="gb_8h.html#a361d5055a7ae880fc1c9d6e0d1164fd6">SWITCH_RAM_MBC5</a> </dd></dl> 1463 1464</div> 1465</div> 1466<a id="ae202f64307ec00f6970ef9225e54646c"></a> 1467<h2 class="memtitle"><span class="permalink"><a href="#ae202f64307ec00f6970ef9225e54646c">◆ </a></span>ENABLE_RAM_MBC1</h2> 1468 1469<div class="memitem"> 1470<div class="memproto"> 1471 <table class="memname"> 1472 <tr> 1473 <td class="memname">#define ENABLE_RAM_MBC1    *(<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *)0x0000 = 0x0A</td> 1474 </tr> 1475 </table> 1476</div><div class="memdoc"> 1477<p>Enables SRAM on MBC1 </p> 1478 1479</div> 1480</div> 1481<a id="a0e9c88657beaac946231a4801481b97f"></a> 1482<h2 class="memtitle"><span class="permalink"><a href="#a0e9c88657beaac946231a4801481b97f">◆ </a></span>ENABLE_RAM</h2> 1483 1484<div class="memitem"> 1485<div class="memproto"> 1486 <table class="memname"> 1487 <tr> 1488 <td class="memname">#define ENABLE_RAM   <a class="el" href="gb_8h.html#ae202f64307ec00f6970ef9225e54646c">ENABLE_RAM_MBC1</a></td> 1489 </tr> 1490 </table> 1491</div><div class="memdoc"> 1492 1493</div> 1494</div> 1495<a id="a177fadce938422926b186a8e42575d1d"></a> 1496<h2 class="memtitle"><span class="permalink"><a href="#a177fadce938422926b186a8e42575d1d">◆ </a></span>DISABLE_RAM_MBC1</h2> 1497 1498<div class="memitem"> 1499<div class="memproto"> 1500 <table class="memname"> 1501 <tr> 1502 <td class="memname">#define DISABLE_RAM_MBC1    *(<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *)0x0000 = 0x00</td> 1503 </tr> 1504 </table> 1505</div><div class="memdoc"> 1506<p>Disables SRAM on MBC1 </p> 1507 1508</div> 1509</div> 1510<a id="a649d27b5587de16a66176e03a1b8ebd5"></a> 1511<h2 class="memtitle"><span class="permalink"><a href="#a649d27b5587de16a66176e03a1b8ebd5">◆ </a></span>DISABLE_RAM</h2> 1512 1513<div class="memitem"> 1514<div class="memproto"> 1515 <table class="memname"> 1516 <tr> 1517 <td class="memname">#define DISABLE_RAM   <a class="el" href="gb_8h.html#a177fadce938422926b186a8e42575d1d">DISABLE_RAM_MBC1</a></td> 1518 </tr> 1519 </table> 1520</div><div class="memdoc"> 1521 1522</div> 1523</div> 1524<a id="a0c689c5a814f1c347c4d98f28ed6c7d6"></a> 1525<h2 class="memtitle"><span class="permalink"><a href="#a0c689c5a814f1c347c4d98f28ed6c7d6">◆ </a></span>SWITCH_16_8_MODE_MBC1</h2> 1526 1527<div class="memitem"> 1528<div class="memproto"> 1529 <table class="memname"> 1530 <tr> 1531 <td class="memname">#define SWITCH_16_8_MODE_MBC1    *(<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *)0x6000 = 0x00</td> 1532 </tr> 1533 </table> 1534</div><div class="memdoc"> 1535 1536</div> 1537</div> 1538<a id="aa5d64e386a00b373f22ffdc5a152c7ba"></a> 1539<h2 class="memtitle"><span class="permalink"><a href="#aa5d64e386a00b373f22ffdc5a152c7ba">◆ </a></span>SWITCH_4_32_MODE_MBC1</h2> 1540 1541<div class="memitem"> 1542<div class="memproto"> 1543 <table class="memname"> 1544 <tr> 1545 <td class="memname">#define SWITCH_4_32_MODE_MBC1    *(<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *)0x6000 = 0x01</td> 1546 </tr> 1547 </table> 1548</div><div class="memdoc"> 1549 1550</div> 1551</div> 1552<a id="a92d040284342702026eb19dab59b586e"></a> 1553<h2 class="memtitle"><span class="permalink"><a href="#a92d040284342702026eb19dab59b586e">◆ </a></span>SWITCH_ROM_MBC5</h2> 1554 1555<div class="memitem"> 1556<div class="memproto"> 1557 <table class="memname"> 1558 <tr> 1559 <td class="memname">#define SWITCH_ROM_MBC5</td> 1560 <td>(</td> 1561 <td class="paramtype"> </td> 1562 <td class="paramname"><a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td><td>)</td> 1563 <td></td> 1564 </tr> 1565 </table> 1566</div><div class="memdoc"> 1567<b>Value:</b><div class="fragment"><div class="line"> <a class="code" href="gb_8h.html#a98b848953a95ce2fff6fda643575d74a">_current_bank</a> = (<a class="code" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a>), \</div> 1568<div class="line"> *(<a class="code" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *)0x3000 = 0, \</div> 1569<div class="line"> *(<a class="code" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *)0x2000 = (<a class="code" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a>)</div> 1570</div><!-- fragment --><p>Makes MBC5 switch to the active ROM bank; only 4M roms are supported, </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a6c15ebc660abd3a978137493ab63ffe9">SWITCH_ROM_MBC5_8M()</a> </dd></dl> 1571<dl class="params"><dt>Parameters</dt><dd> 1572 <table class="params"> 1573 <tr><td class="paramname">b</td><td>ROM bank to switch to</td></tr> 1574 </table> 1575 </dd> 1576</dl> 1577<p>Note the order used here. Writing the other way around on a MBC1 always selects bank 1 </p> 1578 1579</div> 1580</div> 1581<a id="a6c15ebc660abd3a978137493ab63ffe9"></a> 1582<h2 class="memtitle"><span class="permalink"><a href="#a6c15ebc660abd3a978137493ab63ffe9">◆ </a></span>SWITCH_ROM_MBC5_8M</h2> 1583 1584<div class="memitem"> 1585<div class="memproto"> 1586 <table class="memname"> 1587 <tr> 1588 <td class="memname">#define SWITCH_ROM_MBC5_8M</td> 1589 <td>(</td> 1590 <td class="paramtype"> </td> 1591 <td class="paramname"><a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td><td>)</td> 1592 <td></td> 1593 </tr> 1594 </table> 1595</div><div class="memdoc"> 1596<b>Value:</b><div class="fragment"><div class="line"> *(<a class="code" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *)0x3000 = ((<a class="code" href="stdint_8h.html#adf4d876453337156dde61095e1f20223">uint16_t</a>)(<a class="code" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a>) >> 8), \</div> 1597<div class="line"> *(<a class="code" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *)0x2000 = (<a class="code" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a>)</div> 1598</div><!-- fragment --><p>Makes MBC5 to switch the active ROM bank; active bank number is not tracked by _current_bank if you use this macro </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a98b848953a95ce2fff6fda643575d74a">_current_bank</a> </dd></dl> 1599<dl class="params"><dt>Parameters</dt><dd> 1600 <table class="params"> 1601 <tr><td class="paramname">b</td><td>ROM bank to switch to</td></tr> 1602 </table> 1603 </dd> 1604</dl> 1605<p>Note the order used here. Writing the other way around on a MBC1 always selects bank 1 </p> 1606 1607</div> 1608</div> 1609<a id="a361d5055a7ae880fc1c9d6e0d1164fd6"></a> 1610<h2 class="memtitle"><span class="permalink"><a href="#a361d5055a7ae880fc1c9d6e0d1164fd6">◆ </a></span>SWITCH_RAM_MBC5</h2> 1611 1612<div class="memitem"> 1613<div class="memproto"> 1614 <table class="memname"> 1615 <tr> 1616 <td class="memname">#define SWITCH_RAM_MBC5</td> 1617 <td>(</td> 1618 <td class="paramtype"> </td> 1619 <td class="paramname"><a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></td><td>)</td> 1620 <td>    *(<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *)0x4000 = (<a class="el" href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a>)</td> 1621 </tr> 1622 </table> 1623</div><div class="memdoc"> 1624<p>Switches SRAM bank on MBC5 </p><dl class="params"><dt>Parameters</dt><dd> 1625 <table class="params"> 1626 <tr><td class="paramname">b</td><td>SRAM bank to switch to </td></tr> 1627 </table> 1628 </dd> 1629</dl> 1630 1631</div> 1632</div> 1633<a id="a3f033f00c8d781637f9a665b06750937"></a> 1634<h2 class="memtitle"><span class="permalink"><a href="#a3f033f00c8d781637f9a665b06750937">◆ </a></span>ENABLE_RAM_MBC5</h2> 1635 1636<div class="memitem"> 1637<div class="memproto"> 1638 <table class="memname"> 1639 <tr> 1640 <td class="memname">#define ENABLE_RAM_MBC5    *(<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *)0x0000 = 0x0A</td> 1641 </tr> 1642 </table> 1643</div><div class="memdoc"> 1644<p>Enables SRAM on MBC5 </p> 1645 1646</div> 1647</div> 1648<a id="a60191cdfa50ed9b88515f181747eaba2"></a> 1649<h2 class="memtitle"><span class="permalink"><a href="#a60191cdfa50ed9b88515f181747eaba2">◆ </a></span>DISABLE_RAM_MBC5</h2> 1650 1651<div class="memitem"> 1652<div class="memproto"> 1653 <table class="memname"> 1654 <tr> 1655 <td class="memname">#define DISABLE_RAM_MBC5    *(<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> *)0x0000 = 0x00</td> 1656 </tr> 1657 </table> 1658</div><div class="memdoc"> 1659<p>Disables SRAM on MBC5 </p> 1660 1661</div> 1662</div> 1663<a id="a5ae6b05b3e1559c97f0d1b2daaaa0ee4"></a> 1664<h2 class="memtitle"><span class="permalink"><a href="#a5ae6b05b3e1559c97f0d1b2daaaa0ee4">◆ </a></span>DISPLAY_ON</h2> 1665 1666<div class="memitem"> 1667<div class="memproto"> 1668 <table class="memname"> 1669 <tr> 1670 <td class="memname">#define DISPLAY_ON    <a class="el" href="gb_2hardware_8h.html#a6515fdfaa50eeb7e63faeea54f77cd6b">LCDC_REG</a>|=<a class="el" href="gb_2hardware_8h.html#a1491fc03ed7f02e7309cc7b0c48b6c8a">LCDCF_ON</a></td> 1671 </tr> 1672 </table> 1673</div><div class="memdoc"> 1674<p>Turns the display back on. </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a04d57683cdd046dfa45e7e56d7c4ec4d">display_off</a>, <a class="el" href="gb_8h.html#ad2ec9831813c5e7069917aa4455af682">DISPLAY_OFF</a> </dd></dl> 1675 1676</div> 1677</div> 1678<a id="ad2ec9831813c5e7069917aa4455af682"></a> 1679<h2 class="memtitle"><span class="permalink"><a href="#ad2ec9831813c5e7069917aa4455af682">◆ </a></span>DISPLAY_OFF</h2> 1680 1681<div class="memitem"> 1682<div class="memproto"> 1683 <table class="memname"> 1684 <tr> 1685 <td class="memname">#define DISPLAY_OFF    <a class="el" href="sms_8h.html#a7b09691f25fddd65f12ed199b3f88ef0">display_off</a>();</td> 1686 </tr> 1687 </table> 1688</div><div class="memdoc"> 1689<p>Turns the display off immediately. </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a04d57683cdd046dfa45e7e56d7c4ec4d">display_off</a>, <a class="el" href="gb_8h.html#a5ae6b05b3e1559c97f0d1b2daaaa0ee4">DISPLAY_ON</a> </dd></dl> 1690 1691</div> 1692</div> 1693<a id="a0659212acd317ccdebc0ecf435df330f"></a> 1694<h2 class="memtitle"><span class="permalink"><a href="#a0659212acd317ccdebc0ecf435df330f">◆ </a></span>HIDE_LEFT_COLUMN</h2> 1695 1696<div class="memitem"> 1697<div class="memproto"> 1698 <table class="memname"> 1699 <tr> 1700 <td class="memname">#define HIDE_LEFT_COLUMN</td> 1701 </tr> 1702 </table> 1703</div><div class="memdoc"> 1704<p>Does nothing for GB </p> 1705 1706</div> 1707</div> 1708<a id="a5497c2255a9474d397446710189eacbe"></a> 1709<h2 class="memtitle"><span class="permalink"><a href="#a5497c2255a9474d397446710189eacbe">◆ </a></span>SHOW_LEFT_COLUMN</h2> 1710 1711<div class="memitem"> 1712<div class="memproto"> 1713 <table class="memname"> 1714 <tr> 1715 <td class="memname">#define SHOW_LEFT_COLUMN</td> 1716 </tr> 1717 </table> 1718</div><div class="memdoc"> 1719<p>Does nothing for GB </p> 1720 1721</div> 1722</div> 1723<a id="a8e3f36aa68ac036695816757f2a1322c"></a> 1724<h2 class="memtitle"><span class="permalink"><a href="#a8e3f36aa68ac036695816757f2a1322c">◆ </a></span>SHOW_BKG</h2> 1725 1726<div class="memitem"> 1727<div class="memproto"> 1728 <table class="memname"> 1729 <tr> 1730 <td class="memname">#define SHOW_BKG    <a class="el" href="gb_2hardware_8h.html#a6515fdfaa50eeb7e63faeea54f77cd6b">LCDC_REG</a>|=<a class="el" href="gb_2hardware_8h.html#a97ab19d938f05bffbcb4221824c3bfce">LCDCF_BGON</a></td> 1731 </tr> 1732 </table> 1733</div><div class="memdoc"> 1734<p>Turns on the background layer. Sets bit 0 of the LCDC register to 1. </p> 1735 1736</div> 1737</div> 1738<a id="a6d25f7c43b1cbbb48b95cda7ab2c3141"></a> 1739<h2 class="memtitle"><span class="permalink"><a href="#a6d25f7c43b1cbbb48b95cda7ab2c3141">◆ </a></span>HIDE_BKG</h2> 1740 1741<div class="memitem"> 1742<div class="memproto"> 1743 <table class="memname"> 1744 <tr> 1745 <td class="memname">#define HIDE_BKG    <a class="el" href="gb_2hardware_8h.html#a6515fdfaa50eeb7e63faeea54f77cd6b">LCDC_REG</a>&=~<a class="el" href="gb_2hardware_8h.html#a97ab19d938f05bffbcb4221824c3bfce">LCDCF_BGON</a></td> 1746 </tr> 1747 </table> 1748</div><div class="memdoc"> 1749<p>Turns off the background layer. Sets bit 0 of the LCDC register to 0. </p> 1750 1751</div> 1752</div> 1753<a id="ab19da2ab719bb8897bc0843a84af28f8"></a> 1754<h2 class="memtitle"><span class="permalink"><a href="#ab19da2ab719bb8897bc0843a84af28f8">◆ </a></span>SHOW_WIN</h2> 1755 1756<div class="memitem"> 1757<div class="memproto"> 1758 <table class="memname"> 1759 <tr> 1760 <td class="memname">#define SHOW_WIN    <a class="el" href="gb_2hardware_8h.html#a6515fdfaa50eeb7e63faeea54f77cd6b">LCDC_REG</a>|=<a class="el" href="gb_2hardware_8h.html#a13a5f08b9aae68f8fa57a8aa7705b732">LCDCF_WINON</a></td> 1761 </tr> 1762 </table> 1763</div><div class="memdoc"> 1764<p>Turns on the window layer Sets bit 5 of the LCDC register to 1. </p> 1765 1766</div> 1767</div> 1768<a id="aedb6e32c42d4b1d25ad11adccd7100c3"></a> 1769<h2 class="memtitle"><span class="permalink"><a href="#aedb6e32c42d4b1d25ad11adccd7100c3">◆ </a></span>HIDE_WIN</h2> 1770 1771<div class="memitem"> 1772<div class="memproto"> 1773 <table class="memname"> 1774 <tr> 1775 <td class="memname">#define HIDE_WIN    <a class="el" href="gb_2hardware_8h.html#a6515fdfaa50eeb7e63faeea54f77cd6b">LCDC_REG</a>&=~<a class="el" href="gb_2hardware_8h.html#a13a5f08b9aae68f8fa57a8aa7705b732">LCDCF_WINON</a></td> 1776 </tr> 1777 </table> 1778</div><div class="memdoc"> 1779<p>Turns off the window layer. Clears bit 5 of the LCDC register to 0. </p> 1780 1781</div> 1782</div> 1783<a id="a495bc9f405f916f02ad5d97e6e730134"></a> 1784<h2 class="memtitle"><span class="permalink"><a href="#a495bc9f405f916f02ad5d97e6e730134">◆ </a></span>SHOW_SPRITES</h2> 1785 1786<div class="memitem"> 1787<div class="memproto"> 1788 <table class="memname"> 1789 <tr> 1790 <td class="memname">#define SHOW_SPRITES    <a class="el" href="gb_2hardware_8h.html#a6515fdfaa50eeb7e63faeea54f77cd6b">LCDC_REG</a>|=<a class="el" href="gb_2hardware_8h.html#a6aef42158c90e8025b8341cdea2e3918">LCDCF_OBJON</a></td> 1791 </tr> 1792 </table> 1793</div><div class="memdoc"> 1794<p>Turns on the sprites layer. Sets bit 1 of the LCDC register to 1. </p> 1795 1796</div> 1797</div> 1798<a id="a69ef98aee664b8abd8d1a3d45f016dda"></a> 1799<h2 class="memtitle"><span class="permalink"><a href="#a69ef98aee664b8abd8d1a3d45f016dda">◆ </a></span>HIDE_SPRITES</h2> 1800 1801<div class="memitem"> 1802<div class="memproto"> 1803 <table class="memname"> 1804 <tr> 1805 <td class="memname">#define HIDE_SPRITES    <a class="el" href="gb_2hardware_8h.html#a6515fdfaa50eeb7e63faeea54f77cd6b">LCDC_REG</a>&=~<a class="el" href="gb_2hardware_8h.html#a6aef42158c90e8025b8341cdea2e3918">LCDCF_OBJON</a></td> 1806 </tr> 1807 </table> 1808</div><div class="memdoc"> 1809<p>Turns off the sprites layer. Clears bit 1 of the LCDC register to 0. </p> 1810 1811</div> 1812</div> 1813<a id="af91d252f07f4764996154820f970c101"></a> 1814<h2 class="memtitle"><span class="permalink"><a href="#af91d252f07f4764996154820f970c101">◆ </a></span>SPRITES_8x16</h2> 1815 1816<div class="memitem"> 1817<div class="memproto"> 1818 <table class="memname"> 1819 <tr> 1820 <td class="memname">#define SPRITES_8x16    <a class="el" href="gb_2hardware_8h.html#a6515fdfaa50eeb7e63faeea54f77cd6b">LCDC_REG</a>|=<a class="el" href="gb_2hardware_8h.html#a14eddd3d53d8e649f1754bd455b4863d">LCDCF_OBJ16</a></td> 1821 </tr> 1822 </table> 1823</div><div class="memdoc"> 1824<p>Sets sprite size to 8x16 pixels, two tiles one above the other. Sets bit 2 of the LCDC register to 1. </p> 1825 1826</div> 1827</div> 1828<a id="aa87bec0d134136fdb727f52cb773b792"></a> 1829<h2 class="memtitle"><span class="permalink"><a href="#aa87bec0d134136fdb727f52cb773b792">◆ </a></span>SPRITES_8x8</h2> 1830 1831<div class="memitem"> 1832<div class="memproto"> 1833 <table class="memname"> 1834 <tr> 1835 <td class="memname">#define SPRITES_8x8    <a class="el" href="gb_2hardware_8h.html#a6515fdfaa50eeb7e63faeea54f77cd6b">LCDC_REG</a>&=~<a class="el" href="gb_2hardware_8h.html#a14eddd3d53d8e649f1754bd455b4863d">LCDCF_OBJ16</a></td> 1836 </tr> 1837 </table> 1838</div><div class="memdoc"> 1839<p>Sets sprite size to 8x8 pixels, one tile. Clears bit 2 of the LCDC register to 0. </p> 1840 1841</div> 1842</div> 1843<a id="a67f80e65620470b55a4950e2966eb868"></a> 1844<h2 class="memtitle"><span class="permalink"><a href="#a67f80e65620470b55a4950e2966eb868">◆ </a></span>COMPAT_PALETTE</h2> 1845 1846<div class="memitem"> 1847<div class="memproto"> 1848 <table class="memname"> 1849 <tr> 1850 <td class="memname">#define COMPAT_PALETTE</td> 1851 <td>(</td> 1852 <td class="paramtype"> </td> 1853 <td class="paramname">C0, </td> 1854 </tr> 1855 <tr> 1856 <td class="paramkey"></td> 1857 <td></td> 1858 <td class="paramtype"> </td> 1859 <td class="paramname">C1, </td> 1860 </tr> 1861 <tr> 1862 <td class="paramkey"></td> 1863 <td></td> 1864 <td class="paramtype"> </td> 1865 <td class="paramname">C2, </td> 1866 </tr> 1867 <tr> 1868 <td class="paramkey"></td> 1869 <td></td> 1870 <td class="paramtype"> </td> 1871 <td class="paramname">C3 </td> 1872 </tr> 1873 <tr> 1874 <td></td> 1875 <td>)</td> 1876 <td></td><td>   ((<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a>)(((C3) << 6) | ((C2) << 4) | ((C1) << 2) | (C0)))</td> 1877 </tr> 1878 </table> 1879</div><div class="memdoc"> 1880 1881</div> 1882</div> 1883<a id="ab94bfec130df50d9cb808142f94603a5"></a> 1884<h2 class="memtitle"><span class="permalink"><a href="#ab94bfec130df50d9cb808142f94603a5">◆ </a></span>set_bkg_2bpp_data</h2> 1885 1886<div class="memitem"> 1887<div class="memproto"> 1888 <table class="memname"> 1889 <tr> 1890 <td class="memname">#define set_bkg_2bpp_data   <a class="el" href="sms_8h.html#a8130306da1177f4fef89e699f8e2add4">set_bkg_data</a></td> 1891 </tr> 1892 </table> 1893</div><div class="memdoc"> 1894 1895</div> 1896</div> 1897<a id="a55f82ff980398dd97036fd936ebd727e"></a> 1898<h2 class="memtitle"><span class="permalink"><a href="#a55f82ff980398dd97036fd936ebd727e">◆ </a></span>set_tile_map</h2> 1899 1900<div class="memitem"> 1901<div class="memproto"> 1902 <table class="memname"> 1903 <tr> 1904 <td class="memname">#define set_tile_map   <a class="el" href="gb_8h.html#a6da9e2fa1bafd35363e84ee999909ec7">set_bkg_tiles</a></td> 1905 </tr> 1906 </table> 1907</div><div class="memdoc"> 1908 1909</div> 1910</div> 1911<a id="adb5d0970167b81401113812773c90838"></a> 1912<h2 class="memtitle"><span class="permalink"><a href="#adb5d0970167b81401113812773c90838">◆ </a></span>set_tile_submap</h2> 1913 1914<div class="memitem"> 1915<div class="memproto"> 1916 <table class="memname"> 1917 <tr> 1918 <td class="memname">#define set_tile_submap   <a class="el" href="sms_8h.html#a0cfd261bc7a94b1f6093f423bad30298">set_bkg_submap</a></td> 1919 </tr> 1920 </table> 1921</div><div class="memdoc"> 1922 1923</div> 1924</div> 1925<a id="a3b235c526c517fb02d20cdea780ee2c5"></a> 1926<h2 class="memtitle"><span class="permalink"><a href="#a3b235c526c517fb02d20cdea780ee2c5">◆ </a></span>set_tile_xy</h2> 1927 1928<div class="memitem"> 1929<div class="memproto"> 1930 <table class="memname"> 1931 <tr> 1932 <td class="memname">#define set_tile_xy   <a class="el" href="gb_8h.html#a74ee8f0a3495508c90de4ce246b81060">set_bkg_tile_xy</a></td> 1933 </tr> 1934 </table> 1935</div><div class="memdoc"> 1936 1937</div> 1938</div> 1939<a id="a43b4f0ba65856deef626c0d9e7e41ed4"></a> 1940<h2 class="memtitle"><span class="permalink"><a href="#a43b4f0ba65856deef626c0d9e7e41ed4">◆ </a></span>set_sprite_2bpp_data</h2> 1941 1942<div class="memitem"> 1943<div class="memproto"> 1944 <table class="memname"> 1945 <tr> 1946 <td class="memname">#define set_sprite_2bpp_data   <a class="el" href="sms_8h.html#a216a3e3d320ee4d8cf4845600487ae39">set_sprite_data</a></td> 1947 </tr> 1948 </table> 1949</div><div class="memdoc"> 1950 1951</div> 1952</div> 1953<a id="a47607089a434dcda7a8583cfca03b604"></a> 1954<h2 class="memtitle"><span class="permalink"><a href="#a47607089a434dcda7a8583cfca03b604">◆ </a></span>DISABLE_OAM_DMA</h2> 1955 1956<div class="memitem"> 1957<div class="memproto"> 1958 <table class="memname"> 1959 <tr> 1960 <td class="memname">#define DISABLE_OAM_DMA    <a class="el" href="sms_8h.html#a5435fd985412934e96a490e103c6bc49">_shadow_OAM_base</a> = 0</td> 1961 </tr> 1962 </table> 1963</div><div class="memdoc"> 1964 1965</div> 1966</div> 1967<a id="abfd70bf31185a4900680977c9fb5a5ec"></a> 1968<h2 class="memtitle"><span class="permalink"><a href="#abfd70bf31185a4900680977c9fb5a5ec">◆ </a></span>DISABLE_VBL_TRANSFER</h2> 1969 1970<div class="memitem"> 1971<div class="memproto"> 1972 <table class="memname"> 1973 <tr> 1974 <td class="memname">#define DISABLE_VBL_TRANSFER   <a class="el" href="gb_8h.html#a47607089a434dcda7a8583cfca03b604">DISABLE_OAM_DMA</a></td> 1975 </tr> 1976 </table> 1977</div><div class="memdoc"> 1978<p>Disable OAM DMA copy each VBlank </p> 1979 1980</div> 1981</div> 1982<a id="a20895d53fe9caacb08ce8b071d57ce53"></a> 1983<h2 class="memtitle"><span class="permalink"><a href="#a20895d53fe9caacb08ce8b071d57ce53">◆ </a></span>ENABLE_OAM_DMA</h2> 1984 1985<div class="memitem"> 1986<div class="memproto"> 1987 <table class="memname"> 1988 <tr> 1989 <td class="memname">#define ENABLE_OAM_DMA    <a class="el" href="sms_8h.html#a5435fd985412934e96a490e103c6bc49">_shadow_OAM_base</a> = (<a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a>)((<a class="el" href="stdint_8h.html#adf4d876453337156dde61095e1f20223">uint16_t</a>)&<a class="el" href="sms_8h.html#af02f9e73bd894cc25e03aedb0a10a91d">shadow_OAM</a> >> 8)</td> 1990 </tr> 1991 </table> 1992</div><div class="memdoc"> 1993 1994</div> 1995</div> 1996<a id="a77d516c9d3f86f100eddea5e0d133a76"></a> 1997<h2 class="memtitle"><span class="permalink"><a href="#a77d516c9d3f86f100eddea5e0d133a76">◆ </a></span>ENABLE_VBL_TRANSFER</h2> 1998 1999<div class="memitem"> 2000<div class="memproto"> 2001 <table class="memname"> 2002 <tr> 2003 <td class="memname">#define ENABLE_VBL_TRANSFER   <a class="el" href="gb_8h.html#a20895d53fe9caacb08ce8b071d57ce53">ENABLE_OAM_DMA</a></td> 2004 </tr> 2005 </table> 2006</div><div class="memdoc"> 2007<p>Enable OAM DMA copy each VBlank and set it to transfer default shadow_OAM array </p> 2008 2009</div> 2010</div> 2011<a id="a8b77608c87a9aef65a03531482b2163b"></a> 2012<h2 class="memtitle"><span class="permalink"><a href="#a8b77608c87a9aef65a03531482b2163b">◆ </a></span>MAX_HARDWARE_SPRITES</h2> 2013 2014<div class="memitem"> 2015<div class="memproto"> 2016 <table class="memname"> 2017 <tr> 2018 <td class="memname">#define MAX_HARDWARE_SPRITES   40</td> 2019 </tr> 2020 </table> 2021</div><div class="memdoc"> 2022<p>Amount of hardware sprites in OAM </p> 2023 2024</div> 2025</div> 2026<a id="a47865835d7d007d71b4bc8ae5cefb73a"></a> 2027<h2 class="memtitle"><span class="permalink"><a href="#a47865835d7d007d71b4bc8ae5cefb73a">◆ </a></span>fill_rect</h2> 2028 2029<div class="memitem"> 2030<div class="memproto"> 2031 <table class="memname"> 2032 <tr> 2033 <td class="memname">#define fill_rect   <a class="el" href="gb_8h.html#a74c3f53fca019f7abcd1270650808849">fill_bkg_rect</a></td> 2034 </tr> 2035 </table> 2036</div><div class="memdoc"> 2037 2038</div> 2039</div> 2040<h2 class="groupheader">Typedef Documentation</h2> 2041<a id="a9508f919d9482d1d51534ccac212454d"></a> 2042<h2 class="memtitle"><span class="permalink"><a href="#a9508f919d9482d1d51534ccac212454d">◆ </a></span>int_handler</h2> 2043 2044<div class="memitem"> 2045<div class="memproto"> 2046 <table class="memname"> 2047 <tr> 2048 <td class="memname">typedef void(* int_handler) (void) <a class="el" href="asm_2types_8h.html#a7ed081d8dfb6902784b2fc730bbb7f96">NONBANKED</a></td> 2049 </tr> 2050 </table> 2051</div><div class="memdoc"> 2052<p>Interrupt handlers </p> 2053 2054</div> 2055</div> 2056<a id="a8e5ea12b86bdfc812448c2f5c4336c03"></a> 2057<h2 class="memtitle"><span class="permalink"><a href="#a8e5ea12b86bdfc812448c2f5c4336c03">◆ </a></span>OAM_item_t</h2> 2058 2059<div class="memitem"> 2060<div class="memproto"> 2061 <table class="memname"> 2062 <tr> 2063 <td class="memname">typedef struct <a class="el" href="struct_o_a_m__item__t.html">OAM_item_t</a> <a class="el" href="struct_o_a_m__item__t.html">OAM_item_t</a></td> 2064 </tr> 2065 </table> 2066</div><div class="memdoc"> 2067<p>Sprite Attributes structure </p><dl class="params"><dt>Parameters</dt><dd> 2068 <table class="params"> 2069 <tr><td class="paramname">x</td><td>X Coordinate of the sprite on screen </td></tr> 2070 <tr><td class="paramname">y</td><td>Y Coordinate of the sprite on screen </td></tr> 2071 <tr><td class="paramname">tile</td><td>Sprite tile number (see <a class="el" href="sms_8h.html#a05bf0b9f1328de7b568a19a2a428bcfe">set_sprite_tile</a>) </td></tr> 2072 <tr><td class="paramname">prop</td><td>OAM Property Flags (see <a class="el" href="sms_8h.html#a99ea3252469e3614e977cce2aa1d06f7">set_sprite_prop</a>) </td></tr> 2073 </table> 2074 </dd> 2075</dl> 2076 2077</div> 2078</div> 2079<h2 class="groupheader">Function Documentation</h2> 2080<a id="ad43fdfdb1e157b141f3fc48b78bf4386"></a> 2081<h2 class="memtitle"><span class="permalink"><a href="#ad43fdfdb1e157b141f3fc48b78bf4386">◆ </a></span>remove_VBL()</h2> 2082 2083<div class="memitem"> 2084<div class="memproto"> 2085 <table class="memname"> 2086 <tr> 2087 <td class="memname">void remove_VBL </td> 2088 <td>(</td> 2089 <td class="paramtype"><a class="el" href="sms_8h.html#a9508f919d9482d1d51534ccac212454d">int_handler</a> </td> 2090 <td class="paramname"><em>h</em></td><td>)</td> 2091 <td></td> 2092 </tr> 2093 </table> 2094</div><div class="memdoc"> 2095<p>The remove functions will remove any interrupt handler.</p> 2096<p>A handler of NULL will cause bad things to happen if the given interrupt is enabled.</p> 2097<p>Removes the VBL interrupt handler. </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="sms_8h.html#ae59628e2237f301df1341e22bfc8296e">add_VBL()</a></dd></dl> 2098<p>Removes the VBL interrupt handler. </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="sms_8h.html#ae59628e2237f301df1341e22bfc8296e">add_VBL()</a> </dd></dl> 2099 2100</div> 2101</div> 2102<a id="a32683767caa2a263a1f494b3605786e7"></a> 2103<h2 class="memtitle"><span class="permalink"><a href="#a32683767caa2a263a1f494b3605786e7">◆ </a></span>remove_LCD()</h2> 2104 2105<div class="memitem"> 2106<div class="memproto"> 2107 <table class="memname"> 2108 <tr> 2109 <td class="memname">void remove_LCD </td> 2110 <td>(</td> 2111 <td class="paramtype"><a class="el" href="sms_8h.html#a9508f919d9482d1d51534ccac212454d">int_handler</a> </td> 2112 <td class="paramname"><em>h</em></td><td>)</td> 2113 <td></td> 2114 </tr> 2115 </table> 2116</div><div class="memdoc"> 2117<p>Removes the LCD interrupt handler. </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a9f9f77105099a34556247d5bb03368d1">add_LCD()</a>, <a class="el" href="gb_8h.html#ad43fdfdb1e157b141f3fc48b78bf4386">remove_VBL()</a> </dd></dl> 2118 2119</div> 2120</div> 2121<a id="a142f6c7755fce8b1148faf658d8ec147"></a> 2122<h2 class="memtitle"><span class="permalink"><a href="#a142f6c7755fce8b1148faf658d8ec147">◆ </a></span>remove_TIM()</h2> 2123 2124<div class="memitem"> 2125<div class="memproto"> 2126 <table class="memname"> 2127 <tr> 2128 <td class="memname">void remove_TIM </td> 2129 <td>(</td> 2130 <td class="paramtype"><a class="el" href="sms_8h.html#a9508f919d9482d1d51534ccac212454d">int_handler</a> </td> 2131 <td class="paramname"><em>h</em></td><td>)</td> 2132 <td></td> 2133 </tr> 2134 </table> 2135</div><div class="memdoc"> 2136<p>Removes the TIM interrupt handler. </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a028d1a2e820951bb4f103d6469975ffb">add_TIM()</a>, <a class="el" href="gb_8h.html#ad43fdfdb1e157b141f3fc48b78bf4386">remove_VBL()</a> </dd></dl> 2137 2138</div> 2139</div> 2140<a id="a5b821b31215361265d8b7894a9ae7118"></a> 2141<h2 class="memtitle"><span class="permalink"><a href="#a5b821b31215361265d8b7894a9ae7118">◆ </a></span>remove_SIO()</h2> 2142 2143<div class="memitem"> 2144<div class="memproto"> 2145 <table class="memname"> 2146 <tr> 2147 <td class="memname">void remove_SIO </td> 2148 <td>(</td> 2149 <td class="paramtype"><a class="el" href="sms_8h.html#a9508f919d9482d1d51534ccac212454d">int_handler</a> </td> 2150 <td class="paramname"><em>h</em></td><td>)</td> 2151 <td></td> 2152 </tr> 2153 </table> 2154</div><div class="memdoc"> 2155<p>Removes the Serial Link / SIO interrupt handler. </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#aa82422752016328ed0765879e286019f">add_SIO()</a>, </dd> 2156<dd> 2157<a class="el" href="gb_8h.html#ad43fdfdb1e157b141f3fc48b78bf4386">remove_VBL()</a></dd></dl> 2158<p>The default SIO ISR gets installed automatically if any of the standard SIO calls are used. These calls include <a class="el" href="gb_8h.html#aa82422752016328ed0765879e286019f">add_SIO()</a>, <a class="el" href="gb_8h.html#a5b821b31215361265d8b7894a9ae7118">remove_SIO()</a>, <a class="el" href="gb_8h.html#ae339d7d8d7e0ebd6691b42608c416964">send_byte()</a>, <a class="el" href="gb_8h.html#a9a7fd7be44bb12bc85a144b732ce02f7">receive_byte()</a>.</p> 2159<p>The default SIO ISR cannot be removed once installed. Only secondary chained SIO ISRs (added with <a class="el" href="gb_8h.html#aa82422752016328ed0765879e286019f">add_SIO()</a> ) can be removed. </p> 2160 2161</div> 2162</div> 2163<a id="a4a3e87e0917d5efb6bc7c94e9754fcd0"></a> 2164<h2 class="memtitle"><span class="permalink"><a href="#a4a3e87e0917d5efb6bc7c94e9754fcd0">◆ </a></span>remove_JOY()</h2> 2165 2166<div class="memitem"> 2167<div class="memproto"> 2168 <table class="memname"> 2169 <tr> 2170 <td class="memname">void remove_JOY </td> 2171 <td>(</td> 2172 <td class="paramtype"><a class="el" href="sms_8h.html#a9508f919d9482d1d51534ccac212454d">int_handler</a> </td> 2173 <td class="paramname"><em>h</em></td><td>)</td> 2174 <td></td> 2175 </tr> 2176 </table> 2177</div><div class="memdoc"> 2178<p>Removes the JOY interrupt handler. </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#aa2f0235e78da2d1d94d3628d7a1afc30">add_JOY()</a>, <a class="el" href="gb_8h.html#ad43fdfdb1e157b141f3fc48b78bf4386">remove_VBL()</a> </dd></dl> 2179 2180</div> 2181</div> 2182<a id="a0d29659d08708143dd8bc720278e06b5"></a> 2183<h2 class="memtitle"><span class="permalink"><a href="#a0d29659d08708143dd8bc720278e06b5">◆ </a></span>add_VBL()</h2> 2184 2185<div class="memitem"> 2186<div class="memproto"> 2187 <table class="memname"> 2188 <tr> 2189 <td class="memname">void add_VBL </td> 2190 <td>(</td> 2191 <td class="paramtype"><a class="el" href="sms_8h.html#a9508f919d9482d1d51534ccac212454d">int_handler</a> </td> 2192 <td class="paramname"><em>h</em></td><td>)</td> 2193 <td></td> 2194 </tr> 2195 </table> 2196</div><div class="memdoc"> 2197<p>Adds a V-blank interrupt handler.</p> 2198<dl class="params"><dt>Parameters</dt><dd> 2199 <table class="params"> 2200 <tr><td class="paramname">h</td><td>The handler to be called whenever a V-blank interrupt occurs.</td></tr> 2201 </table> 2202 </dd> 2203</dl> 2204<p>Up to 4 handlers may be added, with the last added being called last. If the <a class="el" href="sms_8h.html#a98f7ef49e1758c601979bcb0ff19a1f0">remove_VBL</a> function is to be called, only three may be added.</p> 2205<p>Do not use <a class="el" href="asm_2types_8h.html#ae0233515480e60d29bcc731469976e02">CRITICAL</a> and <a class="el" href="asm_2types_8h.html#ac950c0db046e2f86d15e7ae1f558b017">INTERRUPT</a> attributes for a function added via <a class="el" href="sms_8h.html#ae59628e2237f301df1341e22bfc8296e">add_VBL()</a> (or LCD, etc). The attributes are only required when constructing a bare jump from the interrupt vector itself.</p> 2206<p>Note: The default VBL is installed automatically.</p> 2207<p>Adds a V-blank interrupt handler. </p> 2208 2209</div> 2210</div> 2211<a id="a9f9f77105099a34556247d5bb03368d1"></a> 2212<h2 class="memtitle"><span class="permalink"><a href="#a9f9f77105099a34556247d5bb03368d1">◆ </a></span>add_LCD()</h2> 2213 2214<div class="memitem"> 2215<div class="memproto"> 2216 <table class="memname"> 2217 <tr> 2218 <td class="memname">void add_LCD </td> 2219 <td>(</td> 2220 <td class="paramtype"><a class="el" href="sms_8h.html#a9508f919d9482d1d51534ccac212454d">int_handler</a> </td> 2221 <td class="paramname"><em>h</em></td><td>)</td> 2222 <td></td> 2223 </tr> 2224 </table> 2225</div><div class="memdoc"> 2226<p>Adds a LCD interrupt handler.</p> 2227<p>Called when the LCD interrupt occurs, which is normally when <a class="el" href="gb_2hardware_8h.html#aeb643bd4eac2e6e410cae2fae677c0a7">LY_REG</a> == <a class="el" href="gb_2hardware_8h.html#a591084a506c33266b7d6cc3b4b8936ae">LYC_REG</a>.</p> 2228<p>There are various reasons for this interrupt to occur as described by the <a class="el" href="gb_2hardware_8h.html#ad40ebf3b29add46cdd310a7e0802bc6b">STAT_REG</a> register ($FF41). One very popular reason is to indicate to the user when the video hardware is about to redraw a given LCD line. This can be useful for dynamically controlling the <a class="el" href="gb_2hardware_8h.html#a86cc170585319565195f2c163250be1f">SCX_REG</a> / <a class="el" href="gb_2hardware_8h.html#a244b162cf13bbcb4fe842d7e298b39c2">SCY_REG</a> registers ($FF43/$FF42) to perform special video effects.</p> 2229<dl class="section see"><dt>See also</dt><dd><a class="el" href="sms_8h.html#ae59628e2237f301df1341e22bfc8296e">add_VBL</a></dd></dl> 2230<p>Adds a LCD interrupt handler. </p> 2231 2232</div> 2233</div> 2234<a id="a028d1a2e820951bb4f103d6469975ffb"></a> 2235<h2 class="memtitle"><span class="permalink"><a href="#a028d1a2e820951bb4f103d6469975ffb">◆ </a></span>add_TIM()</h2> 2236 2237<div class="memitem"> 2238<div class="memproto"> 2239 <table class="memname"> 2240 <tr> 2241 <td class="memname">void add_TIM </td> 2242 <td>(</td> 2243 <td class="paramtype"><a class="el" href="sms_8h.html#a9508f919d9482d1d51534ccac212454d">int_handler</a> </td> 2244 <td class="paramname"><em>h</em></td><td>)</td> 2245 <td></td> 2246 </tr> 2247 </table> 2248</div><div class="memdoc"> 2249<p>Adds a timer interrupt handler.</p> 2250<p>Can not be used together with <a class="el" href="gb_8h.html#a970f18857533e062f4780f6e1c407d69">add_low_priority_TIM</a></p> 2251<p>This interrupt occurs when the <a class="el" href="gb_2hardware_8h.html#a9d295bb437953de5ebcb3c12d65743aa">TIMA_REG</a> register ($FF05) changes from $FF to $00.</p> 2252<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a0d29659d08708143dd8bc720278e06b5">add_VBL</a> </dd> 2253<dd> 2254<a class="el" href="gb_8h.html#a9312e7ec34162d6b6ed0875631fa6fe3">set_interrupts()</a> with <a class="el" href="gb_8h.html#a604256210ec5b90b68185e1a18efab49">TIM_IFLAG</a> </dd></dl> 2255 2256</div> 2257</div> 2258<a id="a970f18857533e062f4780f6e1c407d69"></a> 2259<h2 class="memtitle"><span class="permalink"><a href="#a970f18857533e062f4780f6e1c407d69">◆ </a></span>add_low_priority_TIM()</h2> 2260 2261<div class="memitem"> 2262<div class="memproto"> 2263 <table class="memname"> 2264 <tr> 2265 <td class="memname">void add_low_priority_TIM </td> 2266 <td>(</td> 2267 <td class="paramtype"><a class="el" href="sms_8h.html#a9508f919d9482d1d51534ccac212454d">int_handler</a> </td> 2268 <td class="paramname"><em>h</em></td><td>)</td> 2269 <td></td> 2270 </tr> 2271 </table> 2272</div><div class="memdoc"> 2273<p>Adds a timer interrupt handler, that could be interrupted by the other interrupts, as well as itself, if it runs too slow.</p> 2274<p>Can not be used together with <a class="el" href="sms_8h.html#a6c66a583a8f0744e3985c89725e3dc10">add_TIM</a></p> 2275<p>This interrupt occurs when the <a class="el" href="gb_2hardware_8h.html#a9d295bb437953de5ebcb3c12d65743aa">TIMA_REG</a> register ($FF05) changes from $FF to $00.</p> 2276<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a0d29659d08708143dd8bc720278e06b5">add_VBL</a> </dd> 2277<dd> 2278<a class="el" href="gb_8h.html#a9312e7ec34162d6b6ed0875631fa6fe3">set_interrupts()</a> with <a class="el" href="gb_8h.html#a604256210ec5b90b68185e1a18efab49">TIM_IFLAG</a> </dd></dl> 2279 2280</div> 2281</div> 2282<a id="aa82422752016328ed0765879e286019f"></a> 2283<h2 class="memtitle"><span class="permalink"><a href="#aa82422752016328ed0765879e286019f">◆ </a></span>add_SIO()</h2> 2284 2285<div class="memitem"> 2286<div class="memproto"> 2287 <table class="memname"> 2288 <tr> 2289 <td class="memname">void add_SIO </td> 2290 <td>(</td> 2291 <td class="paramtype"><a class="el" href="sms_8h.html#a9508f919d9482d1d51534ccac212454d">int_handler</a> </td> 2292 <td class="paramname"><em>h</em></td><td>)</td> 2293 <td></td> 2294 </tr> 2295 </table> 2296</div><div class="memdoc"> 2297<p>Adds a Serial Link transmit complete interrupt handler.</p> 2298<p>This interrupt occurs when a serial transfer has completed on the game link port.</p> 2299<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#ae339d7d8d7e0ebd6691b42608c416964">send_byte</a>, <a class="el" href="gb_8h.html#a9a7fd7be44bb12bc85a144b732ce02f7">receive_byte()</a>, <a class="el" href="gb_8h.html#a0d29659d08708143dd8bc720278e06b5">add_VBL()</a> </dd> 2300<dd> 2301<a class="el" href="gb_8h.html#a9312e7ec34162d6b6ed0875631fa6fe3">set_interrupts()</a> with <a class="el" href="gb_8h.html#ad90564458646c5646b3880b93db3443e">SIO_IFLAG</a> </dd></dl> 2302 2303</div> 2304</div> 2305<a id="aa2f0235e78da2d1d94d3628d7a1afc30"></a> 2306<h2 class="memtitle"><span class="permalink"><a href="#aa2f0235e78da2d1d94d3628d7a1afc30">◆ </a></span>add_JOY()</h2> 2307 2308<div class="memitem"> 2309<div class="memproto"> 2310 <table class="memname"> 2311 <tr> 2312 <td class="memname">void add_JOY </td> 2313 <td>(</td> 2314 <td class="paramtype"><a class="el" href="sms_8h.html#a9508f919d9482d1d51534ccac212454d">int_handler</a> </td> 2315 <td class="paramname"><em>h</em></td><td>)</td> 2316 <td></td> 2317 </tr> 2318 </table> 2319</div><div class="memdoc"> 2320<p>Adds a joypad button change interrupt handler.</p> 2321<p>This interrupt occurs on a transition of any of the keypad input lines from high to low. Due to the fact that keypad "bounce" is virtually always present, software should expect this interrupt to occur one or more times for every button press and one or more times for every button release.</p> 2322<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a176c477d759b814664785f3a0ad5e253">joypad()</a>, <a class="el" href="gb_8h.html#a0d29659d08708143dd8bc720278e06b5">add_VBL()</a> </dd></dl> 2323 2324</div> 2325</div> 2326<a id="a695c6d0e8fd7cf11dae0d4c67bc058f9"></a> 2327<h2 class="memtitle"><span class="permalink"><a href="#a695c6d0e8fd7cf11dae0d4c67bc058f9">◆ </a></span>nowait_int_handler()</h2> 2328 2329<div class="memitem"> 2330<div class="memproto"> 2331 <table class="memname"> 2332 <tr> 2333 <td class="memname">void nowait_int_handler </td> 2334 <td>(</td> 2335 <td class="paramname"></td><td>)</td> 2336 <td></td> 2337 </tr> 2338 </table> 2339</div><div class="memdoc"> 2340<p>Interrupt handler chain terminator that does <b>not</b> wait for .STAT</p> 2341<p>You must add this handler last in every interrupt handler chain if you want to change the default interrupt handler behaviour that waits for LCD controller mode to become 1 or 0 before return from the interrupt.</p> 2342<p>Example: </p><div class="fragment"><div class="line"><a class="code" href="asm_2types_8h.html#ae0233515480e60d29bcc731469976e02">CRITICAL</a> {</div> 2343<div class="line"> <a class="code" href="gb_8h.html#aa82422752016328ed0765879e286019f">add_SIO</a>(<a class="code" href="gb_8h.html#a695c6d0e8fd7cf11dae0d4c67bc058f9">nowait_int_handler</a>); <span class="comment">// Disable wait on VRAM state before returning from SIO interrupt</span></div> 2344<div class="line">}</div> 2345</div><!-- fragment --> <dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#acc9afd0cb72e763a1213d256b942a68f">wait_int_handler()</a> </dd></dl> 2346 2347</div> 2348</div> 2349<a id="acc9afd0cb72e763a1213d256b942a68f"></a> 2350<h2 class="memtitle"><span class="permalink"><a href="#acc9afd0cb72e763a1213d256b942a68f">◆ </a></span>wait_int_handler()</h2> 2351 2352<div class="memitem"> 2353<div class="memproto"> 2354 <table class="memname"> 2355 <tr> 2356 <td class="memname">void wait_int_handler </td> 2357 <td>(</td> 2358 <td class="paramname"></td><td>)</td> 2359 <td></td> 2360 </tr> 2361 </table> 2362</div><div class="memdoc"> 2363<p>Default Interrupt handler chain terminator that waits for </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_2hardware_8h.html#ad40ebf3b29add46cdd310a7e0802bc6b">STAT_REG</a> and <b>only</b> returns at the BEGINNING of either Mode 0 or Mode 1.</dd></dl> 2364<p>Used by default at the end of interrupt chains to help prevent graphical glitches. The glitches are caused when an ISR interrupts a graphics operation in one mode but returns in a different mode for which that graphics operation is not allowed.</p> 2365<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a695c6d0e8fd7cf11dae0d4c67bc058f9">nowait_int_handler()</a> </dd></dl> 2366 2367</div> 2368</div> 2369<a id="ade5d4c955b871b0ed884273cc2b7215a"></a> 2370<h2 class="memtitle"><span class="permalink"><a href="#ade5d4c955b871b0ed884273cc2b7215a">◆ </a></span>cancel_pending_interrupts()</h2> 2371 2372<div class="memitem"> 2373<div class="memproto"> 2374<table class="mlabels"> 2375 <tr> 2376 <td class="mlabels-left"> 2377 <table class="memname"> 2378 <tr> 2379 <td class="memname"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> cancel_pending_interrupts </td> 2380 <td>(</td> 2381 <td class="paramname"></td><td>)</td> 2382 <td></td> 2383 </tr> 2384 </table> 2385 </td> 2386 <td class="mlabels-right"> 2387<span class="mlabels"><span class="mlabel">inline</span></span> </td> 2388 </tr> 2389</table> 2390</div><div class="memdoc"> 2391<p>Cancel pending interrupts </p> 2392 2393</div> 2394</div> 2395<a id="a3ea524204d839377cf39842eec23e202"></a> 2396<h2 class="memtitle"><span class="permalink"><a href="#a3ea524204d839377cf39842eec23e202">◆ </a></span>mode()</h2> 2397 2398<div class="memitem"> 2399<div class="memproto"> 2400 <table class="memname"> 2401 <tr> 2402 <td class="memname">void mode </td> 2403 <td>(</td> 2404 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 2405 <td class="paramname"><em>m</em></td><td>)</td> 2406 <td></td> 2407 </tr> 2408 </table> 2409</div><div class="memdoc"> 2410<p>Set the current screen mode - one of M_* modes</p> 2411<p>Normally used by internal functions only.</p> 2412<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#acc9798fc62b5d626c91c8b0f20b522ff">M_DRAWING</a>, <a class="el" href="gb_8h.html#af0e30d6af308ffe5a025fbe85da40f6f">M_TEXT_OUT</a>, <a class="el" href="gb_8h.html#a908826e7180f94a5988ceb8633313a2e">M_TEXT_INOUT</a>, <a class="el" href="gb_8h.html#a04382de20738146fe873ddfb0585052b">M_NO_SCROLL</a>, <a class="el" href="gb_8h.html#aca2855edd2d28f66be551a0f7ec23f07">M_NO_INTERP</a> </dd></dl> 2413 2414</div> 2415</div> 2416<a id="a19969b36a6535fc6a966c0e5476baf9c"></a> 2417<h2 class="memtitle"><span class="permalink"><a href="#a19969b36a6535fc6a966c0e5476baf9c">◆ </a></span>get_mode()</h2> 2418 2419<div class="memitem"> 2420<div class="memproto"> 2421 <table class="memname"> 2422 <tr> 2423 <td class="memname"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> get_mode </td> 2424 <td>(</td> 2425 <td class="paramname"></td><td>)</td> 2426 <td></td> 2427 </tr> 2428 </table> 2429</div><div class="memdoc"> 2430<p>Returns the current mode</p> 2431<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#acc9798fc62b5d626c91c8b0f20b522ff">M_DRAWING</a>, <a class="el" href="gb_8h.html#af0e30d6af308ffe5a025fbe85da40f6f">M_TEXT_OUT</a>, <a class="el" href="gb_8h.html#a908826e7180f94a5988ceb8633313a2e">M_TEXT_INOUT</a>, <a class="el" href="gb_8h.html#a04382de20738146fe873ddfb0585052b">M_NO_SCROLL</a>, <a class="el" href="gb_8h.html#aca2855edd2d28f66be551a0f7ec23f07">M_NO_INTERP</a> </dd></dl> 2432 2433</div> 2434</div> 2435<a id="ae339d7d8d7e0ebd6691b42608c416964"></a> 2436<h2 class="memtitle"><span class="permalink"><a href="#ae339d7d8d7e0ebd6691b42608c416964">◆ </a></span>send_byte()</h2> 2437 2438<div class="memitem"> 2439<div class="memproto"> 2440 <table class="memname"> 2441 <tr> 2442 <td class="memname">void send_byte </td> 2443 <td>(</td> 2444 <td class="paramname"></td><td>)</td> 2445 <td></td> 2446 </tr> 2447 </table> 2448</div><div class="memdoc"> 2449<p>Serial Link: Send the byte in <a class="el" href="gb_8h.html#acae13736da20f9fc53e8d38934aa2119">_io_out</a> out through the serial port</p> 2450<p>Make sure to enable interrupts for the Serial Link before trying to transfer data. </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#aa82422752016328ed0765879e286019f">add_SIO()</a>, <a class="el" href="gb_8h.html#a5b821b31215361265d8b7894a9ae7118">remove_SIO()</a> </dd> 2451<dd> 2452<a class="el" href="gb_8h.html#a9312e7ec34162d6b6ed0875631fa6fe3">set_interrupts()</a> with <a class="el" href="sms_8h.html#ad90564458646c5646b3880b93db3443e">SIO_IFLAG</a> </dd></dl> 2453 2454</div> 2455</div> 2456<a id="a9a7fd7be44bb12bc85a144b732ce02f7"></a> 2457<h2 class="memtitle"><span class="permalink"><a href="#a9a7fd7be44bb12bc85a144b732ce02f7">◆ </a></span>receive_byte()</h2> 2458 2459<div class="memitem"> 2460<div class="memproto"> 2461 <table class="memname"> 2462 <tr> 2463 <td class="memname">void receive_byte </td> 2464 <td>(</td> 2465 <td class="paramname"></td><td>)</td> 2466 <td></td> 2467 </tr> 2468 </table> 2469</div><div class="memdoc"> 2470<p>Serial Link: Receive a byte from the serial port into <a class="el" href="gb_8h.html#a02f3a1585ae654444e628c1aa98ef0cf">_io_in</a></p> 2471<p>Make sure to enable interrupts for the Serial Link before trying to transfer data. </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#aa82422752016328ed0765879e286019f">add_SIO()</a>, <a class="el" href="gb_8h.html#a5b821b31215361265d8b7894a9ae7118">remove_SIO()</a> </dd> 2472<dd> 2473<a class="el" href="gb_8h.html#a9312e7ec34162d6b6ed0875631fa6fe3">set_interrupts()</a> with <a class="el" href="sms_8h.html#ad90564458646c5646b3880b93db3443e">SIO_IFLAG</a> </dd></dl> 2474 2475</div> 2476</div> 2477<a id="a2afae202a1f8ca59a12a6455bb909c5d"></a> 2478<h2 class="memtitle"><span class="permalink"><a href="#a2afae202a1f8ca59a12a6455bb909c5d">◆ </a></span>delay()</h2> 2479 2480<div class="memitem"> 2481<div class="memproto"> 2482 <table class="memname"> 2483 <tr> 2484 <td class="memname">void delay </td> 2485 <td>(</td> 2486 <td class="paramtype"><a class="el" href="stdint_8h.html#adf4d876453337156dde61095e1f20223">uint16_t</a> </td> 2487 <td class="paramname"><em>d</em></td><td>)</td> 2488 <td></td> 2489 </tr> 2490 </table> 2491</div><div class="memdoc"> 2492<p>Delays the given number of milliseconds. Uses no timers or interrupts, and can be called with interrupts disabled </p> 2493 2494</div> 2495</div> 2496<a id="a176c477d759b814664785f3a0ad5e253"></a> 2497<h2 class="memtitle"><span class="permalink"><a href="#a176c477d759b814664785f3a0ad5e253">◆ </a></span>joypad()</h2> 2498 2499<div class="memitem"> 2500<div class="memproto"> 2501 <table class="memname"> 2502 <tr> 2503 <td class="memname"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> joypad </td> 2504 <td>(</td> 2505 <td class="paramname"></td><td>)</td> 2506 <td></td> 2507 </tr> 2508 </table> 2509</div><div class="memdoc"> 2510<p>Reads and returns the current state of the joypad. Follows Nintendo's guidelines for reading the pad. Return value is an OR of J_*</p> 2511<p>When testing for multiple different buttons, it's best to read the joypad state <em>once</em> into a variable and then test using that variable.</p> 2512<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#ab769c6e20778298be8bc3321476ceb53">J_START</a>, <a class="el" href="gb_8h.html#ab416a9d96d1582490828f4bac78a8b5b">J_SELECT</a>, <a class="el" href="gb_8h.html#a31af766e3b598eb7a6b63f55a4988e7a">J_A</a>, <a class="el" href="gb_8h.html#ae47e59a309120f9420993f26816b5e6d">J_B</a>, <a class="el" href="gb_8h.html#a05ca817ab32f6da612c3ae26db5abf02">J_UP</a>, <a class="el" href="gb_8h.html#ae032c5c544196e37ec0432f6cfad7904">J_DOWN</a>, <a class="el" href="gb_8h.html#ac70894fecac30c1ca9917f07373cf81c">J_LEFT</a>, <a class="el" href="gb_8h.html#a3bad91d11ae09ffcbb3cb0a81873d325">J_RIGHT</a> </dd></dl> 2513 2514</div> 2515</div> 2516<a id="aae433db7d8e3ee4c095c254b8abd7b8b"></a> 2517<h2 class="memtitle"><span class="permalink"><a href="#aae433db7d8e3ee4c095c254b8abd7b8b">◆ </a></span>waitpad()</h2> 2518 2519<div class="memitem"> 2520<div class="memproto"> 2521 <table class="memname"> 2522 <tr> 2523 <td class="memname"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> waitpad </td> 2524 <td>(</td> 2525 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 2526 <td class="paramname"><em>mask</em></td><td>)</td> 2527 <td></td> 2528 </tr> 2529 </table> 2530</div><div class="memdoc"> 2531<p>Waits until at least one of the buttons given in mask are pressed.</p> 2532<dl class="params"><dt>Parameters</dt><dd> 2533 <table class="params"> 2534 <tr><td class="paramname">mask</td><td>Bitmask indicating which buttons to wait for</td></tr> 2535 </table> 2536 </dd> 2537</dl> 2538<p>Normally only used for checking one key, but it will support many, even J_LEFT at the same time as J_RIGHT. :)</p> 2539<p>Note: Checks in a loop that doesn't HALT at all, so the CPU will be maxed out until this call returns. </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a176c477d759b814664785f3a0ad5e253">joypad</a> </dd> 2540<dd> 2541<a class="el" href="gb_8h.html#ab769c6e20778298be8bc3321476ceb53">J_START</a>, <a class="el" href="gb_8h.html#ab416a9d96d1582490828f4bac78a8b5b">J_SELECT</a>, <a class="el" href="gb_8h.html#a31af766e3b598eb7a6b63f55a4988e7a">J_A</a>, <a class="el" href="gb_8h.html#ae47e59a309120f9420993f26816b5e6d">J_B</a>, <a class="el" href="gb_8h.html#a05ca817ab32f6da612c3ae26db5abf02">J_UP</a>, <a class="el" href="gb_8h.html#ae032c5c544196e37ec0432f6cfad7904">J_DOWN</a>, <a class="el" href="gb_8h.html#ac70894fecac30c1ca9917f07373cf81c">J_LEFT</a>, <a class="el" href="gb_8h.html#a3bad91d11ae09ffcbb3cb0a81873d325">J_RIGHT</a> </dd></dl> 2542 2543</div> 2544</div> 2545<a id="a8484d346b788309ac702b7e0b1fca730"></a> 2546<h2 class="memtitle"><span class="permalink"><a href="#a8484d346b788309ac702b7e0b1fca730">◆ </a></span>waitpadup()</h2> 2547 2548<div class="memitem"> 2549<div class="memproto"> 2550 <table class="memname"> 2551 <tr> 2552 <td class="memname">void waitpadup </td> 2553 <td>(</td> 2554 <td class="paramname"></td><td>)</td> 2555 <td></td> 2556 </tr> 2557 </table> 2558</div><div class="memdoc"> 2559<p>Waits for the directional pad and all buttons to be released.</p> 2560<p>Note: Checks in a loop that doesn't HALT at all, so the CPU will be maxed out until this call returns. </p> 2561 2562</div> 2563</div> 2564<a id="ab7e35e1eff44ed78ad8f0015c6e85b4e"></a> 2565<h2 class="memtitle"><span class="permalink"><a href="#ab7e35e1eff44ed78ad8f0015c6e85b4e">◆ </a></span>joypad_init()</h2> 2566 2567<div class="memitem"> 2568<div class="memproto"> 2569 <table class="memname"> 2570 <tr> 2571 <td class="memname"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> joypad_init </td> 2572 <td>(</td> 2573 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 2574 <td class="paramname"><em>npads</em>, </td> 2575 </tr> 2576 <tr> 2577 <td class="paramkey"></td> 2578 <td></td> 2579 <td class="paramtype"><a class="el" href="structjoypads__t.html">joypads_t</a> * </td> 2580 <td class="paramname"><em>joypads</em> </td> 2581 </tr> 2582 <tr> 2583 <td></td> 2584 <td>)</td> 2585 <td></td><td></td> 2586 </tr> 2587 </table> 2588</div><div class="memdoc"> 2589<p>Initializes <a class="el" href="structjoypads__t.html">joypads_t</a> structure for polling multiple joypads (for the GB and ones connected via SGB) </p><dl class="params"><dt>Parameters</dt><dd> 2590 <table class="params"> 2591 <tr><td class="paramname">npads</td><td>number of joypads requested (1, 2 or 4) </td></tr> 2592 <tr><td class="paramname">joypads</td><td>pointer to <a class="el" href="structjoypads__t.html">joypads_t</a> structure to be initialized</td></tr> 2593 </table> 2594 </dd> 2595</dl> 2596<p>Only required for <a class="el" href="sms_8h.html#a1d45c65829490c5ec98362f5e60edc20">joypad_ex</a>, not required for calls to regular <a class="el" href="gb_8h.html#a176c477d759b814664785f3a0ad5e253">joypad()</a> </p><dl class="section return"><dt>Returns</dt><dd>number of joypads avaliable </dd></dl> 2597<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a6e6f8eb1de2ae1ec9adeafbd7b9884db">joypad_ex()</a>, <a class="el" href="structjoypads__t.html">joypads_t</a> </dd></dl> 2598 2599</div> 2600</div> 2601<a id="a6e6f8eb1de2ae1ec9adeafbd7b9884db"></a> 2602<h2 class="memtitle"><span class="permalink"><a href="#a6e6f8eb1de2ae1ec9adeafbd7b9884db">◆ </a></span>joypad_ex()</h2> 2603 2604<div class="memitem"> 2605<div class="memproto"> 2606 <table class="memname"> 2607 <tr> 2608 <td class="memname">void joypad_ex </td> 2609 <td>(</td> 2610 <td class="paramtype"><a class="el" href="structjoypads__t.html">joypads_t</a> * </td> 2611 <td class="paramname"><em>joypads</em></td><td>)</td> 2612 <td></td> 2613 </tr> 2614 </table> 2615</div><div class="memdoc"> 2616<p>Polls all avaliable joypads (for the GB and ones connected via SGB) </p><dl class="params"><dt>Parameters</dt><dd> 2617 <table class="params"> 2618 <tr><td class="paramname">joypads</td><td>pointer to <a class="el" href="structjoypads__t.html">joypads_t</a> structure to be filled with joypad statuses, must be previously initialized with <a class="el" href="gb_8h.html#ab7e35e1eff44ed78ad8f0015c6e85b4e">joypad_init()</a></td></tr> 2619 </table> 2620 </dd> 2621</dl> 2622<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#ab7e35e1eff44ed78ad8f0015c6e85b4e">joypad_init()</a>, <a class="el" href="structjoypads__t.html">joypads_t</a> </dd></dl> 2623 2624</div> 2625</div> 2626<a id="ae0b13f17609b26c86fc33944aeb6e867"></a> 2627<h2 class="memtitle"><span class="permalink"><a href="#ae0b13f17609b26c86fc33944aeb6e867">◆ </a></span>enable_interrupts()</h2> 2628 2629<div class="memitem"> 2630<div class="memproto"> 2631<table class="mlabels"> 2632 <tr> 2633 <td class="mlabels-left"> 2634 <table class="memname"> 2635 <tr> 2636 <td class="memname">void enable_interrupts </td> 2637 <td>(</td> 2638 <td class="paramname"></td><td>)</td> 2639 <td></td> 2640 </tr> 2641 </table> 2642 </td> 2643 <td class="mlabels-right"> 2644<span class="mlabels"><span class="mlabel">inline</span></span> </td> 2645 </tr> 2646</table> 2647</div><div class="memdoc"> 2648<p>Enables unmasked interrupts</p> 2649<dl class="section note"><dt>Note</dt><dd>Use <a class="el" href="asm_2types_8h.html#ae0233515480e60d29bcc731469976e02">CRITICAL</a> {...} instead for creating a block of of code which should execute with interrupts temporarily turned off.</dd></dl> 2650<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#ad77796783b3a601b6f3781dfc3983499">disable_interrupts</a>, <a class="el" href="gb_8h.html#a9312e7ec34162d6b6ed0875631fa6fe3">set_interrupts</a>, <a class="el" href="asm_2types_8h.html#ae0233515480e60d29bcc731469976e02">CRITICAL</a> </dd></dl> 2651 2652</div> 2653</div> 2654<a id="ad77796783b3a601b6f3781dfc3983499"></a> 2655<h2 class="memtitle"><span class="permalink"><a href="#ad77796783b3a601b6f3781dfc3983499">◆ </a></span>disable_interrupts()</h2> 2656 2657<div class="memitem"> 2658<div class="memproto"> 2659<table class="mlabels"> 2660 <tr> 2661 <td class="mlabels-left"> 2662 <table class="memname"> 2663 <tr> 2664 <td class="memname">void disable_interrupts </td> 2665 <td>(</td> 2666 <td class="paramname"></td><td>)</td> 2667 <td></td> 2668 </tr> 2669 </table> 2670 </td> 2671 <td class="mlabels-right"> 2672<span class="mlabels"><span class="mlabel">inline</span></span> </td> 2673 </tr> 2674</table> 2675</div><div class="memdoc"> 2676<p>Disables interrupts</p> 2677<dl class="section note"><dt>Note</dt><dd>Use <a class="el" href="asm_2types_8h.html#ae0233515480e60d29bcc731469976e02">CRITICAL</a> {...} instead for creating a block of of code which should execute with interrupts temporarily turned off.</dd></dl> 2678<p>This function may be called as many times as you like; however the first call to <a class="el" href="gb_8h.html#ae0b13f17609b26c86fc33944aeb6e867">enable_interrupts</a> will re-enable them.</p> 2679<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#ae0b13f17609b26c86fc33944aeb6e867">enable_interrupts</a>, <a class="el" href="gb_8h.html#a9312e7ec34162d6b6ed0875631fa6fe3">set_interrupts</a>, <a class="el" href="asm_2types_8h.html#ae0233515480e60d29bcc731469976e02">CRITICAL</a> </dd></dl> 2680 2681</div> 2682</div> 2683<a id="a9312e7ec34162d6b6ed0875631fa6fe3"></a> 2684<h2 class="memtitle"><span class="permalink"><a href="#a9312e7ec34162d6b6ed0875631fa6fe3">◆ </a></span>set_interrupts()</h2> 2685 2686<div class="memitem"> 2687<div class="memproto"> 2688 <table class="memname"> 2689 <tr> 2690 <td class="memname">void set_interrupts </td> 2691 <td>(</td> 2692 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 2693 <td class="paramname"><em>flags</em></td><td>)</td> 2694 <td></td> 2695 </tr> 2696 </table> 2697</div><div class="memdoc"> 2698<p>Clears any pending interrupts and sets the interrupt mask register IO to flags. </p><dl class="params"><dt>Parameters</dt><dd> 2699 <table class="params"> 2700 <tr><td class="paramname">flags</td><td>A logical OR of *_IFLAGS</td></tr> 2701 </table> 2702 </dd> 2703</dl> 2704<dl class="section note"><dt>Note</dt><dd>: This disables and then re-enables interrupts so it must be used outside of a critical section.</dd></dl> 2705<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#ae0b13f17609b26c86fc33944aeb6e867">enable_interrupts()</a>, <a class="el" href="gb_8h.html#ad77796783b3a601b6f3781dfc3983499">disable_interrupts()</a> </dd> 2706<dd> 2707<a class="el" href="gb_8h.html#a2ca7720b9a5da9b2173e1f74dba85541">VBL_IFLAG</a>, <a class="el" href="gb_8h.html#a61a9e2910380de6abb34df14ef634eb4">LCD_IFLAG</a>, <a class="el" href="gb_8h.html#a604256210ec5b90b68185e1a18efab49">TIM_IFLAG</a>, <a class="el" href="gb_8h.html#ad90564458646c5646b3880b93db3443e">SIO_IFLAG</a>, <a class="el" href="gb_8h.html#a2f829cf27d6e3e24c875e9b82dfcb280">JOY_IFLAG</a> </dd></dl> 2708 2709</div> 2710</div> 2711<a id="ad20897c5c8bd47f5d4005989bead0e55"></a> 2712<h2 class="memtitle"><span class="permalink"><a href="#ad20897c5c8bd47f5d4005989bead0e55">◆ </a></span>reset()</h2> 2713 2714<div class="memitem"> 2715<div class="memproto"> 2716 <table class="memname"> 2717 <tr> 2718 <td class="memname">void reset </td> 2719 <td>(</td> 2720 <td class="paramname"></td><td>)</td> 2721 <td></td> 2722 </tr> 2723 </table> 2724</div><div class="memdoc"> 2725<p>Performs a warm reset by reloading the CPU value then jumping to the start of crt0 (0x0150) </p> 2726 2727</div> 2728</div> 2729<a id="acd186eb292d441f9389e77b545a55619"></a> 2730<h2 class="memtitle"><span class="permalink"><a href="#acd186eb292d441f9389e77b545a55619">◆ </a></span>wait_vbl_done()</h2> 2731 2732<div class="memitem"> 2733<div class="memproto"> 2734 <table class="memname"> 2735 <tr> 2736 <td class="memname">void wait_vbl_done </td> 2737 <td>(</td> 2738 <td class="paramname"></td><td>)</td> 2739 <td></td> 2740 </tr> 2741 </table> 2742</div><div class="memdoc"> 2743<p>HALTs the CPU and waits for the vertical blank interrupt (VBL) to finish.</p> 2744<p>This is often used in main loops to idle the CPU at low power until it's time to start the next frame. It's also useful for syncing animation with the screen re-draw.</p> 2745<p>Warning: If the VBL interrupt is disabled, this function will never return. If the screen is off this function returns immediately. </p> 2746 2747</div> 2748</div> 2749<a id="a04d57683cdd046dfa45e7e56d7c4ec4d"></a> 2750<h2 class="memtitle"><span class="permalink"><a href="#a04d57683cdd046dfa45e7e56d7c4ec4d">◆ </a></span>display_off()</h2> 2751 2752<div class="memitem"> 2753<div class="memproto"> 2754 <table class="memname"> 2755 <tr> 2756 <td class="memname">void display_off </td> 2757 <td>(</td> 2758 <td class="paramname"></td><td>)</td> 2759 <td></td> 2760 </tr> 2761 </table> 2762</div><div class="memdoc"> 2763<p>Turns the display off.</p> 2764<p>Waits until the VBL interrupt before turning the display off. </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a5ae6b05b3e1559c97f0d1b2daaaa0ee4">DISPLAY_ON</a> </dd></dl> 2765 2766</div> 2767</div> 2768<a id="a2550e7b6b9fd7e1fc495872502311dbb"></a> 2769<h2 class="memtitle"><span class="permalink"><a href="#a2550e7b6b9fd7e1fc495872502311dbb">◆ </a></span>refresh_OAM()</h2> 2770 2771<div class="memitem"> 2772<div class="memproto"> 2773 <table class="memname"> 2774 <tr> 2775 <td class="memname">void refresh_OAM </td> 2776 <td>(</td> 2777 <td class="paramname"></td><td>)</td> 2778 <td></td> 2779 </tr> 2780 </table> 2781</div><div class="memdoc"> 2782<p>Copies data from shadow OAM to OAM </p> 2783 2784</div> 2785</div> 2786<a id="a97b9f2fc6ac7cae97656aca940d65d44"></a> 2787<h2 class="memtitle"><span class="permalink"><a href="#a97b9f2fc6ac7cae97656aca940d65d44">◆ </a></span>hiramcpy()</h2> 2788 2789<div class="memitem"> 2790<div class="memproto"> 2791 <table class="memname"> 2792 <tr> 2793 <td class="memname">void hiramcpy </td> 2794 <td>(</td> 2795 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 2796 <td class="paramname"><em>dst</em>, </td> 2797 </tr> 2798 <tr> 2799 <td class="paramkey"></td> 2800 <td></td> 2801 <td class="paramtype">const void * </td> 2802 <td class="paramname"><em>src</em>, </td> 2803 </tr> 2804 <tr> 2805 <td class="paramkey"></td> 2806 <td></td> 2807 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 2808 <td class="paramname"><em>n</em> </td> 2809 </tr> 2810 <tr> 2811 <td></td> 2812 <td>)</td> 2813 <td></td><td></td> 2814 </tr> 2815 </table> 2816</div><div class="memdoc"> 2817<p>Copies data from somewhere in the lower address space to part of hi-ram. </p><dl class="params"><dt>Parameters</dt><dd> 2818 <table class="params"> 2819 <tr><td class="paramname">dst</td><td>Offset in high ram (0xFF00 and above) to copy to. </td></tr> 2820 <tr><td class="paramname">src</td><td>Area to copy from </td></tr> 2821 <tr><td class="paramname">n</td><td>Number of bytes to copy. </td></tr> 2822 </table> 2823 </dd> 2824</dl> 2825 2826</div> 2827</div> 2828<a id="a7080649e10765996c581e5b618e603b8"></a> 2829<h2 class="memtitle"><span class="permalink"><a href="#a7080649e10765996c581e5b618e603b8">◆ </a></span>set_vram_byte()</h2> 2830 2831<div class="memitem"> 2832<div class="memproto"> 2833 <table class="memname"> 2834 <tr> 2835 <td class="memname">void set_vram_byte </td> 2836 <td>(</td> 2837 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> * </td> 2838 <td class="paramname"><em>addr</em>, </td> 2839 </tr> 2840 <tr> 2841 <td class="paramkey"></td> 2842 <td></td> 2843 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 2844 <td class="paramname"><em>v</em> </td> 2845 </tr> 2846 <tr> 2847 <td></td> 2848 <td>)</td> 2849 <td></td><td></td> 2850 </tr> 2851 </table> 2852</div><div class="memdoc"> 2853<p>Set byte in vram at given memory location</p> 2854<dl class="params"><dt>Parameters</dt><dd> 2855 <table class="params"> 2856 <tr><td class="paramname">addr</td><td>address to write to </td></tr> 2857 <tr><td class="paramname">v</td><td>value </td></tr> 2858 </table> 2859 </dd> 2860</dl> 2861 2862</div> 2863</div> 2864<a id="aa33ba8b8d381df76edf15ea251ccb675"></a> 2865<h2 class="memtitle"><span class="permalink"><a href="#aa33ba8b8d381df76edf15ea251ccb675">◆ </a></span>get_vram_byte()</h2> 2866 2867<div class="memitem"> 2868<div class="memproto"> 2869 <table class="memname"> 2870 <tr> 2871 <td class="memname"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> get_vram_byte </td> 2872 <td>(</td> 2873 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> * </td> 2874 <td class="paramname"><em>addr</em></td><td>)</td> 2875 <td></td> 2876 </tr> 2877 </table> 2878</div><div class="memdoc"> 2879<p>Get byte from vram at given memory location</p> 2880<dl class="params"><dt>Parameters</dt><dd> 2881 <table class="params"> 2882 <tr><td class="paramname">addr</td><td>address to read from </td></tr> 2883 </table> 2884 </dd> 2885</dl> 2886<dl class="section return"><dt>Returns</dt><dd>read value </dd></dl> 2887 2888</div> 2889</div> 2890<a id="a9005b80d3315f50f0fb0e1728e7ee60f"></a> 2891<h2 class="memtitle"><span class="permalink"><a href="#a9005b80d3315f50f0fb0e1728e7ee60f">◆ </a></span>get_bkg_xy_addr()</h2> 2892 2893<div class="memitem"> 2894<div class="memproto"> 2895 <table class="memname"> 2896 <tr> 2897 <td class="memname"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a>* get_bkg_xy_addr </td> 2898 <td>(</td> 2899 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 2900 <td class="paramname"><em>x</em>, </td> 2901 </tr> 2902 <tr> 2903 <td class="paramkey"></td> 2904 <td></td> 2905 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 2906 <td class="paramname"><em>y</em> </td> 2907 </tr> 2908 <tr> 2909 <td></td> 2910 <td>)</td> 2911 <td></td><td></td> 2912 </tr> 2913 </table> 2914</div><div class="memdoc"> 2915<p>Get address of X,Y tile of background map </p> 2916 2917</div> 2918</div> 2919<a id="aa224c9bac27c7fd268e62bdf33338a84"></a> 2920<h2 class="memtitle"><span class="permalink"><a href="#aa224c9bac27c7fd268e62bdf33338a84">◆ </a></span>set_2bpp_palette()</h2> 2921 2922<div class="memitem"> 2923<div class="memproto"> 2924<table class="mlabels"> 2925 <tr> 2926 <td class="mlabels-left"> 2927 <table class="memname"> 2928 <tr> 2929 <td class="memname">void set_2bpp_palette </td> 2930 <td>(</td> 2931 <td class="paramtype"><a class="el" href="stdint_8h.html#adf4d876453337156dde61095e1f20223">uint16_t</a> </td> 2932 <td class="paramname"><em>palette</em></td><td>)</td> 2933 <td></td> 2934 </tr> 2935 </table> 2936 </td> 2937 <td class="mlabels-right"> 2938<span class="mlabels"><span class="mlabel">inline</span></span> </td> 2939 </tr> 2940</table> 2941</div><div class="memdoc"> 2942<p>Sets palette for 2bpp color translation for GG/SMS, does nothing on GB </p> 2943 2944</div> 2945</div> 2946<a id="a1f00bd35cd56aac84c108f5a802c3f9c"></a> 2947<h2 class="memtitle"><span class="permalink"><a href="#a1f00bd35cd56aac84c108f5a802c3f9c">◆ </a></span>set_1bpp_colors_ex()</h2> 2948 2949<div class="memitem"> 2950<div class="memproto"> 2951 <table class="memname"> 2952 <tr> 2953 <td class="memname">void set_1bpp_colors_ex </td> 2954 <td>(</td> 2955 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 2956 <td class="paramname"><em>fgcolor</em>, </td> 2957 </tr> 2958 <tr> 2959 <td class="paramkey"></td> 2960 <td></td> 2961 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 2962 <td class="paramname"><em>bgcolor</em>, </td> 2963 </tr> 2964 <tr> 2965 <td class="paramkey"></td> 2966 <td></td> 2967 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 2968 <td class="paramname"><em>mode</em> </td> 2969 </tr> 2970 <tr> 2971 <td></td> 2972 <td>)</td> 2973 <td></td><td></td> 2974 </tr> 2975 </table> 2976</div><div class="memdoc"> 2977 2978</div> 2979</div> 2980<a id="adcb394299a1033616fc7d2faec8bd6ad"></a> 2981<h2 class="memtitle"><span class="permalink"><a href="#adcb394299a1033616fc7d2faec8bd6ad">◆ </a></span>set_1bpp_colors()</h2> 2982 2983<div class="memitem"> 2984<div class="memproto"> 2985<table class="mlabels"> 2986 <tr> 2987 <td class="mlabels-left"> 2988 <table class="memname"> 2989 <tr> 2990 <td class="memname">void set_1bpp_colors </td> 2991 <td>(</td> 2992 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 2993 <td class="paramname"><em>fgcolor</em>, </td> 2994 </tr> 2995 <tr> 2996 <td class="paramkey"></td> 2997 <td></td> 2998 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 2999 <td class="paramname"><em>bgcolor</em> </td> 3000 </tr> 3001 <tr> 3002 <td></td> 3003 <td>)</td> 3004 <td></td><td></td> 3005 </tr> 3006 </table> 3007 </td> 3008 <td class="mlabels-right"> 3009<span class="mlabels"><span class="mlabel">inline</span></span> </td> 3010 </tr> 3011</table> 3012</div><div class="memdoc"> 3013 3014</div> 3015</div> 3016<a id="a1f5101f2b7bb0123c26a3e257f843626"></a> 3017<h2 class="memtitle"><span class="permalink"><a href="#a1f5101f2b7bb0123c26a3e257f843626">◆ </a></span>set_bkg_data()</h2> 3018 3019<div class="memitem"> 3020<div class="memproto"> 3021 <table class="memname"> 3022 <tr> 3023 <td class="memname">void set_bkg_data </td> 3024 <td>(</td> 3025 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3026 <td class="paramname"><em>first_tile</em>, </td> 3027 </tr> 3028 <tr> 3029 <td class="paramkey"></td> 3030 <td></td> 3031 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3032 <td class="paramname"><em>nb_tiles</em>, </td> 3033 </tr> 3034 <tr> 3035 <td class="paramkey"></td> 3036 <td></td> 3037 <td class="paramtype">const <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> * </td> 3038 <td class="paramname"><em>data</em> </td> 3039 </tr> 3040 <tr> 3041 <td></td> 3042 <td>)</td> 3043 <td></td><td></td> 3044 </tr> 3045 </table> 3046</div><div class="memdoc"> 3047<p>Sets VRAM Tile Pattern data for the Background / Window</p> 3048<dl class="params"><dt>Parameters</dt><dd> 3049 <table class="params"> 3050 <tr><td class="paramname">first_tile</td><td>Index of the first tile to write </td></tr> 3051 <tr><td class="paramname">nb_tiles</td><td>Number of tiles to write </td></tr> 3052 <tr><td class="paramname">data</td><td>Pointer to (2 bpp) source tile data</td></tr> 3053 </table> 3054 </dd> 3055</dl> 3056<p>Writes <b>nb_tiles</b> tiles to VRAM starting at <b>first_tile</b>, tile data is sourced from <b>data</b>. Each Tile is 16 bytes in size (8x8 pixels, 2 bits-per-pixel).</p> 3057<p>Note: Sprite Tiles 128-255 share the same memory region as Background Tiles 128-255.</p> 3058<p>GBC only: <a class="el" href="gb_2hardware_8h.html#a5ccae0d556500e1055a0ec8de20c535a">VBK_REG</a> determines which bank of Background tile patterns are written to. </p><ul> 3059<li>VBK_REG=0 indicates the first bank </li> 3060<li>VBK_REG=1 indicates the second</li> 3061</ul> 3062<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#ac2bf0c4919c30d322fa5853c896e710f">set_win_data</a>, <a class="el" href="gb_8h.html#abe4846d4570b4880b0e54b9e503f4d30">set_tile_data</a> </dd></dl> 3063 3064</div> 3065</div> 3066<a id="a711fa26feecc76dc51482b0f77062859"></a> 3067<h2 class="memtitle"><span class="permalink"><a href="#a711fa26feecc76dc51482b0f77062859">◆ </a></span>set_bkg_1bpp_data()</h2> 3068 3069<div class="memitem"> 3070<div class="memproto"> 3071 <table class="memname"> 3072 <tr> 3073 <td class="memname">void set_bkg_1bpp_data </td> 3074 <td>(</td> 3075 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3076 <td class="paramname"><em>first_tile</em>, </td> 3077 </tr> 3078 <tr> 3079 <td class="paramkey"></td> 3080 <td></td> 3081 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3082 <td class="paramname"><em>nb_tiles</em>, </td> 3083 </tr> 3084 <tr> 3085 <td class="paramkey"></td> 3086 <td></td> 3087 <td class="paramtype">const <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> * </td> 3088 <td class="paramname"><em>data</em> </td> 3089 </tr> 3090 <tr> 3091 <td></td> 3092 <td>)</td> 3093 <td></td><td></td> 3094 </tr> 3095 </table> 3096</div><div class="memdoc"> 3097<p>Sets VRAM Tile Pattern data for the Background / Window using 1bpp source data</p> 3098<dl class="params"><dt>Parameters</dt><dd> 3099 <table class="params"> 3100 <tr><td class="paramname">first_tile</td><td>Index of the first Tile to write </td></tr> 3101 <tr><td class="paramname">nb_tiles</td><td>Number of Tiles to write </td></tr> 3102 <tr><td class="paramname">data</td><td>Pointer to (1bpp) source Tile Pattern data</td></tr> 3103 </table> 3104 </dd> 3105</dl> 3106<p>Similar to <a class="el" href="sms_8h.html#a8130306da1177f4fef89e699f8e2add4">set_bkg_data</a>, except source data is 1 bit-per-pixel which gets expanded into 2 bits-per-pixel.</p> 3107<p>For a given bit that represent a pixel: </p><ul> 3108<li>0 will be expanded into color 0 </li> 3109<li>1 will be expanded into color 1, 2 or 3 depending on color argument</li> 3110</ul> 3111<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a8e3f36aa68ac036695816757f2a1322c">SHOW_BKG</a>, <a class="el" href="gb_8h.html#a6d25f7c43b1cbbb48b95cda7ab2c3141">HIDE_BKG</a>, <a class="el" href="gb_8h.html#a6da9e2fa1bafd35363e84ee999909ec7">set_bkg_tiles</a> </dd></dl> 3112 3113</div> 3114</div> 3115<a id="a5c13238dfec416439d75b133a272e6df"></a> 3116<h2 class="memtitle"><span class="permalink"><a href="#a5c13238dfec416439d75b133a272e6df">◆ </a></span>get_bkg_data()</h2> 3117 3118<div class="memitem"> 3119<div class="memproto"> 3120 <table class="memname"> 3121 <tr> 3122 <td class="memname">void get_bkg_data </td> 3123 <td>(</td> 3124 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3125 <td class="paramname"><em>first_tile</em>, </td> 3126 </tr> 3127 <tr> 3128 <td class="paramkey"></td> 3129 <td></td> 3130 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3131 <td class="paramname"><em>nb_tiles</em>, </td> 3132 </tr> 3133 <tr> 3134 <td class="paramkey"></td> 3135 <td></td> 3136 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> * </td> 3137 <td class="paramname"><em>data</em> </td> 3138 </tr> 3139 <tr> 3140 <td></td> 3141 <td>)</td> 3142 <td></td><td></td> 3143 </tr> 3144 </table> 3145</div><div class="memdoc"> 3146<p>Copies from Background / Window VRAM Tile Pattern data into a buffer</p> 3147<dl class="params"><dt>Parameters</dt><dd> 3148 <table class="params"> 3149 <tr><td class="paramname">first_tile</td><td>Index of the first Tile to read from </td></tr> 3150 <tr><td class="paramname">nb_tiles</td><td>Number of Tiles to read </td></tr> 3151 <tr><td class="paramname">data</td><td>Pointer to destination buffer for Tile Pattern data</td></tr> 3152 </table> 3153 </dd> 3154</dl> 3155<p>Copies <b>nb_tiles</b> tiles from VRAM starting at <b>first_tile</b>, Tile data is copied into <b>data</b>.</p> 3156<p>Each Tile is 16 bytes, so the buffer pointed to by <b>data</b> should be at least <b>nb_tiles</b> x 16 bytes in size.</p> 3157<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a7ef32e7c1669aba48f235500a495baba">get_win_data</a>, <a class="el" href="gb_8h.html#afd8fd71eaa36b0ddd54a2e8e516ed224">get_data</a> </dd></dl> 3158 3159</div> 3160</div> 3161<a id="a6da9e2fa1bafd35363e84ee999909ec7"></a> 3162<h2 class="memtitle"><span class="permalink"><a href="#a6da9e2fa1bafd35363e84ee999909ec7">◆ </a></span>set_bkg_tiles()</h2> 3163 3164<div class="memitem"> 3165<div class="memproto"> 3166 <table class="memname"> 3167 <tr> 3168 <td class="memname">void set_bkg_tiles </td> 3169 <td>(</td> 3170 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3171 <td class="paramname"><em>x</em>, </td> 3172 </tr> 3173 <tr> 3174 <td class="paramkey"></td> 3175 <td></td> 3176 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3177 <td class="paramname"><em>y</em>, </td> 3178 </tr> 3179 <tr> 3180 <td class="paramkey"></td> 3181 <td></td> 3182 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3183 <td class="paramname"><em>w</em>, </td> 3184 </tr> 3185 <tr> 3186 <td class="paramkey"></td> 3187 <td></td> 3188 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3189 <td class="paramname"><em>h</em>, </td> 3190 </tr> 3191 <tr> 3192 <td class="paramkey"></td> 3193 <td></td> 3194 <td class="paramtype">const <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> * </td> 3195 <td class="paramname"><em>tiles</em> </td> 3196 </tr> 3197 <tr> 3198 <td></td> 3199 <td>)</td> 3200 <td></td><td></td> 3201 </tr> 3202 </table> 3203</div><div class="memdoc"> 3204<p>Sets a rectangular region of Background Tile Map.</p> 3205<dl class="params"><dt>Parameters</dt><dd> 3206 <table class="params"> 3207 <tr><td class="paramname">x</td><td>X Start position in Background Map tile coordinates. Range 0 - 31 </td></tr> 3208 <tr><td class="paramname">y</td><td>Y Start position in Background Map tile coordinates. Range 0 - 31 </td></tr> 3209 <tr><td class="paramname">w</td><td>Width of area to set in tiles. Range 1 - 32 </td></tr> 3210 <tr><td class="paramname">h</td><td>Height of area to set in tiles. Range 1 - 32 </td></tr> 3211 <tr><td class="paramname">tiles</td><td>Pointer to source tile map data</td></tr> 3212 </table> 3213 </dd> 3214</dl> 3215<p>Entries are copied from map at <b>tiles</b> to the Background Tile Map starting at <b>x</b>, <b>y</b> writing across for <b>w</b> tiles and down for <b>h</b> tiles.</p> 3216<p>Use <a class="el" href="gb_8h.html#adb21d1c7d533a7133bab36a845489780">set_bkg_submap()</a> instead when: </p><ul> 3217<li>Source map is wider than 32 tiles. </li> 3218<li>Writing a width that does not match the source map width <b>and</b> more than one row high at a time.</li> 3219</ul> 3220<p>One byte per source tile map entry.</p> 3221<p>Writes that exceed coordinate 31 on the x or y axis will wrap around to the Left and Top edges.</p> 3222<p>Note: Patterns 128-255 overlap with patterns 128-255 of the sprite Tile Pattern table.</p> 3223<p>GBC only: <a class="el" href="gb_2hardware_8h.html#a5ccae0d556500e1055a0ec8de20c535a">VBK_REG</a> determines whether Tile Numbers or Tile Attributes get set. </p><ul> 3224<li>VBK_REG=0 Tile Numbers are written </li> 3225<li>VBK_REG=1 Tile Attributes are written</li> 3226</ul> 3227<p>GBC Tile Attributes are defined as: </p><ul> 3228<li>Bit 7 - Priority flag. When this is set, it puts the tile above the sprites with colour 0 being transparent. <br /> 3229 0: Below sprites <br /> 3230 1: Above sprites <br /> 3231 Note: <a class="el" href="sms_8h.html#a8e3f36aa68ac036695816757f2a1322c">SHOW_BKG</a> needs to be set for these priorities to take place. </li> 3232<li>Bit 6 - Vertical flip. Dictates which way up the tile is drawn vertically. <br /> 3233 0: Normal <br /> 3234 1: Flipped Vertically </li> 3235<li>Bit 5 - Horizontal flip. Dictates which way up the tile is drawn horizontally. <br /> 3236 0: Normal <br /> 3237 1: Flipped Horizontally </li> 3238<li>Bit 4 - Not used </li> 3239<li>Bit 3 - Character Bank specification. Dictates from which bank of Background Tile Patterns the tile is taken. <br /> 3240 0: Bank 0 <br /> 3241 1: Bank 1 </li> 3242<li>Bit 2 - See bit 0. </li> 3243<li>Bit 1 - See bit 0. </li> 3244<li>Bit 0 - Bits 0-2 indicate which of the 7 BKG colour palettes the tile is assigned.</li> 3245</ul> 3246<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a8e3f36aa68ac036695816757f2a1322c">SHOW_BKG</a> </dd> 3247<dd> 3248<a class="el" href="gb_8h.html#a1f5101f2b7bb0123c26a3e257f843626">set_bkg_data</a>, <a class="el" href="gb_8h.html#adb21d1c7d533a7133bab36a845489780">set_bkg_submap</a>, <a class="el" href="gb_8h.html#a5c59b4ee6323af9832998906d087266b">set_win_tiles</a>, <a class="el" href="gb_8h.html#a9b205ee302f54cb96ee59aac6d53a91c">set_tiles</a> </dd></dl> 3249 3250</div> 3251</div> 3252<a id="a811c386cac0df2d260aacb5a43608be5"></a> 3253<h2 class="memtitle"><span class="permalink"><a href="#a811c386cac0df2d260aacb5a43608be5">◆ </a></span>set_bkg_based_tiles()</h2> 3254 3255<div class="memitem"> 3256<div class="memproto"> 3257<table class="mlabels"> 3258 <tr> 3259 <td class="mlabels-left"> 3260 <table class="memname"> 3261 <tr> 3262 <td class="memname">void set_bkg_based_tiles </td> 3263 <td>(</td> 3264 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3265 <td class="paramname"><em>x</em>, </td> 3266 </tr> 3267 <tr> 3268 <td class="paramkey"></td> 3269 <td></td> 3270 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3271 <td class="paramname"><em>y</em>, </td> 3272 </tr> 3273 <tr> 3274 <td class="paramkey"></td> 3275 <td></td> 3276 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3277 <td class="paramname"><em>w</em>, </td> 3278 </tr> 3279 <tr> 3280 <td class="paramkey"></td> 3281 <td></td> 3282 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3283 <td class="paramname"><em>h</em>, </td> 3284 </tr> 3285 <tr> 3286 <td class="paramkey"></td> 3287 <td></td> 3288 <td class="paramtype">const <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> * </td> 3289 <td class="paramname"><em>tiles</em>, </td> 3290 </tr> 3291 <tr> 3292 <td class="paramkey"></td> 3293 <td></td> 3294 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3295 <td class="paramname"><em>base_tile</em> </td> 3296 </tr> 3297 <tr> 3298 <td></td> 3299 <td>)</td> 3300 <td></td><td></td> 3301 </tr> 3302 </table> 3303 </td> 3304 <td class="mlabels-right"> 3305<span class="mlabels"><span class="mlabel">inline</span></span> </td> 3306 </tr> 3307</table> 3308</div><div class="memdoc"> 3309<p>Sets a rectangular region of Background Tile Map. The offset value in <b>base_tile</b> is added to the tile ID for each map entry.</p> 3310<dl class="params"><dt>Parameters</dt><dd> 3311 <table class="params"> 3312 <tr><td class="paramname">x</td><td>X Start position in Background Map tile coordinates. Range 0 - 31 </td></tr> 3313 <tr><td class="paramname">y</td><td>Y Start position in Background Map tile coordinates. Range 0 - 31 </td></tr> 3314 <tr><td class="paramname">w</td><td>Width of area to set in tiles. Range 1 - 32 </td></tr> 3315 <tr><td class="paramname">h</td><td>Height of area to set in tiles. Range 1 - 32 </td></tr> 3316 <tr><td class="paramname">tiles</td><td>Pointer to source tile map data </td></tr> 3317 <tr><td class="paramname">base_tile</td><td>Offset each tile ID entry of the source map by this value. Range 1 - 255</td></tr> 3318 </table> 3319 </dd> 3320</dl> 3321<p>This is identical to <a class="el" href="sms_8h.html#a9a732aec1b7aec7d10a9d76ca4da2064">set_bkg_tiles()</a> except that it adds the <b>base_tile</b> parameter for when a tile map's tiles don't start at index zero. (For example, the tiles used by the map range from 100 -> 120 in VRAM instead of 0 -> 20).</p> 3322<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a6da9e2fa1bafd35363e84ee999909ec7">set_bkg_tiles</a> for more details </dd></dl> 3323 3324</div> 3325</div> 3326<a id="adb21d1c7d533a7133bab36a845489780"></a> 3327<h2 class="memtitle"><span class="permalink"><a href="#adb21d1c7d533a7133bab36a845489780">◆ </a></span>set_bkg_submap()</h2> 3328 3329<div class="memitem"> 3330<div class="memproto"> 3331<table class="mlabels"> 3332 <tr> 3333 <td class="mlabels-left"> 3334 <table class="memname"> 3335 <tr> 3336 <td class="memname">void set_bkg_submap </td> 3337 <td>(</td> 3338 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3339 <td class="paramname"><em>x</em>, </td> 3340 </tr> 3341 <tr> 3342 <td class="paramkey"></td> 3343 <td></td> 3344 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3345 <td class="paramname"><em>y</em>, </td> 3346 </tr> 3347 <tr> 3348 <td class="paramkey"></td> 3349 <td></td> 3350 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3351 <td class="paramname"><em>w</em>, </td> 3352 </tr> 3353 <tr> 3354 <td class="paramkey"></td> 3355 <td></td> 3356 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3357 <td class="paramname"><em>h</em>, </td> 3358 </tr> 3359 <tr> 3360 <td class="paramkey"></td> 3361 <td></td> 3362 <td class="paramtype">const <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> * </td> 3363 <td class="paramname"><em>map</em>, </td> 3364 </tr> 3365 <tr> 3366 <td class="paramkey"></td> 3367 <td></td> 3368 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3369 <td class="paramname"><em>map_w</em> </td> 3370 </tr> 3371 <tr> 3372 <td></td> 3373 <td>)</td> 3374 <td></td><td></td> 3375 </tr> 3376 </table> 3377 </td> 3378 <td class="mlabels-right"> 3379<span class="mlabels"><span class="mlabel">inline</span></span> </td> 3380 </tr> 3381</table> 3382</div><div class="memdoc"> 3383<p>Sets a rectangular area of the Background Tile Map using a sub-region from a source tile map. Useful for scrolling implementations of maps larger than 32 x 32 tiles.</p> 3384<dl class="params"><dt>Parameters</dt><dd> 3385 <table class="params"> 3386 <tr><td class="paramname">x</td><td>X Start position in Background Map tile coordinates. Range 0 - 31 </td></tr> 3387 <tr><td class="paramname">y</td><td>Y Start position in Background Map tile coordinates. Range 0 - 31 </td></tr> 3388 <tr><td class="paramname">w</td><td>Width of area to set in tiles. Range 1 - 255 </td></tr> 3389 <tr><td class="paramname">h</td><td>Height of area to set in tiles. Range 1 - 255 </td></tr> 3390 <tr><td class="paramname">map</td><td>Pointer to source tile map data </td></tr> 3391 <tr><td class="paramname">map_w</td><td>Width of source tile map in tiles. Range 1 - 255</td></tr> 3392 </table> 3393 </dd> 3394</dl> 3395<p>Entries are copied from <b>map</b> to the Background Tile Map starting at <b>x</b>, <b>y</b> writing across for <b>w</b> tiles and down for <b>h</b> tiles, using <b>map_w</b> as the rowstride for the source tile map.</p> 3396<p>Use this instead of <a class="el" href="gb_8h.html#a6da9e2fa1bafd35363e84ee999909ec7">set_bkg_tiles</a> when the source map is wider than 32 tiles or when writing a width that does not match the source map width.</p> 3397<p>One byte per source tile map entry.</p> 3398<p>Writes that exceed coordinate 31 on the x or y axis will wrap around to the Left and Top edges.</p> 3399<p>See <a class="el" href="gb_8h.html#a6da9e2fa1bafd35363e84ee999909ec7">set_bkg_tiles</a> for setting CGB attribute maps with <a class="el" href="gb_2hardware_8h.html#a5ccae0d556500e1055a0ec8de20c535a">VBK_REG</a>.</p> 3400<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a8e3f36aa68ac036695816757f2a1322c">SHOW_BKG</a> </dd> 3401<dd> 3402<a class="el" href="gb_8h.html#a1f5101f2b7bb0123c26a3e257f843626">set_bkg_data</a>, <a class="el" href="gb_8h.html#a6da9e2fa1bafd35363e84ee999909ec7">set_bkg_tiles</a>, <a class="el" href="gb_8h.html#af80befa3cad9cae361c7cf4fffb3a8de">set_win_submap</a>, <a class="el" href="gb_8h.html#a9b205ee302f54cb96ee59aac6d53a91c">set_tiles</a> </dd></dl> 3403 3404</div> 3405</div> 3406<a id="abc8bc5808620a9717263b8c9ec2237f0"></a> 3407<h2 class="memtitle"><span class="permalink"><a href="#abc8bc5808620a9717263b8c9ec2237f0">◆ </a></span>set_bkg_based_submap()</h2> 3408 3409<div class="memitem"> 3410<div class="memproto"> 3411<table class="mlabels"> 3412 <tr> 3413 <td class="mlabels-left"> 3414 <table class="memname"> 3415 <tr> 3416 <td class="memname">void set_bkg_based_submap </td> 3417 <td>(</td> 3418 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3419 <td class="paramname"><em>x</em>, </td> 3420 </tr> 3421 <tr> 3422 <td class="paramkey"></td> 3423 <td></td> 3424 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3425 <td class="paramname"><em>y</em>, </td> 3426 </tr> 3427 <tr> 3428 <td class="paramkey"></td> 3429 <td></td> 3430 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3431 <td class="paramname"><em>w</em>, </td> 3432 </tr> 3433 <tr> 3434 <td class="paramkey"></td> 3435 <td></td> 3436 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3437 <td class="paramname"><em>h</em>, </td> 3438 </tr> 3439 <tr> 3440 <td class="paramkey"></td> 3441 <td></td> 3442 <td class="paramtype">const <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> * </td> 3443 <td class="paramname"><em>map</em>, </td> 3444 </tr> 3445 <tr> 3446 <td class="paramkey"></td> 3447 <td></td> 3448 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3449 <td class="paramname"><em>map_w</em>, </td> 3450 </tr> 3451 <tr> 3452 <td class="paramkey"></td> 3453 <td></td> 3454 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3455 <td class="paramname"><em>base_tile</em> </td> 3456 </tr> 3457 <tr> 3458 <td></td> 3459 <td>)</td> 3460 <td></td><td></td> 3461 </tr> 3462 </table> 3463 </td> 3464 <td class="mlabels-right"> 3465<span class="mlabels"><span class="mlabel">inline</span></span> </td> 3466 </tr> 3467</table> 3468</div><div class="memdoc"> 3469<p>Sets a rectangular area of the Background Tile Map using a sub-region from a source tile map. The offset value in <b>base_tile</b> is added to the tile ID for each map entry.</p> 3470<dl class="params"><dt>Parameters</dt><dd> 3471 <table class="params"> 3472 <tr><td class="paramname">x</td><td>X Start position in Background Map tile coordinates. Range 0 - 31 </td></tr> 3473 <tr><td class="paramname">y</td><td>Y Start position in Background Map tile coordinates. Range 0 - 31 </td></tr> 3474 <tr><td class="paramname">w</td><td>Width of area to set in tiles. Range 1 - 255 </td></tr> 3475 <tr><td class="paramname">h</td><td>Height of area to set in tiles. Range 1 - 255 </td></tr> 3476 <tr><td class="paramname">map</td><td>Pointer to source tile map data </td></tr> 3477 <tr><td class="paramname">map_w</td><td>Width of source tile map in tiles. Range 1 - 255 </td></tr> 3478 <tr><td class="paramname">base_tile</td><td>Offset each tile ID entry of the source map by this value. Range 1 - 255</td></tr> 3479 </table> 3480 </dd> 3481</dl> 3482<p>This is identical to <a class="el" href="gb_8h.html#abc8bc5808620a9717263b8c9ec2237f0">set_bkg_based_submap()</a> except that it adds the <b>base_tile</b> parameter for when a tile map's tiles don't start at index zero. (For example, the tiles used by the map range from 100 -> 120 in VRAM instead of 0 -> 20).</p> 3483<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#abc8bc5808620a9717263b8c9ec2237f0">set_bkg_based_submap</a> for more details </dd></dl> 3484 3485</div> 3486</div> 3487<a id="aa6bcf24d97f93307b30f2906251f39a0"></a> 3488<h2 class="memtitle"><span class="permalink"><a href="#aa6bcf24d97f93307b30f2906251f39a0">◆ </a></span>get_bkg_tiles()</h2> 3489 3490<div class="memitem"> 3491<div class="memproto"> 3492 <table class="memname"> 3493 <tr> 3494 <td class="memname">void get_bkg_tiles </td> 3495 <td>(</td> 3496 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3497 <td class="paramname"><em>x</em>, </td> 3498 </tr> 3499 <tr> 3500 <td class="paramkey"></td> 3501 <td></td> 3502 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3503 <td class="paramname"><em>y</em>, </td> 3504 </tr> 3505 <tr> 3506 <td class="paramkey"></td> 3507 <td></td> 3508 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3509 <td class="paramname"><em>w</em>, </td> 3510 </tr> 3511 <tr> 3512 <td class="paramkey"></td> 3513 <td></td> 3514 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3515 <td class="paramname"><em>h</em>, </td> 3516 </tr> 3517 <tr> 3518 <td class="paramkey"></td> 3519 <td></td> 3520 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> * </td> 3521 <td class="paramname"><em>tiles</em> </td> 3522 </tr> 3523 <tr> 3524 <td></td> 3525 <td>)</td> 3526 <td></td><td></td> 3527 </tr> 3528 </table> 3529</div><div class="memdoc"> 3530<p>Copies a rectangular region of Background Tile Map entries into a buffer.</p> 3531<dl class="params"><dt>Parameters</dt><dd> 3532 <table class="params"> 3533 <tr><td class="paramname">x</td><td>X Start position in Background Map tile coordinates. Range 0 - 31 </td></tr> 3534 <tr><td class="paramname">y</td><td>Y Start position in Background Map tile coordinates. Range 0 - 31 </td></tr> 3535 <tr><td class="paramname">w</td><td>Width of area to copy in tiles. Range 0 - 31 </td></tr> 3536 <tr><td class="paramname">h</td><td>Height of area to copy in tiles. Range 0 - 31 </td></tr> 3537 <tr><td class="paramname">tiles</td><td>Pointer to destination buffer for Tile Map data</td></tr> 3538 </table> 3539 </dd> 3540</dl> 3541<p>Entries are copied into <b>tiles</b> from the Background Tile Map starting at <b>x</b>, <b>y</b> reading across for <b>w</b> tiles and down for <b>h</b> tiles.</p> 3542<p>One byte per tile.</p> 3543<p>The buffer pointed to by <b>tiles</b> should be at least <b>x</b> x <b>y</b> bytes in size.</p> 3544<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a8a469de4c6640f921254b336b5a6191a">get_win_tiles</a>, <a class="el" href="gb_8h.html#a55c6581dbe9300dc6df41730f090af51">get_bkg_tile_xy</a>, <a class="el" href="gb_8h.html#a728b9440accedc5fb3477be3d150323a">get_tiles</a>, <a class="el" href="gb_8h.html#aa33ba8b8d381df76edf15ea251ccb675">get_vram_byte</a> </dd></dl> 3545 3546</div> 3547</div> 3548<a id="a74ee8f0a3495508c90de4ce246b81060"></a> 3549<h2 class="memtitle"><span class="permalink"><a href="#a74ee8f0a3495508c90de4ce246b81060">◆ </a></span>set_bkg_tile_xy()</h2> 3550 3551<div class="memitem"> 3552<div class="memproto"> 3553 <table class="memname"> 3554 <tr> 3555 <td class="memname"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a>* set_bkg_tile_xy </td> 3556 <td>(</td> 3557 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3558 <td class="paramname"><em>x</em>, </td> 3559 </tr> 3560 <tr> 3561 <td class="paramkey"></td> 3562 <td></td> 3563 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3564 <td class="paramname"><em>y</em>, </td> 3565 </tr> 3566 <tr> 3567 <td class="paramkey"></td> 3568 <td></td> 3569 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3570 <td class="paramname"><em>t</em> </td> 3571 </tr> 3572 <tr> 3573 <td></td> 3574 <td>)</td> 3575 <td></td><td></td> 3576 </tr> 3577 </table> 3578</div><div class="memdoc"> 3579<p>Set single tile t on background layer at x,y </p><dl class="params"><dt>Parameters</dt><dd> 3580 <table class="params"> 3581 <tr><td class="paramname">x</td><td>X-coordinate </td></tr> 3582 <tr><td class="paramname">y</td><td>Y-coordinate </td></tr> 3583 <tr><td class="paramname">t</td><td>tile index </td></tr> 3584 </table> 3585 </dd> 3586</dl> 3587<dl class="section return"><dt>Returns</dt><dd>returns the address of tile, so you may use faster <a class="el" href="gb_8h.html#a7080649e10765996c581e5b618e603b8">set_vram_byte()</a> later </dd></dl> 3588 3589</div> 3590</div> 3591<a id="a55c6581dbe9300dc6df41730f090af51"></a> 3592<h2 class="memtitle"><span class="permalink"><a href="#a55c6581dbe9300dc6df41730f090af51">◆ </a></span>get_bkg_tile_xy()</h2> 3593 3594<div class="memitem"> 3595<div class="memproto"> 3596 <table class="memname"> 3597 <tr> 3598 <td class="memname"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> get_bkg_tile_xy </td> 3599 <td>(</td> 3600 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3601 <td class="paramname"><em>x</em>, </td> 3602 </tr> 3603 <tr> 3604 <td class="paramkey"></td> 3605 <td></td> 3606 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3607 <td class="paramname"><em>y</em> </td> 3608 </tr> 3609 <tr> 3610 <td></td> 3611 <td>)</td> 3612 <td></td><td></td> 3613 </tr> 3614 </table> 3615</div><div class="memdoc"> 3616<p>Get single tile t on background layer at x,y </p><dl class="params"><dt>Parameters</dt><dd> 3617 <table class="params"> 3618 <tr><td class="paramname">x</td><td>X-coordinate </td></tr> 3619 <tr><td class="paramname">y</td><td>Y-coordinate </td></tr> 3620 </table> 3621 </dd> 3622</dl> 3623<dl class="section return"><dt>Returns</dt><dd>returns tile index </dd></dl> 3624 3625</div> 3626</div> 3627<a id="a6261537edc74068e3f7f057e6a3e8a57"></a> 3628<h2 class="memtitle"><span class="permalink"><a href="#a6261537edc74068e3f7f057e6a3e8a57">◆ </a></span>move_bkg()</h2> 3629 3630<div class="memitem"> 3631<div class="memproto"> 3632<table class="mlabels"> 3633 <tr> 3634 <td class="mlabels-left"> 3635 <table class="memname"> 3636 <tr> 3637 <td class="memname">void move_bkg </td> 3638 <td>(</td> 3639 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3640 <td class="paramname"><em>x</em>, </td> 3641 </tr> 3642 <tr> 3643 <td class="paramkey"></td> 3644 <td></td> 3645 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3646 <td class="paramname"><em>y</em> </td> 3647 </tr> 3648 <tr> 3649 <td></td> 3650 <td>)</td> 3651 <td></td><td></td> 3652 </tr> 3653 </table> 3654 </td> 3655 <td class="mlabels-right"> 3656<span class="mlabels"><span class="mlabel">inline</span></span> </td> 3657 </tr> 3658</table> 3659</div><div class="memdoc"> 3660<p>Moves the Background Layer to the position specified in <b>x</b> and <b>y</b> in pixels.</p> 3661<dl class="params"><dt>Parameters</dt><dd> 3662 <table class="params"> 3663 <tr><td class="paramname">x</td><td>X axis screen coordinate for Left edge of the Background </td></tr> 3664 <tr><td class="paramname">y</td><td>Y axis screen coordinate for Top edge of the Background</td></tr> 3665 </table> 3666 </dd> 3667</dl> 3668<p>0,0 is the top left corner of the GB screen. The Background Layer wraps around the screen, so when part of it goes off the screen it appears on the opposite side (factoring in the larger size of the Background Layer versus the screen size).</p> 3669<p>The background layer is always under the Window Layer.</p> 3670<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a8e3f36aa68ac036695816757f2a1322c">SHOW_BKG</a>, <a class="el" href="gb_8h.html#a6d25f7c43b1cbbb48b95cda7ab2c3141">HIDE_BKG</a> </dd></dl> 3671 3672</div> 3673</div> 3674<a id="a1f583f7a880daa6145ca78b086a209d1"></a> 3675<h2 class="memtitle"><span class="permalink"><a href="#a1f583f7a880daa6145ca78b086a209d1">◆ </a></span>scroll_bkg()</h2> 3676 3677<div class="memitem"> 3678<div class="memproto"> 3679<table class="mlabels"> 3680 <tr> 3681 <td class="mlabels-left"> 3682 <table class="memname"> 3683 <tr> 3684 <td class="memname">void scroll_bkg </td> 3685 <td>(</td> 3686 <td class="paramtype"><a class="el" href="stdint_8h.html#aef44329758059c91c76d334e8fc09700">int8_t</a> </td> 3687 <td class="paramname"><em>x</em>, </td> 3688 </tr> 3689 <tr> 3690 <td class="paramkey"></td> 3691 <td></td> 3692 <td class="paramtype"><a class="el" href="stdint_8h.html#aef44329758059c91c76d334e8fc09700">int8_t</a> </td> 3693 <td class="paramname"><em>y</em> </td> 3694 </tr> 3695 <tr> 3696 <td></td> 3697 <td>)</td> 3698 <td></td><td></td> 3699 </tr> 3700 </table> 3701 </td> 3702 <td class="mlabels-right"> 3703<span class="mlabels"><span class="mlabel">inline</span></span> </td> 3704 </tr> 3705</table> 3706</div><div class="memdoc"> 3707<p>Moves the Background relative to it's current position.</p> 3708<dl class="params"><dt>Parameters</dt><dd> 3709 <table class="params"> 3710 <tr><td class="paramname">x</td><td>Number of pixels to move the Background on the <b>X axis</b> <br /> 3711 Range: -128 - 127 </td></tr> 3712 <tr><td class="paramname">y</td><td>Number of pixels to move the Background on the <b>Y axis</b> <br /> 3713 Range: -128 - 127</td></tr> 3714 </table> 3715 </dd> 3716</dl> 3717<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a6261537edc74068e3f7f057e6a3e8a57">move_bkg</a> </dd></dl> 3718 3719</div> 3720</div> 3721<a id="aa8213cfad631865e3b6faec18e772cb4"></a> 3722<h2 class="memtitle"><span class="permalink"><a href="#aa8213cfad631865e3b6faec18e772cb4">◆ </a></span>get_win_xy_addr()</h2> 3723 3724<div class="memitem"> 3725<div class="memproto"> 3726 <table class="memname"> 3727 <tr> 3728 <td class="memname"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a>* get_win_xy_addr </td> 3729 <td>(</td> 3730 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3731 <td class="paramname"><em>x</em>, </td> 3732 </tr> 3733 <tr> 3734 <td class="paramkey"></td> 3735 <td></td> 3736 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3737 <td class="paramname"><em>y</em> </td> 3738 </tr> 3739 <tr> 3740 <td></td> 3741 <td>)</td> 3742 <td></td><td></td> 3743 </tr> 3744 </table> 3745</div><div class="memdoc"> 3746<p>Get address of X,Y tile of window map </p> 3747 3748</div> 3749</div> 3750<a id="ac2bf0c4919c30d322fa5853c896e710f"></a> 3751<h2 class="memtitle"><span class="permalink"><a href="#ac2bf0c4919c30d322fa5853c896e710f">◆ </a></span>set_win_data()</h2> 3752 3753<div class="memitem"> 3754<div class="memproto"> 3755 <table class="memname"> 3756 <tr> 3757 <td class="memname">void set_win_data </td> 3758 <td>(</td> 3759 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3760 <td class="paramname"><em>first_tile</em>, </td> 3761 </tr> 3762 <tr> 3763 <td class="paramkey"></td> 3764 <td></td> 3765 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3766 <td class="paramname"><em>nb_tiles</em>, </td> 3767 </tr> 3768 <tr> 3769 <td class="paramkey"></td> 3770 <td></td> 3771 <td class="paramtype">const <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> * </td> 3772 <td class="paramname"><em>data</em> </td> 3773 </tr> 3774 <tr> 3775 <td></td> 3776 <td>)</td> 3777 <td></td><td></td> 3778 </tr> 3779 </table> 3780</div><div class="memdoc"> 3781<p>Sets VRAM Tile Pattern data for the Window / Background</p> 3782<dl class="params"><dt>Parameters</dt><dd> 3783 <table class="params"> 3784 <tr><td class="paramname">first_tile</td><td>Index of the first tile to write </td></tr> 3785 <tr><td class="paramname">nb_tiles</td><td>Number of tiles to write </td></tr> 3786 <tr><td class="paramname">data</td><td>Pointer to (2 bpp) source Tile Pattern data.</td></tr> 3787 </table> 3788 </dd> 3789</dl> 3790<p>This is the same as <a class="el" href="sms_8h.html#a8130306da1177f4fef89e699f8e2add4">set_bkg_data</a>, since the Window Layer and Background Layer share the same Tile pattern data.</p> 3791<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a1f5101f2b7bb0123c26a3e257f843626">set_bkg_data</a> </dd> 3792<dd> 3793<a class="el" href="gb_8h.html#a5c59b4ee6323af9832998906d087266b">set_win_tiles</a>, <a class="el" href="gb_8h.html#a1f5101f2b7bb0123c26a3e257f843626">set_bkg_data</a>, <a class="el" href="gb_8h.html#a650d2df96e69a40b70548ab468e00f25">set_data</a> </dd> 3794<dd> 3795<a class="el" href="gb_8h.html#ab19da2ab719bb8897bc0843a84af28f8">SHOW_WIN</a>, <a class="el" href="gb_8h.html#aedb6e32c42d4b1d25ad11adccd7100c3">HIDE_WIN</a> </dd></dl> 3796 3797</div> 3798</div> 3799<a id="acd5ee7a94059e6edbe9223f291bc2b46"></a> 3800<h2 class="memtitle"><span class="permalink"><a href="#acd5ee7a94059e6edbe9223f291bc2b46">◆ </a></span>set_win_1bpp_data()</h2> 3801 3802<div class="memitem"> 3803<div class="memproto"> 3804 <table class="memname"> 3805 <tr> 3806 <td class="memname">void set_win_1bpp_data </td> 3807 <td>(</td> 3808 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3809 <td class="paramname"><em>first_tile</em>, </td> 3810 </tr> 3811 <tr> 3812 <td class="paramkey"></td> 3813 <td></td> 3814 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3815 <td class="paramname"><em>nb_tiles</em>, </td> 3816 </tr> 3817 <tr> 3818 <td class="paramkey"></td> 3819 <td></td> 3820 <td class="paramtype">const <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> * </td> 3821 <td class="paramname"><em>data</em> </td> 3822 </tr> 3823 <tr> 3824 <td></td> 3825 <td>)</td> 3826 <td></td><td></td> 3827 </tr> 3828 </table> 3829</div><div class="memdoc"> 3830<p>Sets VRAM Tile Pattern data for the Window / Background using 1bpp source data</p> 3831<dl class="params"><dt>Parameters</dt><dd> 3832 <table class="params"> 3833 <tr><td class="paramname">first_tile</td><td>Index of the first tile to write </td></tr> 3834 <tr><td class="paramname">nb_tiles</td><td>Number of tiles to write </td></tr> 3835 <tr><td class="paramname">data</td><td>Pointer to (1bpp) source Tile Pattern data</td></tr> 3836 </table> 3837 </dd> 3838</dl> 3839<p>This is the same as <a class="el" href="sms_8h.html#a4d5f74eed0489ebfdc2410ee3f9f7f04">set_bkg_1bpp_data</a>, since the Window Layer and Background Layer share the same Tile pattern data.</p> 3840<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a1f5101f2b7bb0123c26a3e257f843626">set_bkg_data</a>, <a class="el" href="gb_8h.html#a711fa26feecc76dc51482b0f77062859">set_bkg_1bpp_data</a>, <a class="el" href="gb_8h.html#ac2bf0c4919c30d322fa5853c896e710f">set_win_data</a> </dd></dl> 3841 3842</div> 3843</div> 3844<a id="a7ef32e7c1669aba48f235500a495baba"></a> 3845<h2 class="memtitle"><span class="permalink"><a href="#a7ef32e7c1669aba48f235500a495baba">◆ </a></span>get_win_data()</h2> 3846 3847<div class="memitem"> 3848<div class="memproto"> 3849 <table class="memname"> 3850 <tr> 3851 <td class="memname">void get_win_data </td> 3852 <td>(</td> 3853 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3854 <td class="paramname"><em>first_tile</em>, </td> 3855 </tr> 3856 <tr> 3857 <td class="paramkey"></td> 3858 <td></td> 3859 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3860 <td class="paramname"><em>nb_tiles</em>, </td> 3861 </tr> 3862 <tr> 3863 <td class="paramkey"></td> 3864 <td></td> 3865 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> * </td> 3866 <td class="paramname"><em>data</em> </td> 3867 </tr> 3868 <tr> 3869 <td></td> 3870 <td>)</td> 3871 <td></td><td></td> 3872 </tr> 3873 </table> 3874</div><div class="memdoc"> 3875<p>Copies from Window / Background VRAM Tile Pattern data into a buffer</p> 3876<dl class="params"><dt>Parameters</dt><dd> 3877 <table class="params"> 3878 <tr><td class="paramname">first_tile</td><td>Index of the first Tile to read from </td></tr> 3879 <tr><td class="paramname">nb_tiles</td><td>Number of Tiles to read </td></tr> 3880 <tr><td class="paramname">data</td><td>Pointer to destination buffer for Tile Pattern Data</td></tr> 3881 </table> 3882 </dd> 3883</dl> 3884<p>This is the same as <a class="el" href="gb_8h.html#a5c13238dfec416439d75b133a272e6df">get_bkg_data</a>, since the Window Layer and Background Layer share the same Tile pattern data.</p> 3885<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a5c13238dfec416439d75b133a272e6df">get_bkg_data</a>, <a class="el" href="gb_8h.html#afd8fd71eaa36b0ddd54a2e8e516ed224">get_data</a> </dd></dl> 3886 3887</div> 3888</div> 3889<a id="a5c59b4ee6323af9832998906d087266b"></a> 3890<h2 class="memtitle"><span class="permalink"><a href="#a5c59b4ee6323af9832998906d087266b">◆ </a></span>set_win_tiles()</h2> 3891 3892<div class="memitem"> 3893<div class="memproto"> 3894 <table class="memname"> 3895 <tr> 3896 <td class="memname">void set_win_tiles </td> 3897 <td>(</td> 3898 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3899 <td class="paramname"><em>x</em>, </td> 3900 </tr> 3901 <tr> 3902 <td class="paramkey"></td> 3903 <td></td> 3904 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3905 <td class="paramname"><em>y</em>, </td> 3906 </tr> 3907 <tr> 3908 <td class="paramkey"></td> 3909 <td></td> 3910 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3911 <td class="paramname"><em>w</em>, </td> 3912 </tr> 3913 <tr> 3914 <td class="paramkey"></td> 3915 <td></td> 3916 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3917 <td class="paramname"><em>h</em>, </td> 3918 </tr> 3919 <tr> 3920 <td class="paramkey"></td> 3921 <td></td> 3922 <td class="paramtype">const <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> * </td> 3923 <td class="paramname"><em>tiles</em> </td> 3924 </tr> 3925 <tr> 3926 <td></td> 3927 <td>)</td> 3928 <td></td><td></td> 3929 </tr> 3930 </table> 3931</div><div class="memdoc"> 3932<p>Sets a rectangular region of the Window Tile Map.</p> 3933<dl class="params"><dt>Parameters</dt><dd> 3934 <table class="params"> 3935 <tr><td class="paramname">x</td><td>X Start position in Window Map tile coordinates. Range 0 - 31 </td></tr> 3936 <tr><td class="paramname">y</td><td>Y Start position in Window Map tile coordinates. Range 0 - 31 </td></tr> 3937 <tr><td class="paramname">w</td><td>Width of area to set in tiles. Range 1 - 32 </td></tr> 3938 <tr><td class="paramname">h</td><td>Height of area to set in tiles. Range 1 - 32 </td></tr> 3939 <tr><td class="paramname">tiles</td><td>Pointer to source tile map data</td></tr> 3940 </table> 3941 </dd> 3942</dl> 3943<p>Entries are copied from map at <b>tiles</b> to the Window Tile Map starting at <b>x</b>, <b>y</b> writing across for <b>w</b> tiles and down for <b>h</b> tiles.</p> 3944<p>Use <a class="el" href="gb_8h.html#af80befa3cad9cae361c7cf4fffb3a8de">set_win_submap()</a> instead when: </p><ul> 3945<li>Source map is wider than 32 tiles. </li> 3946<li>Writing a width that does not match the source map width <b>and</b> more than one row high at a time.</li> 3947</ul> 3948<p>One byte per source tile map entry.</p> 3949<p>Writes that exceed coordinate 31 on the x or y axis will wrap around to the Left and Top edges.</p> 3950<p>Note: Patterns 128-255 overlap with patterns 128-255 of the sprite Tile Pattern table.</p> 3951<p>GBC only: <a class="el" href="gb_2hardware_8h.html#a5ccae0d556500e1055a0ec8de20c535a">VBK_REG</a> determines whether Tile Numbers or Tile Attributes get set. </p><ul> 3952<li>VBK_REG=0 Tile Numbers are written </li> 3953<li>VBK_REG=1 Tile Attributes are written</li> 3954</ul> 3955<p>For more details about GBC Tile Attributes see <a class="el" href="gb_8h.html#a6da9e2fa1bafd35363e84ee999909ec7">set_bkg_tiles</a>.</p> 3956<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#ab19da2ab719bb8897bc0843a84af28f8">SHOW_WIN</a>, <a class="el" href="gb_8h.html#aedb6e32c42d4b1d25ad11adccd7100c3">HIDE_WIN</a>, <a class="el" href="gb_8h.html#af80befa3cad9cae361c7cf4fffb3a8de">set_win_submap</a>, <a class="el" href="gb_8h.html#a6da9e2fa1bafd35363e84ee999909ec7">set_bkg_tiles</a>, <a class="el" href="gb_8h.html#a1f5101f2b7bb0123c26a3e257f843626">set_bkg_data</a>, <a class="el" href="gb_8h.html#a9b205ee302f54cb96ee59aac6d53a91c">set_tiles</a> </dd></dl> 3957 3958</div> 3959</div> 3960<a id="a739a212609ae60c9c56c095f96b4ea80"></a> 3961<h2 class="memtitle"><span class="permalink"><a href="#a739a212609ae60c9c56c095f96b4ea80">◆ </a></span>set_win_based_tiles()</h2> 3962 3963<div class="memitem"> 3964<div class="memproto"> 3965<table class="mlabels"> 3966 <tr> 3967 <td class="mlabels-left"> 3968 <table class="memname"> 3969 <tr> 3970 <td class="memname">void set_win_based_tiles </td> 3971 <td>(</td> 3972 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3973 <td class="paramname"><em>x</em>, </td> 3974 </tr> 3975 <tr> 3976 <td class="paramkey"></td> 3977 <td></td> 3978 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3979 <td class="paramname"><em>y</em>, </td> 3980 </tr> 3981 <tr> 3982 <td class="paramkey"></td> 3983 <td></td> 3984 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3985 <td class="paramname"><em>w</em>, </td> 3986 </tr> 3987 <tr> 3988 <td class="paramkey"></td> 3989 <td></td> 3990 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 3991 <td class="paramname"><em>h</em>, </td> 3992 </tr> 3993 <tr> 3994 <td class="paramkey"></td> 3995 <td></td> 3996 <td class="paramtype">const <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> * </td> 3997 <td class="paramname"><em>tiles</em>, </td> 3998 </tr> 3999 <tr> 4000 <td class="paramkey"></td> 4001 <td></td> 4002 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4003 <td class="paramname"><em>base_tile</em> </td> 4004 </tr> 4005 <tr> 4006 <td></td> 4007 <td>)</td> 4008 <td></td><td></td> 4009 </tr> 4010 </table> 4011 </td> 4012 <td class="mlabels-right"> 4013<span class="mlabels"><span class="mlabel">inline</span></span> </td> 4014 </tr> 4015</table> 4016</div><div class="memdoc"> 4017<p>Sets a rectangular region of the Window Tile Map. The offset value in <b>base_tile</b> is added to the tile ID for each map entry.</p> 4018<dl class="params"><dt>Parameters</dt><dd> 4019 <table class="params"> 4020 <tr><td class="paramname">x</td><td>X Start position in Window Map tile coordinates. Range 0 - 31 </td></tr> 4021 <tr><td class="paramname">y</td><td>Y Start position in Window Map tile coordinates. Range 0 - 31 </td></tr> 4022 <tr><td class="paramname">w</td><td>Width of area to set in tiles. Range 1 - 32 </td></tr> 4023 <tr><td class="paramname">h</td><td>Height of area to set in tiles. Range 1 - 32 </td></tr> 4024 <tr><td class="paramname">tiles</td><td>Pointer to source tile map data </td></tr> 4025 <tr><td class="paramname">base_tile</td><td>Offset each tile ID entry of the source map by this value. Range 1 - 255</td></tr> 4026 </table> 4027 </dd> 4028</dl> 4029<p>This is identical to <a class="el" href="sms_8h.html#a429db030287423012f40a6dca81ae7e3">set_win_tiles()</a> except that it adds the <b>base_tile</b> parameter for when a tile map's tiles don't start at index zero. (For example, the tiles used by the map range from 100 -> 120 in VRAM instead of 0 -> 20).</p> 4030<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a5c59b4ee6323af9832998906d087266b">set_win_tiles</a> for more details </dd></dl> 4031 4032</div> 4033</div> 4034<a id="af80befa3cad9cae361c7cf4fffb3a8de"></a> 4035<h2 class="memtitle"><span class="permalink"><a href="#af80befa3cad9cae361c7cf4fffb3a8de">◆ </a></span>set_win_submap()</h2> 4036 4037<div class="memitem"> 4038<div class="memproto"> 4039<table class="mlabels"> 4040 <tr> 4041 <td class="mlabels-left"> 4042 <table class="memname"> 4043 <tr> 4044 <td class="memname">void set_win_submap </td> 4045 <td>(</td> 4046 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4047 <td class="paramname"><em>x</em>, </td> 4048 </tr> 4049 <tr> 4050 <td class="paramkey"></td> 4051 <td></td> 4052 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4053 <td class="paramname"><em>y</em>, </td> 4054 </tr> 4055 <tr> 4056 <td class="paramkey"></td> 4057 <td></td> 4058 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4059 <td class="paramname"><em>w</em>, </td> 4060 </tr> 4061 <tr> 4062 <td class="paramkey"></td> 4063 <td></td> 4064 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4065 <td class="paramname"><em>h</em>, </td> 4066 </tr> 4067 <tr> 4068 <td class="paramkey"></td> 4069 <td></td> 4070 <td class="paramtype">const <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> * </td> 4071 <td class="paramname"><em>map</em>, </td> 4072 </tr> 4073 <tr> 4074 <td class="paramkey"></td> 4075 <td></td> 4076 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4077 <td class="paramname"><em>map_w</em> </td> 4078 </tr> 4079 <tr> 4080 <td></td> 4081 <td>)</td> 4082 <td></td><td></td> 4083 </tr> 4084 </table> 4085 </td> 4086 <td class="mlabels-right"> 4087<span class="mlabels"><span class="mlabel">inline</span></span> </td> 4088 </tr> 4089</table> 4090</div><div class="memdoc"> 4091<p>Sets a rectangular area of the Window Tile Map using a sub-region from a source tile map.</p> 4092<dl class="params"><dt>Parameters</dt><dd> 4093 <table class="params"> 4094 <tr><td class="paramname">x</td><td>X Start position in Window Map tile coordinates. Range 0 - 31 </td></tr> 4095 <tr><td class="paramname">y</td><td>Y Start position in Wimdpw Map tile coordinates. Range 0 - 31 </td></tr> 4096 <tr><td class="paramname">w</td><td>Width of area to set in tiles. Range 1 - 255 </td></tr> 4097 <tr><td class="paramname">h</td><td>Height of area to set in tiles. Range 1 - 255 </td></tr> 4098 <tr><td class="paramname">map</td><td>Pointer to source tile map data </td></tr> 4099 <tr><td class="paramname">map_w</td><td>Width of source tile map in tiles. Range 1 - 255</td></tr> 4100 </table> 4101 </dd> 4102</dl> 4103<p>Entries are copied from <b>map</b> to the Window Tile Map starting at <b>x</b>, <b>y</b> writing across for <b>w</b> tiles and down for <b>h</b> tiles, using <b>map_w</b> as the rowstride for the source tile map.</p> 4104<p>Use this instead of <a class="el" href="gb_8h.html#a5c59b4ee6323af9832998906d087266b">set_win_tiles</a> when the source map is wider than 32 tiles or when writing a width that does not match the source map width.</p> 4105<p>One byte per source tile map entry.</p> 4106<p>Writes that exceed coordinate 31 on the x or y axis will wrap around to the Left and Top edges.</p> 4107<p>GBC only: <a class="el" href="gb_2hardware_8h.html#a5ccae0d556500e1055a0ec8de20c535a">VBK_REG</a> determines whether Tile Numbers or Tile Attributes get set. </p><ul> 4108<li>VBK_REG=0 Tile Numbers are written </li> 4109<li>VBK_REG=1 Tile Attributes are written</li> 4110</ul> 4111<p>See <a class="el" href="gb_8h.html#a6da9e2fa1bafd35363e84ee999909ec7">set_bkg_tiles</a> for details about CGB attribute maps with <a class="el" href="gb_2hardware_8h.html#a5ccae0d556500e1055a0ec8de20c535a">VBK_REG</a>.</p> 4112<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#ab19da2ab719bb8897bc0843a84af28f8">SHOW_WIN</a>, <a class="el" href="gb_8h.html#aedb6e32c42d4b1d25ad11adccd7100c3">HIDE_WIN</a>, <a class="el" href="gb_8h.html#a5c59b4ee6323af9832998906d087266b">set_win_tiles</a>, <a class="el" href="gb_8h.html#adb21d1c7d533a7133bab36a845489780">set_bkg_submap</a>, <a class="el" href="gb_8h.html#a6da9e2fa1bafd35363e84ee999909ec7">set_bkg_tiles</a>, <a class="el" href="gb_8h.html#a1f5101f2b7bb0123c26a3e257f843626">set_bkg_data</a>, <a class="el" href="gb_8h.html#a9b205ee302f54cb96ee59aac6d53a91c">set_tiles</a> </dd></dl> 4113 4114</div> 4115</div> 4116<a id="a1b8a1026983cb2b2c0bd46334b4692a0"></a> 4117<h2 class="memtitle"><span class="permalink"><a href="#a1b8a1026983cb2b2c0bd46334b4692a0">◆ </a></span>set_win_based_submap()</h2> 4118 4119<div class="memitem"> 4120<div class="memproto"> 4121<table class="mlabels"> 4122 <tr> 4123 <td class="mlabels-left"> 4124 <table class="memname"> 4125 <tr> 4126 <td class="memname">void set_win_based_submap </td> 4127 <td>(</td> 4128 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4129 <td class="paramname"><em>x</em>, </td> 4130 </tr> 4131 <tr> 4132 <td class="paramkey"></td> 4133 <td></td> 4134 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4135 <td class="paramname"><em>y</em>, </td> 4136 </tr> 4137 <tr> 4138 <td class="paramkey"></td> 4139 <td></td> 4140 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4141 <td class="paramname"><em>w</em>, </td> 4142 </tr> 4143 <tr> 4144 <td class="paramkey"></td> 4145 <td></td> 4146 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4147 <td class="paramname"><em>h</em>, </td> 4148 </tr> 4149 <tr> 4150 <td class="paramkey"></td> 4151 <td></td> 4152 <td class="paramtype">const <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> * </td> 4153 <td class="paramname"><em>map</em>, </td> 4154 </tr> 4155 <tr> 4156 <td class="paramkey"></td> 4157 <td></td> 4158 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4159 <td class="paramname"><em>map_w</em>, </td> 4160 </tr> 4161 <tr> 4162 <td class="paramkey"></td> 4163 <td></td> 4164 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4165 <td class="paramname"><em>base_tile</em> </td> 4166 </tr> 4167 <tr> 4168 <td></td> 4169 <td>)</td> 4170 <td></td><td></td> 4171 </tr> 4172 </table> 4173 </td> 4174 <td class="mlabels-right"> 4175<span class="mlabels"><span class="mlabel">inline</span></span> </td> 4176 </tr> 4177</table> 4178</div><div class="memdoc"> 4179<p>Sets a rectangular area of the Window Tile Map using a sub-region from a source tile map. The offset value in <b>base_tile</b> is added to the tile ID for each map entry.</p> 4180<dl class="params"><dt>Parameters</dt><dd> 4181 <table class="params"> 4182 <tr><td class="paramname">x</td><td>X Start position in Window Map tile coordinates. Range 0 - 31 </td></tr> 4183 <tr><td class="paramname">y</td><td>Y Start position in Wimdpw Map tile coordinates. Range 0 - 31 </td></tr> 4184 <tr><td class="paramname">w</td><td>Width of area to set in tiles. Range 1 - 255 </td></tr> 4185 <tr><td class="paramname">h</td><td>Height of area to set in tiles. Range 1 - 255 </td></tr> 4186 <tr><td class="paramname">map</td><td>Pointer to source tile map data </td></tr> 4187 <tr><td class="paramname">map_w</td><td>Width of source tile map in tiles. Range 1 - 255 </td></tr> 4188 <tr><td class="paramname">base_tile</td><td>Offset each tile ID entry of the source map by this value. Range 1 - 255</td></tr> 4189 </table> 4190 </dd> 4191</dl> 4192<p>This is identical to <a class="el" href="gb_8h.html#af80befa3cad9cae361c7cf4fffb3a8de">set_win_submap()</a> except that it adds the <b>base_tile</b> parameter for when a tile map's tiles don't start at index zero. (For example, the tiles used by the map range from 100 -> 120 in VRAM instead of 0 -> 20).</p> 4193<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#af80befa3cad9cae361c7cf4fffb3a8de">set_win_submap</a> for more details </dd></dl> 4194 4195</div> 4196</div> 4197<a id="a8a469de4c6640f921254b336b5a6191a"></a> 4198<h2 class="memtitle"><span class="permalink"><a href="#a8a469de4c6640f921254b336b5a6191a">◆ </a></span>get_win_tiles()</h2> 4199 4200<div class="memitem"> 4201<div class="memproto"> 4202 <table class="memname"> 4203 <tr> 4204 <td class="memname">void get_win_tiles </td> 4205 <td>(</td> 4206 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4207 <td class="paramname"><em>x</em>, </td> 4208 </tr> 4209 <tr> 4210 <td class="paramkey"></td> 4211 <td></td> 4212 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4213 <td class="paramname"><em>y</em>, </td> 4214 </tr> 4215 <tr> 4216 <td class="paramkey"></td> 4217 <td></td> 4218 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4219 <td class="paramname"><em>w</em>, </td> 4220 </tr> 4221 <tr> 4222 <td class="paramkey"></td> 4223 <td></td> 4224 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4225 <td class="paramname"><em>h</em>, </td> 4226 </tr> 4227 <tr> 4228 <td class="paramkey"></td> 4229 <td></td> 4230 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> * </td> 4231 <td class="paramname"><em>tiles</em> </td> 4232 </tr> 4233 <tr> 4234 <td></td> 4235 <td>)</td> 4236 <td></td><td></td> 4237 </tr> 4238 </table> 4239</div><div class="memdoc"> 4240<p>Copies a rectangular region of Window Tile Map entries into a buffer.</p> 4241<dl class="params"><dt>Parameters</dt><dd> 4242 <table class="params"> 4243 <tr><td class="paramname">x</td><td>X Start position in Window Map tile coordinates. Range 0 - 31 </td></tr> 4244 <tr><td class="paramname">y</td><td>Y Start position in Window Map tile coordinates. Range 0 - 31 </td></tr> 4245 <tr><td class="paramname">w</td><td>Width of area to copy in tiles. Range 0 - 31 </td></tr> 4246 <tr><td class="paramname">h</td><td>Height of area to copy in tiles. Range 0 - 31 </td></tr> 4247 <tr><td class="paramname">tiles</td><td>Pointer to destination buffer for Tile Map data</td></tr> 4248 </table> 4249 </dd> 4250</dl> 4251<p>Entries are copied into <b>tiles</b> from the Window Tile Map starting at <b>x</b>, <b>y</b> reading across for <b>w</b> tiles and down for <b>h</b> tiles.</p> 4252<p>One byte per tile.</p> 4253<p>The buffer pointed to by <b>tiles</b> should be at least <b>x</b> x <b>y</b> bytes in size.</p> 4254<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#aa6bcf24d97f93307b30f2906251f39a0">get_bkg_tiles</a>, <a class="el" href="gb_8h.html#a55c6581dbe9300dc6df41730f090af51">get_bkg_tile_xy</a>, <a class="el" href="gb_8h.html#a728b9440accedc5fb3477be3d150323a">get_tiles</a>, <a class="el" href="gb_8h.html#aa33ba8b8d381df76edf15ea251ccb675">get_vram_byte</a> </dd></dl> 4255 4256</div> 4257</div> 4258<a id="a0c70a53db1fbc0c99627da3f282befd8"></a> 4259<h2 class="memtitle"><span class="permalink"><a href="#a0c70a53db1fbc0c99627da3f282befd8">◆ </a></span>set_win_tile_xy()</h2> 4260 4261<div class="memitem"> 4262<div class="memproto"> 4263 <table class="memname"> 4264 <tr> 4265 <td class="memname"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a>* set_win_tile_xy </td> 4266 <td>(</td> 4267 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4268 <td class="paramname"><em>x</em>, </td> 4269 </tr> 4270 <tr> 4271 <td class="paramkey"></td> 4272 <td></td> 4273 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4274 <td class="paramname"><em>y</em>, </td> 4275 </tr> 4276 <tr> 4277 <td class="paramkey"></td> 4278 <td></td> 4279 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4280 <td class="paramname"><em>t</em> </td> 4281 </tr> 4282 <tr> 4283 <td></td> 4284 <td>)</td> 4285 <td></td><td></td> 4286 </tr> 4287 </table> 4288</div><div class="memdoc"> 4289<p>Set single tile t on window layer at x,y </p><dl class="params"><dt>Parameters</dt><dd> 4290 <table class="params"> 4291 <tr><td class="paramname">x</td><td>X-coordinate </td></tr> 4292 <tr><td class="paramname">y</td><td>Y-coordinate </td></tr> 4293 <tr><td class="paramname">t</td><td>tile index </td></tr> 4294 </table> 4295 </dd> 4296</dl> 4297<dl class="section return"><dt>Returns</dt><dd>returns the address of tile, so you may use faster <a class="el" href="gb_8h.html#a7080649e10765996c581e5b618e603b8">set_vram_byte()</a> later </dd></dl> 4298 4299</div> 4300</div> 4301<a id="a2e29fdca81c28c627c2591029722e71c"></a> 4302<h2 class="memtitle"><span class="permalink"><a href="#a2e29fdca81c28c627c2591029722e71c">◆ </a></span>get_win_tile_xy()</h2> 4303 4304<div class="memitem"> 4305<div class="memproto"> 4306 <table class="memname"> 4307 <tr> 4308 <td class="memname"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> get_win_tile_xy </td> 4309 <td>(</td> 4310 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4311 <td class="paramname"><em>x</em>, </td> 4312 </tr> 4313 <tr> 4314 <td class="paramkey"></td> 4315 <td></td> 4316 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4317 <td class="paramname"><em>y</em> </td> 4318 </tr> 4319 <tr> 4320 <td></td> 4321 <td>)</td> 4322 <td></td><td></td> 4323 </tr> 4324 </table> 4325</div><div class="memdoc"> 4326<p>Get single tile t on window layer at x,y </p><dl class="params"><dt>Parameters</dt><dd> 4327 <table class="params"> 4328 <tr><td class="paramname">x</td><td>X-coordinate </td></tr> 4329 <tr><td class="paramname">y</td><td>Y-coordinate </td></tr> 4330 </table> 4331 </dd> 4332</dl> 4333<dl class="section return"><dt>Returns</dt><dd>returns the tile index </dd></dl> 4334 4335</div> 4336</div> 4337<a id="aeef17768c494bcd6b67f7591329f7ff5"></a> 4338<h2 class="memtitle"><span class="permalink"><a href="#aeef17768c494bcd6b67f7591329f7ff5">◆ </a></span>move_win()</h2> 4339 4340<div class="memitem"> 4341<div class="memproto"> 4342<table class="mlabels"> 4343 <tr> 4344 <td class="mlabels-left"> 4345 <table class="memname"> 4346 <tr> 4347 <td class="memname">void move_win </td> 4348 <td>(</td> 4349 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4350 <td class="paramname"><em>x</em>, </td> 4351 </tr> 4352 <tr> 4353 <td class="paramkey"></td> 4354 <td></td> 4355 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4356 <td class="paramname"><em>y</em> </td> 4357 </tr> 4358 <tr> 4359 <td></td> 4360 <td>)</td> 4361 <td></td><td></td> 4362 </tr> 4363 </table> 4364 </td> 4365 <td class="mlabels-right"> 4366<span class="mlabels"><span class="mlabel">inline</span></span> </td> 4367 </tr> 4368</table> 4369</div><div class="memdoc"> 4370<p>Moves the Window to the <b>x</b>, <b>y</b> position on the screen.</p> 4371<dl class="params"><dt>Parameters</dt><dd> 4372 <table class="params"> 4373 <tr><td class="paramname">x</td><td>X coordinate for Left edge of the Window (actual displayed location will be X - 7) </td></tr> 4374 <tr><td class="paramname">y</td><td>Y coordinate for Top edge of the Window</td></tr> 4375 </table> 4376 </dd> 4377</dl> 4378<p>7,0 is the top left corner of the screen in Window coordinates. The Window is locked to the bottom right corner.</p> 4379<p>The Window is always over the Background layer.</p> 4380<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#ab19da2ab719bb8897bc0843a84af28f8">SHOW_WIN</a>, <a class="el" href="gb_8h.html#aedb6e32c42d4b1d25ad11adccd7100c3">HIDE_WIN</a> </dd></dl> 4381 4382</div> 4383</div> 4384<a id="a12c2b5ac249d01caf1561cbbf3962044"></a> 4385<h2 class="memtitle"><span class="permalink"><a href="#a12c2b5ac249d01caf1561cbbf3962044">◆ </a></span>scroll_win()</h2> 4386 4387<div class="memitem"> 4388<div class="memproto"> 4389<table class="mlabels"> 4390 <tr> 4391 <td class="mlabels-left"> 4392 <table class="memname"> 4393 <tr> 4394 <td class="memname">void scroll_win </td> 4395 <td>(</td> 4396 <td class="paramtype"><a class="el" href="stdint_8h.html#aef44329758059c91c76d334e8fc09700">int8_t</a> </td> 4397 <td class="paramname"><em>x</em>, </td> 4398 </tr> 4399 <tr> 4400 <td class="paramkey"></td> 4401 <td></td> 4402 <td class="paramtype"><a class="el" href="stdint_8h.html#aef44329758059c91c76d334e8fc09700">int8_t</a> </td> 4403 <td class="paramname"><em>y</em> </td> 4404 </tr> 4405 <tr> 4406 <td></td> 4407 <td>)</td> 4408 <td></td><td></td> 4409 </tr> 4410 </table> 4411 </td> 4412 <td class="mlabels-right"> 4413<span class="mlabels"><span class="mlabel">inline</span></span> </td> 4414 </tr> 4415</table> 4416</div><div class="memdoc"> 4417<p>Move the Window relative to its current position.</p> 4418<dl class="params"><dt>Parameters</dt><dd> 4419 <table class="params"> 4420 <tr><td class="paramname">x</td><td>Number of pixels to move the window on the <b>X axis</b> <br /> 4421 Range: -128 - 127 </td></tr> 4422 <tr><td class="paramname">y</td><td>Number of pixels to move the window on the <b>Y axis</b> <br /> 4423 Range: -128 - 127</td></tr> 4424 </table> 4425 </dd> 4426</dl> 4427<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#aeef17768c494bcd6b67f7591329f7ff5">move_win</a> </dd></dl> 4428 4429</div> 4430</div> 4431<a id="ae45b1c639698951b47e44fa8e89556f2"></a> 4432<h2 class="memtitle"><span class="permalink"><a href="#ae45b1c639698951b47e44fa8e89556f2">◆ </a></span>set_sprite_data()</h2> 4433 4434<div class="memitem"> 4435<div class="memproto"> 4436 <table class="memname"> 4437 <tr> 4438 <td class="memname">void set_sprite_data </td> 4439 <td>(</td> 4440 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4441 <td class="paramname"><em>first_tile</em>, </td> 4442 </tr> 4443 <tr> 4444 <td class="paramkey"></td> 4445 <td></td> 4446 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4447 <td class="paramname"><em>nb_tiles</em>, </td> 4448 </tr> 4449 <tr> 4450 <td class="paramkey"></td> 4451 <td></td> 4452 <td class="paramtype">const <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> * </td> 4453 <td class="paramname"><em>data</em> </td> 4454 </tr> 4455 <tr> 4456 <td></td> 4457 <td>)</td> 4458 <td></td><td></td> 4459 </tr> 4460 </table> 4461</div><div class="memdoc"> 4462<p>Sets VRAM Tile Pattern data for Sprites</p> 4463<dl class="params"><dt>Parameters</dt><dd> 4464 <table class="params"> 4465 <tr><td class="paramname">first_tile</td><td>Index of the first tile to write </td></tr> 4466 <tr><td class="paramname">nb_tiles</td><td>Number of tiles to write </td></tr> 4467 <tr><td class="paramname">data</td><td>Pointer to (2 bpp) source Tile Pattern data</td></tr> 4468 </table> 4469 </dd> 4470</dl> 4471<p>Writes <b>nb_tiles</b> tiles to VRAM starting at <b>first_tile</b>, tile data is sourced from <b>data</b>. Each Tile is 16 bytes in size (8x8 pixels, 2 bits-per-pixel).</p> 4472<p>Note: Sprite Tiles 128-255 share the same memory region as Background Tiles 128-255.</p> 4473<p>GBC only: <a class="el" href="gb_2hardware_8h.html#a5ccae0d556500e1055a0ec8de20c535a">VBK_REG</a> determines which bank of Background tile patterns are written to. </p><ul> 4474<li>VBK_REG=0 indicates the first bank </li> 4475<li>VBK_REG=1 indicates the second </li> 4476</ul> 4477 4478</div> 4479</div> 4480<a id="ab3e60c92c9f8fbed855f8712187ea3ea"></a> 4481<h2 class="memtitle"><span class="permalink"><a href="#ab3e60c92c9f8fbed855f8712187ea3ea">◆ </a></span>set_sprite_1bpp_data()</h2> 4482 4483<div class="memitem"> 4484<div class="memproto"> 4485 <table class="memname"> 4486 <tr> 4487 <td class="memname">void set_sprite_1bpp_data </td> 4488 <td>(</td> 4489 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4490 <td class="paramname"><em>first_tile</em>, </td> 4491 </tr> 4492 <tr> 4493 <td class="paramkey"></td> 4494 <td></td> 4495 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4496 <td class="paramname"><em>nb_tiles</em>, </td> 4497 </tr> 4498 <tr> 4499 <td class="paramkey"></td> 4500 <td></td> 4501 <td class="paramtype">const <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> * </td> 4502 <td class="paramname"><em>data</em> </td> 4503 </tr> 4504 <tr> 4505 <td></td> 4506 <td>)</td> 4507 <td></td><td></td> 4508 </tr> 4509 </table> 4510</div><div class="memdoc"> 4511<p>Sets VRAM Tile Pattern data for Sprites using 1bpp source data</p> 4512<dl class="params"><dt>Parameters</dt><dd> 4513 <table class="params"> 4514 <tr><td class="paramname">first_tile</td><td>Index of the first tile to write </td></tr> 4515 <tr><td class="paramname">nb_tiles</td><td>Number of tiles to write </td></tr> 4516 <tr><td class="paramname">data</td><td>Pointer to (1bpp) source Tile Pattern data</td></tr> 4517 </table> 4518 </dd> 4519</dl> 4520<p>Similar to <a class="el" href="sms_8h.html#a216a3e3d320ee4d8cf4845600487ae39">set_sprite_data</a>, except source data is 1 bit-per-pixel which gets expanded into 2 bits-per-pixel.</p> 4521<p>For a given bit that represent a pixel: </p><ul> 4522<li>0 will be expanded into color 0 </li> 4523<li>1 will be expanded into color 3</li> 4524</ul> 4525<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a495bc9f405f916f02ad5d97e6e730134">SHOW_SPRITES</a>, <a class="el" href="gb_8h.html#a69ef98aee664b8abd8d1a3d45f016dda">HIDE_SPRITES</a>, <a class="el" href="gb_8h.html#a05bf0b9f1328de7b568a19a2a428bcfe">set_sprite_tile</a> </dd></dl> 4526 4527</div> 4528</div> 4529<a id="adcdec4034a14abc5be9bb88c29b947c9"></a> 4530<h2 class="memtitle"><span class="permalink"><a href="#adcdec4034a14abc5be9bb88c29b947c9">◆ </a></span>get_sprite_data()</h2> 4531 4532<div class="memitem"> 4533<div class="memproto"> 4534 <table class="memname"> 4535 <tr> 4536 <td class="memname">void get_sprite_data </td> 4537 <td>(</td> 4538 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4539 <td class="paramname"><em>first_tile</em>, </td> 4540 </tr> 4541 <tr> 4542 <td class="paramkey"></td> 4543 <td></td> 4544 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4545 <td class="paramname"><em>nb_tiles</em>, </td> 4546 </tr> 4547 <tr> 4548 <td class="paramkey"></td> 4549 <td></td> 4550 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> * </td> 4551 <td class="paramname"><em>data</em> </td> 4552 </tr> 4553 <tr> 4554 <td></td> 4555 <td>)</td> 4556 <td></td><td></td> 4557 </tr> 4558 </table> 4559</div><div class="memdoc"> 4560<p>Copies from Sprite VRAM Tile Pattern data into a buffer</p> 4561<dl class="params"><dt>Parameters</dt><dd> 4562 <table class="params"> 4563 <tr><td class="paramname">first_tile</td><td>Index of the first tile to read from </td></tr> 4564 <tr><td class="paramname">nb_tiles</td><td>Number of tiles to read </td></tr> 4565 <tr><td class="paramname">data</td><td>Pointer to destination buffer for Tile Pattern data</td></tr> 4566 </table> 4567 </dd> 4568</dl> 4569<p>Copies <b>nb_tiles</b> tiles from VRAM starting at <b>first_tile</b>, tile data is copied into <b>data</b>.</p> 4570<p>Each Tile is 16 bytes, so the buffer pointed to by <b>data</b> should be at least <b>nb_tiles</b> x 16 bytes in size. </p> 4571 4572</div> 4573</div> 4574<a id="a7e0cdfd6b9a2ae1b7f30384f132d8687"></a> 4575<h2 class="memtitle"><span class="permalink"><a href="#a7e0cdfd6b9a2ae1b7f30384f132d8687">◆ </a></span>SET_SHADOW_OAM_ADDRESS()</h2> 4576 4577<div class="memitem"> 4578<div class="memproto"> 4579<table class="mlabels"> 4580 <tr> 4581 <td class="mlabels-left"> 4582 <table class="memname"> 4583 <tr> 4584 <td class="memname">void SET_SHADOW_OAM_ADDRESS </td> 4585 <td>(</td> 4586 <td class="paramtype">void * </td> 4587 <td class="paramname"><em>address</em></td><td>)</td> 4588 <td></td> 4589 </tr> 4590 </table> 4591 </td> 4592 <td class="mlabels-right"> 4593<span class="mlabels"><span class="mlabel">inline</span></span> </td> 4594 </tr> 4595</table> 4596</div><div class="memdoc"> 4597<p>Enable OAM DMA copy each VBlank and set it to transfer any 256-byte aligned array </p> 4598 4599</div> 4600</div> 4601<a id="a05bf0b9f1328de7b568a19a2a428bcfe"></a> 4602<h2 class="memtitle"><span class="permalink"><a href="#a05bf0b9f1328de7b568a19a2a428bcfe">◆ </a></span>set_sprite_tile()</h2> 4603 4604<div class="memitem"> 4605<div class="memproto"> 4606<table class="mlabels"> 4607 <tr> 4608 <td class="mlabels-left"> 4609 <table class="memname"> 4610 <tr> 4611 <td class="memname">void set_sprite_tile </td> 4612 <td>(</td> 4613 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4614 <td class="paramname"><em>nb</em>, </td> 4615 </tr> 4616 <tr> 4617 <td class="paramkey"></td> 4618 <td></td> 4619 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4620 <td class="paramname"><em>tile</em> </td> 4621 </tr> 4622 <tr> 4623 <td></td> 4624 <td>)</td> 4625 <td></td><td></td> 4626 </tr> 4627 </table> 4628 </td> 4629 <td class="mlabels-right"> 4630<span class="mlabels"><span class="mlabel">inline</span></span> </td> 4631 </tr> 4632</table> 4633</div><div class="memdoc"> 4634<p>Sets sprite number <b>nb__in the OAM to display tile number __tile</b>.</p> 4635<dl class="params"><dt>Parameters</dt><dd> 4636 <table class="params"> 4637 <tr><td class="paramname">nb</td><td>Sprite number, range 0 - 39 </td></tr> 4638 <tr><td class="paramname">tile</td><td>Selects a tile (0 - 255) from memory at 8000h - 8FFFh <br /> 4639 In CGB Mode this could be either in VRAM Bank <br /> 4640 0 or 1, depending on Bit 3 of the OAM Attribute Flag <br /> 4641 (see <a class="el" href="sms_8h.html#a99ea3252469e3614e977cce2aa1d06f7">set_sprite_prop</a>)</td></tr> 4642 </table> 4643 </dd> 4644</dl> 4645<p>In 8x16 mode: </p><ul> 4646<li>The sprite will also display the next tile (<b>tile</b> + 1) directly below (y + 8) the first tile. </li> 4647<li>The lower bit of the tile number is ignored: the upper 8x8 tile is (<b>tile</b> & 0xFE), and the lower 8x8 tile is (<b>tile</b> | 0x01). </li> 4648<li>See: <a class="el" href="sms_8h.html#af91d252f07f4764996154820f970c101">SPRITES_8x16</a> </li> 4649</ul> 4650 4651</div> 4652</div> 4653<a id="af5c0beff7d7a7d8641b51fd95c811b2a"></a> 4654<h2 class="memtitle"><span class="permalink"><a href="#af5c0beff7d7a7d8641b51fd95c811b2a">◆ </a></span>get_sprite_tile()</h2> 4655 4656<div class="memitem"> 4657<div class="memproto"> 4658<table class="mlabels"> 4659 <tr> 4660 <td class="mlabels-left"> 4661 <table class="memname"> 4662 <tr> 4663 <td class="memname"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> get_sprite_tile </td> 4664 <td>(</td> 4665 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4666 <td class="paramname"><em>nb</em></td><td>)</td> 4667 <td></td> 4668 </tr> 4669 </table> 4670 </td> 4671 <td class="mlabels-right"> 4672<span class="mlabels"><span class="mlabel">inline</span></span> </td> 4673 </tr> 4674</table> 4675</div><div class="memdoc"> 4676<p>Returns the tile number of sprite number <b>nb</b> in the OAM.</p> 4677<dl class="params"><dt>Parameters</dt><dd> 4678 <table class="params"> 4679 <tr><td class="paramname">nb</td><td>Sprite number, range 0 - 39</td></tr> 4680 </table> 4681 </dd> 4682</dl> 4683<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a05bf0b9f1328de7b568a19a2a428bcfe">set_sprite_tile</a> for more details </dd></dl> 4684 4685</div> 4686</div> 4687<a id="a99ea3252469e3614e977cce2aa1d06f7"></a> 4688<h2 class="memtitle"><span class="permalink"><a href="#a99ea3252469e3614e977cce2aa1d06f7">◆ </a></span>set_sprite_prop()</h2> 4689 4690<div class="memitem"> 4691<div class="memproto"> 4692<table class="mlabels"> 4693 <tr> 4694 <td class="mlabels-left"> 4695 <table class="memname"> 4696 <tr> 4697 <td class="memname">void set_sprite_prop </td> 4698 <td>(</td> 4699 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4700 <td class="paramname"><em>nb</em>, </td> 4701 </tr> 4702 <tr> 4703 <td class="paramkey"></td> 4704 <td></td> 4705 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4706 <td class="paramname"><em>prop</em> </td> 4707 </tr> 4708 <tr> 4709 <td></td> 4710 <td>)</td> 4711 <td></td><td></td> 4712 </tr> 4713 </table> 4714 </td> 4715 <td class="mlabels-right"> 4716<span class="mlabels"><span class="mlabel">inline</span></span> </td> 4717 </tr> 4718</table> 4719</div><div class="memdoc"> 4720<p>Sets the OAM Property Flags of sprite number <b>nb</b> to those defined in <b>prop</b>.</p> 4721<dl class="params"><dt>Parameters</dt><dd> 4722 <table class="params"> 4723 <tr><td class="paramname">nb</td><td>Sprite number, range 0 - 39 </td></tr> 4724 <tr><td class="paramname">prop</td><td>Property setting (see bitfield description)</td></tr> 4725 </table> 4726 </dd> 4727</dl> 4728<p>The bits in <b>prop</b> represent: </p><ul> 4729<li>Bit 7 - Priority flag. When this is set the sprites appear behind the background and window layer. <br /> 4730 0: infront <br /> 4731 1: behind </li> 4732<li>Bit 6 - Vertical flip. Dictates which way up the sprite is drawn vertically. <br /> 4733 0: normal <br /> 4734 1:upside down </li> 4735<li>Bit 5 - Horizontal flip. Dictates which way up the sprite is drawn horizontally. <br /> 4736 0: normal <br /> 4737 1:back to front </li> 4738<li>Bit 4 - DMG/Non-CGB Mode Only. Assigns either one of the two b/w palettes to the sprite. <br /> 4739 0: OBJ palette 0 <br /> 4740 1: OBJ palette 1 </li> 4741<li>Bit 3 - GBC only. Dictates from which bank of Sprite Tile Patterns the tile is taken. <br /> 4742 0: Bank 0 <br /> 4743 1: Bank 1 </li> 4744<li>Bit 2 - See bit 0. </li> 4745<li>Bit 1 - See bit 0. </li> 4746<li>Bit 0 - GBC only. Bits 0-2 indicate which of the 7 OBJ colour palettes the sprite is assigned. </li> 4747</ul> 4748 4749</div> 4750</div> 4751<a id="a6b873c807c9e2c90fb574951e85fdf88"></a> 4752<h2 class="memtitle"><span class="permalink"><a href="#a6b873c807c9e2c90fb574951e85fdf88">◆ </a></span>get_sprite_prop()</h2> 4753 4754<div class="memitem"> 4755<div class="memproto"> 4756<table class="mlabels"> 4757 <tr> 4758 <td class="mlabels-left"> 4759 <table class="memname"> 4760 <tr> 4761 <td class="memname"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> get_sprite_prop </td> 4762 <td>(</td> 4763 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4764 <td class="paramname"><em>nb</em></td><td>)</td> 4765 <td></td> 4766 </tr> 4767 </table> 4768 </td> 4769 <td class="mlabels-right"> 4770<span class="mlabels"><span class="mlabel">inline</span></span> </td> 4771 </tr> 4772</table> 4773</div><div class="memdoc"> 4774<p>Returns the OAM Property Flags of sprite number <b>nb</b>.</p> 4775<dl class="params"><dt>Parameters</dt><dd> 4776 <table class="params"> 4777 <tr><td class="paramname">nb</td><td>Sprite number, range 0 - 39 </td></tr> 4778 </table> 4779 </dd> 4780</dl> 4781<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a99ea3252469e3614e977cce2aa1d06f7">set_sprite_prop</a> for property bitfield settings </dd></dl> 4782 4783</div> 4784</div> 4785<a id="ab42c12c1d9aed3fd963248fbea9830cd"></a> 4786<h2 class="memtitle"><span class="permalink"><a href="#ab42c12c1d9aed3fd963248fbea9830cd">◆ </a></span>move_sprite()</h2> 4787 4788<div class="memitem"> 4789<div class="memproto"> 4790<table class="mlabels"> 4791 <tr> 4792 <td class="mlabels-left"> 4793 <table class="memname"> 4794 <tr> 4795 <td class="memname">void move_sprite </td> 4796 <td>(</td> 4797 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4798 <td class="paramname"><em>nb</em>, </td> 4799 </tr> 4800 <tr> 4801 <td class="paramkey"></td> 4802 <td></td> 4803 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4804 <td class="paramname"><em>x</em>, </td> 4805 </tr> 4806 <tr> 4807 <td class="paramkey"></td> 4808 <td></td> 4809 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4810 <td class="paramname"><em>y</em> </td> 4811 </tr> 4812 <tr> 4813 <td></td> 4814 <td>)</td> 4815 <td></td><td></td> 4816 </tr> 4817 </table> 4818 </td> 4819 <td class="mlabels-right"> 4820<span class="mlabels"><span class="mlabel">inline</span></span> </td> 4821 </tr> 4822</table> 4823</div><div class="memdoc"> 4824<p>Moves sprite number <b>nb</b> to the <b>x</b>, <b>y</b> position on the screen.</p> 4825<dl class="params"><dt>Parameters</dt><dd> 4826 <table class="params"> 4827 <tr><td class="paramname">nb</td><td>Sprite number, range 0 - 39 </td></tr> 4828 <tr><td class="paramname">x</td><td>X Position. Specifies the sprites horizontal position on the screen (minus 8). <br /> 4829 An offscreen value (X=0 or X>=168) hides the sprite, but the sprite still affects the priority ordering - a better way to hide a sprite is to set its Y-coordinate offscreen. </td></tr> 4830 <tr><td class="paramname">y</td><td>Y Position. Specifies the sprites vertical position on the screen (minus 16). <br /> 4831 An offscreen value (for example, Y=0 or Y>=160) hides the sprite.</td></tr> 4832 </table> 4833 </dd> 4834</dl> 4835<p>Moving the sprite to 0,0 (or similar off-screen location) will hide it. </p> 4836 4837</div> 4838</div> 4839<a id="a6c59aa9a4f9ea42bed6ca6940b2741fe"></a> 4840<h2 class="memtitle"><span class="permalink"><a href="#a6c59aa9a4f9ea42bed6ca6940b2741fe">◆ </a></span>scroll_sprite()</h2> 4841 4842<div class="memitem"> 4843<div class="memproto"> 4844<table class="mlabels"> 4845 <tr> 4846 <td class="mlabels-left"> 4847 <table class="memname"> 4848 <tr> 4849 <td class="memname">void scroll_sprite </td> 4850 <td>(</td> 4851 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4852 <td class="paramname"><em>nb</em>, </td> 4853 </tr> 4854 <tr> 4855 <td class="paramkey"></td> 4856 <td></td> 4857 <td class="paramtype"><a class="el" href="stdint_8h.html#aef44329758059c91c76d334e8fc09700">int8_t</a> </td> 4858 <td class="paramname"><em>x</em>, </td> 4859 </tr> 4860 <tr> 4861 <td class="paramkey"></td> 4862 <td></td> 4863 <td class="paramtype"><a class="el" href="stdint_8h.html#aef44329758059c91c76d334e8fc09700">int8_t</a> </td> 4864 <td class="paramname"><em>y</em> </td> 4865 </tr> 4866 <tr> 4867 <td></td> 4868 <td>)</td> 4869 <td></td><td></td> 4870 </tr> 4871 </table> 4872 </td> 4873 <td class="mlabels-right"> 4874<span class="mlabels"><span class="mlabel">inline</span></span> </td> 4875 </tr> 4876</table> 4877</div><div class="memdoc"> 4878<p>Moves sprite number <b>nb</b> relative to its current position.</p> 4879<dl class="params"><dt>Parameters</dt><dd> 4880 <table class="params"> 4881 <tr><td class="paramname">nb</td><td>Sprite number, range 0 - 39 </td></tr> 4882 <tr><td class="paramname">x</td><td>Number of pixels to move the sprite on the <b>X axis</b> <br /> 4883 Range: -128 - 127 </td></tr> 4884 <tr><td class="paramname">y</td><td>Number of pixels to move the sprite on the <b>Y axis</b> <br /> 4885 Range: -128 - 127</td></tr> 4886 </table> 4887 </dd> 4888</dl> 4889<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#ab42c12c1d9aed3fd963248fbea9830cd">move_sprite</a> for more details about the X and Y position </dd></dl> 4890 4891</div> 4892</div> 4893<a id="ad22c51635d052399bbbe1777999c794d"></a> 4894<h2 class="memtitle"><span class="permalink"><a href="#ad22c51635d052399bbbe1777999c794d">◆ </a></span>hide_sprite()</h2> 4895 4896<div class="memitem"> 4897<div class="memproto"> 4898<table class="mlabels"> 4899 <tr> 4900 <td class="mlabels-left"> 4901 <table class="memname"> 4902 <tr> 4903 <td class="memname">void hide_sprite </td> 4904 <td>(</td> 4905 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 4906 <td class="paramname"><em>nb</em></td><td>)</td> 4907 <td></td> 4908 </tr> 4909 </table> 4910 </td> 4911 <td class="mlabels-right"> 4912<span class="mlabels"><span class="mlabel">inline</span></span> </td> 4913 </tr> 4914</table> 4915</div><div class="memdoc"> 4916<p>Hides sprite number <b>nb</b> by moving it to zero position by Y.</p> 4917<dl class="params"><dt>Parameters</dt><dd> 4918 <table class="params"> 4919 <tr><td class="paramname">nb</td><td>Sprite number, range 0 - 39 </td></tr> 4920 </table> 4921 </dd> 4922</dl> 4923 4924</div> 4925</div> 4926<a id="a650d2df96e69a40b70548ab468e00f25"></a> 4927<h2 class="memtitle"><span class="permalink"><a href="#a650d2df96e69a40b70548ab468e00f25">◆ </a></span>set_data()</h2> 4928 4929<div class="memitem"> 4930<div class="memproto"> 4931 <table class="memname"> 4932 <tr> 4933 <td class="memname">void set_data </td> 4934 <td>(</td> 4935 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> * </td> 4936 <td class="paramname"><em>vram_addr</em>, </td> 4937 </tr> 4938 <tr> 4939 <td class="paramkey"></td> 4940 <td></td> 4941 <td class="paramtype">const <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> * </td> 4942 <td class="paramname"><em>data</em>, </td> 4943 </tr> 4944 <tr> 4945 <td class="paramkey"></td> 4946 <td></td> 4947 <td class="paramtype"><a class="el" href="stdint_8h.html#adf4d876453337156dde61095e1f20223">uint16_t</a> </td> 4948 <td class="paramname"><em>len</em> </td> 4949 </tr> 4950 <tr> 4951 <td></td> 4952 <td>)</td> 4953 <td></td><td></td> 4954 </tr> 4955 </table> 4956</div><div class="memdoc"> 4957<p>Copies arbitrary data to an address in VRAM without taking into account the state of LCDC bits 3 or 4.</p> 4958<dl class="params"><dt>Parameters</dt><dd> 4959 <table class="params"> 4960 <tr><td class="paramname">vram_addr</td><td>Pointer to destination VRAM Address </td></tr> 4961 <tr><td class="paramname">data</td><td>Pointer to source buffer </td></tr> 4962 <tr><td class="paramname">len</td><td>Number of bytes to copy</td></tr> 4963 </table> 4964 </dd> 4965</dl> 4966<p>Copies <b>len</b> bytes from a buffer at <b>data</b> to VRAM starting at <b>vram_addr</b>.</p> 4967<p>GBC only: <a class="el" href="gb_2hardware_8h.html#a5ccae0d556500e1055a0ec8de20c535a">VBK_REG</a> determines which bank of Background tile patterns are written to. </p><ul> 4968<li>VBK_REG=0 indicates the first bank </li> 4969<li>VBK_REG=1 indicates the second</li> 4970</ul> 4971<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a1f5101f2b7bb0123c26a3e257f843626">set_bkg_data</a>, <a class="el" href="gb_8h.html#ac2bf0c4919c30d322fa5853c896e710f">set_win_data</a>, <a class="el" href="gb_8h.html#a6da9e2fa1bafd35363e84ee999909ec7">set_bkg_tiles</a>, <a class="el" href="gb_8h.html#a5c59b4ee6323af9832998906d087266b">set_win_tiles</a>, <a class="el" href="gb_8h.html#abe4846d4570b4880b0e54b9e503f4d30">set_tile_data</a>, <a class="el" href="gb_8h.html#a9b205ee302f54cb96ee59aac6d53a91c">set_tiles</a> </dd></dl> 4972 4973</div> 4974</div> 4975<a id="afd8fd71eaa36b0ddd54a2e8e516ed224"></a> 4976<h2 class="memtitle"><span class="permalink"><a href="#afd8fd71eaa36b0ddd54a2e8e516ed224">◆ </a></span>get_data()</h2> 4977 4978<div class="memitem"> 4979<div class="memproto"> 4980 <table class="memname"> 4981 <tr> 4982 <td class="memname">void get_data </td> 4983 <td>(</td> 4984 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> * </td> 4985 <td class="paramname"><em>data</em>, </td> 4986 </tr> 4987 <tr> 4988 <td class="paramkey"></td> 4989 <td></td> 4990 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> * </td> 4991 <td class="paramname"><em>vram_addr</em>, </td> 4992 </tr> 4993 <tr> 4994 <td class="paramkey"></td> 4995 <td></td> 4996 <td class="paramtype"><a class="el" href="stdint_8h.html#adf4d876453337156dde61095e1f20223">uint16_t</a> </td> 4997 <td class="paramname"><em>len</em> </td> 4998 </tr> 4999 <tr> 5000 <td></td> 5001 <td>)</td> 5002 <td></td><td></td> 5003 </tr> 5004 </table> 5005</div><div class="memdoc"> 5006<p>Copies arbitrary data from an address in VRAM into a buffer without taking into account the state of LCDC bits 3 or 4.</p> 5007<dl class="params"><dt>Parameters</dt><dd> 5008 <table class="params"> 5009 <tr><td class="paramname">vram_addr</td><td>Pointer to source VRAM Address </td></tr> 5010 <tr><td class="paramname">data</td><td>Pointer to destination buffer </td></tr> 5011 <tr><td class="paramname">len</td><td>Number of bytes to copy</td></tr> 5012 </table> 5013 </dd> 5014</dl> 5015<p>Copies <b>len</b> bytes from VRAM starting at <b>vram_addr</b> into a buffer at <b>data</b>.</p> 5016<p>GBC only: <a class="el" href="gb_2hardware_8h.html#a5ccae0d556500e1055a0ec8de20c535a">VBK_REG</a> determines which bank of Background tile patterns are written to. </p><ul> 5017<li>VBK_REG=0 indicates the first bank </li> 5018<li>VBK_REG=1 indicates the second</li> 5019</ul> 5020<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a5c13238dfec416439d75b133a272e6df">get_bkg_data</a>, <a class="el" href="gb_8h.html#a7ef32e7c1669aba48f235500a495baba">get_win_data</a>, <a class="el" href="gb_8h.html#aa6bcf24d97f93307b30f2906251f39a0">get_bkg_tiles</a>, <a class="el" href="gb_8h.html#a8a469de4c6640f921254b336b5a6191a">get_win_tiles</a>, <a class="el" href="gb_8h.html#a728b9440accedc5fb3477be3d150323a">get_tiles</a> </dd></dl> 5021 5022</div> 5023</div> 5024<a id="a36f9e5d95c2d7d58f203b5ac358e25e7"></a> 5025<h2 class="memtitle"><span class="permalink"><a href="#a36f9e5d95c2d7d58f203b5ac358e25e7">◆ </a></span>vmemcpy()</h2> 5026 5027<div class="memitem"> 5028<div class="memproto"> 5029 <table class="memname"> 5030 <tr> 5031 <td class="memname">void vmemcpy </td> 5032 <td>(</td> 5033 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> * </td> 5034 <td class="paramname"><em>dest</em>, </td> 5035 </tr> 5036 <tr> 5037 <td class="paramkey"></td> 5038 <td></td> 5039 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> * </td> 5040 <td class="paramname"><em>sour</em>, </td> 5041 </tr> 5042 <tr> 5043 <td class="paramkey"></td> 5044 <td></td> 5045 <td class="paramtype"><a class="el" href="stdint_8h.html#adf4d876453337156dde61095e1f20223">uint16_t</a> </td> 5046 <td class="paramname"><em>len</em> </td> 5047 </tr> 5048 <tr> 5049 <td></td> 5050 <td>)</td> 5051 <td></td><td></td> 5052 </tr> 5053 </table> 5054</div><div class="memdoc"> 5055<p>Copies arbitrary data from an address in VRAM into a buffer</p> 5056<dl class="params"><dt>Parameters</dt><dd> 5057 <table class="params"> 5058 <tr><td class="paramname">dest</td><td>Pointer to destination buffer (may be in VRAM) </td></tr> 5059 <tr><td class="paramname">sour</td><td>Pointer to source buffer (may be in VRAM) </td></tr> 5060 <tr><td class="paramname">len</td><td>Number of bytes to copy</td></tr> 5061 </table> 5062 </dd> 5063</dl> 5064<p>Copies <b>len</b> bytes from or to VRAM starting at <b>sour</b> into a buffer or to VRAM at <b>dest</b>.</p> 5065<p>GBC only: <a class="el" href="gb_2hardware_8h.html#a5ccae0d556500e1055a0ec8de20c535a">VBK_REG</a> determines which bank of Background tile patterns are written to. </p><ul> 5066<li>VBK_REG=0 indicates the first bank </li> 5067<li>VBK_REG=1 indicates the second </li> 5068</ul> 5069 5070</div> 5071</div> 5072<a id="a9b205ee302f54cb96ee59aac6d53a91c"></a> 5073<h2 class="memtitle"><span class="permalink"><a href="#a9b205ee302f54cb96ee59aac6d53a91c">◆ </a></span>set_tiles()</h2> 5074 5075<div class="memitem"> 5076<div class="memproto"> 5077 <table class="memname"> 5078 <tr> 5079 <td class="memname">void set_tiles </td> 5080 <td>(</td> 5081 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 5082 <td class="paramname"><em>x</em>, </td> 5083 </tr> 5084 <tr> 5085 <td class="paramkey"></td> 5086 <td></td> 5087 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 5088 <td class="paramname"><em>y</em>, </td> 5089 </tr> 5090 <tr> 5091 <td class="paramkey"></td> 5092 <td></td> 5093 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 5094 <td class="paramname"><em>w</em>, </td> 5095 </tr> 5096 <tr> 5097 <td class="paramkey"></td> 5098 <td></td> 5099 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 5100 <td class="paramname"><em>h</em>, </td> 5101 </tr> 5102 <tr> 5103 <td class="paramkey"></td> 5104 <td></td> 5105 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> * </td> 5106 <td class="paramname"><em>vram_addr</em>, </td> 5107 </tr> 5108 <tr> 5109 <td class="paramkey"></td> 5110 <td></td> 5111 <td class="paramtype">const <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> * </td> 5112 <td class="paramname"><em>tiles</em> </td> 5113 </tr> 5114 <tr> 5115 <td></td> 5116 <td>)</td> 5117 <td></td><td></td> 5118 </tr> 5119 </table> 5120</div><div class="memdoc"> 5121<p>Sets a rectangular region of Tile Map entries at a given VRAM Address without taking into account the state of LCDC bit 3.</p> 5122<dl class="params"><dt>Parameters</dt><dd> 5123 <table class="params"> 5124 <tr><td class="paramname">x</td><td>X Start position in Map tile coordinates. Range 0 - 31 </td></tr> 5125 <tr><td class="paramname">y</td><td>Y Start position in Map tile coordinates. Range 0 - 31 </td></tr> 5126 <tr><td class="paramname">w</td><td>Width of area to set in tiles. Range 1 - 32 </td></tr> 5127 <tr><td class="paramname">h</td><td>Height of area to set in tiles. Range 1 - 32 </td></tr> 5128 <tr><td class="paramname">vram_addr</td><td>Pointer to destination VRAM Address </td></tr> 5129 <tr><td class="paramname">tiles</td><td>Pointer to source Tile Map data</td></tr> 5130 </table> 5131 </dd> 5132</dl> 5133<p>Entries are copied from <b>tiles</b> to Tile Map at address vram_addr starting at <b>x</b>, <b>y</b> writing across for <b>w</b> tiles and down for <b>h</b> tiles.</p> 5134<p>One byte per source tile map entry.</p> 5135<p>There are two 32x32 Tile Maps in VRAM at addresses 9800h-9BFFh and 9C00h-9FFFh.</p> 5136<p>GBC only: <a class="el" href="gb_2hardware_8h.html#a5ccae0d556500e1055a0ec8de20c535a">VBK_REG</a> determines whether Tile Numbers or Tile Attributes get set. </p><ul> 5137<li>VBK_REG=0 Tile Numbers are written </li> 5138<li>VBK_REG=1 Tile Attributes are written</li> 5139</ul> 5140<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a6da9e2fa1bafd35363e84ee999909ec7">set_bkg_tiles</a>, <a class="el" href="gb_8h.html#a5c59b4ee6323af9832998906d087266b">set_win_tiles</a> </dd></dl> 5141 5142</div> 5143</div> 5144<a id="abe4846d4570b4880b0e54b9e503f4d30"></a> 5145<h2 class="memtitle"><span class="permalink"><a href="#abe4846d4570b4880b0e54b9e503f4d30">◆ </a></span>set_tile_data()</h2> 5146 5147<div class="memitem"> 5148<div class="memproto"> 5149 <table class="memname"> 5150 <tr> 5151 <td class="memname">void set_tile_data </td> 5152 <td>(</td> 5153 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 5154 <td class="paramname"><em>first_tile</em>, </td> 5155 </tr> 5156 <tr> 5157 <td class="paramkey"></td> 5158 <td></td> 5159 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 5160 <td class="paramname"><em>nb_tiles</em>, </td> 5161 </tr> 5162 <tr> 5163 <td class="paramkey"></td> 5164 <td></td> 5165 <td class="paramtype">const <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> * </td> 5166 <td class="paramname"><em>data</em>, </td> 5167 </tr> 5168 <tr> 5169 <td class="paramkey"></td> 5170 <td></td> 5171 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 5172 <td class="paramname"><em>base</em> </td> 5173 </tr> 5174 <tr> 5175 <td></td> 5176 <td>)</td> 5177 <td></td><td></td> 5178 </tr> 5179 </table> 5180</div><div class="memdoc"> 5181<p>Sets VRAM Tile Pattern data starting from given base address without taking into account the state of LCDC bit 4.</p> 5182<dl class="params"><dt>Parameters</dt><dd> 5183 <table class="params"> 5184 <tr><td class="paramname">first_tile</td><td>Index of the first tile to write </td></tr> 5185 <tr><td class="paramname">nb_tiles</td><td>Number of tiles to write </td></tr> 5186 <tr><td class="paramname">data</td><td>Pointer to (2 bpp) source Tile Pattern data. </td></tr> 5187 <tr><td class="paramname">base</td><td>MSB of the destination address in VRAM (usually 0x80 or 0x90 which gives 0x8000 or 0x9000)</td></tr> 5188 </table> 5189 </dd> 5190</dl> 5191<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a1f5101f2b7bb0123c26a3e257f843626">set_bkg_data</a>, <a class="el" href="gb_8h.html#ac2bf0c4919c30d322fa5853c896e710f">set_win_data</a>, <a class="el" href="gb_8h.html#a650d2df96e69a40b70548ab468e00f25">set_data</a> </dd></dl> 5192 5193</div> 5194</div> 5195<a id="a728b9440accedc5fb3477be3d150323a"></a> 5196<h2 class="memtitle"><span class="permalink"><a href="#a728b9440accedc5fb3477be3d150323a">◆ </a></span>get_tiles()</h2> 5197 5198<div class="memitem"> 5199<div class="memproto"> 5200 <table class="memname"> 5201 <tr> 5202 <td class="memname">void get_tiles </td> 5203 <td>(</td> 5204 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 5205 <td class="paramname"><em>x</em>, </td> 5206 </tr> 5207 <tr> 5208 <td class="paramkey"></td> 5209 <td></td> 5210 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 5211 <td class="paramname"><em>y</em>, </td> 5212 </tr> 5213 <tr> 5214 <td class="paramkey"></td> 5215 <td></td> 5216 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 5217 <td class="paramname"><em>w</em>, </td> 5218 </tr> 5219 <tr> 5220 <td class="paramkey"></td> 5221 <td></td> 5222 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 5223 <td class="paramname"><em>h</em>, </td> 5224 </tr> 5225 <tr> 5226 <td class="paramkey"></td> 5227 <td></td> 5228 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> * </td> 5229 <td class="paramname"><em>vram_addr</em>, </td> 5230 </tr> 5231 <tr> 5232 <td class="paramkey"></td> 5233 <td></td> 5234 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> * </td> 5235 <td class="paramname"><em>tiles</em> </td> 5236 </tr> 5237 <tr> 5238 <td></td> 5239 <td>)</td> 5240 <td></td><td></td> 5241 </tr> 5242 </table> 5243</div><div class="memdoc"> 5244<p>Copies a rectangular region of Tile Map entries from a given VRAM Address into a buffer without taking into account the state of LCDC bit 3.</p> 5245<dl class="params"><dt>Parameters</dt><dd> 5246 <table class="params"> 5247 <tr><td class="paramname">x</td><td>X Start position in Background Map tile coordinates. Range 0 - 31 </td></tr> 5248 <tr><td class="paramname">y</td><td>Y Start position in Background Map tile coordinates. Range 0 - 31 </td></tr> 5249 <tr><td class="paramname">w</td><td>Width of area to copy in tiles. Range 0 - 31 </td></tr> 5250 <tr><td class="paramname">h</td><td>Height of area to copy in tiles. Range 0 - 31 </td></tr> 5251 <tr><td class="paramname">vram_addr</td><td>Pointer to source VRAM Address </td></tr> 5252 <tr><td class="paramname">tiles</td><td>Pointer to destination buffer for Tile Map data</td></tr> 5253 </table> 5254 </dd> 5255</dl> 5256<p>Entries are copied into <b>tiles</b> from the Background Tile Map starting at <b>x</b>, <b>y</b> reading across for <b>w</b> tiles and down for <b>h</b> tiles.</p> 5257<p>One byte per tile.</p> 5258<p>There are two 32x32 Tile Maps in VRAM at addresses 9800h - 9BFFh and 9C00h - 9FFFh.</p> 5259<p>The buffer pointed to by <b>tiles</b> should be at least <b>x</b> x <b>y</b> bytes in size.</p> 5260<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#aa6bcf24d97f93307b30f2906251f39a0">get_bkg_tiles</a>, <a class="el" href="gb_8h.html#a8a469de4c6640f921254b336b5a6191a">get_win_tiles</a> </dd></dl> 5261 5262</div> 5263</div> 5264<a id="a68651e50243349b48164a8ad983dca4e"></a> 5265<h2 class="memtitle"><span class="permalink"><a href="#a68651e50243349b48164a8ad983dca4e">◆ </a></span>set_native_tile_data()</h2> 5266 5267<div class="memitem"> 5268<div class="memproto"> 5269<table class="mlabels"> 5270 <tr> 5271 <td class="mlabels-left"> 5272 <table class="memname"> 5273 <tr> 5274 <td class="memname">void set_native_tile_data </td> 5275 <td>(</td> 5276 <td class="paramtype"><a class="el" href="stdint_8h.html#adf4d876453337156dde61095e1f20223">uint16_t</a> </td> 5277 <td class="paramname"><em>first_tile</em>, </td> 5278 </tr> 5279 <tr> 5280 <td class="paramkey"></td> 5281 <td></td> 5282 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 5283 <td class="paramname"><em>nb_tiles</em>, </td> 5284 </tr> 5285 <tr> 5286 <td class="paramkey"></td> 5287 <td></td> 5288 <td class="paramtype">const <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> * </td> 5289 <td class="paramname"><em>data</em> </td> 5290 </tr> 5291 <tr> 5292 <td></td> 5293 <td>)</td> 5294 <td></td><td></td> 5295 </tr> 5296 </table> 5297 </td> 5298 <td class="mlabels-right"> 5299<span class="mlabels"><span class="mlabel">inline</span></span> </td> 5300 </tr> 5301</table> 5302</div><div class="memdoc"> 5303<p>Sets VRAM Tile Pattern data in the native format</p> 5304<dl class="params"><dt>Parameters</dt><dd> 5305 <table class="params"> 5306 <tr><td class="paramname">first_tile</td><td>Index of the first tile to write (0 - 511) </td></tr> 5307 <tr><td class="paramname">nb_tiles</td><td>Number of tiles to write </td></tr> 5308 <tr><td class="paramname">data</td><td>Pointer to source Tile Pattern data.</td></tr> 5309 </table> 5310 </dd> 5311</dl> 5312<p>When <code>first_tile</code> is larger than 256 on the GB/AP, it will write to sprite data instead of background data.</p> 5313<p>The bit depth of the source Tile Pattern data depends on which console is being used: </p><ul> 5314<li>Game Boy/Analogue Pocket: loads 2bpp tiles data </li> 5315<li>SMS/GG: loads 4bpp tile data </li> 5316</ul> 5317 5318</div> 5319</div> 5320<a id="af6ac67037de041eb0141ba3725b1db83"></a> 5321<h2 class="memtitle"><span class="permalink"><a href="#af6ac67037de041eb0141ba3725b1db83">◆ </a></span>init_win()</h2> 5322 5323<div class="memitem"> 5324<div class="memproto"> 5325 <table class="memname"> 5326 <tr> 5327 <td class="memname">void init_win </td> 5328 <td>(</td> 5329 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 5330 <td class="paramname"><em>c</em></td><td>)</td> 5331 <td></td> 5332 </tr> 5333 </table> 5334</div><div class="memdoc"> 5335<p>Initializes the entire Window Tile Map with Tile Number <b>c</b> </p><dl class="params"><dt>Parameters</dt><dd> 5336 <table class="params"> 5337 <tr><td class="paramname">c</td><td>Tile number to fill with</td></tr> 5338 </table> 5339 </dd> 5340</dl> 5341<p>Note: This function avoids writes during modes 2 & 3 </p> 5342 5343</div> 5344</div> 5345<a id="a46058204097dd305bf72bc20ea7f7a3b"></a> 5346<h2 class="memtitle"><span class="permalink"><a href="#a46058204097dd305bf72bc20ea7f7a3b">◆ </a></span>init_bkg()</h2> 5347 5348<div class="memitem"> 5349<div class="memproto"> 5350 <table class="memname"> 5351 <tr> 5352 <td class="memname">void init_bkg </td> 5353 <td>(</td> 5354 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 5355 <td class="paramname"><em>c</em></td><td>)</td> 5356 <td></td> 5357 </tr> 5358 </table> 5359</div><div class="memdoc"> 5360<p>Initializes the entire Background Tile Map with Tile Number <b>c</b> </p><dl class="params"><dt>Parameters</dt><dd> 5361 <table class="params"> 5362 <tr><td class="paramname">c</td><td>Tile number to fill with</td></tr> 5363 </table> 5364 </dd> 5365</dl> 5366<p>Note: This function avoids writes during modes 2 & 3 </p> 5367 5368</div> 5369</div> 5370<a id="a97bab71effd5e4e386629cb6ca5816cf"></a> 5371<h2 class="memtitle"><span class="permalink"><a href="#a97bab71effd5e4e386629cb6ca5816cf">◆ </a></span>vmemset()</h2> 5372 5373<div class="memitem"> 5374<div class="memproto"> 5375 <table class="memname"> 5376 <tr> 5377 <td class="memname">void vmemset </td> 5378 <td>(</td> 5379 <td class="paramtype">void * </td> 5380 <td class="paramname"><em>s</em>, </td> 5381 </tr> 5382 <tr> 5383 <td class="paramkey"></td> 5384 <td></td> 5385 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 5386 <td class="paramname"><em>c</em>, </td> 5387 </tr> 5388 <tr> 5389 <td class="paramkey"></td> 5390 <td></td> 5391 <td class="paramtype"><a class="el" href="asm_2gbz80_2types_8h.html#a7c94ea6f8948649f8d181ae55911eeaf">size_t</a> </td> 5392 <td class="paramname"><em>n</em> </td> 5393 </tr> 5394 <tr> 5395 <td></td> 5396 <td>)</td> 5397 <td></td><td></td> 5398 </tr> 5399 </table> 5400</div><div class="memdoc"> 5401<p>Fills the VRAM memory region <b>s</b> of size <b>n</b> with Tile Number <b>c</b> </p><dl class="params"><dt>Parameters</dt><dd> 5402 <table class="params"> 5403 <tr><td class="paramname">s</td><td>Start address in VRAM </td></tr> 5404 <tr><td class="paramname">c</td><td>Tile number to fill with </td></tr> 5405 <tr><td class="paramname">n</td><td>Size of memory region (in bytes) to fill</td></tr> 5406 </table> 5407 </dd> 5408</dl> 5409<p>Note: This function avoids writes during modes 2 & 3 </p> 5410 5411</div> 5412</div> 5413<a id="a74c3f53fca019f7abcd1270650808849"></a> 5414<h2 class="memtitle"><span class="permalink"><a href="#a74c3f53fca019f7abcd1270650808849">◆ </a></span>fill_bkg_rect()</h2> 5415 5416<div class="memitem"> 5417<div class="memproto"> 5418 <table class="memname"> 5419 <tr> 5420 <td class="memname">void fill_bkg_rect </td> 5421 <td>(</td> 5422 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 5423 <td class="paramname"><em>x</em>, </td> 5424 </tr> 5425 <tr> 5426 <td class="paramkey"></td> 5427 <td></td> 5428 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 5429 <td class="paramname"><em>y</em>, </td> 5430 </tr> 5431 <tr> 5432 <td class="paramkey"></td> 5433 <td></td> 5434 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 5435 <td class="paramname"><em>w</em>, </td> 5436 </tr> 5437 <tr> 5438 <td class="paramkey"></td> 5439 <td></td> 5440 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 5441 <td class="paramname"><em>h</em>, </td> 5442 </tr> 5443 <tr> 5444 <td class="paramkey"></td> 5445 <td></td> 5446 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 5447 <td class="paramname"><em>tile</em> </td> 5448 </tr> 5449 <tr> 5450 <td></td> 5451 <td>)</td> 5452 <td></td><td></td> 5453 </tr> 5454 </table> 5455</div><div class="memdoc"> 5456<p>Fills a rectangular region of Tile Map entries for the Background layer with tile.</p> 5457<dl class="params"><dt>Parameters</dt><dd> 5458 <table class="params"> 5459 <tr><td class="paramname">x</td><td>X Start position in Background Map tile coordinates. Range 0 - 31 </td></tr> 5460 <tr><td class="paramname">y</td><td>Y Start position in Background Map tile coordinates. Range 0 - 31 </td></tr> 5461 <tr><td class="paramname">w</td><td>Width of area to set in tiles. Range 0 - 31 </td></tr> 5462 <tr><td class="paramname">h</td><td>Height of area to set in tiles. Range 0 - 31 </td></tr> 5463 <tr><td class="paramname">tile</td><td>Fill value </td></tr> 5464 </table> 5465 </dd> 5466</dl> 5467 5468</div> 5469</div> 5470<a id="ad5bc3dc922707507aa51ed7f5b4a21e3"></a> 5471<h2 class="memtitle"><span class="permalink"><a href="#ad5bc3dc922707507aa51ed7f5b4a21e3">◆ </a></span>fill_win_rect()</h2> 5472 5473<div class="memitem"> 5474<div class="memproto"> 5475 <table class="memname"> 5476 <tr> 5477 <td class="memname">void fill_win_rect </td> 5478 <td>(</td> 5479 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 5480 <td class="paramname"><em>x</em>, </td> 5481 </tr> 5482 <tr> 5483 <td class="paramkey"></td> 5484 <td></td> 5485 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 5486 <td class="paramname"><em>y</em>, </td> 5487 </tr> 5488 <tr> 5489 <td class="paramkey"></td> 5490 <td></td> 5491 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 5492 <td class="paramname"><em>w</em>, </td> 5493 </tr> 5494 <tr> 5495 <td class="paramkey"></td> 5496 <td></td> 5497 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 5498 <td class="paramname"><em>h</em>, </td> 5499 </tr> 5500 <tr> 5501 <td class="paramkey"></td> 5502 <td></td> 5503 <td class="paramtype"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> </td> 5504 <td class="paramname"><em>tile</em> </td> 5505 </tr> 5506 <tr> 5507 <td></td> 5508 <td>)</td> 5509 <td></td><td></td> 5510 </tr> 5511 </table> 5512</div><div class="memdoc"> 5513<p>Fills a rectangular region of Tile Map entries for the Window layer with tile.</p> 5514<dl class="params"><dt>Parameters</dt><dd> 5515 <table class="params"> 5516 <tr><td class="paramname">x</td><td>X Start position in Window Map tile coordinates. Range 0 - 31 </td></tr> 5517 <tr><td class="paramname">y</td><td>Y Start position in Window Map tile coordinates. Range 0 - 31 </td></tr> 5518 <tr><td class="paramname">w</td><td>Width of area to set in tiles. Range 0 - 31 </td></tr> 5519 <tr><td class="paramname">h</td><td>Height of area to set in tiles. Range 0 - 31 </td></tr> 5520 <tr><td class="paramname">tile</td><td>Fill value </td></tr> 5521 </table> 5522 </dd> 5523</dl> 5524 5525</div> 5526</div> 5527<h2 class="groupheader">Variable Documentation</h2> 5528<a id="a0b3366755f3276b0243c1e0497471b7a"></a> 5529<h2 class="memtitle"><span class="permalink"><a href="#a0b3366755f3276b0243c1e0497471b7a">◆ </a></span>c</h2> 5530 5531<div class="memitem"> 5532<div class="memproto"> 5533 <table class="memname"> 5534 <tr> 5535 <td class="memname">void c</td> 5536 </tr> 5537 </table> 5538</div><div class="memdoc"> 5539 5540</div> 5541</div> 5542<a id="a874b9bd95b0a05d6a6072feabc879e45"></a> 5543<h2 class="memtitle"><span class="permalink"><a href="#a874b9bd95b0a05d6a6072feabc879e45">◆ </a></span>_cpu</h2> 5544 5545<div class="memitem"> 5546<div class="memproto"> 5547<table class="mlabels"> 5548 <tr> 5549 <td class="mlabels-left"> 5550 <table class="memname"> 5551 <tr> 5552 <td class="memname"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> _cpu</td> 5553 </tr> 5554 </table> 5555 </td> 5556 <td class="mlabels-right"> 5557<span class="mlabels"><span class="mlabel">extern</span></span> </td> 5558 </tr> 5559</table> 5560</div><div class="memdoc"> 5561<p>GB CPU type</p> 5562<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a0031c07799247a6d6c1bfa3decac79d0">DMG_TYPE</a>, <a class="el" href="gb_8h.html#ae996ed4fd8bb6b308b9c8708a91df06b">MGB_TYPE</a>, <a class="el" href="gb_8h.html#aee435a3a0dde3dbd7b6112dbb456cde8">CGB_TYPE</a>, <a class="el" href="cgb_8h.html#a884a743919b234cd9c37789380784d08">cpu_fast()</a>, <a class="el" href="cgb_8h.html#a6a36fb9584e4a123f6164530a3b1e5e2">cpu_slow()</a>, <a class="el" href="gb_8h.html#a539b7b45b1c2d6b2051553665c76fd36">_is_GBA</a> </dd></dl> 5563 5564</div> 5565</div> 5566<a id="a539b7b45b1c2d6b2051553665c76fd36"></a> 5567<h2 class="memtitle"><span class="permalink"><a href="#a539b7b45b1c2d6b2051553665c76fd36">◆ </a></span>_is_GBA</h2> 5568 5569<div class="memitem"> 5570<div class="memproto"> 5571<table class="mlabels"> 5572 <tr> 5573 <td class="mlabels-left"> 5574 <table class="memname"> 5575 <tr> 5576 <td class="memname"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> _is_GBA</td> 5577 </tr> 5578 </table> 5579 </td> 5580 <td class="mlabels-right"> 5581<span class="mlabels"><span class="mlabel">extern</span></span> </td> 5582 </tr> 5583</table> 5584</div><div class="memdoc"> 5585<p>GBA detection</p> 5586<dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a6ccf5d0f34fb0af0b6e73b9df0ccd745">GBA_DETECTED</a>, <a class="el" href="gb_8h.html#aa311f84dd9fce6e136ba4881e7b0d98d">GBA_NOT_DETECTED</a>, <a class="el" href="gb_8h.html#a874b9bd95b0a05d6a6072feabc879e45">_cpu</a> </dd></dl> 5587 5588</div> 5589</div> 5590<a id="a78d2fd18666afec116f176d46debb4e7"></a> 5591<h2 class="memtitle"><span class="permalink"><a href="#a78d2fd18666afec116f176d46debb4e7">◆ </a></span>sys_time</h2> 5592 5593<div class="memitem"> 5594<div class="memproto"> 5595<table class="mlabels"> 5596 <tr> 5597 <td class="mlabels-left"> 5598 <table class="memname"> 5599 <tr> 5600 <td class="memname">volatile <a class="el" href="stdint_8h.html#adf4d876453337156dde61095e1f20223">uint16_t</a> sys_time</td> 5601 </tr> 5602 </table> 5603 </td> 5604 <td class="mlabels-right"> 5605<span class="mlabels"><span class="mlabel">extern</span></span> </td> 5606 </tr> 5607</table> 5608</div><div class="memdoc"> 5609<p>Global Time Counter in VBL periods (60Hz)</p> 5610<p>Increments once per Frame</p> 5611<p>Will wrap around every ~18 minutes (unsigned 16 bits = 65535 / 60 / 60 = 18.2) </p> 5612 5613</div> 5614</div> 5615<a id="a2e3415ce2f7fb63427618bd9b9cb6635"></a> 5616<h2 class="memtitle"><span class="permalink"><a href="#a2e3415ce2f7fb63427618bd9b9cb6635">◆ </a></span>_io_status</h2> 5617 5618<div class="memitem"> 5619<div class="memproto"> 5620<table class="mlabels"> 5621 <tr> 5622 <td class="mlabels-left"> 5623 <table class="memname"> 5624 <tr> 5625 <td class="memname">volatile <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> _io_status</td> 5626 </tr> 5627 </table> 5628 </td> 5629 <td class="mlabels-right"> 5630<span class="mlabels"><span class="mlabel">extern</span></span> </td> 5631 </tr> 5632</table> 5633</div><div class="memdoc"> 5634<p>Serial Link: Current IO Status. An OR of IO_* </p> 5635 5636</div> 5637</div> 5638<a id="a02f3a1585ae654444e628c1aa98ef0cf"></a> 5639<h2 class="memtitle"><span class="permalink"><a href="#a02f3a1585ae654444e628c1aa98ef0cf">◆ </a></span>_io_in</h2> 5640 5641<div class="memitem"> 5642<div class="memproto"> 5643<table class="mlabels"> 5644 <tr> 5645 <td class="mlabels-left"> 5646 <table class="memname"> 5647 <tr> 5648 <td class="memname">volatile <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> _io_in</td> 5649 </tr> 5650 </table> 5651 </td> 5652 <td class="mlabels-right"> 5653<span class="mlabels"><span class="mlabel">extern</span></span> </td> 5654 </tr> 5655</table> 5656</div><div class="memdoc"> 5657<p>Serial Link: Byte just read after calling <a class="el" href="gb_8h.html#a9a7fd7be44bb12bc85a144b732ce02f7">receive_byte()</a> </p> 5658 5659</div> 5660</div> 5661<a id="acae13736da20f9fc53e8d38934aa2119"></a> 5662<h2 class="memtitle"><span class="permalink"><a href="#acae13736da20f9fc53e8d38934aa2119">◆ </a></span>_io_out</h2> 5663 5664<div class="memitem"> 5665<div class="memproto"> 5666<table class="mlabels"> 5667 <tr> 5668 <td class="mlabels-left"> 5669 <table class="memname"> 5670 <tr> 5671 <td class="memname">volatile <a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> _io_out</td> 5672 </tr> 5673 </table> 5674 </td> 5675 <td class="mlabels-right"> 5676<span class="mlabels"><span class="mlabel">extern</span></span> </td> 5677 </tr> 5678</table> 5679</div><div class="memdoc"> 5680<p>Serial Link: Write byte to send here before calling <a class="el" href="gb_8h.html#ae339d7d8d7e0ebd6691b42608c416964">send_byte()</a> </p> 5681 5682</div> 5683</div> 5684<a id="a98b848953a95ce2fff6fda643575d74a"></a> 5685<h2 class="memtitle"><span class="permalink"><a href="#a98b848953a95ce2fff6fda643575d74a">◆ </a></span>_current_bank</h2> 5686 5687<div class="memitem"> 5688<div class="memproto"> 5689 <table class="memname"> 5690 <tr> 5691 <td class="memname"><a class="el" href="gb_2hardware_8h.html#a0b42e4dadd74c927e8b801b4f42c0e44">__REG</a> _current_bank</td> 5692 </tr> 5693 </table> 5694</div><div class="memdoc"> 5695<p>Tracks current active ROM bank </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="gb_8h.html#a19558f5bbc9fea767f945001ae9cd13f">SWITCH_ROM_MBC1()</a>, <a class="el" href="gb_8h.html#a92d040284342702026eb19dab59b586e">SWITCH_ROM_MBC5()</a> This variable is updated automatically when you call <a class="el" href="gb_8h.html#a19558f5bbc9fea767f945001ae9cd13f">SWITCH_ROM_MBC1</a> or <a class="el" href="gb_8h.html#a92d040284342702026eb19dab59b586e">SWITCH_ROM_MBC5</a>, or call a <a class="el" href="asm_2types_8h.html#aa8480aed89a168ec484727f5ac985cd0">BANKED</a> function. </dd></dl> 5696 5697</div> 5698</div> 5699<a id="a1f1dfeb2f802fe99f37fe91867b84456"></a> 5700<h2 class="memtitle"><span class="permalink"><a href="#a1f1dfeb2f802fe99f37fe91867b84456">◆ </a></span>h</h2> 5701 5702<div class="memitem"> 5703<div class="memproto"> 5704 <table class="memname"> 5705 <tr> 5706 <td class="memname"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> h</td> 5707 </tr> 5708 </table> 5709</div><div class="memdoc"> 5710 5711</div> 5712</div> 5713<a id="af79b920bcb642bba2e652874c4f7eeff"></a> 5714<h2 class="memtitle"><span class="permalink"><a href="#af79b920bcb642bba2e652874c4f7eeff">◆ </a></span>l</h2> 5715 5716<div class="memitem"> 5717<div class="memproto"> 5718 <table class="memname"> 5719 <tr> 5720 <td class="memname">void l</td> 5721 </tr> 5722 </table> 5723</div><div class="memdoc"> 5724<b>Initial value:</b><div class="fragment"><div class="line">{</div> 5725<div class="line"> __asm__(<span class="stringliteral">"ei"</span>)</div> 5726</div><!-- fragment --> 5727</div> 5728</div> 5729<a id="a4c2e4adef74067fdbb49005bc73de937"></a> 5730<h2 class="memtitle"><span class="permalink"><a href="#a4c2e4adef74067fdbb49005bc73de937">◆ </a></span>b</h2> 5731 5732<div class="memitem"> 5733<div class="memproto"> 5734 <table class="memname"> 5735 <tr> 5736 <td class="memname">void b</td> 5737 </tr> 5738 </table> 5739</div><div class="memdoc"> 5740 5741</div> 5742</div> 5743<a id="a0a3d95ad0ab8ad213016101d2e9c3d3e"></a> 5744<h2 class="memtitle"><span class="permalink"><a href="#a0a3d95ad0ab8ad213016101d2e9c3d3e">◆ </a></span>d</h2> 5745 5746<div class="memitem"> 5747<div class="memproto"> 5748 <table class="memname"> 5749 <tr> 5750 <td class="memname">void d</td> 5751 </tr> 5752 </table> 5753</div><div class="memdoc"> 5754 5755</div> 5756</div> 5757<a id="aeda4515a31485c9688c4601ac5ce2d79"></a> 5758<h2 class="memtitle"><span class="permalink"><a href="#aeda4515a31485c9688c4601ac5ce2d79">◆ </a></span>e</h2> 5759 5760<div class="memitem"> 5761<div class="memproto"> 5762 <table class="memname"> 5763 <tr> 5764 <td class="memname">void e</td> 5765 </tr> 5766 </table> 5767</div><div class="memdoc"> 5768 5769</div> 5770</div> 5771<a id="a250f5339e05523912926be566e9eb8c0"></a> 5772<h2 class="memtitle"><span class="permalink"><a href="#a250f5339e05523912926be566e9eb8c0">◆ </a></span>_current_1bpp_colors</h2> 5773 5774<div class="memitem"> 5775<div class="memproto"> 5776<table class="mlabels"> 5777 <tr> 5778 <td class="mlabels-left"> 5779 <table class="memname"> 5780 <tr> 5781 <td class="memname"><a class="el" href="stdint_8h.html#adf4d876453337156dde61095e1f20223">uint16_t</a> _current_1bpp_colors</td> 5782 </tr> 5783 </table> 5784 </td> 5785 <td class="mlabels-right"> 5786<span class="mlabels"><span class="mlabel">extern</span></span> </td> 5787 </tr> 5788</table> 5789</div><div class="memdoc"> 5790 5791</div> 5792</div> 5793<a id="aa82205e9629f984d0b3dc8055c211522"></a> 5794<h2 class="memtitle"><span class="permalink"><a href="#aa82205e9629f984d0b3dc8055c211522">◆ </a></span>_map_tile_offset</h2> 5795 5796<div class="memitem"> 5797<div class="memproto"> 5798<table class="mlabels"> 5799 <tr> 5800 <td class="mlabels-left"> 5801 <table class="memname"> 5802 <tr> 5803 <td class="memname"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> _map_tile_offset</td> 5804 </tr> 5805 </table> 5806 </td> 5807 <td class="mlabels-right"> 5808<span class="mlabels"><span class="mlabel">extern</span></span> </td> 5809 </tr> 5810</table> 5811</div><div class="memdoc"> 5812 5813</div> 5814</div> 5815<a id="ab472d9bbb1bcfd141374f5babc71934c"></a> 5816<h2 class="memtitle"><span class="permalink"><a href="#ab472d9bbb1bcfd141374f5babc71934c">◆ </a></span>_submap_tile_offset</h2> 5817 5818<div class="memitem"> 5819<div class="memproto"> 5820<table class="mlabels"> 5821 <tr> 5822 <td class="mlabels-left"> 5823 <table class="memname"> 5824 <tr> 5825 <td class="memname"><a class="el" href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> _submap_tile_offset</td> 5826 </tr> 5827 </table> 5828 </td> 5829 <td class="mlabels-right"> 5830<span class="mlabels"><span class="mlabel">extern</span></span> </td> 5831 </tr> 5832</table> 5833</div><div class="memdoc"> 5834 5835</div> 5836</div> 5837<a id="a3619f9cb1e3c92238a033ead79a0c551"></a> 5838<h2 class="memtitle"><span class="permalink"><a href="#a3619f9cb1e3c92238a033ead79a0c551">◆ </a></span>shadow_OAM</h2> 5839 5840<div class="memitem"> 5841<div class="memproto"> 5842<table class="mlabels"> 5843 <tr> 5844 <td class="mlabels-left"> 5845 <table class="memname"> 5846 <tr> 5847 <td class="memname">volatile struct <a class="el" href="struct_o_a_m__item__t.html">OAM_item_t</a> shadow_OAM[]</td> 5848 </tr> 5849 </table> 5850 </td> 5851 <td class="mlabels-right"> 5852<span class="mlabels"><span class="mlabel">extern</span></span> </td> 5853 </tr> 5854</table> 5855</div><div class="memdoc"> 5856<p>Shadow OAM array in WRAM, that is DMA-transferred into the real OAM each VBlank </p> 5857 5858</div> 5859</div> 5860<a id="a7b662ae4d83f9837bacb9fd580673054"></a> 5861<h2 class="memtitle"><span class="permalink"><a href="#a7b662ae4d83f9837bacb9fd580673054">◆ </a></span>_shadow_OAM_base</h2> 5862 5863<div class="memitem"> 5864<div class="memproto"> 5865 <table class="memname"> 5866 <tr> 5867 <td class="memname"><a class="el" href="gb_2hardware_8h.html#a0b42e4dadd74c927e8b801b4f42c0e44">__REG</a> _shadow_OAM_base</td> 5868 </tr> 5869 </table> 5870</div><div class="memdoc"> 5871<p>MSB of shadow_OAM address is used by OAM DMA copying routine </p> 5872 5873</div> 5874</div> 5875</div><!-- contents --> 5876</div><!-- doc-content --> 5877<div class="ttc" id="astdint_8h_html_aba7bc1797add20fe3efdf37ced1182c5"><div class="ttname"><a href="stdint_8h.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a></div><div class="ttdeci">unsigned char uint8_t</div><div class="ttdef"><b>Definition:</b> stdint.h:51</div></div> 5878<div class="ttc" id="agb_8h_html_a98b848953a95ce2fff6fda643575d74a"><div class="ttname"><a href="gb_8h.html#a98b848953a95ce2fff6fda643575d74a">_current_bank</a></div><div class="ttdeci">__REG _current_bank</div><div class="ttdef"><b>Definition:</b> gb.h:427</div></div> 5879<div class="ttc" id="astdint_8h_html_adf4d876453337156dde61095e1f20223"><div class="ttname"><a href="stdint_8h.html#adf4d876453337156dde61095e1f20223">uint16_t</a></div><div class="ttdeci">unsigned short int uint16_t</div><div class="ttdef"><b>Definition:</b> stdint.h:52</div></div> 5880<div class="ttc" id="agb_8h_html_a9727caafc483ba6ec65e9344b033d684"><div class="ttname"><a href="gb_8h.html#a9727caafc483ba6ec65e9344b033d684">DMG_PALETTE</a></div><div class="ttdeci">#define DMG_PALETTE(C0, C1, C2, C3)</div><div class="ttdef"><b>Definition:</b> gb.h:136</div></div> 5881<div class="ttc" id="agb_8h_html_a695c6d0e8fd7cf11dae0d4c67bc058f9"><div class="ttname"><a href="gb_8h.html#a695c6d0e8fd7cf11dae0d4c67bc058f9">nowait_int_handler</a></div><div class="ttdeci">void nowait_int_handler()</div></div> 5882<div class="ttc" id="agb_8h_html_ab311e53739c992294ae07ca506a924ad"><div class="ttname"><a href="gb_8h.html#ab311e53739c992294ae07ca506a924ad">DMG_BLACK</a></div><div class="ttdeci">#define DMG_BLACK</div><div class="ttdef"><b>Definition:</b> gb.h:113</div></div> 5883<div class="ttc" id="agb_8h_html_aa82422752016328ed0765879e286019f"><div class="ttname"><a href="gb_8h.html#aa82422752016328ed0765879e286019f">add_SIO</a></div><div class="ttdeci">void add_SIO(int_handler h) OLDCALL</div></div> 5884<div class="ttc" id="agb_8h_html_a4c2e4adef74067fdbb49005bc73de937"><div class="ttname"><a href="gb_8h.html#a4c2e4adef74067fdbb49005bc73de937">b</a></div><div class="ttdeci">void b</div><div class="ttdef"><b>Definition:</b> gb.h:608</div></div> 5885<div class="ttc" id="agb_8h_html_a45d13a674e169dd83df7e1f46513ccba"><div class="ttname"><a href="gb_8h.html#a45d13a674e169dd83df7e1f46513ccba">DMG_DARK_GRAY</a></div><div class="ttdeci">#define DMG_DARK_GRAY</div><div class="ttdef"><b>Definition:</b> gb.h:114</div></div> 5886<div class="ttc" id="agb_8h_html_a11cedc2ee58acfbbfc48dfb2b9a551b3"><div class="ttname"><a href="gb_8h.html#a11cedc2ee58acfbbfc48dfb2b9a551b3">DMG_WHITE</a></div><div class="ttdeci">#define DMG_WHITE</div><div class="ttdef"><b>Definition:</b> gb.h:116</div></div> 5887<div class="ttc" id="agb_8h_html_a8ccd6732d3bdf390cc0943e8567341f3"><div class="ttname"><a href="gb_8h.html#a8ccd6732d3bdf390cc0943e8567341f3">DMG_LITE_GRAY</a></div><div class="ttdeci">#define DMG_LITE_GRAY</div><div class="ttdef"><b>Definition:</b> gb.h:115</div></div> 5888<div class="ttc" id="aasm_2types_8h_html_ae0233515480e60d29bcc731469976e02"><div class="ttname"><a href="asm_2types_8h.html#ae0233515480e60d29bcc731469976e02">CRITICAL</a></div><div class="ttdeci">#define CRITICAL</div><div class="ttdef"><b>Definition:</b> types.h:42</div></div> 5889<!-- HTML footer for doxygen 1.8.14--> 5890<!-- start footer part --> 5891<div id="nav-path" class="navpath"><!-- id is needed for treeview function! --> 5892</div> 5893</body> 5894</html>