@@ -314,20 +314,38 @@ ready to communicate with your Android device.</li>
314314
315315<h3 id="alt-build">Using the ADK Alternative Build System</h3>
316316
317- <p>An alternative build and load system is also available for the ADK 2012. This system is command
318- line based and intended for production environments where using an IDE environment to load software
319- onto accessory hardware may be inconvenient or undesirable.</p>
317+ <p>An alternative, make file-based build and upload system is also available for the ADK 2012. This
318+ system is command line based and intended for production environments where using an IDE environment
319+ to load software onto accessory hardware may be inconvenient or undesirable.</p>
320320
321- <p>To use the command line based build system :</p>
321+ <p>To setup the environment :</p>
322322<ol>
323323 <li><a href="#src-download">Download</a> the ADK 2012 source code files.</li>
324- <li>Download and install the <a href="http://www.gnu.org/software/make/">make</a> tool on your
325- development system.</li>
326- <li>Update your system’s PATH to include {@code
327- <adk-source-download>/external/toolchain/bin}.</li>
328- <li>Open a terminal window, navigate to {@code
329- <adk-source-download>/external/toolchain/app} and execute the following command:
330- <pre>$> make</pre></li>
324+ <li>In a terminal window, navigate to {@code
325+ <adk-source-download>/adk2012/board/MakefileBasedBuild}.</li>
326+ <li>Execute the following command and follow the instructions:
327+ <pre>$> ./setup</pre>
328+ </li>
329+ </ol>
330+
331+ <p>To build a program for your accessory:</p>
332+ <ol>
333+ <li>Place your accessory code in the {@code MakefileBasedBuild/app} directory, including all
334+ required library files. See the {@code app/main.c} file for an example of the program format.</li>
335+ <li>Execute the following command and follow the instructions:
336+ <pre>$> ./build</pre>
337+ </li>
338+ </ol>
339+
340+ <p>To load the program on your accessory hardware:</p>
341+ <ol>
342+ <li>Run the build process above and make sure your program compiled successfully.</li>
343+ <li>Attach the accessory via USB cable to your development computer.</li>
344+ <li>Check which port the accessory is attached to and modify the {@code UART} variable in the
345+ {@code flash} script to the correct port address. On linux machines, the port address is typically
346+ {@code /dev/ttyUSB0}.</li>
347+ <li>Execute the following command to load the program on the accessory:
348+ <pre>$> ./flash</pre></li>
331349</ol>
332350
333351<h2 id="adk-conn">How the ADK Connects with Android Devices</h2>
0 commit comments