auto import from //branches/cupcake/...@125939

This commit is contained in:
The Android Open Source Project
2009-01-09 17:51:19 -08:00
parent e943f2fd8e
commit 95cf464c5a
176 changed files with 4721 additions and 7588 deletions

View File

@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<resources xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
<string name="appTitle">"Application de secours"</string>
<string name="title">"Action non prise en charge"</string>
<string name="error">"Cette action n\'est actuellement pas prise en charge."</string>
</resources>

View File

@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<resources xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
<string name="appTitle">"Fallback"</string>
<string name="title">"Azione non supportata"</string>
<string name="error">"L\'azione non è al momento supportata."</string>
</resources>

View File

@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<resources xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
<string name="appTitle">"Fallback"</string>
<string name="title">"不支持的操作"</string>
<string name="error">"当前不支持该操作。"</string>
</resources>

View File

@@ -60,13 +60,22 @@ import java.util.ArrayList;
*/ */
public class Term extends Activity { public class Term extends Activity {
/**
* Set to true to add debugging code and logging.
*/
public static final boolean DEBUG = false;
/** /**
* Set to true to log each character received from the remote process to the * Set to true to log each character received from the remote process to the
* android log, which makes it easier to debug some kinds of problems with * android log, which makes it easier to debug some kinds of problems with
* emulating escape sequences and control codes. * emulating escape sequences and control codes.
*/ */
public static final boolean LOG_CHARACTERS_FLAG = false; public static final boolean LOG_CHARACTERS_FLAG = DEBUG && false;
/**
* Set to true to log unknown escape sequences.
*/
public static final boolean LOG_UNKNOWN_ESCAPE_SEQUENCES = DEBUG && false;
/** /**
* The tag we use when logging, so that our messages can be distinguished * The tag we use when logging, so that our messages can be distinguished
@@ -619,7 +628,7 @@ interface Screen {
* @param columns * @param columns
* @param rows * @param rows
*/ */
void resize(int columns, int rows); void resize(int columns, int rows, int foreColor, int backColor);
} }
@@ -673,7 +682,7 @@ class TranscriptScreen implements Screen {
private char[] mData; private char[] mData;
/** /**
* The data's stored as bytes, but the drawing routines require chars, so we * The data's stored as color-encoded chars, but the drawing routines require chars, so we
* need a temporary buffer to hold a row's worth of characters. * need a temporary buffer to hold a row's worth of characters.
*/ */
private char[] mRowBuffer; private char[] mRowBuffer;
@@ -695,23 +704,25 @@ class TranscriptScreen implements Screen {
* transcript that holds lines that have scrolled off the top of the * transcript that holds lines that have scrolled off the top of the
* screen. * screen.
*/ */
public TranscriptScreen(int columns, int totalRows, int screenRows) { public TranscriptScreen(int columns, int totalRows, int screenRows,
init(columns, totalRows, screenRows); int foreColor, int backColor) {
init(columns, totalRows, screenRows, foreColor, backColor);
} }
private void init(int columns, int totalRows, int screenRows) { private void init(int columns, int totalRows, int screenRows, int foreColor, int backColor) {
mColumns = columns; mColumns = columns;
mTotalRows = totalRows; mTotalRows = totalRows;
mActiveTranscriptRows = 0; mActiveTranscriptRows = 0;
mHead = 0; mHead = 0;
mActiveRows = mScreenRows; mActiveRows = screenRows;
mScreenRows = screenRows; mScreenRows = screenRows;
int totalSize = columns * totalRows; int totalSize = columns * totalRows;
mData = new char[totalSize]; mData = new char[totalSize];
blockSet(0, 0, mColumns, mScreenRows, ' ', 0, 7); blockSet(0, 0, mColumns, mScreenRows, ' ', foreColor, backColor);
mRowBuffer = new char[columns]; mRowBuffer = new char[columns];
mLineWrap = new boolean[totalRows]; mLineWrap = new boolean[totalRows];
} consistencyCheck();
}
/** /**
* Convert a row value from the public external coordinate system to our * Convert a row value from the public external coordinate system to our
@@ -781,7 +792,7 @@ class TranscriptScreen implements Screen {
// Adjust the transcript so that the last line of the transcript // Adjust the transcript so that the last line of the transcript
// is ready to receive the newly scrolled data // is ready to receive the newly scrolled data
consistencyCheck();
int expansionRows = Math.min(1, mTotalRows - mActiveRows); int expansionRows = Math.min(1, mTotalRows - mActiveRows);
int rollRows = 1 - expansionRows; int rollRows = 1 - expansionRows;
mActiveRows += expansionRows; mActiveRows += expansionRows;
@@ -789,6 +800,7 @@ class TranscriptScreen implements Screen {
if (mActiveTranscriptRows > 0) { if (mActiveTranscriptRows > 0) {
mHead = (mHead + rollRows) % mActiveTranscriptRows; mHead = (mHead + rollRows) % mActiveTranscriptRows;
} }
consistencyCheck();
// Block move the scroll line to the transcript // Block move the scroll line to the transcript
int topOffset = getOffset(topMargin); int topOffset = getOffset(topMargin);
@@ -799,7 +811,6 @@ class TranscriptScreen implements Screen {
int destLine = externalToInternalRow(-1); int destLine = externalToInternalRow(-1);
System.arraycopy(mLineWrap, topLine, mLineWrap, destLine, 1); System.arraycopy(mLineWrap, topLine, mLineWrap, destLine, 1);
// Block move the scrolled data up // Block move the scrolled data up
int numScrollChars = (bottomMargin - topMargin - 1) * mColumns; int numScrollChars = (bottomMargin - topMargin - 1) * mColumns;
System.arraycopy(mData, topOffset + mColumns, mData, topOffset, System.arraycopy(mData, topOffset + mColumns, mData, topOffset,
@@ -813,6 +824,41 @@ class TranscriptScreen implements Screen {
mLineWrap[externalToInternalRow(bottomMargin-1)] = false; mLineWrap[externalToInternalRow(bottomMargin-1)] = false;
} }
private void consistencyCheck() {
checkPositive(mColumns);
checkPositive(mTotalRows);
checkRange(0, mActiveTranscriptRows, mTotalRows);
if (mActiveTranscriptRows == 0) {
checkEqual(mHead, 0);
} else {
checkRange(0, mHead, mActiveTranscriptRows-1);
}
checkEqual(mScreenRows + mActiveTranscriptRows, mActiveRows);
checkRange(0, mScreenRows, mTotalRows);
checkEqual(mTotalRows, mLineWrap.length);
checkEqual(mTotalRows*mColumns, mData.length);
checkEqual(mColumns, mRowBuffer.length);
}
private void checkPositive(int n) {
if (n < 0) {
throw new IllegalArgumentException("checkPositive " + n);
}
}
private void checkRange(int a, int b, int c) {
if (a > b || b > c) {
throw new IllegalArgumentException("checkRange " + a + " <= " + b + " <= " + c);
}
}
private void checkEqual(int a, int b) {
if (a != b) {
throw new IllegalArgumentException("checkEqual " + a + " == " + b);
}
}
/** /**
* Block copy characters from one position in the screen to another. The two * Block copy characters from one position in the screen to another. The two
* positions can overlap. All characters of the source and destination must * positions can overlap. All characters of the source and destination must
@@ -872,7 +918,7 @@ class TranscriptScreen implements Screen {
for (int y = 0; y < h; y++) { for (int y = 0; y < h; y++) {
int offset = getOffset(sx, sy + y); int offset = getOffset(sx, sy + y);
for (int x = 0; x < w; x++) { for (int x = 0; x < w; x++) {
data[offset + x] = (char) val; data[offset + x] = encodedVal;
} }
} }
} }
@@ -954,7 +1000,7 @@ class TranscriptScreen implements Screen {
return internalGetTranscriptText(true); return internalGetTranscriptText(true);
} }
public String internalGetTranscriptText(boolean stripColors) { private String internalGetTranscriptText(boolean stripColors) {
StringBuilder builder = new StringBuilder(); StringBuilder builder = new StringBuilder();
char[] rowBuffer = mRowBuffer; char[] rowBuffer = mRowBuffer;
char[] data = mData; char[] data = mData;
@@ -982,55 +1028,11 @@ class TranscriptScreen implements Screen {
return builder.toString(); return builder.toString();
} }
public void resize(int columns, int rows) { public void resize(int columns, int rows, int foreColor, int backColor) {
if (columns == mColumns) { init(columns, mTotalRows, rows, foreColor, backColor);
if (rows == mScreenRows) {
return;
}
if (rows < mTotalRows) {
mScreenRows = rows;
mActiveTranscriptRows = mActiveRows - mScreenRows;
return;
}
}
// Tough case: columns size changes or need to expand rows
String transcriptText = internalGetTranscriptText(false);
int totalRows = Math.max(rows + 1, mTotalRows);
init(columns, totalRows, rows);
int length = transcriptText.length();
// Copy transcript into buffer
int row = 0;
char[] data = mData;
int col = 0;
for(int i = 0; i < length && row < totalRows; i++) {
char c = transcriptText.charAt(i);
if (c == '\n') {
row++;
col = 0;
} else {
if (col < columns) {
data[row * columns + col] = c;
col += 1;
} else {
if (row < totalRows-1) {
mLineWrap[row] = true;
row++;
col = 0;
data[row * columns + col] = c;
col += 1;
} else {
break; // ran out of room
}
}
}
}
mActiveRows = rows;
mActiveTranscriptRows = mActiveRows - mScreenRows;
} }
} }
/** /**
* Renders text into a screen. Contains all the terminal-specific knowlege and * Renders text into a screen. Contains all the terminal-specific knowlege and
* state. Emulates a subset of the X Window System xterm terminal, which in turn * state. Emulates a subset of the X Window System xterm terminal, which in turn
@@ -1270,12 +1272,14 @@ class TerminalEmulator {
if (mRows == rows && mColumns == columns) { if (mRows == rows && mColumns == columns) {
return; return;
} }
mScreen.resize(columns, rows); String transcriptText = mScreen.getTranscriptText();
mScreen.resize(columns, rows, mForeColor, mBackColor);
if (mRows != rows) { if (mRows != rows) {
mRows = rows; mRows = rows;
mTopMargin = 0; mTopMargin = 0;
mBottomMargin = mRows; mBottomMargin = mRows;
mCursorRow = Math.min(mCursorRow, mBottomMargin-1);
} }
if (mColumns != columns) { if (mColumns != columns) {
int oldColumns = mColumns; int oldColumns = mColumns;
@@ -1288,7 +1292,23 @@ class TerminalEmulator {
mCursorCol -= columns; mCursorCol -= columns;
mCursorRow = Math.min(mBottomMargin-1, mCursorRow + 1); mCursorRow = Math.min(mBottomMargin-1, mCursorRow + 1);
} }
mAboutToAutoWrap = false; }
mCursorRow = 0;
mCursorCol = 0;
mAboutToAutoWrap = false;
int end = transcriptText.length()-1;
while ((end >= 0) && transcriptText.charAt(end) == '\n') {
end--;
}
for(int i = 0; i <= end; i++) {
byte c = (byte) transcriptText.charAt(i);
if (c == '\n') {
setCursorCol(0);
doLinefeed();
} else {
emit(c);
}
} }
} }
@@ -1877,7 +1897,9 @@ class TerminalEmulator {
} else if (code >= 40 && code <= 47) { // background color } else if (code >= 40 && code <= 47) { // background color
mBackColor = (mBackColor & 0x8) | (code - 40); mBackColor = (mBackColor & 0x8) | (code - 40);
} else { } else {
Log.w(Term.LOG_TAG, String.format("SGR unknown code %d", code)); if (Term.LOG_UNKNOWN_ESCAPE_SEQUENCES) {
Log.w(Term.LOG_TAG, String.format("SGR unknown code %d", code));
}
} }
} }
} }
@@ -2030,52 +2052,59 @@ class TerminalEmulator {
} }
private void unimplementedSequence(byte b) { private void unimplementedSequence(byte b) {
logError("unimplemented", b); if (Term.LOG_UNKNOWN_ESCAPE_SEQUENCES) {
logError("unimplemented", b);
}
finishSequence(); finishSequence();
} }
private void unknownSequence(byte b) { private void unknownSequence(byte b) {
logError("unknown", b); if (Term.LOG_UNKNOWN_ESCAPE_SEQUENCES) {
logError("unknown", b);
}
finishSequence(); finishSequence();
} }
private void unknownParameter(int parameter) { private void unknownParameter(int parameter) {
// We could log that we didn't recognize parameter. if (Term.LOG_UNKNOWN_ESCAPE_SEQUENCES) {
StringBuilder buf = new StringBuilder(); StringBuilder buf = new StringBuilder();
buf.append("Unknown parameter"); buf.append("Unknown parameter");
buf.append(parameter); buf.append(parameter);
logError(buf.toString()); logError(buf.toString());
}
} }
private void logError(String errorType, byte b) { private void logError(String errorType, byte b) {
// We could log that we didn't recognize character b. if (Term.LOG_UNKNOWN_ESCAPE_SEQUENCES) {
StringBuilder buf = new StringBuilder(); StringBuilder buf = new StringBuilder();
buf.append(errorType); buf.append(errorType);
buf.append(" sequence "); buf.append(" sequence ");
buf.append(" EscapeState: "); buf.append(" EscapeState: ");
buf.append(mEscapeState); buf.append(mEscapeState);
buf.append(" char: '"); buf.append(" char: '");
buf.append((char) b); buf.append((char) b);
buf.append("' ("); buf.append("' (");
buf.append((int) b); buf.append((int) b);
buf.append(")"); buf.append(")");
boolean firstArg = true; boolean firstArg = true;
for (int i = 0; i <= mArgIndex; i++) { for (int i = 0; i <= mArgIndex; i++) {
int value = mArgs[i]; int value = mArgs[i];
if (value >= 0) { if (value >= 0) {
if (firstArg) { if (firstArg) {
firstArg = false; firstArg = false;
buf.append("args = "); buf.append("args = ");
}
buf.append(String.format("%d; ", value));
} }
buf.append(String.format("%d; ", value));
} }
logError(buf.toString());
} }
logError(buf.toString());
} }
private void logError(String error) { private void logError(String error) {
Log.e(Term.LOG_TAG, error); if (Term.LOG_UNKNOWN_ESCAPE_SEQUENCES) {
Log.e(Term.LOG_TAG, error);
}
finishSequence(); finishSequence();
} }
@@ -2848,7 +2877,7 @@ class EmulatorView extends View implements GestureDetector.OnGestureListener {
mEmulator.updateSize(mColumns, mRows); mEmulator.updateSize(mColumns, mRows);
} else { } else {
mTranscriptScreen = mTranscriptScreen =
new TranscriptScreen(mColumns, TRANSCRIPT_ROWS, mRows); new TranscriptScreen(mColumns, TRANSCRIPT_ROWS, mRows, 0, 7);
mEmulator = mEmulator =
new TerminalEmulator(mTranscriptScreen, mColumns, mRows, new TerminalEmulator(mTranscriptScreen, mColumns, mRows,
mTermOut); mTermOut);

View File

@@ -50,11 +50,10 @@ development/tools/scripts/java_tests_file.template platforms/${PLATFORM_NAME}/te
development/tools/scripts/layout.template platforms/${PLATFORM_NAME}/templates/layout.template development/tools/scripts/layout.template platforms/${PLATFORM_NAME}/templates/layout.template
development/tools/scripts/strings.template platforms/${PLATFORM_NAME}/templates/strings.template development/tools/scripts/strings.template platforms/${PLATFORM_NAME}/templates/strings.template
development/tools/scripts/alias.template platforms/${PLATFORM_NAME}/templates/alias.template development/tools/scripts/alias.template platforms/${PLATFORM_NAME}/templates/alias.template
development/tools/scripts/android_rules.xml platforms/${PLATFORM_NAME}/templates/android_rules.xml
development/tools/scripts/alias_rules.xml platforms/${PLATFORM_NAME}/templates/alias_rules.xml
development/tools/scripts/build.template tools/lib/build.template development/tools/scripts/build.template tools/lib/build.template
development/tools/scripts/build.alias.template tools/lib/build.alias.template development/tools/scripts/build.alias.template tools/lib/build.alias.template
development/tools/scripts/default.properties.template tools/lib/default.properties.template
development/tools/scripts/android_rules.xml tools/lib/android_rules.xml
development/tools/scripts/alias_rules.xml tools/lib/alias_rules.xml
# emacs support # emacs support
development/tools/scripts/android.el tools/lib/android.el development/tools/scripts/android.el tools/lib/android.el
@@ -116,6 +115,7 @@ framework/traceview.jar tools/lib/traceview.jar
# activitycreator # activitycreator
bin/activitycreator tools/activitycreator bin/activitycreator tools/activitycreator
framework/activitycreator.jar tools/lib/activitycreator.jar framework/activitycreator.jar tools/lib/activitycreator.jar
framework/anttasks.jar tools/lib/anttasks.jar
# sdkmanager # sdkmanager
bin/android tools/android bin/android tools/android

View File

@@ -2,6 +2,7 @@
#include <stdio.h> #include <stdio.h>
#include <stdlib.h> #include <stdlib.h>
#include <unistd.h>
#include <inttypes.h> #include <inttypes.h>
#include <string.h> #include <string.h>
#include "dmtrace.h" #include "dmtrace.h"

View File

@@ -14,13 +14,181 @@
# limitations under the License. # limitations under the License.
# #
# Assemble the Platform Development Kit # Assemble the Platform Development Kit (PDK)
# (TODO) Figure out why $(ACP) builds with target ndk but not pdk_docs
# (TODO) Copy over index.html from templates instead of from generatedDocs
# (TODO) Build doxygen (depend on latest version)
pdk: ndk pdk:
@echo "Package: $@" @echo "Package: $@ has targets ndk, pdk_docs and pdk_all"
LOCAL_PATH := $(my-dir) pdk_all: ndk pdk_docs
@echo "Package: $^"
LOCAL_PATH := $(call my-dir)
#-------------------------------------------------------------------------------
# Make the Native Development Kit (Code examples)
# Allows vendors to build shared libraries without entire source tree.
# This include adds /ndk to LOCAL_PATH, so can't use it afterwards...
include $(LOCAL_PATH)/ndk/Ndk.mk include $(LOCAL_PATH)/ndk/Ndk.mk
#-------------------------------------------------------------------------------
# Make the Plaftorm Development Kit Documentation.
# Doxygenize the header files to create html docs in the generatedDocs dir.
# Copy the template files and the generated html to the docs dir and zip
# everything up to the distribution directory.
# Workspace directory
pdk_docs_intermediates := $(call intermediates-dir-for,PACKAGING,pdkdocs)
# Source directories for templates, config & header files
pdk_templates_dir := development/pdk/docs
pdk_config_dir := development/pdk/doxygen_config
pdk_docsfile_dir := $(pdk_config_dir)/docsfiles
pdk_hardware_dir := hardware/libhardware/include/hardware
pdk_camera_dir := frameworks/base/include/ui
# Destination directory for docs (templates + doxygenated headers)
pdk_docs_dest_dir := $(pdk_docs_intermediates)/docs
# Working directory for source to be doxygenated
pdk_doxy_source_dir := $(pdk_docs_intermediates)/sources
# Working directory for html, et al. after doxygination
pdk_generated_source_dir := $(pdk_docs_intermediates)/generatedDocs/html
# Working directory for .dox files
pdk_doxy_docsfiles_dir := $(pdk_docs_intermediates)/docsfiles
# Doxygen version to use, so we can override it on the command line
# doxygen 1.4.6 working, the latest version get-apt installable on goobuntu.
# (TODO) doxygen 1.5.6 generated source files not displayable
# doxygen_version='~pubengdocs/shared/doxy/doxygen.1.5.6.kcc'
# for latest version of doxygen on linux
doxygen_version = doxygen
#-------------------------------------------------------------------------------
# Header files to doxygenize.
# Add new header files to document here, also adjust the templates to have
# descriptions for the new headers and point to the new doxygen created html.
pdk_headers := $(pdk_hardware_dir)/AudioHardwareInterface.h \
$(pdk_hardware_dir)/gps.h \
$(pdk_hardware_dir)/wifi.h \
$(pdk_camera_dir)/CameraHardwareInterface.h
# Create a rule to copy the list of PDK headers to be doxyginated.
# copy-one-header defines the actual rule.
$(foreach header,$(pdk_headers), \
$(eval _chFrom := $(header)) \
$(eval _chTo := $(pdk_doxy_source_dir)/$(notdir $(header))) \
$(eval $(call copy-one-header,$(_chFrom),$(_chTo))) \
$(eval all_copied_pdk_headers: $(_chTo)) \
)
_chFrom :=
_chTo :=
#-------------------------------------------------------------------------------
# Assemble all the necessary doxygen config files and the sources into the
# working directories
pdk_templates := $(shell find $(pdk_templates_dir) -type f)
# Create a rule to copy the list of PDK doc templates.
# copy-one-file defines the actual rule.
$(foreach template,$(pdk_templates), \
$(eval _chFrom := $(template)) \
$(eval _chTo := $(pdk_docs_dest_dir)/$(notdir $(template))) \
$(eval $(call copy-one-header,$(_chFrom),$(_chTo))) \
$(eval all_copied_pdk_templates: $(_chTo)) \
)
_chFrom :=
_chTo :=
# Copy newer doxygen config file (basic configs, should not change very often.)
pdk_doxygen_config_file := $(pdk_docs_intermediates)/pdk_config.conf
$(pdk_doxygen_config_file): $(pdk_config_dir)/pdk_config.conf
@echo "PDK: $@"
$(copy-file-to-target-with-cp)
# Copy newer doxygen override config file (may change these more often.)
pdk_doxygen_config_override_file := $(pdk_docs_intermediates)/overrideconfig.conf
$(pdk_doxygen_config_override_file): $(pdk_config_dir)/overrideconfig.conf
@echo "PDK: $@"
$(copy-file-to-target-with-cp)
# (TODO) Get the latest templates
# Copy newer doxygen html files.
$(pdk_docs_intermediates)/header.html: $(pdk_config_dir)/header.html
@echo "PDK: $@"
$(copy-file-to-target-with-cp)
$(pdk_docs_intermediates)/footer.html: $(pdk_config_dir)/footer.html
@echo "PDK: $@"
$(copy-file-to-target-with-cp)
# Copy newer doxygen .dox files
$(pdk_doxy_docsfiles_dir)/groups.dox: $(pdk_docsfile_dir)/groups.dox
@echo "PDK: $@"
$(copy-file-to-target-with-cp)
$(pdk_doxy_docsfiles_dir)/main.dox: $(pdk_docsfile_dir)/main.dox
@echo "PDK: $@"
$(copy-file-to-target-with-cp)
# Run doxygen and copy all output and templates to the final destination
# We replace index.html with a template file so don't use the generated one
pdk_doxygen: all_copied_pdk_headers $(pdk_doxygen_config_override_file) \
$(pdk_doxygen_config_file) $(pdk_docs_intermediates)/header.html \
$(pdk_docs_intermediates)/footer.html $(pdk_doxy_docsfiles_dir)/groups.dox \
$(pdk_doxy_docsfiles_dir)/main.dox
@echo "Files for Doxygination: $^"
@mkdir -p $(pdk_generated_source_dir)
@rm -f $(pdk_generated_source_dir)/*
@cd $(pdk_docs_intermediates) && $(doxygen_version) pdk_config.conf
@mkdir -p $(pdk_docs_dest_dir)
@cd $(pdk_generated_source_dir) && chmod ug+rx *
@rm -f $(pdk_generated_source_dir)/index.html
@cp -fp $(pdk_generated_source_dir)/* $(pdk_docs_dest_dir)
# Name the tar files
name := android_pdk_docs-$(REQUESTED_PRODUCT)
ifeq ($(TARGET_BUILD_TYPE),debug)
name := $(name)_debug
endif
name := $(name)-$(BUILD_NUMBER)
pdk_docs_tarfile := $(pdk_docs_intermediates)/$(name).tar
pdk_docs_tarfile_zipped := $(pdk_docs_tarfile).gz
.PHONY: pdk pdk_docs pdk_doxygen all_copied_pdk_headers all_copied_pdk_templates
pdk_docs: $(pdk_docs_tarfile_zipped)
@echo "PDK: Docs tarred and zipped"
# Put the pdk_docs zip files in the distribution directory
$(call dist-for-goals,pdk_docs,$(pdk_docs_tarfile_zipped))
# zip up tar files
%.tar.gz: %.tar
@echo "PDK: zipped $<"
$(hide) gzip -cf $< > $@
# tar up all the files to make the pdk docs.
$(pdk_docs_tarfile): pdk_doxygen all_copied_pdk_templates
@echo "PDK: $@"
@mkdir -p $(dir $@)
@rm -f $@
$(hide) tar rf $@ -C $(pdk_docs_intermediates) docs
# Debugging reporting can go here, add it as a target to get output.
pdk_debug:
@echo "You are here: $@"
@echo "pdk headers copied: $(all_copied_pdk_headers)"
@echo "pdk headers: $(pdk_headers)"
@echo "pdk docs dest: $(pdk_docs_dest_dir)"
@echo "config dest: $(pdk_doxygen_config_file)"
@echo "config src: $(pdk_config_dir)/pdk_config.conf"
@echo "pdk templates: $(pdk_templates_dir)"

View File

@@ -1,4 +1,4 @@
Building the pdk Building the pdk (platform development kit)
1) get a cupcake source tree 1) get a cupcake source tree
@@ -54,9 +54,15 @@ Building the pdk
(which contains: (which contains:
DT=`date +%y%m%d-%H%M%S` DT=`date +%y%m%d-%H%M%S`
#time make -j4 PRODUCT-generic-eng pdk dist DIST_DIR=dist 2>&1 | tee logs/$DT time make -j4 pdk pdk_all dist DIST_DIR=dist 2>&1 | tee logs/$DT
time make -j4 pdk dist DIST_DIR=dist 2>&1 | tee logs/$DT
so you can see the results of the build in the logs directory.) so you can see the results of the build in the logs directory.)
5) the pdk tar file is put in the dist directory. 5) the pdk tar file is put in the dist directory.
The build target 'pdk' brings in the pdk/ndk make files into the build system.
Then there are three targets:
pdk_docs - which builds the pdk documentation
ndk - which builds the native development kit (native compiler, linker, etc.)
pdk_all - which builds the above two targets

View File

@@ -1,268 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Doxygen-Generated Content</title>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
.navigation {
display: none;
}
-->
</style>
</head>
<body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li class="current"><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
</div>
<h1>AudioHardwareInterface.h</h1><a href="_audio_hardware_interface_8h.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="comment">/*</span>
<a name="l00002"></a>00002 <span class="comment"> * Copyright (C) 2007 The Android Open Source Project</span>
<a name="l00003"></a>00003 <span class="comment"> *</span>
<a name="l00004"></a>00004 <span class="comment"> * Licensed under the Apache License, Version 2.0 (the "License");</span>
<a name="l00005"></a>00005 <span class="comment"> * you may not use this file except in compliance with the License.</span>
<a name="l00006"></a>00006 <span class="comment"> * You may obtain a copy of the License at</span>
<a name="l00007"></a>00007 <span class="comment"> *</span>
<a name="l00008"></a>00008 <span class="comment"> * http://www.apache.org/licenses/LICENSE-2.0</span>
<a name="l00009"></a>00009 <span class="comment"> *</span>
<a name="l00010"></a>00010 <span class="comment"> * Unless required by applicable law or agreed to in writing, software</span>
<a name="l00011"></a>00011 <span class="comment"> * distributed under the License is distributed on an "AS IS" BASIS,</span>
<a name="l00012"></a>00012 <span class="comment"> * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.</span>
<a name="l00013"></a>00013 <span class="comment"> * See the License for the specific language governing permissions and</span>
<a name="l00014"></a>00014 <span class="comment"> * limitations under the License.</span>
<a name="l00015"></a>00015 <span class="comment"> */</span>
<a name="l00016"></a>00016
<a name="l00017"></a>00017 <span class="preprocessor">#ifndef ANDROID_AUDIO_HARDWARE_INTERFACE_H</span>
<a name="l00018"></a>00018 <span class="preprocessor"></span><span class="preprocessor">#define ANDROID_AUDIO_HARDWARE_INTERFACE_H</span>
<a name="l00019"></a>00019 <span class="preprocessor"></span>
<a name="l00020"></a>00020 <span class="preprocessor">#include &lt;stdint.h&gt;</span>
<a name="l00021"></a>00021 <span class="preprocessor">#include &lt;sys/types.h&gt;</span>
<a name="l00022"></a>00022
<a name="l00023"></a>00023 <span class="preprocessor">#include &lt;utils/Errors.h&gt;</span>
<a name="l00024"></a>00024 <span class="preprocessor">#include &lt;utils/Vector.h&gt;</span>
<a name="l00025"></a>00025 <span class="preprocessor">#include &lt;utils/String16.h&gt;</span>
<a name="l00026"></a>00026
<a name="l00027"></a>00027 <span class="preprocessor">#include &lt;media/IAudioFlinger.h&gt;</span>
<a name="l00028"></a>00028 <span class="preprocessor">#include "media/AudioSystem.h"</span>
<a name="l00029"></a>00029
<a name="l00030"></a>00030
<a name="l00031"></a><a class="code" href="namespaceandroid.html">00031</a> <span class="keyword">namespace </span>android {
<a name="l00032"></a>00032
<a name="l00033"></a>00033 <span class="comment">// ----------------------------------------------------------------------------</span>
<a name="l00034"></a>00034 <span class="comment"></span>
<a name="l00035"></a>00035 <span class="comment">/**</span>
<a name="l00036"></a>00036 <span class="comment"> * AudioStreamOut is the abstraction interface for the audio output hardware.</span>
<a name="l00037"></a>00037 <span class="comment"> *</span>
<a name="l00038"></a>00038 <span class="comment"> * It provides information about various properties of the audio output hardware driver.</span>
<a name="l00039"></a>00039 <span class="comment"> */</span>
<a name="l00040"></a><a class="code" href="classandroid_1_1_audio_stream_out.html">00040</a> <span class="keyword">class </span><a class="code" href="classandroid_1_1_audio_stream_out.html" title="AudioStreamOut is the abstraction interface for the audio output hardware.">AudioStreamOut</a> {
<a name="l00041"></a>00041 <span class="keyword">public</span>:
<a name="l00042"></a>00042 <span class="keyword">virtual</span> <a class="code" href="classandroid_1_1_audio_stream_out.html#09074dbae95b82d4f83c513035a0034f">~AudioStreamOut</a>() = 0;
<a name="l00043"></a>00043 <span class="comment"></span>
<a name="l00044"></a>00044 <span class="comment"> /** return audio sampling rate in hz - eg. 44100 */</span>
<a name="l00045"></a>00045 <span class="keyword">virtual</span> uint32_t <a class="code" href="classandroid_1_1_audio_stream_out.html#6bb028e125d13289f26d3d74f851c921" title="return audio sampling rate in hz - eg.">sampleRate</a>() <span class="keyword">const</span> = 0;
<a name="l00046"></a>00046 <span class="comment"></span>
<a name="l00047"></a>00047 <span class="comment"> /** returns size of output buffer - eg. 4800 */</span>
<a name="l00048"></a>00048 <span class="keyword">virtual</span> <span class="keywordtype">size_t</span> <a class="code" href="classandroid_1_1_audio_stream_out.html#7b3c5f2ce79b9b6f167408f63d19af0a" title="returns size of output buffer - eg.">bufferSize</a>() <span class="keyword">const</span> = 0;
<a name="l00049"></a>00049 <span class="comment"></span>
<a name="l00050"></a>00050 <span class="comment"> /**</span>
<a name="l00051"></a>00051 <span class="comment"> * return number of output audio channels.</span>
<a name="l00052"></a>00052 <span class="comment"> * Acceptable values are 1 (mono) or 2 (stereo)</span>
<a name="l00053"></a>00053 <span class="comment"> */</span>
<a name="l00054"></a>00054 <span class="keyword">virtual</span> <span class="keywordtype">int</span> <a class="code" href="classandroid_1_1_audio_stream_out.html#4e880a5379c168e8f68c26827e41275b" title="return number of output audio channels.">channelCount</a>() <span class="keyword">const</span> = 0;
<a name="l00055"></a>00055 <span class="comment"></span>
<a name="l00056"></a>00056 <span class="comment"> /**</span>
<a name="l00057"></a>00057 <span class="comment"> * return audio format in 8bit or 16bit PCM format -</span>
<a name="l00058"></a>00058 <span class="comment"> * eg. AudioSystem:PCM_16_BIT</span>
<a name="l00059"></a>00059 <span class="comment"> */</span>
<a name="l00060"></a>00060 <span class="keyword">virtual</span> <span class="keywordtype">int</span> <a class="code" href="classandroid_1_1_audio_stream_out.html#eb2b430bbff4eebd8fb8590507b1dce1" title="return audio format in 8bit or 16bit PCM format - eg.">format</a>() <span class="keyword">const</span> = 0;
<a name="l00061"></a>00061 <span class="comment"></span>
<a name="l00062"></a>00062 <span class="comment"> /**</span>
<a name="l00063"></a>00063 <span class="comment"> * return the frame size (number of bytes per sample).</span>
<a name="l00064"></a>00064 <span class="comment"> */</span>
<a name="l00065"></a><a class="code" href="classandroid_1_1_audio_stream_out.html#66b7c4bb510db4060adfd03a376897d8">00065</a> uint32_t <a class="code" href="classandroid_1_1_audio_stream_out.html#66b7c4bb510db4060adfd03a376897d8" title="return the frame size (number of bytes per sample).">frameSize</a>()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> <a class="code" href="classandroid_1_1_audio_stream_out.html#4e880a5379c168e8f68c26827e41275b" title="return number of output audio channels.">channelCount</a>()*((<a class="code" href="classandroid_1_1_audio_stream_out.html#eb2b430bbff4eebd8fb8590507b1dce1" title="return audio format in 8bit or 16bit PCM format - eg.">format</a>()==AudioSystem::PCM_16_BIT)?<span class="keyword">sizeof</span>(int16_t):<span class="keyword">sizeof</span>(int8_t)); }
<a name="l00066"></a>00066 <span class="comment"></span>
<a name="l00067"></a>00067 <span class="comment"> /**</span>
<a name="l00068"></a>00068 <span class="comment"> * return the audio hardware driver latency in milli seconds.</span>
<a name="l00069"></a>00069 <span class="comment"> */</span>
<a name="l00070"></a>00070 <span class="keyword">virtual</span> uint32_t <a class="code" href="classandroid_1_1_audio_stream_out.html#c698a3d95cf0829dcfe283cd5ea437cb" title="return the audio hardware driver latency in milli seconds.">latency</a>() <span class="keyword">const</span> = 0;
<a name="l00071"></a>00071 <span class="comment"></span>
<a name="l00072"></a>00072 <span class="comment"> /**</span>
<a name="l00073"></a>00073 <span class="comment"> * Use this method in situations where audio mixing is done in the</span>
<a name="l00074"></a>00074 <span class="comment"> * hardware. This method serves as a direct interface with hardware,</span>
<a name="l00075"></a>00075 <span class="comment"> * allowing you to directly set the volume as apposed to via the framework.</span>
<a name="l00076"></a>00076 <span class="comment"> * This method might produce multiple PCM outputs or hardware accelerated</span>
<a name="l00077"></a>00077 <span class="comment"> * codecs, such as MP3 or AAC.</span>
<a name="l00078"></a>00078 <span class="comment"> */</span>
<a name="l00079"></a>00079 <span class="keyword">virtual</span> status_t <a class="code" href="classandroid_1_1_audio_stream_out.html#e6d301925d193c25561b42239c7f44b6" title="Use this method in situations where audio mixing is done in the hardware.">setVolume</a>(<span class="keywordtype">float</span> volume) = 0;
<a name="l00080"></a>00080 <span class="comment"></span>
<a name="l00081"></a>00081 <span class="comment"> /** write audio buffer to driver. Returns number of bytes written */</span>
<a name="l00082"></a>00082 <span class="keyword">virtual</span> ssize_t <a class="code" href="classandroid_1_1_audio_stream_out.html#cba177e4a4a35a87ab9f8aa2a9c0e78e" title="write audio buffer to driver.">write</a>(<span class="keyword">const</span> <span class="keywordtype">void</span>* buffer, <span class="keywordtype">size_t</span> bytes) = 0;
<a name="l00083"></a>00083 <span class="comment"></span>
<a name="l00084"></a>00084 <span class="comment"> /** dump the state of the audio output device */</span>
<a name="l00085"></a>00085 <span class="keyword">virtual</span> status_t <a class="code" href="classandroid_1_1_audio_stream_out.html#97e3cc4610ba40d6c37b3d376a032b98" title="dump the state of the audio output device">dump</a>(<span class="keywordtype">int</span> fd, <span class="keyword">const</span> Vector&lt;String16&gt;&amp; args) = 0;
<a name="l00086"></a>00086 };
<a name="l00087"></a>00087 <span class="comment"></span>
<a name="l00088"></a>00088 <span class="comment">/**</span>
<a name="l00089"></a>00089 <span class="comment"> * AudioStreamIn is the abstraction interface for the audio input hardware.</span>
<a name="l00090"></a>00090 <span class="comment"> *</span>
<a name="l00091"></a>00091 <span class="comment"> * It defines the various properties of the audio hardware input driver.</span>
<a name="l00092"></a>00092 <span class="comment"> */</span>
<a name="l00093"></a><a class="code" href="classandroid_1_1_audio_stream_in.html">00093</a> <span class="keyword">class </span><a class="code" href="classandroid_1_1_audio_stream_in.html" title="AudioStreamIn is the abstraction interface for the audio input hardware.">AudioStreamIn</a> {
<a name="l00094"></a>00094 <span class="keyword">public</span>:
<a name="l00095"></a>00095 <span class="keyword">virtual</span> <a class="code" href="classandroid_1_1_audio_stream_in.html#72067577568bbdd0163c1369fe80f101">~AudioStreamIn</a>() = 0;
<a name="l00096"></a>00096 <span class="comment"></span>
<a name="l00097"></a>00097 <span class="comment"> /** return the input buffer size allowed by audio driver */</span>
<a name="l00098"></a>00098 <span class="keyword">virtual</span> <span class="keywordtype">size_t</span> <a class="code" href="classandroid_1_1_audio_stream_in.html#a458f9cde3edde82f256af7eaa7b2ddf" title="return the input buffer size allowed by audio driver">bufferSize</a>() <span class="keyword">const</span> = 0;
<a name="l00099"></a>00099 <span class="comment"></span>
<a name="l00100"></a>00100 <span class="comment"> /** return the number of audio input channels */</span>
<a name="l00101"></a>00101 <span class="keyword">virtual</span> <span class="keywordtype">int</span> <a class="code" href="classandroid_1_1_audio_stream_in.html#04f84006dd5f2e0a5e512897a039f851" title="return the number of audio input channels">channelCount</a>() <span class="keyword">const</span> = 0;
<a name="l00102"></a>00102 <span class="comment"></span>
<a name="l00103"></a>00103 <span class="comment"> /**</span>
<a name="l00104"></a>00104 <span class="comment"> * return audio format in 8bit or 16bit PCM format -</span>
<a name="l00105"></a>00105 <span class="comment"> * eg. AudioSystem:PCM_16_BIT</span>
<a name="l00106"></a>00106 <span class="comment"> */</span>
<a name="l00107"></a>00107 <span class="keyword">virtual</span> <span class="keywordtype">int</span> <a class="code" href="classandroid_1_1_audio_stream_in.html#4ade98c5243b9ed5f3a71a8f36e74b36" title="return audio format in 8bit or 16bit PCM format - eg.">format</a>() <span class="keyword">const</span> = 0;
<a name="l00108"></a>00108 <span class="comment"></span>
<a name="l00109"></a>00109 <span class="comment"> /**</span>
<a name="l00110"></a>00110 <span class="comment"> * return the frame size (number of bytes per sample).</span>
<a name="l00111"></a>00111 <span class="comment"> */</span>
<a name="l00112"></a><a class="code" href="classandroid_1_1_audio_stream_in.html#43d2c6b97806c005f0717a7bb6f7595c">00112</a> uint32_t <a class="code" href="classandroid_1_1_audio_stream_in.html#43d2c6b97806c005f0717a7bb6f7595c" title="return the frame size (number of bytes per sample).">frameSize</a>()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> <a class="code" href="classandroid_1_1_audio_stream_in.html#04f84006dd5f2e0a5e512897a039f851" title="return the number of audio input channels">channelCount</a>()*((<a class="code" href="classandroid_1_1_audio_stream_in.html#4ade98c5243b9ed5f3a71a8f36e74b36" title="return audio format in 8bit or 16bit PCM format - eg.">format</a>()==AudioSystem::PCM_16_BIT)?<span class="keyword">sizeof</span>(int16_t):<span class="keyword">sizeof</span>(int8_t)); }
<a name="l00113"></a>00113 <span class="comment"></span>
<a name="l00114"></a>00114 <span class="comment"> /** set the input gain for the audio driver. This method is for</span>
<a name="l00115"></a>00115 <span class="comment"> * for future use */</span>
<a name="l00116"></a>00116 <span class="keyword">virtual</span> status_t <a class="code" href="classandroid_1_1_audio_stream_in.html#339822afb3f2f2ac1b4c775d31d12440" title="set the input gain for the audio driver.">setGain</a>(<span class="keywordtype">float</span> gain) = 0;
<a name="l00117"></a>00117 <span class="comment"></span>
<a name="l00118"></a>00118 <span class="comment"> /** read audio buffer in from audio driver */</span>
<a name="l00119"></a>00119 <span class="keyword">virtual</span> ssize_t <a class="code" href="classandroid_1_1_audio_stream_in.html#7c313cbfbb47dafd90f3225bcd26e592" title="read audio buffer in from audio driver">read</a>(<span class="keywordtype">void</span>* buffer, ssize_t bytes) = 0;
<a name="l00120"></a>00120 <span class="comment"></span>
<a name="l00121"></a>00121 <span class="comment"> /** dump the state of the audio input device */</span>
<a name="l00122"></a>00122 <span class="keyword">virtual</span> status_t <a class="code" href="classandroid_1_1_audio_stream_in.html#18c3760208bfb99498715a0d4977f675" title="dump the state of the audio input device">dump</a>(<span class="keywordtype">int</span> fd, <span class="keyword">const</span> Vector&lt;String16&gt;&amp; args) = 0;
<a name="l00123"></a>00123 <span class="comment"></span>
<a name="l00124"></a>00124 <span class="comment"> /**</span>
<a name="l00125"></a>00125 <span class="comment"> * Put the audio hardware input into standby mode. Returns</span>
<a name="l00126"></a>00126 <span class="comment"> * status based on include/utils/Errors.h</span>
<a name="l00127"></a>00127 <span class="comment"> */</span>
<a name="l00128"></a>00128 <span class="keyword">virtual</span> status_t <a class="code" href="classandroid_1_1_audio_stream_in.html#93fab46e8afdbaedd4d20cc6ee2b7c41" title="Put the audio hardware input into standby mode.">standby</a>() = 0;
<a name="l00129"></a>00129
<a name="l00130"></a>00130 };
<a name="l00131"></a>00131 <span class="comment"></span>
<a name="l00132"></a>00132 <span class="comment">/**</span>
<a name="l00133"></a>00133 <span class="comment"> * AudioHardwareInterface.h defines the interface to the audio hardware abstraction layer.</span>
<a name="l00134"></a>00134 <span class="comment"> *</span>
<a name="l00135"></a>00135 <span class="comment"> * The interface supports setting and getting parameters, selecting audio routing</span>
<a name="l00136"></a>00136 <span class="comment"> * paths, and defining input and output streams.</span>
<a name="l00137"></a>00137 <span class="comment"> *</span>
<a name="l00138"></a>00138 <span class="comment"> * AudioFlinger initializes the audio hardware and immediately opens an output stream.</span>
<a name="l00139"></a>00139 <span class="comment"> * You can set Audio routing to output to handset, speaker, Bluetooth, or a headset.</span>
<a name="l00140"></a>00140 <span class="comment"> *</span>
<a name="l00141"></a>00141 <span class="comment"> * The audio input stream is initialized when AudioFlinger is called to carry out</span>
<a name="l00142"></a>00142 <span class="comment"> * a record operation.</span>
<a name="l00143"></a>00143 <span class="comment"> */</span>
<a name="l00144"></a><a class="code" href="classandroid_1_1_audio_hardware_interface.html">00144</a> <span class="keyword">class </span><a class="code" href="classandroid_1_1_audio_hardware_interface.html" title="AudioHardwareInterface.h defines the interface to the audio hardware abstraction...">AudioHardwareInterface</a>
<a name="l00145"></a>00145 {
<a name="l00146"></a>00146 <span class="keyword">public</span>:<span class="comment"></span>
<a name="l00147"></a>00147 <span class="comment"> /**</span>
<a name="l00148"></a>00148 <span class="comment"> * check to see if the audio hardware interface has been initialized.</span>
<a name="l00149"></a>00149 <span class="comment"> * return status based on values defined in include/utils/Errors.h</span>
<a name="l00150"></a>00150 <span class="comment"> */</span>
<a name="l00151"></a>00151 <span class="keyword">virtual</span> status_t <a class="code" href="classandroid_1_1_audio_hardware_interface.html#b7e19e09fa6cbc07c127122fa9866c50" title="check to see if the audio hardware interface has been initialized.">initCheck</a>() = 0;
<a name="l00152"></a>00152 <span class="comment"></span>
<a name="l00153"></a>00153 <span class="comment"> /**</span>
<a name="l00154"></a>00154 <span class="comment"> * put the audio hardware into standby mode to conserve power. Returns</span>
<a name="l00155"></a>00155 <span class="comment"> * status based on include/utils/Errors.h</span>
<a name="l00156"></a>00156 <span class="comment"> */</span>
<a name="l00157"></a>00157 <span class="keyword">virtual</span> status_t <a class="code" href="classandroid_1_1_audio_hardware_interface.html#61121d365bb4d182bdec2c1b12fb1178" title="put the audio hardware into standby mode to conserve power.">standby</a>() = 0;
<a name="l00158"></a>00158 <span class="comment"></span>
<a name="l00159"></a>00159 <span class="comment"> /** set the audio volume of a voice call. Range is between 0.0 and 1.0 */</span>
<a name="l00160"></a>00160 <span class="keyword">virtual</span> status_t <a class="code" href="classandroid_1_1_audio_hardware_interface.html#7b7418072df1eeaacc89cd0c725755f6" title="set the audio volume of a voice call.">setVoiceVolume</a>(<span class="keywordtype">float</span> volume) = 0;
<a name="l00161"></a>00161 <span class="comment"></span>
<a name="l00162"></a>00162 <span class="comment"> /**</span>
<a name="l00163"></a>00163 <span class="comment"> * set the audio volume for all audio activities other than voice call.</span>
<a name="l00164"></a>00164 <span class="comment"> * Range between 0.0 and 1.0. If any value other than NO_ERROR is returned,</span>
<a name="l00165"></a>00165 <span class="comment"> * the software mixer will emulate this capability.</span>
<a name="l00166"></a>00166 <span class="comment"> */</span>
<a name="l00167"></a>00167 <span class="keyword">virtual</span> status_t <a class="code" href="classandroid_1_1_audio_hardware_interface.html#925092e556eb89f304bcebb09f90c9a3" title="set the audio volume for all audio activities other than voice call.">setMasterVolume</a>(<span class="keywordtype">float</span> volume) = 0;
<a name="l00168"></a>00168 <span class="comment"></span>
<a name="l00169"></a>00169 <span class="comment"> /**</span>
<a name="l00170"></a>00170 <span class="comment"> * Audio routing methods. Routes defined in include/hardware/AudioSystem.h.</span>
<a name="l00171"></a>00171 <span class="comment"> * Audio routes can be (ROUTE_EARPIECE | ROUTE_SPEAKER | ROUTE_BLUETOOTH</span>
<a name="l00172"></a>00172 <span class="comment"> * | ROUTE_HEADSET)</span>
<a name="l00173"></a>00173 <span class="comment"> *</span>
<a name="l00174"></a>00174 <span class="comment"> * setRouting sets the routes for a mode. This is called at startup. It is</span>
<a name="l00175"></a>00175 <span class="comment"> * also called when a new device is connected, such as a wired headset is</span>
<a name="l00176"></a>00176 <span class="comment"> * plugged in or a Bluetooth headset is paired.</span>
<a name="l00177"></a>00177 <span class="comment"> */</span>
<a name="l00178"></a>00178 <span class="keyword">virtual</span> status_t <a class="code" href="classandroid_1_1_audio_hardware_interface.html#39b2690e19219425b8cff093ef83bfb1" title="Audio routing methods.">setRouting</a>(<span class="keywordtype">int</span> mode, uint32_t routes) = 0;
<a name="l00179"></a>00179
<a name="l00180"></a>00180 <span class="keyword">virtual</span> status_t <a class="code" href="classandroid_1_1_audio_hardware_interface.html#1886de8fff2342ae628dbbbc0c45ba83">getRouting</a>(<span class="keywordtype">int</span> mode, uint32_t* routes) = 0;
<a name="l00181"></a>00181 <span class="comment"></span>
<a name="l00182"></a>00182 <span class="comment"> /**</span>
<a name="l00183"></a>00183 <span class="comment"> * setMode is called when the audio mode changes. NORMAL mode is for</span>
<a name="l00184"></a>00184 <span class="comment"> * standard audio playback, RINGTONE when a ringtone is playing, and IN_CALL</span>
<a name="l00185"></a>00185 <span class="comment"> * when a call is in progress.</span>
<a name="l00186"></a>00186 <span class="comment"> */</span>
<a name="l00187"></a>00187 <span class="keyword">virtual</span> status_t <a class="code" href="classandroid_1_1_audio_hardware_interface.html#aaf2a429c240f00b21836794849b430f" title="setMode is called when the audio mode changes.">setMode</a>(<span class="keywordtype">int</span> mode) = 0;
<a name="l00188"></a>00188 <span class="keyword">virtual</span> status_t <a class="code" href="classandroid_1_1_audio_hardware_interface.html#8466c76328a51b8a83da103032abba55">getMode</a>(<span class="keywordtype">int</span>* mode) = 0;
<a name="l00189"></a>00189
<a name="l00190"></a>00190 <span class="comment">// mic mute</span>
<a name="l00191"></a>00191 <span class="keyword">virtual</span> status_t <a class="code" href="classandroid_1_1_audio_hardware_interface.html#be35b7cb738531939a3ac9abc5514621">setMicMute</a>(<span class="keywordtype">bool</span> state) = 0;
<a name="l00192"></a>00192 <span class="keyword">virtual</span> status_t <a class="code" href="classandroid_1_1_audio_hardware_interface.html#15d3c33d7e3f965dc2588c537f05a133">getMicMute</a>(<span class="keywordtype">bool</span>* state) = 0;
<a name="l00193"></a>00193
<a name="l00194"></a>00194 <span class="comment">// Temporary interface, do not use</span>
<a name="l00195"></a>00195 <span class="comment">// TODO: Replace with a more generic key:value get/set mechanism</span>
<a name="l00196"></a>00196 <span class="keyword">virtual</span> status_t <a class="code" href="classandroid_1_1_audio_hardware_interface.html#a1b477901df48b3a27103a77e6bb39c8">setParameter</a>(<span class="keyword">const</span> <span class="keywordtype">char</span>* key, <span class="keyword">const</span> <span class="keywordtype">char</span>* value) = 0;
<a name="l00197"></a>00197
<a name="l00198"></a>00198 <span class="comment">// Returns audio input buffer size according to parameters passed or 0 if one of the</span>
<a name="l00199"></a>00199 <span class="comment">// parameters is not supported</span>
<a name="l00200"></a>00200 <span class="keyword">virtual</span> <span class="keywordtype">size_t</span> <a class="code" href="classandroid_1_1_audio_hardware_interface.html#19f68d873b2a6e4c00c017c580170395">getInputBufferSize</a>(uint32_t sampleRate, <span class="keywordtype">int</span> format, <span class="keywordtype">int</span> channelCount) = 0;
<a name="l00201"></a>00201 <span class="comment"></span>
<a name="l00202"></a>00202 <span class="comment"> /** This method creates and opens the audio hardware output stream */</span>
<a name="l00203"></a>00203 <span class="keyword">virtual</span> <a class="code" href="classandroid_1_1_audio_stream_out.html" title="AudioStreamOut is the abstraction interface for the audio output hardware.">AudioStreamOut</a>* <a class="code" href="classandroid_1_1_audio_hardware_interface.html#eda0986e145c8dd68d21cb79051f94f9" title="This method creates and opens the audio hardware output stream.">openOutputStream</a>(
<a name="l00204"></a>00204 <span class="keywordtype">int</span> format=0,
<a name="l00205"></a>00205 <span class="keywordtype">int</span> channelCount=0,
<a name="l00206"></a>00206 uint32_t sampleRate=0,
<a name="l00207"></a>00207 status_t *status=0) = 0;
<a name="l00208"></a>00208 <span class="comment"></span>
<a name="l00209"></a>00209 <span class="comment"> /** This method creates and opens the audio hardware input stream */</span>
<a name="l00210"></a>00210 <span class="keyword">virtual</span> <a class="code" href="classandroid_1_1_audio_stream_in.html" title="AudioStreamIn is the abstraction interface for the audio input hardware.">AudioStreamIn</a>* <a class="code" href="classandroid_1_1_audio_hardware_interface.html#efb777d192fcbcd65458fa4f2d976476" title="This method creates and opens the audio hardware input stream.">openInputStream</a>(
<a name="l00211"></a>00211 <span class="keywordtype">int</span> format,
<a name="l00212"></a>00212 <span class="keywordtype">int</span> channelCount,
<a name="l00213"></a>00213 uint32_t sampleRate,
<a name="l00214"></a>00214 status_t *status) = 0;
<a name="l00215"></a>00215 <span class="comment"></span>
<a name="l00216"></a>00216 <span class="comment"> /**This method dumps the state of the audio hardware */</span>
<a name="l00217"></a>00217 <span class="keyword">virtual</span> status_t <a class="code" href="classandroid_1_1_audio_hardware_interface.html#05f035af60e67a22251175b44a089f69" title="This method dumps the state of the audio hardware.">dumpState</a>(<span class="keywordtype">int</span> fd, <span class="keyword">const</span> Vector&lt;String16&gt;&amp; args) = 0;
<a name="l00218"></a>00218
<a name="l00219"></a>00219 <span class="keyword">static</span> <a class="code" href="classandroid_1_1_audio_hardware_interface.html" title="AudioHardwareInterface.h defines the interface to the audio hardware abstraction...">AudioHardwareInterface</a>* <a class="code" href="classandroid_1_1_audio_hardware_interface.html#aa5ae45e9ad969fefc494e103cf5068d">create</a>();
<a name="l00220"></a>00220
<a name="l00221"></a>00221 <span class="keyword">protected</span>:<span class="comment"></span>
<a name="l00222"></a>00222 <span class="comment"> /**</span>
<a name="l00223"></a>00223 <span class="comment"> * doRouting actually initiates the routing. A call to setRouting</span>
<a name="l00224"></a>00224 <span class="comment"> * or setMode may result in a routing change. The generic logic calls</span>
<a name="l00225"></a>00225 <span class="comment"> * doRouting when required. If the device has any special requirements these</span>
<a name="l00226"></a>00226 <span class="comment"> * methods can be overriden.</span>
<a name="l00227"></a>00227 <span class="comment"> */</span>
<a name="l00228"></a>00228 <span class="keyword">virtual</span> status_t <a class="code" href="classandroid_1_1_audio_hardware_interface.html#d82c3e4827f275abf28eb872e8751e1f" title="doRouting actually initiates the routing.">doRouting</a>() = 0;
<a name="l00229"></a>00229
<a name="l00230"></a>00230 <span class="keyword">virtual</span> status_t <a class="code" href="classandroid_1_1_audio_hardware_interface.html#371f198a416cb726804e0f47e8763217">dump</a>(<span class="keywordtype">int</span> fd, <span class="keyword">const</span> Vector&lt;String16&gt;&amp; args) = 0;
<a name="l00231"></a>00231 };
<a name="l00232"></a>00232
<a name="l00233"></a>00233 <span class="comment">// ----------------------------------------------------------------------------</span>
<a name="l00234"></a>00234
<a name="l00235"></a>00235 <span class="keyword">extern</span> <span class="stringliteral">"C"</span> <a class="code" href="classandroid_1_1_audio_hardware_interface.html" title="AudioHardwareInterface.h defines the interface to the audio hardware abstraction...">AudioHardwareInterface</a>* <a class="code" href="namespaceandroid.html#dcc80314ddffcb0981a9e9c5468662f8">createAudioHardware</a>(<span class="keywordtype">void</span>);
<a name="l00236"></a>00236
<a name="l00237"></a>00237 }; <span class="comment">// namespace android</span>
<a name="l00238"></a>00238
<a name="l00239"></a>00239 <span class="preprocessor">#endif // ANDROID_AUDIO_HARDWARE_INTERFACE_H</span>
</pre></div></div>
</body>
</html>

View File

@@ -1,51 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Doxygen-Generated Content</title>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
.navigation {
display: none;
}
-->
</style>
</head>
<body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li class="current"><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
</div>
<div class="contents">
<h1>AudioHardwareInterface.h File Reference</h1>
<p>
<a href="_audio_hardware_interface_8h-source.html">Go to the source code of this file.</a><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Namespaces</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">namespace &nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceandroid.html">android</a></td></tr>
<tr><td colspan="2"><br><h2>Data Structures</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">class &nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_stream_out.html">android::AudioStreamOut</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight"><a class="el" href="classandroid_1_1_audio_stream_out.html" title="AudioStreamOut is the abstraction interface for the audio output hardware.">AudioStreamOut</a> is the abstraction interface for the audio output hardware. <a href="classandroid_1_1_audio_stream_out.html#_details">More...</a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">class &nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_stream_in.html">android::AudioStreamIn</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight"><a class="el" href="classandroid_1_1_audio_stream_in.html" title="AudioStreamIn is the abstraction interface for the audio input hardware.">AudioStreamIn</a> is the abstraction interface for the audio input hardware. <a href="classandroid_1_1_audio_stream_in.html#_details">More...</a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">class &nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_hardware_interface.html">android::AudioHardwareInterface</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight"><a class="el" href="_audio_hardware_interface_8h.html">AudioHardwareInterface.h</a> defines the interface to the audio hardware abstraction layer. <a href="classandroid_1_1_audio_hardware_interface.html#_details">More...</a><br></td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">AudioHardwareInterface *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceandroid.html#dcc80314ddffcb0981a9e9c5468662f8">android::createAudioHardware</a> (void)</td></tr>
</table>
</div>
</body>
</html>

View File

@@ -1,179 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Doxygen-Generated Content</title>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
.navigation {
display: none;
}
-->
</style>
</head>
<body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li class="current"><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
</div>
<h1>CameraHardwareInterface.h</h1><a href="_camera_hardware_interface_8h.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="comment">/*</span>
<a name="l00002"></a>00002 <span class="comment"> * Copyright (C) 2008 The Android Open Source Project</span>
<a name="l00003"></a>00003 <span class="comment"> *</span>
<a name="l00004"></a>00004 <span class="comment"> * Licensed under the Apache License, Version 2.0 (the "License");</span>
<a name="l00005"></a>00005 <span class="comment"> * you may not use this file except in compliance with the License.</span>
<a name="l00006"></a>00006 <span class="comment"> * You may obtain a copy of the License at</span>
<a name="l00007"></a>00007 <span class="comment"> *</span>
<a name="l00008"></a>00008 <span class="comment"> * http://www.apache.org/licenses/LICENSE-2.0</span>
<a name="l00009"></a>00009 <span class="comment"> *</span>
<a name="l00010"></a>00010 <span class="comment"> * Unless required by applicable law or agreed to in writing, software</span>
<a name="l00011"></a>00011 <span class="comment"> * distributed under the License is distributed on an "AS IS" BASIS,</span>
<a name="l00012"></a>00012 <span class="comment"> * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.</span>
<a name="l00013"></a>00013 <span class="comment"> * See the License for the specific language governing permissions and</span>
<a name="l00014"></a>00014 <span class="comment"> * limitations under the License.</span>
<a name="l00015"></a>00015 <span class="comment"> */</span>
<a name="l00016"></a>00016
<a name="l00017"></a>00017 <span class="preprocessor">#ifndef ANDROID_HARDWARE_CAMERA_HARDWARE_INTERFACE_H</span>
<a name="l00018"></a>00018 <span class="preprocessor"></span><span class="preprocessor">#define ANDROID_HARDWARE_CAMERA_HARDWARE_INTERFACE_H</span>
<a name="l00019"></a>00019 <span class="preprocessor"></span>
<a name="l00020"></a>00020 <span class="preprocessor">#include &lt;utils/IMemory.h&gt;</span>
<a name="l00021"></a>00021 <span class="preprocessor">#include &lt;utils/RefBase.h&gt;</span>
<a name="l00022"></a>00022 <span class="preprocessor">#include &lt;ui/CameraParameters.h&gt;</span>
<a name="l00023"></a>00023
<a name="l00024"></a>00024 <span class="keyword">namespace </span>android {
<a name="l00025"></a>00025 <span class="comment"></span>
<a name="l00026"></a>00026 <span class="comment">/** Callback for startPreview() */</span>
<a name="l00027"></a><a class="code" href="namespaceandroid.html#d32b08663d42356404e2eb971e271636">00027</a> <span class="keyword">typedef</span> void (*<a class="code" href="namespaceandroid.html#d32b08663d42356404e2eb971e271636" title="Callback for startPreview().">preview_callback</a>)(<span class="keyword">const</span> sp&lt;IMemory&gt;&amp; mem, <span class="keywordtype">void</span>* user);
<a name="l00028"></a>00028 <span class="comment"></span>
<a name="l00029"></a>00029 <span class="comment">/** Callback for takePicture() */</span>
<a name="l00030"></a><a class="code" href="namespaceandroid.html#04c83209c2627e2d303320712ca9ee65">00030</a> <span class="keyword">typedef</span> void (*<a class="code" href="namespaceandroid.html#04c83209c2627e2d303320712ca9ee65" title="Callback for takePicture().">shutter_callback</a>)(<span class="keywordtype">void</span>* user);
<a name="l00031"></a>00031 <span class="comment"></span>
<a name="l00032"></a>00032 <span class="comment">/** Callback for takePicture() */</span>
<a name="l00033"></a><a class="code" href="namespaceandroid.html#a97926709e452d66360cb9b24736969e">00033</a> <span class="keyword">typedef</span> void (*<a class="code" href="namespaceandroid.html#a97926709e452d66360cb9b24736969e" title="Callback for takePicture().">raw_callback</a>)(<span class="keyword">const</span> sp&lt;IMemory&gt;&amp; mem, <span class="keywordtype">void</span>* user);
<a name="l00034"></a>00034 <span class="comment"></span>
<a name="l00035"></a>00035 <span class="comment">/** Callback for takePicture() */</span>
<a name="l00036"></a><a class="code" href="namespaceandroid.html#c21980d4be1e0cc458399ecf5374d473">00036</a> <span class="keyword">typedef</span> void (*<a class="code" href="namespaceandroid.html#c21980d4be1e0cc458399ecf5374d473" title="Callback for takePicture().">jpeg_callback</a>)(<span class="keyword">const</span> sp&lt;IMemory&gt;&amp; mem, <span class="keywordtype">void</span>* user);
<a name="l00037"></a>00037 <span class="comment"></span>
<a name="l00038"></a>00038 <span class="comment">/** Callback for autoFocus() */</span>
<a name="l00039"></a><a class="code" href="namespaceandroid.html#4dca8d8b824ca9a684358133da0ec8f2">00039</a> <span class="keyword">typedef</span> void (*<a class="code" href="namespaceandroid.html#4dca8d8b824ca9a684358133da0ec8f2" title="Callback for autoFocus().">autofocus_callback</a>)(<span class="keywordtype">bool</span> focused, <span class="keywordtype">void</span>* user);
<a name="l00040"></a>00040 <span class="comment"></span>
<a name="l00041"></a>00041 <span class="comment">/**</span>
<a name="l00042"></a>00042 <span class="comment"> * CameraHardwareInterface.h defines the interface to the</span>
<a name="l00043"></a>00043 <span class="comment"> * camera hardware abstraction layer, used for setting and getting</span>
<a name="l00044"></a>00044 <span class="comment"> * parameters, live previewing, and taking pictures.</span>
<a name="l00045"></a>00045 <span class="comment"> *</span>
<a name="l00046"></a>00046 <span class="comment"> * It is a referenced counted interface with RefBase as its base class.</span>
<a name="l00047"></a>00047 <span class="comment"> * CameraService calls openCameraHardware() to retrieve a strong pointer to the</span>
<a name="l00048"></a>00048 <span class="comment"> * instance of this interface and may be called multiple times. The</span>
<a name="l00049"></a>00049 <span class="comment"> * following steps describe a typical sequence:</span>
<a name="l00050"></a>00050 <span class="comment"> *</span>
<a name="l00051"></a>00051 <span class="comment"> * -# After CameraService calls openCameraHardware(), getParameters() and</span>
<a name="l00052"></a>00052 <span class="comment"> * setParameters() are used to initialize the camera instance.</span>
<a name="l00053"></a>00053 <span class="comment"> * CameraService calls getPreviewHeap() to establish access to the</span>
<a name="l00054"></a>00054 <span class="comment"> * preview heap so it can be registered with SurfaceFlinger for</span>
<a name="l00055"></a>00055 <span class="comment"> * efficient display updating while in preview mode.</span>
<a name="l00056"></a>00056 <span class="comment"> * -# startPreview() is called, which is passed a preview_callback()</span>
<a name="l00057"></a>00057 <span class="comment"> * function and a user parameter. The camera instance then periodically</span>
<a name="l00058"></a>00058 <span class="comment"> * calls preview_callback() each time a new preview frame is available.</span>
<a name="l00059"></a>00059 <span class="comment"> * The callback routine has two parameters: the first is a pointer to</span>
<a name="l00060"></a>00060 <span class="comment"> * the IMemory containing the frame and the second a user parameter. If</span>
<a name="l00061"></a>00061 <span class="comment"> * the preview_callback code needs to use this memory after returning,</span>
<a name="l00062"></a>00062 <span class="comment"> * it must copy the data.</span>
<a name="l00063"></a>00063 <span class="comment"> *</span>
<a name="l00064"></a>00064 <span class="comment"> * Prior to taking a picture, CameraService calls autofocus() with</span>
<a name="l00065"></a>00065 <span class="comment"> * autofocus_callback() and a user parameter. When auto focusing has</span>
<a name="l00066"></a>00066 <span class="comment"> * completed, the camera instance calls autofocus_callback(), which informs</span>
<a name="l00067"></a>00067 <span class="comment"> * the application whether focusing was successful. The camera instance</span>
<a name="l00068"></a>00068 <span class="comment"> * only calls autofocus_callback() once and it is up to the application to</span>
<a name="l00069"></a>00069 <span class="comment"> * call autoFocus() again if refocusing is desired.</span>
<a name="l00070"></a>00070 <span class="comment"> *</span>
<a name="l00071"></a>00071 <span class="comment"> * CameraService calls takePicture() to request the camera instance take a</span>
<a name="l00072"></a>00072 <span class="comment"> * picture. This method has two callbacks: raw_callback() and jpeg_callback().</span>
<a name="l00073"></a>00073 <span class="comment"> * When the raw image is available, raw_callback() is called with a pointer</span>
<a name="l00074"></a>00074 <span class="comment"> * to the IMemory containing the raw image. When the jpeg image is available,</span>
<a name="l00075"></a>00075 <span class="comment"> * jpeg_callback() is called with a pointer to the IMemory containing the</span>
<a name="l00076"></a>00076 <span class="comment"> * jpeg image. As with preview_callback(), the memory must be copied if it's</span>
<a name="l00077"></a>00077 <span class="comment"> * needed after returning.</span>
<a name="l00078"></a>00078 <span class="comment"> */</span>
<a name="l00079"></a><a class="code" href="classandroid_1_1_camera_hardware_interface.html">00079</a> <span class="keyword">class </span><a class="code" href="classandroid_1_1_camera_hardware_interface.html" title="CameraHardwareInterface.h defines the interface to the camera hardware abstraction...">CameraHardwareInterface</a> : <span class="keyword">public</span> <span class="keyword">virtual</span> RefBase {
<a name="l00080"></a>00080 <span class="keyword">public</span>:
<a name="l00081"></a><a class="code" href="classandroid_1_1_camera_hardware_interface.html#99f4ab74b58cd4b23e0fb00a46a60cb1">00081</a> <span class="keyword">virtual</span> <a class="code" href="classandroid_1_1_camera_hardware_interface.html#99f4ab74b58cd4b23e0fb00a46a60cb1">~CameraHardwareInterface</a>() { }
<a name="l00082"></a>00082 <span class="comment"></span>
<a name="l00083"></a>00083 <span class="comment"> /** Return the IMemoryHeap for the preview image heap */</span>
<a name="l00084"></a>00084 <span class="keyword">virtual</span> sp&lt;IMemoryHeap&gt; <a class="code" href="classandroid_1_1_camera_hardware_interface.html#9d4071fb234a0c2e7bf6ea78e723f2f4" title="Return the IMemoryHeap for the preview image heap.">getPreviewHeap</a>() <span class="keyword">const</span> = 0;
<a name="l00085"></a>00085 <span class="comment"></span>
<a name="l00086"></a>00086 <span class="comment"> /**</span>
<a name="l00087"></a>00087 <span class="comment"> * Start preview mode. When a preview image is available</span>
<a name="l00088"></a>00088 <span class="comment"> * preview_callback is called with the user parameter. The</span>
<a name="l00089"></a>00089 <span class="comment"> * call back parameter may be null.</span>
<a name="l00090"></a>00090 <span class="comment"> */</span>
<a name="l00091"></a>00091 <span class="keyword">virtual</span> status_t <a class="code" href="classandroid_1_1_camera_hardware_interface.html#62def8031dee8bdab7933770708a6312" title="Start preview mode.">startPreview</a>(<a class="code" href="namespaceandroid.html#d32b08663d42356404e2eb971e271636" title="Callback for startPreview().">preview_callback</a> cb, <span class="keywordtype">void</span>* user) = 0;
<a name="l00092"></a>00092 <span class="comment"></span>
<a name="l00093"></a>00093 <span class="comment"> /**</span>
<a name="l00094"></a>00094 <span class="comment"> * Stop a previously started preview.</span>
<a name="l00095"></a>00095 <span class="comment"> */</span>
<a name="l00096"></a>00096 <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="classandroid_1_1_camera_hardware_interface.html#34faa77065f415b93cb1acf84fc788bf" title="Stop a previously started preview.">stopPreview</a>() = 0;
<a name="l00097"></a>00097 <span class="comment"></span>
<a name="l00098"></a>00098 <span class="comment"> /**</span>
<a name="l00099"></a>00099 <span class="comment"> * Start auto focus, the callback routine is called</span>
<a name="l00100"></a>00100 <span class="comment"> * once when focusing is complete. autoFocus() will</span>
<a name="l00101"></a>00101 <span class="comment"> * be called again if another auto focus is needed.</span>
<a name="l00102"></a>00102 <span class="comment"> */</span>
<a name="l00103"></a>00103 <span class="keyword">virtual</span> status_t <a class="code" href="classandroid_1_1_camera_hardware_interface.html#0dda73938e9b18326dd48bd721dbd515" title="Start auto focus, the callback routine is called once when focusing is complete.">autoFocus</a>(<a class="code" href="namespaceandroid.html#4dca8d8b824ca9a684358133da0ec8f2" title="Callback for autoFocus().">autofocus_callback</a>,
<a name="l00104"></a>00104 <span class="keywordtype">void</span>* user) = 0;
<a name="l00105"></a>00105 <span class="comment"></span>
<a name="l00106"></a>00106 <span class="comment"> /**</span>
<a name="l00107"></a>00107 <span class="comment"> * Take a picture. The raw_callback is called when</span>
<a name="l00108"></a>00108 <span class="comment"> * the uncompressed image is available. The jpeg_callback</span>
<a name="l00109"></a>00109 <span class="comment"> * is called when the compressed image is available. These</span>
<a name="l00110"></a>00110 <span class="comment"> * call backs may be null. The user parameter is passed</span>
<a name="l00111"></a>00111 <span class="comment"> * to each of the call back routines.</span>
<a name="l00112"></a>00112 <span class="comment"> */</span>
<a name="l00113"></a>00113 <span class="keyword">virtual</span> status_t <a class="code" href="classandroid_1_1_camera_hardware_interface.html#2aedf65cad695ce439029f37a7cb66c4" title="Take a picture.">takePicture</a>(<a class="code" href="namespaceandroid.html#04c83209c2627e2d303320712ca9ee65" title="Callback for takePicture().">shutter_callback</a>,
<a name="l00114"></a>00114 <a class="code" href="namespaceandroid.html#a97926709e452d66360cb9b24736969e" title="Callback for takePicture().">raw_callback</a>,
<a name="l00115"></a>00115 <a class="code" href="namespaceandroid.html#c21980d4be1e0cc458399ecf5374d473" title="Callback for takePicture().">jpeg_callback</a>,
<a name="l00116"></a>00116 <span class="keywordtype">void</span>* user) = 0;
<a name="l00117"></a>00117 <span class="comment"></span>
<a name="l00118"></a>00118 <span class="comment"> /**</span>
<a name="l00119"></a>00119 <span class="comment"> * Cancel a picture that was started with takePicture. You may cancel any</span>
<a name="l00120"></a>00120 <span class="comment"> * of the shutter, raw, or jpeg callbacks. Calling this method when no</span>
<a name="l00121"></a>00121 <span class="comment"> * picture is being taken is a no-op.</span>
<a name="l00122"></a>00122 <span class="comment"> */</span>
<a name="l00123"></a>00123 <span class="keyword">virtual</span> status_t <a class="code" href="classandroid_1_1_camera_hardware_interface.html#da8faf376215a605357d26afa1b79386" title="Cancel a picture that was started with takePicture.">cancelPicture</a>(<span class="keywordtype">bool</span> cancel_shutter,
<a name="l00124"></a>00124 <span class="keywordtype">bool</span> cancel_raw,
<a name="l00125"></a>00125 <span class="keywordtype">bool</span> cancel_jpeg) = 0;
<a name="l00126"></a>00126 <span class="comment"></span>
<a name="l00127"></a>00127 <span class="comment"> /** Set the camera parameters. */</span>
<a name="l00128"></a>00128 <span class="keyword">virtual</span> status_t <a class="code" href="classandroid_1_1_camera_hardware_interface.html#82e54ede14bd263274bbc8777bafc384" title="Set the camera parameters.">setParameters</a>(<span class="keyword">const</span> CameraParameters&amp; params) = 0;
<a name="l00129"></a>00129 <span class="comment"></span>
<a name="l00130"></a>00130 <span class="comment"> /** Return the camera parameters. */</span>
<a name="l00131"></a>00131 <span class="keyword">virtual</span> CameraParameters <a class="code" href="classandroid_1_1_camera_hardware_interface.html#4c748a3c0aa3c5f2333e0abcdbeb15cb" title="Return the camera parameters.">getParameters</a>() <span class="keyword">const</span> = 0;
<a name="l00132"></a>00132 <span class="comment"></span>
<a name="l00133"></a>00133 <span class="comment"> /**</span>
<a name="l00134"></a>00134 <span class="comment"> * Release the hardware resources owned by this object. Note that this is</span>
<a name="l00135"></a>00135 <span class="comment"> * *not* done in the destructor.</span>
<a name="l00136"></a>00136 <span class="comment"> */</span>
<a name="l00137"></a>00137 <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="classandroid_1_1_camera_hardware_interface.html#df65310b8aa176e0ce5f08b87d6b7eb8" title="Release the hardware resources owned by this object.">release</a>() = 0;
<a name="l00138"></a>00138 <span class="comment"></span>
<a name="l00139"></a>00139 <span class="comment"> /**</span>
<a name="l00140"></a>00140 <span class="comment"> * Dump state of the camera hardware</span>
<a name="l00141"></a>00141 <span class="comment"> */</span>
<a name="l00142"></a>00142 <span class="keyword">virtual</span> status_t <a class="code" href="classandroid_1_1_camera_hardware_interface.html#06df1bf91b8af07964dca314a6031b32" title="Dump state of the camera hardware.">dump</a>(<span class="keywordtype">int</span> fd, <span class="keyword">const</span> Vector&lt;String16&gt;&amp; args) <span class="keyword">const</span> = 0;
<a name="l00143"></a>00143 };
<a name="l00144"></a>00144 <span class="comment"></span>
<a name="l00145"></a>00145 <span class="comment">/** factory function to instantiate a camera hardware object */</span>
<a name="l00146"></a>00146 <span class="keyword">extern</span> <span class="stringliteral">"C"</span> sp&lt;CameraHardwareInterface&gt; <a class="code" href="namespaceandroid.html#24c243f7f9ba0d1d881be17ae06254a2" title="factory function to instantiate a camera hardware object">openCameraHardware</a>();
<a name="l00147"></a>00147
<a name="l00148"></a>00148 }; <span class="comment">// namespace android</span>
<a name="l00149"></a>00149
<a name="l00150"></a>00150 <span class="preprocessor">#endif</span>
</pre></div></div>
</body>
</html>

View File

@@ -1,62 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Doxygen-Generated Content</title>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
.navigation {
display: none;
}
-->
</style>
</head>
<body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li class="current"><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
</div>
<div class="contents">
<h1>CameraHardwareInterface.h File Reference</h1>
<p>
<a href="_camera_hardware_interface_8h-source.html">Go to the source code of this file.</a><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Namespaces</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">namespace &nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceandroid.html">android</a></td></tr>
<tr><td colspan="2"><br><h2>Data Structures</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">class &nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_camera_hardware_interface.html">android::CameraHardwareInterface</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight"><a class="el" href="_camera_hardware_interface_8h.html">CameraHardwareInterface.h</a> defines the interface to the camera hardware abstraction layer, used for setting and getting parameters, live previewing, and taking pictures. <a href="classandroid_1_1_camera_hardware_interface.html#_details">More...</a><br></td></tr>
<tr><td colspan="2"><br><h2>Typedefs</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef void(*&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceandroid.html#d32b08663d42356404e2eb971e271636">android::preview_callback</a> )(const sp&lt; IMemory &gt; &amp;mem, void *user)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Callback for startPreview(). <a href="#d32b08663d42356404e2eb971e271636"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef void(*&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceandroid.html#04c83209c2627e2d303320712ca9ee65">android::shutter_callback</a> )(void *user)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Callback for takePicture(). <a href="#04c83209c2627e2d303320712ca9ee65"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef void(*&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceandroid.html#a97926709e452d66360cb9b24736969e">android::raw_callback</a> )(const sp&lt; IMemory &gt; &amp;mem, void *user)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Callback for takePicture(). <a href="#a97926709e452d66360cb9b24736969e"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef void(*&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceandroid.html#c21980d4be1e0cc458399ecf5374d473">android::jpeg_callback</a> )(const sp&lt; IMemory &gt; &amp;mem, void *user)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Callback for takePicture(). <a href="#c21980d4be1e0cc458399ecf5374d473"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef void(*&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceandroid.html#4dca8d8b824ca9a684358133da0ec8f2">android::autofocus_callback</a> )(bool focused, void *user)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Callback for autoFocus(). <a href="#4dca8d8b824ca9a684358133da0ec8f2"></a><br></td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">sp&lt; CameraHardwareInterface &gt;&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceandroid.html#24c243f7f9ba0d1d881be17ae06254a2">android::openCameraHardware</a> ()</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">factory function to instantiate a camera hardware object <a href="#24c243f7f9ba0d1d881be17ae06254a2"></a><br></td></tr>
</table>
</div>
</body>
</html>

View File

@@ -1,51 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Doxygen-Generated Content</title>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
.navigation {
display: none;
}
-->
</style>
</head>
<body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li class="current"><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li class="current"><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="functions.html"><span>Data&nbsp;Fields</span></a></li>
</ul>
</div>
</div>
<div class="contents">
<h1>Data Structures</h1>Here are the data structures with brief descriptions:<table>
<tr><td class="indexkey"><a class="el" href="classandroid_1_1_audio_hardware_interface.html">android::AudioHardwareInterface</a></td><td class="indexvalue"><a class="el" href="_audio_hardware_interface_8h.html">AudioHardwareInterface.h</a> defines the interface to the audio hardware abstraction layer </td></tr>
<tr><td class="indexkey"><a class="el" href="classandroid_1_1_audio_stream_in.html">android::AudioStreamIn</a></td><td class="indexvalue"><a class="el" href="classandroid_1_1_audio_stream_in.html" title="AudioStreamIn is the abstraction interface for the audio input hardware.">AudioStreamIn</a> is the abstraction interface for the audio input hardware </td></tr>
<tr><td class="indexkey"><a class="el" href="classandroid_1_1_audio_stream_out.html">android::AudioStreamOut</a></td><td class="indexvalue"><a class="el" href="classandroid_1_1_audio_stream_out.html" title="AudioStreamOut is the abstraction interface for the audio output hardware.">AudioStreamOut</a> is the abstraction interface for the audio output hardware </td></tr>
<tr><td class="indexkey"><a class="el" href="classandroid_1_1_camera_hardware_interface.html">android::CameraHardwareInterface</a></td><td class="indexvalue"><a class="el" href="_camera_hardware_interface_8h.html">CameraHardwareInterface.h</a> defines the interface to the camera hardware abstraction layer, used for setting and getting parameters, live previewing, and taking pictures </td></tr>
<tr><td class="indexkey"><a class="el" href="struct_gps_callbacks.html">GpsCallbacks</a></td><td class="indexvalue">GPS callback structure </td></tr>
<tr><td class="indexkey"><a class="el" href="struct_gps_interface.html">GpsInterface</a></td><td class="indexvalue">Represents the standard GPS interface </td></tr>
<tr><td class="indexkey"><a class="el" href="struct_gps_location.html">GpsLocation</a></td><td class="indexvalue">Represents a location </td></tr>
<tr><td class="indexkey"><a class="el" href="struct_gps_status.html">GpsStatus</a></td><td class="indexvalue">Represents the status </td></tr>
<tr><td class="indexkey"><a class="el" href="struct_gps_supl_interface.html">GpsSuplInterface</a></td><td class="indexvalue">Extended interface for SUPL support </td></tr>
<tr><td class="indexkey"><a class="el" href="struct_gps_sv_info.html">GpsSvInfo</a></td><td class="indexvalue">Represents SV information </td></tr>
<tr><td class="indexkey"><a class="el" href="struct_gps_sv_status.html">GpsSvStatus</a></td><td class="indexvalue">Represents SV status </td></tr>
<tr><td class="indexkey"><a class="el" href="struct_gps_xtra_callbacks.html">GpsXtraCallbacks</a></td><td class="indexvalue">Callback structure for the XTRA interface </td></tr>
<tr><td class="indexkey"><a class="el" href="struct_gps_xtra_interface.html">GpsXtraInterface</a></td><td class="indexvalue">Extended interface for XTRA support </td></tr>
</table>
</div>
</body>
</html>

View File

@@ -227,7 +227,7 @@ include $(BUILD_SHARED_LIBRARY)
<p class="note"><strong>Note</strong>: This document relies on some Doxygen-generated content that appears in an iFrame below. To return to the Doxygen default content for this page, <a href="audio_sub_system.html">click here</a>.</p> <p class="note"><strong>Note</strong>: This document relies on some Doxygen-generated content that appears in an iFrame below. To return to the Doxygen default content for this page, <a href="audio_sub_system.html">click here</a>.</p>
<iframe onLoad="resizeHeight();" src="_audio_hardware_interface_8h.html" scrolling="no" scroll="no" id="doxygen" marginwidth="0" marginheight="0" frameborder="0" style="width:100%;"></iframe> <iframe onLoad="resizeHeight();" src="AudioHardwareInterface_8h.html" scrolling="no" scroll="no" id="doxygen" marginwidth="0" marginheight="0" frameborder="0" style="width:100%;"></iframe>
<p><span class="lh2"><a name="androidFooter"></a></span> <p><span class="lh2"><a name="androidFooter"></a></span>

View File

@@ -246,7 +246,7 @@ include $(BUILD_SHARED_LIBRARY)
<p class="note"><strong>Note</strong>: This document relies on some Doxygen-generated content that appears in an iFrame below. To return to the Doxygen default content for this page, <a href="camera.html">click here</a>.</p> <p class="note"><strong>Note</strong>: This document relies on some Doxygen-generated content that appears in an iFrame below. To return to the Doxygen default content for this page, <a href="camera.html">click here</a>.</p>
<iframe onLoad="resizeHeight();" src="_camera_hardware_interface_8h.html" scrolling="no" scroll="no" id="doxygen" marginwidth="0" marginheight="0" frameborder="0" style="width:100%;"></iframe> <iframe onLoad="resizeHeight();" src="CameraHardwareInterface_8h.html " scrolling="no" scroll="no" id="doxygen" marginwidth="0" marginheight="0" frameborder="0" style="width:100%;"></iframe>
<p><span class="lh2"><a name="androidFooter"></a></span> <p><span class="lh2"><a name="androidFooter"></a></span>

View File

@@ -1,584 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Doxygen-Generated Content</title>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
.navigation {
display: none;
}
-->
</style>
</head>
<body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li class="current"><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="functions.html"><span>Data&nbsp;Fields</span></a></li>
</ul>
</div>
<div class="navpath"><a class="el" href="namespaceandroid.html">android</a>::<a class="el" href="classandroid_1_1_audio_hardware_interface.html">AudioHardwareInterface</a>
</div>
</div>
<div class="contents">
<h1>android::AudioHardwareInterface Class Reference</h1><!-- doxytag: class="android::AudioHardwareInterface" --><a class="el" href="_audio_hardware_interface_8h.html">AudioHardwareInterface.h</a> defines the interface to the audio hardware abstraction layer.
<a href="#_details">More...</a>
<p>
<code>#include &lt;<a class="el" href="_audio_hardware_interface_8h-source.html">AudioHardwareInterface.h</a>&gt;</code>
<p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Public Member Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual status_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_hardware_interface.html#b7e19e09fa6cbc07c127122fa9866c50">initCheck</a> ()=0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">check to see if the audio hardware interface has been initialized. <a href="#b7e19e09fa6cbc07c127122fa9866c50"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual status_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_hardware_interface.html#61121d365bb4d182bdec2c1b12fb1178">standby</a> ()=0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">put the audio hardware into standby mode to conserve power. <a href="#61121d365bb4d182bdec2c1b12fb1178"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual status_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_hardware_interface.html#7b7418072df1eeaacc89cd0c725755f6">setVoiceVolume</a> (float volume)=0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">set the audio volume of a voice call. <a href="#7b7418072df1eeaacc89cd0c725755f6"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual status_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_hardware_interface.html#925092e556eb89f304bcebb09f90c9a3">setMasterVolume</a> (float volume)=0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">set the audio volume for all audio activities other than voice call. <a href="#925092e556eb89f304bcebb09f90c9a3"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual status_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_hardware_interface.html#39b2690e19219425b8cff093ef83bfb1">setRouting</a> (int mode, uint32_t routes)=0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Audio routing methods. <a href="#39b2690e19219425b8cff093ef83bfb1"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual status_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_hardware_interface.html#1886de8fff2342ae628dbbbc0c45ba83">getRouting</a> (int mode, uint32_t *routes)=0</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual status_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_hardware_interface.html#aaf2a429c240f00b21836794849b430f">setMode</a> (int mode)=0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">setMode is called when the audio mode changes. <a href="#aaf2a429c240f00b21836794849b430f"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual status_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_hardware_interface.html#8466c76328a51b8a83da103032abba55">getMode</a> (int *mode)=0</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual status_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_hardware_interface.html#be35b7cb738531939a3ac9abc5514621">setMicMute</a> (bool state)=0</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual status_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_hardware_interface.html#15d3c33d7e3f965dc2588c537f05a133">getMicMute</a> (bool *state)=0</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual status_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_hardware_interface.html#a1b477901df48b3a27103a77e6bb39c8">setParameter</a> (const char *key, const char *value)=0</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual size_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_hardware_interface.html#19f68d873b2a6e4c00c017c580170395">getInputBufferSize</a> (uint32_t sampleRate, int format, int channelCount)=0</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="classandroid_1_1_audio_stream_out.html">AudioStreamOut</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_hardware_interface.html#eda0986e145c8dd68d21cb79051f94f9">openOutputStream</a> (int format=0, int channelCount=0, uint32_t sampleRate=0, status_t *status=0)=0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">This method creates and opens the audio hardware output stream. <a href="#eda0986e145c8dd68d21cb79051f94f9"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="classandroid_1_1_audio_stream_in.html">AudioStreamIn</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_hardware_interface.html#efb777d192fcbcd65458fa4f2d976476">openInputStream</a> (int format, int channelCount, uint32_t sampleRate, status_t *status)=0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">This method creates and opens the audio hardware input stream. <a href="#efb777d192fcbcd65458fa4f2d976476"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual status_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_hardware_interface.html#05f035af60e67a22251175b44a089f69">dumpState</a> (int fd, const Vector&lt; String16 &gt; &amp;args)=0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">This method dumps the state of the audio hardware. <a href="#05f035af60e67a22251175b44a089f69"></a><br></td></tr>
<tr><td colspan="2"><br><h2>Static Public Member Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">static <a class="el" href="classandroid_1_1_audio_hardware_interface.html">AudioHardwareInterface</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_hardware_interface.html#aa5ae45e9ad969fefc494e103cf5068d">create</a> ()</td></tr>
<tr><td colspan="2"><br><h2>Protected Member Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual status_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_hardware_interface.html#d82c3e4827f275abf28eb872e8751e1f">doRouting</a> ()=0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">doRouting actually initiates the routing. <a href="#d82c3e4827f275abf28eb872e8751e1f"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual status_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_hardware_interface.html#371f198a416cb726804e0f47e8763217">dump</a> (int fd, const Vector&lt; String16 &gt; &amp;args)=0</td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
<a class="el" href="_audio_hardware_interface_8h.html">AudioHardwareInterface.h</a> defines the interface to the audio hardware abstraction layer.
<p>
The interface supports setting and getting parameters, selecting audio routing paths, and defining input and output streams.<p>
AudioFlinger initializes the audio hardware and immediately opens an output stream. You can set Audio routing to output to handset, speaker, Bluetooth, or a headset.<p>
The audio input stream is initialized when AudioFlinger is called to carry out a record operation.
<p>Definition at line <a class="el" href="_audio_hardware_interface_8h-source.html#l00144">144</a> of file <a class="el" href="_audio_hardware_interface_8h-source.html">AudioHardwareInterface.h</a>.</p>
<hr><h2>Member Function Documentation</h2>
<a class="anchor" name="b7e19e09fa6cbc07c127122fa9866c50"></a><!-- doxytag: member="android::AudioHardwareInterface::initCheck" ref="b7e19e09fa6cbc07c127122fa9866c50" args="()=0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual status_t android::AudioHardwareInterface::initCheck </td>
<td>(</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td><code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
check to see if the audio hardware interface has been initialized.
<p>
return status based on values defined in include/utils/Errors.h
</div>
</div><p>
<a class="anchor" name="61121d365bb4d182bdec2c1b12fb1178"></a><!-- doxytag: member="android::AudioHardwareInterface::standby" ref="61121d365bb4d182bdec2c1b12fb1178" args="()=0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual status_t android::AudioHardwareInterface::standby </td>
<td>(</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td><code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
put the audio hardware into standby mode to conserve power.
<p>
Returns status based on include/utils/Errors.h
</div>
</div><p>
<a class="anchor" name="7b7418072df1eeaacc89cd0c725755f6"></a><!-- doxytag: member="android::AudioHardwareInterface::setVoiceVolume" ref="7b7418072df1eeaacc89cd0c725755f6" args="(float volume)=0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual status_t android::AudioHardwareInterface::setVoiceVolume </td>
<td>(</td>
<td class="paramtype">float&nbsp;</td>
<td class="paramname"> <em>volume</em> </td>
<td>&nbsp;)&nbsp;</td>
<td><code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
set the audio volume of a voice call.
<p>
Range is between 0.0 and 1.0
</div>
</div><p>
<a class="anchor" name="925092e556eb89f304bcebb09f90c9a3"></a><!-- doxytag: member="android::AudioHardwareInterface::setMasterVolume" ref="925092e556eb89f304bcebb09f90c9a3" args="(float volume)=0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual status_t android::AudioHardwareInterface::setMasterVolume </td>
<td>(</td>
<td class="paramtype">float&nbsp;</td>
<td class="paramname"> <em>volume</em> </td>
<td>&nbsp;)&nbsp;</td>
<td><code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
set the audio volume for all audio activities other than voice call.
<p>
Range between 0.0 and 1.0. If any value other than NO_ERROR is returned, the software mixer will emulate this capability.
</div>
</div><p>
<a class="anchor" name="39b2690e19219425b8cff093ef83bfb1"></a><!-- doxytag: member="android::AudioHardwareInterface::setRouting" ref="39b2690e19219425b8cff093ef83bfb1" args="(int mode, uint32_t routes)=0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual status_t android::AudioHardwareInterface::setRouting </td>
<td>(</td>
<td class="paramtype">int&nbsp;</td>
<td class="paramname"> <em>mode</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">uint32_t&nbsp;</td>
<td class="paramname"> <em>routes</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td><code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Audio routing methods.
<p>
Routes defined in include/hardware/AudioSystem.h. Audio routes can be (ROUTE_EARPIECE | ROUTE_SPEAKER | ROUTE_BLUETOOTH | ROUTE_HEADSET)<p>
setRouting sets the routes for a mode. This is called at startup. It is also called when a new device is connected, such as a wired headset is plugged in or a Bluetooth headset is paired.
</div>
</div><p>
<a class="anchor" name="1886de8fff2342ae628dbbbc0c45ba83"></a><!-- doxytag: member="android::AudioHardwareInterface::getRouting" ref="1886de8fff2342ae628dbbbc0c45ba83" args="(int mode, uint32_t *routes)=0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual status_t android::AudioHardwareInterface::getRouting </td>
<td>(</td>
<td class="paramtype">int&nbsp;</td>
<td class="paramname"> <em>mode</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">uint32_t *&nbsp;</td>
<td class="paramname"> <em>routes</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td><code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
</div>
</div><p>
<a class="anchor" name="aaf2a429c240f00b21836794849b430f"></a><!-- doxytag: member="android::AudioHardwareInterface::setMode" ref="aaf2a429c240f00b21836794849b430f" args="(int mode)=0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual status_t android::AudioHardwareInterface::setMode </td>
<td>(</td>
<td class="paramtype">int&nbsp;</td>
<td class="paramname"> <em>mode</em> </td>
<td>&nbsp;)&nbsp;</td>
<td><code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
setMode is called when the audio mode changes.
<p>
NORMAL mode is for standard audio playback, RINGTONE when a ringtone is playing, and IN_CALL when a call is in progress.
</div>
</div><p>
<a class="anchor" name="8466c76328a51b8a83da103032abba55"></a><!-- doxytag: member="android::AudioHardwareInterface::getMode" ref="8466c76328a51b8a83da103032abba55" args="(int *mode)=0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual status_t android::AudioHardwareInterface::getMode </td>
<td>(</td>
<td class="paramtype">int *&nbsp;</td>
<td class="paramname"> <em>mode</em> </td>
<td>&nbsp;)&nbsp;</td>
<td><code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
</div>
</div><p>
<a class="anchor" name="be35b7cb738531939a3ac9abc5514621"></a><!-- doxytag: member="android::AudioHardwareInterface::setMicMute" ref="be35b7cb738531939a3ac9abc5514621" args="(bool state)=0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual status_t android::AudioHardwareInterface::setMicMute </td>
<td>(</td>
<td class="paramtype">bool&nbsp;</td>
<td class="paramname"> <em>state</em> </td>
<td>&nbsp;)&nbsp;</td>
<td><code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
</div>
</div><p>
<a class="anchor" name="15d3c33d7e3f965dc2588c537f05a133"></a><!-- doxytag: member="android::AudioHardwareInterface::getMicMute" ref="15d3c33d7e3f965dc2588c537f05a133" args="(bool *state)=0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual status_t android::AudioHardwareInterface::getMicMute </td>
<td>(</td>
<td class="paramtype">bool *&nbsp;</td>
<td class="paramname"> <em>state</em> </td>
<td>&nbsp;)&nbsp;</td>
<td><code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
</div>
</div><p>
<a class="anchor" name="a1b477901df48b3a27103a77e6bb39c8"></a><!-- doxytag: member="android::AudioHardwareInterface::setParameter" ref="a1b477901df48b3a27103a77e6bb39c8" args="(const char *key, const char *value)=0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual status_t android::AudioHardwareInterface::setParameter </td>
<td>(</td>
<td class="paramtype">const char *&nbsp;</td>
<td class="paramname"> <em>key</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const char *&nbsp;</td>
<td class="paramname"> <em>value</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td><code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
</div>
</div><p>
<a class="anchor" name="19f68d873b2a6e4c00c017c580170395"></a><!-- doxytag: member="android::AudioHardwareInterface::getInputBufferSize" ref="19f68d873b2a6e4c00c017c580170395" args="(uint32_t sampleRate, int format, int channelCount)=0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual size_t android::AudioHardwareInterface::getInputBufferSize </td>
<td>(</td>
<td class="paramtype">uint32_t&nbsp;</td>
<td class="paramname"> <em>sampleRate</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int&nbsp;</td>
<td class="paramname"> <em>format</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int&nbsp;</td>
<td class="paramname"> <em>channelCount</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td><code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
</div>
</div><p>
<a class="anchor" name="eda0986e145c8dd68d21cb79051f94f9"></a><!-- doxytag: member="android::AudioHardwareInterface::openOutputStream" ref="eda0986e145c8dd68d21cb79051f94f9" args="(int format=0, int channelCount=0, uint32_t sampleRate=0, status_t *status=0)=0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual <a class="el" href="classandroid_1_1_audio_stream_out.html">AudioStreamOut</a>* android::AudioHardwareInterface::openOutputStream </td>
<td>(</td>
<td class="paramtype">int&nbsp;</td>
<td class="paramname"> <em>format</em> = <code>0</code>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int&nbsp;</td>
<td class="paramname"> <em>channelCount</em> = <code>0</code>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">uint32_t&nbsp;</td>
<td class="paramname"> <em>sampleRate</em> = <code>0</code>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">status_t *&nbsp;</td>
<td class="paramname"> <em>status</em> = <code>0</code></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td><code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
This method creates and opens the audio hardware output stream.
<p>
</div>
</div><p>
<a class="anchor" name="efb777d192fcbcd65458fa4f2d976476"></a><!-- doxytag: member="android::AudioHardwareInterface::openInputStream" ref="efb777d192fcbcd65458fa4f2d976476" args="(int format, int channelCount, uint32_t sampleRate, status_t *status)=0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual <a class="el" href="classandroid_1_1_audio_stream_in.html">AudioStreamIn</a>* android::AudioHardwareInterface::openInputStream </td>
<td>(</td>
<td class="paramtype">int&nbsp;</td>
<td class="paramname"> <em>format</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int&nbsp;</td>
<td class="paramname"> <em>channelCount</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">uint32_t&nbsp;</td>
<td class="paramname"> <em>sampleRate</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">status_t *&nbsp;</td>
<td class="paramname"> <em>status</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td><code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
This method creates and opens the audio hardware input stream.
<p>
</div>
</div><p>
<a class="anchor" name="05f035af60e67a22251175b44a089f69"></a><!-- doxytag: member="android::AudioHardwareInterface::dumpState" ref="05f035af60e67a22251175b44a089f69" args="(int fd, const Vector&lt; String16 &gt; &amp;args)=0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual status_t android::AudioHardwareInterface::dumpState </td>
<td>(</td>
<td class="paramtype">int&nbsp;</td>
<td class="paramname"> <em>fd</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const Vector&lt; String16 &gt; &amp;&nbsp;</td>
<td class="paramname"> <em>args</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td><code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
This method dumps the state of the audio hardware.
<p>
</div>
</div><p>
<a class="anchor" name="aa5ae45e9ad969fefc494e103cf5068d"></a><!-- doxytag: member="android::AudioHardwareInterface::create" ref="aa5ae45e9ad969fefc494e103cf5068d" args="()" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">static <a class="el" href="classandroid_1_1_audio_hardware_interface.html">AudioHardwareInterface</a>* android::AudioHardwareInterface::create </td>
<td>(</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td><code> [static]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
</div>
</div><p>
<a class="anchor" name="d82c3e4827f275abf28eb872e8751e1f"></a><!-- doxytag: member="android::AudioHardwareInterface::doRouting" ref="d82c3e4827f275abf28eb872e8751e1f" args="()=0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual status_t android::AudioHardwareInterface::doRouting </td>
<td>(</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td><code> [protected, pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
doRouting actually initiates the routing.
<p>
A call to setRouting or setMode may result in a routing change. The generic logic calls doRouting when required. If the device has any special requirements these methods can be overriden.
</div>
</div><p>
<a class="anchor" name="371f198a416cb726804e0f47e8763217"></a><!-- doxytag: member="android::AudioHardwareInterface::dump" ref="371f198a416cb726804e0f47e8763217" args="(int fd, const Vector&lt; String16 &gt; &amp;args)=0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual status_t android::AudioHardwareInterface::dump </td>
<td>(</td>
<td class="paramtype">int&nbsp;</td>
<td class="paramname"> <em>fd</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const Vector&lt; String16 &gt; &amp;&nbsp;</td>
<td class="paramname"> <em>args</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td><code> [protected, pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
</div>
</div><p>
<hr>The documentation for this class was generated from the following file:<ul>
<li><a class="el" href="_audio_hardware_interface_8h-source.html">AudioHardwareInterface.h</a></ul>
</div>
</body>
</html>

View File

@@ -1,292 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Doxygen-Generated Content</title>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
.navigation {
display: none;
}
-->
</style>
</head>
<body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li class="current"><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="functions.html"><span>Data&nbsp;Fields</span></a></li>
</ul>
</div>
<div class="navpath"><a class="el" href="namespaceandroid.html">android</a>::<a class="el" href="classandroid_1_1_audio_stream_in.html">AudioStreamIn</a>
</div>
</div>
<div class="contents">
<h1>android::AudioStreamIn Class Reference</h1><!-- doxytag: class="android::AudioStreamIn" --><a class="el" href="classandroid_1_1_audio_stream_in.html" title="AudioStreamIn is the abstraction interface for the audio input hardware.">AudioStreamIn</a> is the abstraction interface for the audio input hardware.
<a href="#_details">More...</a>
<p>
<code>#include &lt;<a class="el" href="_audio_hardware_interface_8h-source.html">AudioHardwareInterface.h</a>&gt;</code>
<p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Public Member Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_stream_in.html#72067577568bbdd0163c1369fe80f101">~AudioStreamIn</a> ()=0</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual size_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_stream_in.html#a458f9cde3edde82f256af7eaa7b2ddf">bufferSize</a> () const =0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">return the input buffer size allowed by audio driver <a href="#a458f9cde3edde82f256af7eaa7b2ddf"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_stream_in.html#04f84006dd5f2e0a5e512897a039f851">channelCount</a> () const =0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">return the number of audio input channels <a href="#04f84006dd5f2e0a5e512897a039f851"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_stream_in.html#4ade98c5243b9ed5f3a71a8f36e74b36">format</a> () const =0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">return audio format in 8bit or 16bit PCM format - eg. <a href="#4ade98c5243b9ed5f3a71a8f36e74b36"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">uint32_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_stream_in.html#43d2c6b97806c005f0717a7bb6f7595c">frameSize</a> () const </td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">return the frame size (number of bytes per sample). <a href="#43d2c6b97806c005f0717a7bb6f7595c"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual status_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_stream_in.html#339822afb3f2f2ac1b4c775d31d12440">setGain</a> (float gain)=0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">set the input gain for the audio driver. <a href="#339822afb3f2f2ac1b4c775d31d12440"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual ssize_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_stream_in.html#7c313cbfbb47dafd90f3225bcd26e592">read</a> (void *buffer, ssize_t bytes)=0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">read audio buffer in from audio driver <a href="#7c313cbfbb47dafd90f3225bcd26e592"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual status_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_stream_in.html#18c3760208bfb99498715a0d4977f675">dump</a> (int fd, const Vector&lt; String16 &gt; &amp;args)=0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">dump the state of the audio input device <a href="#18c3760208bfb99498715a0d4977f675"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual status_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_stream_in.html#93fab46e8afdbaedd4d20cc6ee2b7c41">standby</a> ()=0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Put the audio hardware input into standby mode. <a href="#93fab46e8afdbaedd4d20cc6ee2b7c41"></a><br></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
<a class="el" href="classandroid_1_1_audio_stream_in.html" title="AudioStreamIn is the abstraction interface for the audio input hardware.">AudioStreamIn</a> is the abstraction interface for the audio input hardware.
<p>
It defines the various properties of the audio hardware input driver.
<p>Definition at line <a class="el" href="_audio_hardware_interface_8h-source.html#l00093">93</a> of file <a class="el" href="_audio_hardware_interface_8h-source.html">AudioHardwareInterface.h</a>.</p>
<hr><h2>Constructor &amp; Destructor Documentation</h2>
<a class="anchor" name="72067577568bbdd0163c1369fe80f101"></a><!-- doxytag: member="android::AudioStreamIn::~AudioStreamIn" ref="72067577568bbdd0163c1369fe80f101" args="()=0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual android::AudioStreamIn::~AudioStreamIn </td>
<td>(</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td><code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
</div>
</div><p>
<hr><h2>Member Function Documentation</h2>
<a class="anchor" name="a458f9cde3edde82f256af7eaa7b2ddf"></a><!-- doxytag: member="android::AudioStreamIn::bufferSize" ref="a458f9cde3edde82f256af7eaa7b2ddf" args="() const =0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual size_t android::AudioStreamIn::bufferSize </td>
<td>(</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td> const<code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
return the input buffer size allowed by audio driver
<p>
</div>
</div><p>
<a class="anchor" name="04f84006dd5f2e0a5e512897a039f851"></a><!-- doxytag: member="android::AudioStreamIn::channelCount" ref="04f84006dd5f2e0a5e512897a039f851" args="() const =0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual int android::AudioStreamIn::channelCount </td>
<td>(</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td> const<code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
return the number of audio input channels
<p>
</div>
</div><p>
<a class="anchor" name="4ade98c5243b9ed5f3a71a8f36e74b36"></a><!-- doxytag: member="android::AudioStreamIn::format" ref="4ade98c5243b9ed5f3a71a8f36e74b36" args="() const =0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual int android::AudioStreamIn::format </td>
<td>(</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td> const<code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
return audio format in 8bit or 16bit PCM format - eg.
<p>
AudioSystem:PCM_16_BIT
</div>
</div><p>
<a class="anchor" name="43d2c6b97806c005f0717a7bb6f7595c"></a><!-- doxytag: member="android::AudioStreamIn::frameSize" ref="43d2c6b97806c005f0717a7bb6f7595c" args="() const " -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">uint32_t android::AudioStreamIn::frameSize </td>
<td>(</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td> const<code> [inline]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
return the frame size (number of bytes per sample).
<p>
<p>Definition at line <a class="el" href="_audio_hardware_interface_8h-source.html#l00112">112</a> of file <a class="el" href="_audio_hardware_interface_8h-source.html">AudioHardwareInterface.h</a>.</p>
</div>
</div><p>
<a class="anchor" name="339822afb3f2f2ac1b4c775d31d12440"></a><!-- doxytag: member="android::AudioStreamIn::setGain" ref="339822afb3f2f2ac1b4c775d31d12440" args="(float gain)=0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual status_t android::AudioStreamIn::setGain </td>
<td>(</td>
<td class="paramtype">float&nbsp;</td>
<td class="paramname"> <em>gain</em> </td>
<td>&nbsp;)&nbsp;</td>
<td><code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
set the input gain for the audio driver.
<p>
This method is for for future use
</div>
</div><p>
<a class="anchor" name="7c313cbfbb47dafd90f3225bcd26e592"></a><!-- doxytag: member="android::AudioStreamIn::read" ref="7c313cbfbb47dafd90f3225bcd26e592" args="(void *buffer, ssize_t bytes)=0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual ssize_t android::AudioStreamIn::read </td>
<td>(</td>
<td class="paramtype">void *&nbsp;</td>
<td class="paramname"> <em>buffer</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">ssize_t&nbsp;</td>
<td class="paramname"> <em>bytes</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td><code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
read audio buffer in from audio driver
<p>
</div>
</div><p>
<a class="anchor" name="18c3760208bfb99498715a0d4977f675"></a><!-- doxytag: member="android::AudioStreamIn::dump" ref="18c3760208bfb99498715a0d4977f675" args="(int fd, const Vector&lt; String16 &gt; &amp;args)=0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual status_t android::AudioStreamIn::dump </td>
<td>(</td>
<td class="paramtype">int&nbsp;</td>
<td class="paramname"> <em>fd</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const Vector&lt; String16 &gt; &amp;&nbsp;</td>
<td class="paramname"> <em>args</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td><code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
dump the state of the audio input device
<p>
</div>
</div><p>
<a class="anchor" name="93fab46e8afdbaedd4d20cc6ee2b7c41"></a><!-- doxytag: member="android::AudioStreamIn::standby" ref="93fab46e8afdbaedd4d20cc6ee2b7c41" args="()=0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual status_t android::AudioStreamIn::standby </td>
<td>(</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td><code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Put the audio hardware input into standby mode.
<p>
Returns status based on include/utils/Errors.h
</div>
</div><p>
<hr>The documentation for this class was generated from the following file:<ul>
<li><a class="el" href="_audio_hardware_interface_8h-source.html">AudioHardwareInterface.h</a></ul>
</div>
</body>
</html>

View File

@@ -1,316 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Doxygen-Generated Content</title>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
.navigation {
display: none;
}
-->
</style>
</head>
<body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li class="current"><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="functions.html"><span>Data&nbsp;Fields</span></a></li>
</ul>
</div>
<div class="navpath"><a class="el" href="namespaceandroid.html">android</a>::<a class="el" href="classandroid_1_1_audio_stream_out.html">AudioStreamOut</a>
</div>
</div>
<div class="contents">
<h1>android::AudioStreamOut Class Reference</h1><!-- doxytag: class="android::AudioStreamOut" --><a class="el" href="classandroid_1_1_audio_stream_out.html" title="AudioStreamOut is the abstraction interface for the audio output hardware.">AudioStreamOut</a> is the abstraction interface for the audio output hardware.
<a href="#_details">More...</a>
<p>
<code>#include &lt;<a class="el" href="_audio_hardware_interface_8h-source.html">AudioHardwareInterface.h</a>&gt;</code>
<p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Public Member Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_stream_out.html#09074dbae95b82d4f83c513035a0034f">~AudioStreamOut</a> ()=0</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual uint32_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_stream_out.html#6bb028e125d13289f26d3d74f851c921">sampleRate</a> () const =0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">return audio sampling rate in hz - eg. <a href="#6bb028e125d13289f26d3d74f851c921"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual size_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_stream_out.html#7b3c5f2ce79b9b6f167408f63d19af0a">bufferSize</a> () const =0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">returns size of output buffer - eg. <a href="#7b3c5f2ce79b9b6f167408f63d19af0a"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_stream_out.html#4e880a5379c168e8f68c26827e41275b">channelCount</a> () const =0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">return number of output audio channels. <a href="#4e880a5379c168e8f68c26827e41275b"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_stream_out.html#eb2b430bbff4eebd8fb8590507b1dce1">format</a> () const =0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">return audio format in 8bit or 16bit PCM format - eg. <a href="#eb2b430bbff4eebd8fb8590507b1dce1"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">uint32_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_stream_out.html#66b7c4bb510db4060adfd03a376897d8">frameSize</a> () const </td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">return the frame size (number of bytes per sample). <a href="#66b7c4bb510db4060adfd03a376897d8"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual uint32_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_stream_out.html#c698a3d95cf0829dcfe283cd5ea437cb">latency</a> () const =0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">return the audio hardware driver latency in milli seconds. <a href="#c698a3d95cf0829dcfe283cd5ea437cb"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual status_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_stream_out.html#e6d301925d193c25561b42239c7f44b6">setVolume</a> (float volume)=0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Use this method in situations where audio mixing is done in the hardware. <a href="#e6d301925d193c25561b42239c7f44b6"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual ssize_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_stream_out.html#cba177e4a4a35a87ab9f8aa2a9c0e78e">write</a> (const void *buffer, size_t bytes)=0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">write audio buffer to driver. <a href="#cba177e4a4a35a87ab9f8aa2a9c0e78e"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual status_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_stream_out.html#97e3cc4610ba40d6c37b3d376a032b98">dump</a> (int fd, const Vector&lt; String16 &gt; &amp;args)=0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">dump the state of the audio output device <a href="#97e3cc4610ba40d6c37b3d376a032b98"></a><br></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
<a class="el" href="classandroid_1_1_audio_stream_out.html" title="AudioStreamOut is the abstraction interface for the audio output hardware.">AudioStreamOut</a> is the abstraction interface for the audio output hardware.
<p>
It provides information about various properties of the audio output hardware driver.
<p>Definition at line <a class="el" href="_audio_hardware_interface_8h-source.html#l00040">40</a> of file <a class="el" href="_audio_hardware_interface_8h-source.html">AudioHardwareInterface.h</a>.</p>
<hr><h2>Constructor &amp; Destructor Documentation</h2>
<a class="anchor" name="09074dbae95b82d4f83c513035a0034f"></a><!-- doxytag: member="android::AudioStreamOut::~AudioStreamOut" ref="09074dbae95b82d4f83c513035a0034f" args="()=0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual android::AudioStreamOut::~AudioStreamOut </td>
<td>(</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td><code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
</div>
</div><p>
<hr><h2>Member Function Documentation</h2>
<a class="anchor" name="6bb028e125d13289f26d3d74f851c921"></a><!-- doxytag: member="android::AudioStreamOut::sampleRate" ref="6bb028e125d13289f26d3d74f851c921" args="() const =0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual uint32_t android::AudioStreamOut::sampleRate </td>
<td>(</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td> const<code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
return audio sampling rate in hz - eg.
<p>
44100
</div>
</div><p>
<a class="anchor" name="7b3c5f2ce79b9b6f167408f63d19af0a"></a><!-- doxytag: member="android::AudioStreamOut::bufferSize" ref="7b3c5f2ce79b9b6f167408f63d19af0a" args="() const =0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual size_t android::AudioStreamOut::bufferSize </td>
<td>(</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td> const<code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
returns size of output buffer - eg.
<p>
4800
</div>
</div><p>
<a class="anchor" name="4e880a5379c168e8f68c26827e41275b"></a><!-- doxytag: member="android::AudioStreamOut::channelCount" ref="4e880a5379c168e8f68c26827e41275b" args="() const =0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual int android::AudioStreamOut::channelCount </td>
<td>(</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td> const<code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
return number of output audio channels.
<p>
Acceptable values are 1 (mono) or 2 (stereo)
</div>
</div><p>
<a class="anchor" name="eb2b430bbff4eebd8fb8590507b1dce1"></a><!-- doxytag: member="android::AudioStreamOut::format" ref="eb2b430bbff4eebd8fb8590507b1dce1" args="() const =0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual int android::AudioStreamOut::format </td>
<td>(</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td> const<code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
return audio format in 8bit or 16bit PCM format - eg.
<p>
AudioSystem:PCM_16_BIT
</div>
</div><p>
<a class="anchor" name="66b7c4bb510db4060adfd03a376897d8"></a><!-- doxytag: member="android::AudioStreamOut::frameSize" ref="66b7c4bb510db4060adfd03a376897d8" args="() const " -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">uint32_t android::AudioStreamOut::frameSize </td>
<td>(</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td> const<code> [inline]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
return the frame size (number of bytes per sample).
<p>
<p>Definition at line <a class="el" href="_audio_hardware_interface_8h-source.html#l00065">65</a> of file <a class="el" href="_audio_hardware_interface_8h-source.html">AudioHardwareInterface.h</a>.</p>
</div>
</div><p>
<a class="anchor" name="c698a3d95cf0829dcfe283cd5ea437cb"></a><!-- doxytag: member="android::AudioStreamOut::latency" ref="c698a3d95cf0829dcfe283cd5ea437cb" args="() const =0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual uint32_t android::AudioStreamOut::latency </td>
<td>(</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td> const<code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
return the audio hardware driver latency in milli seconds.
<p>
</div>
</div><p>
<a class="anchor" name="e6d301925d193c25561b42239c7f44b6"></a><!-- doxytag: member="android::AudioStreamOut::setVolume" ref="e6d301925d193c25561b42239c7f44b6" args="(float volume)=0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual status_t android::AudioStreamOut::setVolume </td>
<td>(</td>
<td class="paramtype">float&nbsp;</td>
<td class="paramname"> <em>volume</em> </td>
<td>&nbsp;)&nbsp;</td>
<td><code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Use this method in situations where audio mixing is done in the hardware.
<p>
This method serves as a direct interface with hardware, allowing you to directly set the volume as apposed to via the framework. This method might produce multiple PCM outputs or hardware accelerated codecs, such as MP3 or AAC.
</div>
</div><p>
<a class="anchor" name="cba177e4a4a35a87ab9f8aa2a9c0e78e"></a><!-- doxytag: member="android::AudioStreamOut::write" ref="cba177e4a4a35a87ab9f8aa2a9c0e78e" args="(const void *buffer, size_t bytes)=0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual ssize_t android::AudioStreamOut::write </td>
<td>(</td>
<td class="paramtype">const void *&nbsp;</td>
<td class="paramname"> <em>buffer</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">size_t&nbsp;</td>
<td class="paramname"> <em>bytes</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td><code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
write audio buffer to driver.
<p>
Returns number of bytes written
</div>
</div><p>
<a class="anchor" name="97e3cc4610ba40d6c37b3d376a032b98"></a><!-- doxytag: member="android::AudioStreamOut::dump" ref="97e3cc4610ba40d6c37b3d376a032b98" args="(int fd, const Vector&lt; String16 &gt; &amp;args)=0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual status_t android::AudioStreamOut::dump </td>
<td>(</td>
<td class="paramtype">int&nbsp;</td>
<td class="paramname"> <em>fd</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const Vector&lt; String16 &gt; &amp;&nbsp;</td>
<td class="paramname"> <em>args</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td><code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
dump the state of the audio output device
<p>
</div>
</div><p>
<hr>The documentation for this class was generated from the following file:<ul>
<li><a class="el" href="_audio_hardware_interface_8h-source.html">AudioHardwareInterface.h</a></ul>
</div>
</body>
</html>

View File

@@ -1,393 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Doxygen-Generated Content</title>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
.navigation {
display: none;
}
-->
</style>
</head>
<body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li class="current"><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="functions.html"><span>Data&nbsp;Fields</span></a></li>
</ul>
</div>
<div class="navpath"><a class="el" href="namespaceandroid.html">android</a>::<a class="el" href="classandroid_1_1_camera_hardware_interface.html">CameraHardwareInterface</a>
</div>
</div>
<div class="contents">
<h1>android::CameraHardwareInterface Class Reference</h1><!-- doxytag: class="android::CameraHardwareInterface" --><a class="el" href="_camera_hardware_interface_8h.html">CameraHardwareInterface.h</a> defines the interface to the camera hardware abstraction layer, used for setting and getting parameters, live previewing, and taking pictures.
<a href="#_details">More...</a>
<p>
<code>#include &lt;<a class="el" href="_camera_hardware_interface_8h-source.html">CameraHardwareInterface.h</a>&gt;</code>
<p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Public Member Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_camera_hardware_interface.html#99f4ab74b58cd4b23e0fb00a46a60cb1">~CameraHardwareInterface</a> ()</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual sp&lt; IMemoryHeap &gt;&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_camera_hardware_interface.html#9d4071fb234a0c2e7bf6ea78e723f2f4">getPreviewHeap</a> () const =0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Return the IMemoryHeap for the preview image heap. <a href="#9d4071fb234a0c2e7bf6ea78e723f2f4"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual status_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_camera_hardware_interface.html#62def8031dee8bdab7933770708a6312">startPreview</a> (<a class="el" href="namespaceandroid.html#d32b08663d42356404e2eb971e271636">preview_callback</a> cb, void *user)=0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Start preview mode. <a href="#62def8031dee8bdab7933770708a6312"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_camera_hardware_interface.html#34faa77065f415b93cb1acf84fc788bf">stopPreview</a> ()=0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Stop a previously started preview. <a href="#34faa77065f415b93cb1acf84fc788bf"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual status_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_camera_hardware_interface.html#0dda73938e9b18326dd48bd721dbd515">autoFocus</a> (<a class="el" href="namespaceandroid.html#4dca8d8b824ca9a684358133da0ec8f2">autofocus_callback</a>, void *user)=0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Start auto focus, the callback routine is called once when focusing is complete. <a href="#0dda73938e9b18326dd48bd721dbd515"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual status_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_camera_hardware_interface.html#2aedf65cad695ce439029f37a7cb66c4">takePicture</a> (<a class="el" href="namespaceandroid.html#04c83209c2627e2d303320712ca9ee65">shutter_callback</a>, <a class="el" href="namespaceandroid.html#a97926709e452d66360cb9b24736969e">raw_callback</a>, <a class="el" href="namespaceandroid.html#c21980d4be1e0cc458399ecf5374d473">jpeg_callback</a>, void *user)=0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Take a picture. <a href="#2aedf65cad695ce439029f37a7cb66c4"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual status_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_camera_hardware_interface.html#da8faf376215a605357d26afa1b79386">cancelPicture</a> (bool cancel_shutter, bool cancel_raw, bool cancel_jpeg)=0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Cancel a picture that was started with takePicture. <a href="#da8faf376215a605357d26afa1b79386"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual status_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_camera_hardware_interface.html#82e54ede14bd263274bbc8777bafc384">setParameters</a> (const CameraParameters &amp;params)=0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Set the camera parameters. <a href="#82e54ede14bd263274bbc8777bafc384"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual CameraParameters&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_camera_hardware_interface.html#4c748a3c0aa3c5f2333e0abcdbeb15cb">getParameters</a> () const =0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Return the camera parameters. <a href="#4c748a3c0aa3c5f2333e0abcdbeb15cb"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_camera_hardware_interface.html#df65310b8aa176e0ce5f08b87d6b7eb8">release</a> ()=0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Release the hardware resources owned by this object. <a href="#df65310b8aa176e0ce5f08b87d6b7eb8"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual status_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_camera_hardware_interface.html#06df1bf91b8af07964dca314a6031b32">dump</a> (int fd, const Vector&lt; String16 &gt; &amp;args) const =0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Dump state of the camera hardware. <a href="#06df1bf91b8af07964dca314a6031b32"></a><br></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
<a class="el" href="_camera_hardware_interface_8h.html">CameraHardwareInterface.h</a> defines the interface to the camera hardware abstraction layer, used for setting and getting parameters, live previewing, and taking pictures.
<p>
It is a referenced counted interface with RefBase as its base class. CameraService calls <a class="el" href="namespaceandroid.html#24c243f7f9ba0d1d881be17ae06254a2" title="factory function to instantiate a camera hardware object">openCameraHardware()</a> to retrieve a strong pointer to the instance of this interface and may be called multiple times. The following steps describe a typical sequence:<p>
<ol type=1>
<li>After CameraService calls <a class="el" href="namespaceandroid.html#24c243f7f9ba0d1d881be17ae06254a2" title="factory function to instantiate a camera hardware object">openCameraHardware()</a>, <a class="el" href="classandroid_1_1_camera_hardware_interface.html#4c748a3c0aa3c5f2333e0abcdbeb15cb" title="Return the camera parameters.">getParameters()</a> and <a class="el" href="classandroid_1_1_camera_hardware_interface.html#82e54ede14bd263274bbc8777bafc384" title="Set the camera parameters.">setParameters()</a> are used to initialize the camera instance. CameraService calls <a class="el" href="classandroid_1_1_camera_hardware_interface.html#9d4071fb234a0c2e7bf6ea78e723f2f4" title="Return the IMemoryHeap for the preview image heap.">getPreviewHeap()</a> to establish access to the preview heap so it can be registered with SurfaceFlinger for efficient display updating while in preview mode.</li><li><a class="el" href="classandroid_1_1_camera_hardware_interface.html#62def8031dee8bdab7933770708a6312" title="Start preview mode.">startPreview()</a> is called, which is passed a <a class="el" href="namespaceandroid.html#d32b08663d42356404e2eb971e271636" title="Callback for startPreview().">preview_callback()</a> function and a user parameter. The camera instance then periodically calls <a class="el" href="namespaceandroid.html#d32b08663d42356404e2eb971e271636" title="Callback for startPreview().">preview_callback()</a> each time a new preview frame is available. The callback routine has two parameters: the first is a pointer to the IMemory containing the frame and the second a user parameter. If the preview_callback code needs to use this memory after returning, it must copy the data.</li></ol>
<p>
Prior to taking a picture, CameraService calls autofocus() with <a class="el" href="namespaceandroid.html#4dca8d8b824ca9a684358133da0ec8f2" title="Callback for autoFocus().">autofocus_callback()</a> and a user parameter. When auto focusing has completed, the camera instance calls <a class="el" href="namespaceandroid.html#4dca8d8b824ca9a684358133da0ec8f2" title="Callback for autoFocus().">autofocus_callback()</a>, which informs the application whether focusing was successful. The camera instance only calls <a class="el" href="namespaceandroid.html#4dca8d8b824ca9a684358133da0ec8f2" title="Callback for autoFocus().">autofocus_callback()</a> once and it is up to the application to call <a class="el" href="classandroid_1_1_camera_hardware_interface.html#0dda73938e9b18326dd48bd721dbd515" title="Start auto focus, the callback routine is called once when focusing is complete.">autoFocus()</a> again if refocusing is desired.<p>
CameraService calls <a class="el" href="classandroid_1_1_camera_hardware_interface.html#2aedf65cad695ce439029f37a7cb66c4" title="Take a picture.">takePicture()</a> to request the camera instance take a picture. This method has two callbacks: <a class="el" href="namespaceandroid.html#a97926709e452d66360cb9b24736969e" title="Callback for takePicture().">raw_callback()</a> and <a class="el" href="namespaceandroid.html#c21980d4be1e0cc458399ecf5374d473" title="Callback for takePicture().">jpeg_callback()</a>. When the raw image is available, <a class="el" href="namespaceandroid.html#a97926709e452d66360cb9b24736969e" title="Callback for takePicture().">raw_callback()</a> is called with a pointer to the IMemory containing the raw image. When the jpeg image is available, <a class="el" href="namespaceandroid.html#c21980d4be1e0cc458399ecf5374d473" title="Callback for takePicture().">jpeg_callback()</a> is called with a pointer to the IMemory containing the jpeg image. As with <a class="el" href="namespaceandroid.html#d32b08663d42356404e2eb971e271636" title="Callback for startPreview().">preview_callback()</a>, the memory must be copied if it's needed after returning.
<p>Definition at line <a class="el" href="_camera_hardware_interface_8h-source.html#l00079">79</a> of file <a class="el" href="_camera_hardware_interface_8h-source.html">CameraHardwareInterface.h</a>.</p>
<hr><h2>Constructor &amp; Destructor Documentation</h2>
<a class="anchor" name="99f4ab74b58cd4b23e0fb00a46a60cb1"></a><!-- doxytag: member="android::CameraHardwareInterface::~CameraHardwareInterface" ref="99f4ab74b58cd4b23e0fb00a46a60cb1" args="()" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual android::CameraHardwareInterface::~CameraHardwareInterface </td>
<td>(</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td><code> [inline, virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
<p>Definition at line <a class="el" href="_camera_hardware_interface_8h-source.html#l00081">81</a> of file <a class="el" href="_camera_hardware_interface_8h-source.html">CameraHardwareInterface.h</a>.</p>
</div>
</div><p>
<hr><h2>Member Function Documentation</h2>
<a class="anchor" name="9d4071fb234a0c2e7bf6ea78e723f2f4"></a><!-- doxytag: member="android::CameraHardwareInterface::getPreviewHeap" ref="9d4071fb234a0c2e7bf6ea78e723f2f4" args="() const =0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual sp&lt;IMemoryHeap&gt; android::CameraHardwareInterface::getPreviewHeap </td>
<td>(</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td> const<code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Return the IMemoryHeap for the preview image heap.
<p>
</div>
</div><p>
<a class="anchor" name="62def8031dee8bdab7933770708a6312"></a><!-- doxytag: member="android::CameraHardwareInterface::startPreview" ref="62def8031dee8bdab7933770708a6312" args="(preview_callback cb, void *user)=0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual status_t android::CameraHardwareInterface::startPreview </td>
<td>(</td>
<td class="paramtype"><a class="el" href="namespaceandroid.html#d32b08663d42356404e2eb971e271636">preview_callback</a>&nbsp;</td>
<td class="paramname"> <em>cb</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">void *&nbsp;</td>
<td class="paramname"> <em>user</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td><code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Start preview mode.
<p>
When a preview image is available preview_callback is called with the user parameter. The call back parameter may be null.
</div>
</div><p>
<a class="anchor" name="34faa77065f415b93cb1acf84fc788bf"></a><!-- doxytag: member="android::CameraHardwareInterface::stopPreview" ref="34faa77065f415b93cb1acf84fc788bf" args="()=0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual void android::CameraHardwareInterface::stopPreview </td>
<td>(</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td><code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Stop a previously started preview.
<p>
</div>
</div><p>
<a class="anchor" name="0dda73938e9b18326dd48bd721dbd515"></a><!-- doxytag: member="android::CameraHardwareInterface::autoFocus" ref="0dda73938e9b18326dd48bd721dbd515" args="(autofocus_callback, void *user)=0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual status_t android::CameraHardwareInterface::autoFocus </td>
<td>(</td>
<td class="paramtype"><a class="el" href="namespaceandroid.html#4dca8d8b824ca9a684358133da0ec8f2">autofocus_callback</a>&nbsp;</td>
<td class="paramname">, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">void *&nbsp;</td>
<td class="paramname"> <em>user</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td><code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Start auto focus, the callback routine is called once when focusing is complete.
<p>
<a class="el" href="classandroid_1_1_camera_hardware_interface.html#0dda73938e9b18326dd48bd721dbd515" title="Start auto focus, the callback routine is called once when focusing is complete.">autoFocus()</a> will be called again if another auto focus is needed.
</div>
</div><p>
<a class="anchor" name="2aedf65cad695ce439029f37a7cb66c4"></a><!-- doxytag: member="android::CameraHardwareInterface::takePicture" ref="2aedf65cad695ce439029f37a7cb66c4" args="(shutter_callback, raw_callback, jpeg_callback, void *user)=0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual status_t android::CameraHardwareInterface::takePicture </td>
<td>(</td>
<td class="paramtype"><a class="el" href="namespaceandroid.html#04c83209c2627e2d303320712ca9ee65">shutter_callback</a>&nbsp;</td>
<td class="paramname">, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="namespaceandroid.html#a97926709e452d66360cb9b24736969e">raw_callback</a>&nbsp;</td>
<td class="paramname">, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="namespaceandroid.html#c21980d4be1e0cc458399ecf5374d473">jpeg_callback</a>&nbsp;</td>
<td class="paramname">, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">void *&nbsp;</td>
<td class="paramname"> <em>user</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td><code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Take a picture.
<p>
The raw_callback is called when the uncompressed image is available. The jpeg_callback is called when the compressed image is available. These call backs may be null. The user parameter is passed to each of the call back routines.
</div>
</div><p>
<a class="anchor" name="da8faf376215a605357d26afa1b79386"></a><!-- doxytag: member="android::CameraHardwareInterface::cancelPicture" ref="da8faf376215a605357d26afa1b79386" args="(bool cancel_shutter, bool cancel_raw, bool cancel_jpeg)=0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual status_t android::CameraHardwareInterface::cancelPicture </td>
<td>(</td>
<td class="paramtype">bool&nbsp;</td>
<td class="paramname"> <em>cancel_shutter</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">bool&nbsp;</td>
<td class="paramname"> <em>cancel_raw</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">bool&nbsp;</td>
<td class="paramname"> <em>cancel_jpeg</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td><code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Cancel a picture that was started with takePicture.
<p>
You may cancel any of the shutter, raw, or jpeg callbacks. Calling this method when no picture is being taken is a no-op.
</div>
</div><p>
<a class="anchor" name="82e54ede14bd263274bbc8777bafc384"></a><!-- doxytag: member="android::CameraHardwareInterface::setParameters" ref="82e54ede14bd263274bbc8777bafc384" args="(const CameraParameters &amp;params)=0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual status_t android::CameraHardwareInterface::setParameters </td>
<td>(</td>
<td class="paramtype">const CameraParameters &amp;&nbsp;</td>
<td class="paramname"> <em>params</em> </td>
<td>&nbsp;)&nbsp;</td>
<td><code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Set the camera parameters.
<p>
</div>
</div><p>
<a class="anchor" name="4c748a3c0aa3c5f2333e0abcdbeb15cb"></a><!-- doxytag: member="android::CameraHardwareInterface::getParameters" ref="4c748a3c0aa3c5f2333e0abcdbeb15cb" args="() const =0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual CameraParameters android::CameraHardwareInterface::getParameters </td>
<td>(</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td> const<code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Return the camera parameters.
<p>
</div>
</div><p>
<a class="anchor" name="df65310b8aa176e0ce5f08b87d6b7eb8"></a><!-- doxytag: member="android::CameraHardwareInterface::release" ref="df65310b8aa176e0ce5f08b87d6b7eb8" args="()=0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual void android::CameraHardwareInterface::release </td>
<td>(</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td><code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Release the hardware resources owned by this object.
<p>
Note that this is *not* done in the destructor.
</div>
</div><p>
<a class="anchor" name="06df1bf91b8af07964dca314a6031b32"></a><!-- doxytag: member="android::CameraHardwareInterface::dump" ref="06df1bf91b8af07964dca314a6031b32" args="(int fd, const Vector&lt; String16 &gt; &amp;args) const =0" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual status_t android::CameraHardwareInterface::dump </td>
<td>(</td>
<td class="paramtype">int&nbsp;</td>
<td class="paramname"> <em>fd</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const Vector&lt; String16 &gt; &amp;&nbsp;</td>
<td class="paramname"> <em>args</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td> const<code> [pure virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Dump state of the camera hardware.
<p>
</div>
</div><p>
<hr>The documentation for this class was generated from the following file:<ul>
<li><a class="el" href="_camera_hardware_interface_8h-source.html">CameraHardwareInterface.h</a></ul>
</div>
</body>
</html>

View File

@@ -1,473 +0,0 @@
BODY,H1,H2,H3,H4,H5,H6,P,CENTER,TD,TH,UL,DL,DIV {
font-family: Geneva, Arial, Helvetica, sans-serif;
}
BODY,TD {
font-size: 90%;
}
H1 {
text-align: center;
font-size: 160%;
}
H2 {
font-size: 120%;
}
H3 {
font-size: 100%;
}
CAPTION {
font-weight: bold
}
DIV.qindex {
width: 100%;
background-color: #e8eef2;
border: 1px solid #84b0c7;
text-align: center;
margin: 2px;
padding: 2px;
line-height: 140%;
}
DIV.navpath {
width: 100%;
background-color: #e8eef2;
border: 1px solid #84b0c7;
text-align: center;
margin: 2px;
padding: 2px;
line-height: 140%;
}
DIV.navtab {
background-color: #e8eef2;
border: 1px solid #84b0c7;
text-align: center;
margin: 2px;
margin-right: 15px;
padding: 2px;
}
TD.navtab {
font-size: 70%;
}
A.qindex {
text-decoration: none;
font-weight: bold;
color: #1A419D;
}
A.qindex:visited {
text-decoration: none;
font-weight: bold;
color: #1A419D
}
A.qindex:hover {
text-decoration: none;
background-color: #ddddff;
}
A.qindexHL {
text-decoration: none;
font-weight: bold;
background-color: #6666cc;
color: #ffffff;
border: 1px double #9295C2;
}
A.qindexHL:hover {
text-decoration: none;
background-color: #6666cc;
color: #ffffff;
}
A.qindexHL:visited {
text-decoration: none;
background-color: #6666cc;
color: #ffffff
}
A.el {
text-decoration: none;
font-weight: bold
}
A.elRef {
font-weight: bold
}
A.code:link {
text-decoration: none;
font-weight: normal;
color: #0000FF
}
A.code:visited {
text-decoration: none;
font-weight: normal;
color: #0000FF
}
A.codeRef:link {
font-weight: normal;
color: #0000FF
}
A.codeRef:visited {
font-weight: normal;
color: #0000FF
}
A:hover {
text-decoration: none;
background-color: #f2f2ff
}
DL.el {
margin-left: -1cm
}
.fragment {
font-family: monospace, fixed;
font-size: 95%;
}
PRE.fragment {
border: 1px solid #CCCCCC;
background-color: #f5f5f5;
margin-top: 4px;
margin-bottom: 4px;
margin-left: 2px;
margin-right: 8px;
padding-left: 6px;
padding-right: 6px;
padding-top: 4px;
padding-bottom: 4px;
}
DIV.ah {
background-color: black;
font-weight: bold;
color: #ffffff;
margin-bottom: 3px;
margin-top: 3px
}
DIV.groupHeader {
margin-left: 16px;
margin-top: 12px;
margin-bottom: 6px;
font-weight: bold;
}
DIV.groupText {
margin-left: 16px;
font-style: italic;
font-size: 90%
}
BODY {
background: white;
color: black;
margin-right: 20px;
margin-left: 20px;
}
TD.indexkey {
background-color: #e8eef2;
font-weight: bold;
padding-right : 10px;
padding-top : 2px;
padding-left : 10px;
padding-bottom : 2px;
margin-left : 0px;
margin-right : 0px;
margin-top : 2px;
margin-bottom : 2px;
border: 1px solid #CCCCCC;
}
TD.indexvalue {
background-color: #e8eef2;
font-style: italic;
padding-right : 10px;
padding-top : 2px;
padding-left : 10px;
padding-bottom : 2px;
margin-left : 0px;
margin-right : 0px;
margin-top : 2px;
margin-bottom : 2px;
border: 1px solid #CCCCCC;
}
TR.memlist {
background-color: #f0f0f0;
}
P.formulaDsp {
text-align: center;
}
IMG.formulaDsp {
}
IMG.formulaInl {
vertical-align: middle;
}
SPAN.keyword { color: #008000 }
SPAN.keywordtype { color: #604020 }
SPAN.keywordflow { color: #e08000 }
SPAN.comment { color: #800000 }
SPAN.preprocessor { color: #806020 }
SPAN.stringliteral { color: #002080 }
SPAN.charliteral { color: #008080 }
SPAN.vhdldigit { color: #ff00ff }
SPAN.vhdlchar { color: #000000 }
SPAN.vhdlkeyword { color: #700070 }
SPAN.vhdllogic { color: #ff0000 }
.mdescLeft {
padding: 0px 8px 4px 8px;
font-size: 80%;
font-style: italic;
background-color: #FAFAFA;
border-top: 1px none #E0E0E0;
border-right: 1px none #E0E0E0;
border-bottom: 1px none #E0E0E0;
border-left: 1px none #E0E0E0;
margin: 0px;
}
.mdescRight {
padding: 0px 8px 4px 8px;
font-size: 80%;
font-style: italic;
background-color: #FAFAFA;
border-top: 1px none #E0E0E0;
border-right: 1px none #E0E0E0;
border-bottom: 1px none #E0E0E0;
border-left: 1px none #E0E0E0;
margin: 0px;
}
.memItemLeft {
padding: 1px 0px 0px 8px;
margin: 4px;
border-top-width: 1px;
border-right-width: 1px;
border-bottom-width: 1px;
border-left-width: 1px;
border-top-color: #E0E0E0;
border-right-color: #E0E0E0;
border-bottom-color: #E0E0E0;
border-left-color: #E0E0E0;
border-top-style: solid;
border-right-style: none;
border-bottom-style: none;
border-left-style: none;
background-color: #FAFAFA;
font-size: 80%;
}
.memItemRight {
padding: 1px 8px 0px 8px;
margin: 4px;
border-top-width: 1px;
border-right-width: 1px;
border-bottom-width: 1px;
border-left-width: 1px;
border-top-color: #E0E0E0;
border-right-color: #E0E0E0;
border-bottom-color: #E0E0E0;
border-left-color: #E0E0E0;
border-top-style: solid;
border-right-style: none;
border-bottom-style: none;
border-left-style: none;
background-color: #FAFAFA;
font-size: 80%;
}
.memTemplItemLeft {
padding: 1px 0px 0px 8px;
margin: 4px;
border-top-width: 1px;
border-right-width: 1px;
border-bottom-width: 1px;
border-left-width: 1px;
border-top-color: #E0E0E0;
border-right-color: #E0E0E0;
border-bottom-color: #E0E0E0;
border-left-color: #E0E0E0;
border-top-style: none;
border-right-style: none;
border-bottom-style: none;
border-left-style: none;
background-color: #FAFAFA;
font-size: 80%;
}
.memTemplItemRight {
padding: 1px 8px 0px 8px;
margin: 4px;
border-top-width: 1px;
border-right-width: 1px;
border-bottom-width: 1px;
border-left-width: 1px;
border-top-color: #E0E0E0;
border-right-color: #E0E0E0;
border-bottom-color: #E0E0E0;
border-left-color: #E0E0E0;
border-top-style: none;
border-right-style: none;
border-bottom-style: none;
border-left-style: none;
background-color: #FAFAFA;
font-size: 80%;
}
.memTemplParams {
padding: 1px 0px 0px 8px;
margin: 4px;
border-top-width: 1px;
border-right-width: 1px;
border-bottom-width: 1px;
border-left-width: 1px;
border-top-color: #E0E0E0;
border-right-color: #E0E0E0;
border-bottom-color: #E0E0E0;
border-left-color: #E0E0E0;
border-top-style: solid;
border-right-style: none;
border-bottom-style: none;
border-left-style: none;
color: #606060;
background-color: #FAFAFA;
font-size: 80%;
}
.search {
color: #003399;
font-weight: bold;
}
FORM.search {
margin-bottom: 0px;
margin-top: 0px;
}
INPUT.search {
font-size: 75%;
color: #000080;
font-weight: normal;
background-color: #e8eef2;
}
TD.tiny {
font-size: 75%;
}
a {
color: #1A41A8;
}
a:visited {
color: #2A3798;
}
.dirtab {
padding: 4px;
border-collapse: collapse;
border: 1px solid #84b0c7;
}
TH.dirtab {
background: #e8eef2;
font-weight: bold;
}
HR {
height: 1px;
border: none;
border-top: 1px solid black;
}
/* Style for detailed member documentation */
.memtemplate {
font-size: 80%;
color: #606060;
font-weight: normal;
margin-left: 3px;
}
.memnav {
background-color: #e8eef2;
border: 1px solid #84b0c7;
text-align: center;
margin: 2px;
margin-right: 15px;
padding: 2px;
}
.memitem {
padding: 4px;
background-color: #eef3f5;
border-width: 1px;
border-style: solid;
border-color: #dedeee;
-moz-border-radius: 8px 8px 8px 8px;
}
.memname {
white-space: nowrap;
font-weight: bold;
}
.memdoc{
padding-left: 10px;
}
.memproto {
background-color: #d5e1e8;
width: 100%;
border-width: 1px;
border-style: solid;
border-color: #84b0c7;
font-weight: bold;
-moz-border-radius: 8px 8px 8px 8px;
}
.paramkey {
text-align: right;
}
.paramtype {
white-space: nowrap;
}
.paramname {
color: #602020;
font-style: italic;
white-space: nowrap;
}
/* End Styling for detailed member documentation */
/* for the tree view */
.ftvtree {
font-family: sans-serif;
margin:0.5em;
}
/* these are for tree view when used as main index */
.directory {
font-size: 9pt;
font-weight: bold;
}
.directory h3 {
margin: 0px;
margin-top: 1em;
font-size: 11pt;
}
/* The following two styles can be used to replace the root node title */
/* with an image of your choice. Simply uncomment the next two styles, */
/* specify the name of your image and be sure to set 'height' to the */
/* proper pixel height of your image. */
/* .directory h3.swap { */
/* height: 61px; */
/* background-repeat: no-repeat; */
/* background-image: url("yourimage.gif"); */
/* } */
/* .directory h3.swap span { */
/* display: none; */
/* } */
.directory > h3 {
margin-top: 0;
}
.directory p {
margin: 0px;
white-space: nowrap;
}
.directory div {
display: none;
margin: 0px;
}
.directory img {
vertical-align: -30%;
}
/* these are for tree view when not used as main index */
.directory-alt {
font-size: 100%;
font-weight: bold;
}
.directory-alt h3 {
margin: 0px;
margin-top: 1em;
font-size: 11pt;
}
.directory-alt > h3 {
margin-top: 0;
}
.directory-alt p {
margin: 0px;
white-space: nowrap;
}
.directory-alt div {
display: none;
margin: 0px;
}
.directory-alt img {
vertical-align: -30%;
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.3 KiB

View File

@@ -1,42 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Doxygen-Generated Content</title>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
.navigation {
display: none;
}
-->
</style>
</head>
<body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li class="current"><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li class="current"><a href="files.html"><span>File&nbsp;List</span></a></li>
<li><a href="globals.html"><span>Globals</span></a></li>
</ul>
</div>
</div>
<div class="contents">
<h1>File List</h1>Here is a list of all files with brief descriptions:<table>
<tr><td class="indexkey"><a class="el" href="_audio_hardware_interface_8h.html">AudioHardwareInterface.h</a> <a href="_audio_hardware_interface_8h-source.html">[code]</a></td><td class="indexvalue"></td></tr>
<tr><td class="indexkey"><a class="el" href="_camera_hardware_interface_8h.html">CameraHardwareInterface.h</a> <a href="_camera_hardware_interface_8h-source.html">[code]</a></td><td class="indexvalue"></td></tr>
<tr><td class="indexkey"><a class="el" href="gps_8h.html">gps.h</a> <a href="gps_8h-source.html">[code]</a></td><td class="indexvalue"></td></tr>
<tr><td class="indexkey"><a class="el" href="wifi_8h.html">wifi.h</a> <a href="wifi_8h-source.html">[code]</a></td><td class="indexvalue"></td></tr>
</table>
</div>
</body>
</html>

View File

@@ -1,258 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Doxygen-Generated Content</title>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
.navigation {
display: none;
}
-->
</style>
</head>
<body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li class="current"><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li class="current"><a href="functions.html"><span>Data&nbsp;Fields</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li class="current"><a href="functions.html"><span>All</span></a></li>
<li><a href="functions_func.html"><span>Functions</span></a></li>
<li><a href="functions_vars.html"><span>Variables</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="#index_a"><span>a</span></a></li>
<li><a href="#index_b"><span>b</span></a></li>
<li><a href="#index_c"><span>c</span></a></li>
<li><a href="#index_d"><span>d</span></a></li>
<li><a href="#index_e"><span>e</span></a></li>
<li><a href="#index_f"><span>f</span></a></li>
<li><a href="#index_g"><span>g</span></a></li>
<li><a href="#index_i"><span>i</span></a></li>
<li><a href="#index_l"><span>l</span></a></li>
<li><a href="#index_n"><span>n</span></a></li>
<li><a href="#index_o"><span>o</span></a></li>
<li><a href="#index_p"><span>p</span></a></li>
<li><a href="#index_r"><span>r</span></a></li>
<li><a href="#index_s"><span>s</span></a></li>
<li><a href="#index_t"><span>t</span></a></li>
<li><a href="#index_u"><span>u</span></a></li>
<li><a href="#index_w"><span>w</span></a></li>
<li><a href="#index_~"><span>~</span></a></li>
</ul>
</div>
</div>
<div class="contents">
Here is a list of all struct and union fields with links to the structures/unions they belong to:
<p>
<h3><a class="anchor" name="index_a">- a -</a></h3><ul>
<li>accuracy
: <a class="el" href="struct_gps_location.html#801ec0db8ee69fa263a63528876d773b">GpsLocation</a>
<li>almanac_mask
: <a class="el" href="struct_gps_sv_status.html#6ed4b741a9882ecc2852e94e8ad60310">GpsSvStatus</a>
<li>altitude
: <a class="el" href="struct_gps_location.html#cb3cc5ad378a6a3864e47ae67df38778">GpsLocation</a>
<li>autoFocus()
: <a class="el" href="classandroid_1_1_camera_hardware_interface.html#0dda73938e9b18326dd48bd721dbd515">android::CameraHardwareInterface</a>
<li>azimuth
: <a class="el" href="struct_gps_sv_info.html#94755ad36e31a012269459d5a4ef0594">GpsSvInfo</a>
</ul>
<h3><a class="anchor" name="index_b">- b -</a></h3><ul>
<li>bearing
: <a class="el" href="struct_gps_location.html#b71bf9b61cf55f10ffcf34ba1654d082">GpsLocation</a>
<li>bufferSize()
: <a class="el" href="classandroid_1_1_audio_stream_in.html#a458f9cde3edde82f256af7eaa7b2ddf">android::AudioStreamIn</a>
, <a class="el" href="classandroid_1_1_audio_stream_out.html#7b3c5f2ce79b9b6f167408f63d19af0a">android::AudioStreamOut</a>
</ul>
<h3><a class="anchor" name="index_c">- c -</a></h3><ul>
<li>cancelPicture()
: <a class="el" href="classandroid_1_1_camera_hardware_interface.html#da8faf376215a605357d26afa1b79386">android::CameraHardwareInterface</a>
<li>channelCount()
: <a class="el" href="classandroid_1_1_audio_stream_out.html#4e880a5379c168e8f68c26827e41275b">android::AudioStreamOut</a>
, <a class="el" href="classandroid_1_1_audio_stream_in.html#04f84006dd5f2e0a5e512897a039f851">android::AudioStreamIn</a>
<li>cleanup
: <a class="el" href="struct_gps_interface.html#2911808e36c70259dc0db162de02dc13">GpsInterface</a>
<li>create()
: <a class="el" href="classandroid_1_1_audio_hardware_interface.html#aa5ae45e9ad969fefc494e103cf5068d">android::AudioHardwareInterface</a>
</ul>
<h3><a class="anchor" name="index_d">- d -</a></h3><ul>
<li>delete_aiding_data
: <a class="el" href="struct_gps_interface.html#a3a9b81a8a719b628ac8049344f50b58">GpsInterface</a>
<li>doRouting()
: <a class="el" href="classandroid_1_1_audio_hardware_interface.html#d82c3e4827f275abf28eb872e8751e1f">android::AudioHardwareInterface</a>
<li>download_request_cb
: <a class="el" href="struct_gps_xtra_callbacks.html#7e879ba4c3e32c52eaa0fb04fb9c226f">GpsXtraCallbacks</a>
<li>dump()
: <a class="el" href="classandroid_1_1_audio_hardware_interface.html#371f198a416cb726804e0f47e8763217">android::AudioHardwareInterface</a>
, <a class="el" href="classandroid_1_1_audio_stream_in.html#18c3760208bfb99498715a0d4977f675">android::AudioStreamIn</a>
, <a class="el" href="classandroid_1_1_audio_stream_out.html#97e3cc4610ba40d6c37b3d376a032b98">android::AudioStreamOut</a>
, <a class="el" href="classandroid_1_1_camera_hardware_interface.html#06df1bf91b8af07964dca314a6031b32">android::CameraHardwareInterface</a>
<li>dumpState()
: <a class="el" href="classandroid_1_1_audio_hardware_interface.html#05f035af60e67a22251175b44a089f69">android::AudioHardwareInterface</a>
</ul>
<h3><a class="anchor" name="index_e">- e -</a></h3><ul>
<li>elevation
: <a class="el" href="struct_gps_sv_info.html#0634009d0476b2f06f27568b0722a04d">GpsSvInfo</a>
<li>ephemeris_mask
: <a class="el" href="struct_gps_sv_status.html#4751f70f8e275241dece99db0df4ab5b">GpsSvStatus</a>
</ul>
<h3><a class="anchor" name="index_f">- f -</a></h3><ul>
<li>flags
: <a class="el" href="struct_gps_location.html#07d55fee34dc28cff50062e9ac42c717">GpsLocation</a>
<li>format()
: <a class="el" href="classandroid_1_1_audio_stream_out.html#eb2b430bbff4eebd8fb8590507b1dce1">android::AudioStreamOut</a>
, <a class="el" href="classandroid_1_1_audio_stream_in.html#4ade98c5243b9ed5f3a71a8f36e74b36">android::AudioStreamIn</a>
<li>frameSize()
: <a class="el" href="classandroid_1_1_audio_stream_out.html#66b7c4bb510db4060adfd03a376897d8">android::AudioStreamOut</a>
, <a class="el" href="classandroid_1_1_audio_stream_in.html#43d2c6b97806c005f0717a7bb6f7595c">android::AudioStreamIn</a>
</ul>
<h3><a class="anchor" name="index_g">- g -</a></h3><ul>
<li>get_extension
: <a class="el" href="struct_gps_interface.html#19af32bd9d01ebbcdb196e36514b0e98">GpsInterface</a>
<li>getInputBufferSize()
: <a class="el" href="classandroid_1_1_audio_hardware_interface.html#19f68d873b2a6e4c00c017c580170395">android::AudioHardwareInterface</a>
<li>getMicMute()
: <a class="el" href="classandroid_1_1_audio_hardware_interface.html#15d3c33d7e3f965dc2588c537f05a133">android::AudioHardwareInterface</a>
<li>getMode()
: <a class="el" href="classandroid_1_1_audio_hardware_interface.html#8466c76328a51b8a83da103032abba55">android::AudioHardwareInterface</a>
<li>getParameters()
: <a class="el" href="classandroid_1_1_camera_hardware_interface.html#4c748a3c0aa3c5f2333e0abcdbeb15cb">android::CameraHardwareInterface</a>
<li>getPreviewHeap()
: <a class="el" href="classandroid_1_1_camera_hardware_interface.html#9d4071fb234a0c2e7bf6ea78e723f2f4">android::CameraHardwareInterface</a>
<li>getRouting()
: <a class="el" href="classandroid_1_1_audio_hardware_interface.html#1886de8fff2342ae628dbbbc0c45ba83">android::AudioHardwareInterface</a>
</ul>
<h3><a class="anchor" name="index_i">- i -</a></h3><ul>
<li>init
: <a class="el" href="struct_gps_interface.html#d5139fa13b75108bdedd8a2717f37135">GpsInterface</a>
, <a class="el" href="struct_gps_xtra_interface.html#5532e662c68e1d3df7db86570df96bf0">GpsXtraInterface</a>
<li>initCheck()
: <a class="el" href="classandroid_1_1_audio_hardware_interface.html#b7e19e09fa6cbc07c127122fa9866c50">android::AudioHardwareInterface</a>
<li>inject_time
: <a class="el" href="struct_gps_interface.html#e731891e96a916271a4275eaaea47ad8">GpsInterface</a>
<li>inject_xtra_data
: <a class="el" href="struct_gps_xtra_interface.html#2b1962c8a5a2751702937cf469dc7435">GpsXtraInterface</a>
</ul>
<h3><a class="anchor" name="index_l">- l -</a></h3><ul>
<li>latency()
: <a class="el" href="classandroid_1_1_audio_stream_out.html#c698a3d95cf0829dcfe283cd5ea437cb">android::AudioStreamOut</a>
<li>latitude
: <a class="el" href="struct_gps_location.html#3a7da06efae47c66428fa2815a3eb4bd">GpsLocation</a>
<li>location_cb
: <a class="el" href="struct_gps_callbacks.html#1f59b4f8eeaca50620f94761536dabd3">GpsCallbacks</a>
<li>longitude
: <a class="el" href="struct_gps_location.html#3672d2d19087d62d7ea9b0b71418da40">GpsLocation</a>
</ul>
<h3><a class="anchor" name="index_n">- n -</a></h3><ul>
<li>num_svs
: <a class="el" href="struct_gps_sv_status.html#b90eb63a499039de996c95d98afad545">GpsSvStatus</a>
</ul>
<h3><a class="anchor" name="index_o">- o -</a></h3><ul>
<li>openInputStream()
: <a class="el" href="classandroid_1_1_audio_hardware_interface.html#efb777d192fcbcd65458fa4f2d976476">android::AudioHardwareInterface</a>
<li>openOutputStream()
: <a class="el" href="classandroid_1_1_audio_hardware_interface.html#eda0986e145c8dd68d21cb79051f94f9">android::AudioHardwareInterface</a>
</ul>
<h3><a class="anchor" name="index_p">- p -</a></h3><ul>
<li>prn
: <a class="el" href="struct_gps_sv_info.html#5c94e86f2efc3ed08fb5a40735a2440b">GpsSvInfo</a>
</ul>
<h3><a class="anchor" name="index_r">- r -</a></h3><ul>
<li>read()
: <a class="el" href="classandroid_1_1_audio_stream_in.html#7c313cbfbb47dafd90f3225bcd26e592">android::AudioStreamIn</a>
<li>release()
: <a class="el" href="classandroid_1_1_camera_hardware_interface.html#df65310b8aa176e0ce5f08b87d6b7eb8">android::CameraHardwareInterface</a>
</ul>
<h3><a class="anchor" name="index_s">- s -</a></h3><ul>
<li>sampleRate()
: <a class="el" href="classandroid_1_1_audio_stream_out.html#6bb028e125d13289f26d3d74f851c921">android::AudioStreamOut</a>
<li>set_apn
: <a class="el" href="struct_gps_supl_interface.html#145834775007930d644086393a6b9dce">GpsSuplInterface</a>
<li>set_fix_frequency
: <a class="el" href="struct_gps_interface.html#1e727f5862ae7132f12af44ebdfa76b2">GpsInterface</a>
<li>set_position_mode
: <a class="el" href="struct_gps_interface.html#924bff47462a773b669d310d87b75734">GpsInterface</a>
<li>setGain()
: <a class="el" href="classandroid_1_1_audio_stream_in.html#339822afb3f2f2ac1b4c775d31d12440">android::AudioStreamIn</a>
<li>setMasterVolume()
: <a class="el" href="classandroid_1_1_audio_hardware_interface.html#925092e556eb89f304bcebb09f90c9a3">android::AudioHardwareInterface</a>
<li>setMicMute()
: <a class="el" href="classandroid_1_1_audio_hardware_interface.html#be35b7cb738531939a3ac9abc5514621">android::AudioHardwareInterface</a>
<li>setMode()
: <a class="el" href="classandroid_1_1_audio_hardware_interface.html#aaf2a429c240f00b21836794849b430f">android::AudioHardwareInterface</a>
<li>setParameter()
: <a class="el" href="classandroid_1_1_audio_hardware_interface.html#a1b477901df48b3a27103a77e6bb39c8">android::AudioHardwareInterface</a>
<li>setParameters()
: <a class="el" href="classandroid_1_1_camera_hardware_interface.html#82e54ede14bd263274bbc8777bafc384">android::CameraHardwareInterface</a>
<li>setRouting()
: <a class="el" href="classandroid_1_1_audio_hardware_interface.html#39b2690e19219425b8cff093ef83bfb1">android::AudioHardwareInterface</a>
<li>setVoiceVolume()
: <a class="el" href="classandroid_1_1_audio_hardware_interface.html#7b7418072df1eeaacc89cd0c725755f6">android::AudioHardwareInterface</a>
<li>setVolume()
: <a class="el" href="classandroid_1_1_audio_stream_out.html#e6d301925d193c25561b42239c7f44b6">android::AudioStreamOut</a>
<li>snr
: <a class="el" href="struct_gps_sv_info.html#eebf16140beb95390733529bd5e7db58">GpsSvInfo</a>
<li>speed
: <a class="el" href="struct_gps_location.html#38ae20b9c5e7be995513dce25ed87016">GpsLocation</a>
<li>standby()
: <a class="el" href="classandroid_1_1_audio_stream_in.html#93fab46e8afdbaedd4d20cc6ee2b7c41">android::AudioStreamIn</a>
, <a class="el" href="classandroid_1_1_audio_hardware_interface.html#61121d365bb4d182bdec2c1b12fb1178">android::AudioHardwareInterface</a>
<li>start
: <a class="el" href="struct_gps_interface.html#2b212721e0d160e24944330b2d830790">GpsInterface</a>
<li>startPreview()
: <a class="el" href="classandroid_1_1_camera_hardware_interface.html#62def8031dee8bdab7933770708a6312">android::CameraHardwareInterface</a>
<li>status
: <a class="el" href="struct_gps_status.html#64c9e8cd609d97533bee5c5e8ca78608">GpsStatus</a>
<li>status_cb
: <a class="el" href="struct_gps_callbacks.html#7b15a1bf4f9b989677fef84f4d8141df">GpsCallbacks</a>
<li>stop
: <a class="el" href="struct_gps_interface.html#d20b0cfcbf976d8cec17bf4ea0a027f1">GpsInterface</a>
<li>stopPreview()
: <a class="el" href="classandroid_1_1_camera_hardware_interface.html#34faa77065f415b93cb1acf84fc788bf">android::CameraHardwareInterface</a>
<li>sv_list
: <a class="el" href="struct_gps_sv_status.html#7a3fe2114e7a603b96fd9675adf0c5b5">GpsSvStatus</a>
<li>sv_status_cb
: <a class="el" href="struct_gps_callbacks.html#fb34f60ad58e80de5c04790b107bb93d">GpsCallbacks</a>
</ul>
<h3><a class="anchor" name="index_t">- t -</a></h3><ul>
<li>takePicture()
: <a class="el" href="classandroid_1_1_camera_hardware_interface.html#2aedf65cad695ce439029f37a7cb66c4">android::CameraHardwareInterface</a>
<li>timestamp
: <a class="el" href="struct_gps_location.html#3e16861f64869d6f0e15e4300bb2658b">GpsLocation</a>
</ul>
<h3><a class="anchor" name="index_u">- u -</a></h3><ul>
<li>used_in_fix_mask
: <a class="el" href="struct_gps_sv_status.html#9090a26639d97eec2b59bcd0446659c0">GpsSvStatus</a>
</ul>
<h3><a class="anchor" name="index_w">- w -</a></h3><ul>
<li>write()
: <a class="el" href="classandroid_1_1_audio_stream_out.html#cba177e4a4a35a87ab9f8aa2a9c0e78e">android::AudioStreamOut</a>
</ul>
<h3><a class="anchor" name="index_~">- ~ -</a></h3><ul>
<li>~AudioStreamIn()
: <a class="el" href="classandroid_1_1_audio_stream_in.html#72067577568bbdd0163c1369fe80f101">android::AudioStreamIn</a>
<li>~AudioStreamOut()
: <a class="el" href="classandroid_1_1_audio_stream_out.html#09074dbae95b82d4f83c513035a0034f">android::AudioStreamOut</a>
<li>~CameraHardwareInterface()
: <a class="el" href="classandroid_1_1_camera_hardware_interface.html#99f4ab74b58cd4b23e0fb00a46a60cb1">android::CameraHardwareInterface</a>
</ul>
</div>
</body>
</html>

View File

@@ -1,179 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Doxygen-Generated Content</title>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
.navigation {
display: none;
}
-->
</style>
</head>
<body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li class="current"><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li class="current"><a href="functions.html"><span>Data&nbsp;Fields</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="functions.html"><span>All</span></a></li>
<li class="current"><a href="functions_func.html"><span>Functions</span></a></li>
<li><a href="functions_vars.html"><span>Variables</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="#index_a"><span>a</span></a></li>
<li><a href="#index_b"><span>b</span></a></li>
<li><a href="#index_c"><span>c</span></a></li>
<li><a href="#index_d"><span>d</span></a></li>
<li><a href="#index_f"><span>f</span></a></li>
<li><a href="#index_g"><span>g</span></a></li>
<li><a href="#index_i"><span>i</span></a></li>
<li><a href="#index_l"><span>l</span></a></li>
<li><a href="#index_o"><span>o</span></a></li>
<li><a href="#index_r"><span>r</span></a></li>
<li><a href="#index_s"><span>s</span></a></li>
<li><a href="#index_t"><span>t</span></a></li>
<li><a href="#index_w"><span>w</span></a></li>
<li><a href="#index_~"><span>~</span></a></li>
</ul>
</div>
</div>
<div class="contents">
&nbsp;
<p>
<h3><a class="anchor" name="index_a">- a -</a></h3><ul>
<li>autoFocus()
: <a class="el" href="classandroid_1_1_camera_hardware_interface.html#0dda73938e9b18326dd48bd721dbd515">android::CameraHardwareInterface</a>
</ul>
<h3><a class="anchor" name="index_b">- b -</a></h3><ul>
<li>bufferSize()
: <a class="el" href="classandroid_1_1_audio_stream_out.html#7b3c5f2ce79b9b6f167408f63d19af0a">android::AudioStreamOut</a>
, <a class="el" href="classandroid_1_1_audio_stream_in.html#a458f9cde3edde82f256af7eaa7b2ddf">android::AudioStreamIn</a>
</ul>
<h3><a class="anchor" name="index_c">- c -</a></h3><ul>
<li>cancelPicture()
: <a class="el" href="classandroid_1_1_camera_hardware_interface.html#da8faf376215a605357d26afa1b79386">android::CameraHardwareInterface</a>
<li>channelCount()
: <a class="el" href="classandroid_1_1_audio_stream_out.html#4e880a5379c168e8f68c26827e41275b">android::AudioStreamOut</a>
, <a class="el" href="classandroid_1_1_audio_stream_in.html#04f84006dd5f2e0a5e512897a039f851">android::AudioStreamIn</a>
<li>create()
: <a class="el" href="classandroid_1_1_audio_hardware_interface.html#aa5ae45e9ad969fefc494e103cf5068d">android::AudioHardwareInterface</a>
</ul>
<h3><a class="anchor" name="index_d">- d -</a></h3><ul>
<li>doRouting()
: <a class="el" href="classandroid_1_1_audio_hardware_interface.html#d82c3e4827f275abf28eb872e8751e1f">android::AudioHardwareInterface</a>
<li>dump()
: <a class="el" href="classandroid_1_1_audio_stream_out.html#97e3cc4610ba40d6c37b3d376a032b98">android::AudioStreamOut</a>
, <a class="el" href="classandroid_1_1_camera_hardware_interface.html#06df1bf91b8af07964dca314a6031b32">android::CameraHardwareInterface</a>
, <a class="el" href="classandroid_1_1_audio_hardware_interface.html#371f198a416cb726804e0f47e8763217">android::AudioHardwareInterface</a>
, <a class="el" href="classandroid_1_1_audio_stream_in.html#18c3760208bfb99498715a0d4977f675">android::AudioStreamIn</a>
<li>dumpState()
: <a class="el" href="classandroid_1_1_audio_hardware_interface.html#05f035af60e67a22251175b44a089f69">android::AudioHardwareInterface</a>
</ul>
<h3><a class="anchor" name="index_f">- f -</a></h3><ul>
<li>format()
: <a class="el" href="classandroid_1_1_audio_stream_out.html#eb2b430bbff4eebd8fb8590507b1dce1">android::AudioStreamOut</a>
, <a class="el" href="classandroid_1_1_audio_stream_in.html#4ade98c5243b9ed5f3a71a8f36e74b36">android::AudioStreamIn</a>
<li>frameSize()
: <a class="el" href="classandroid_1_1_audio_stream_out.html#66b7c4bb510db4060adfd03a376897d8">android::AudioStreamOut</a>
, <a class="el" href="classandroid_1_1_audio_stream_in.html#43d2c6b97806c005f0717a7bb6f7595c">android::AudioStreamIn</a>
</ul>
<h3><a class="anchor" name="index_g">- g -</a></h3><ul>
<li>getInputBufferSize()
: <a class="el" href="classandroid_1_1_audio_hardware_interface.html#19f68d873b2a6e4c00c017c580170395">android::AudioHardwareInterface</a>
<li>getMicMute()
: <a class="el" href="classandroid_1_1_audio_hardware_interface.html#15d3c33d7e3f965dc2588c537f05a133">android::AudioHardwareInterface</a>
<li>getMode()
: <a class="el" href="classandroid_1_1_audio_hardware_interface.html#8466c76328a51b8a83da103032abba55">android::AudioHardwareInterface</a>
<li>getParameters()
: <a class="el" href="classandroid_1_1_camera_hardware_interface.html#4c748a3c0aa3c5f2333e0abcdbeb15cb">android::CameraHardwareInterface</a>
<li>getPreviewHeap()
: <a class="el" href="classandroid_1_1_camera_hardware_interface.html#9d4071fb234a0c2e7bf6ea78e723f2f4">android::CameraHardwareInterface</a>
<li>getRouting()
: <a class="el" href="classandroid_1_1_audio_hardware_interface.html#1886de8fff2342ae628dbbbc0c45ba83">android::AudioHardwareInterface</a>
</ul>
<h3><a class="anchor" name="index_i">- i -</a></h3><ul>
<li>initCheck()
: <a class="el" href="classandroid_1_1_audio_hardware_interface.html#b7e19e09fa6cbc07c127122fa9866c50">android::AudioHardwareInterface</a>
</ul>
<h3><a class="anchor" name="index_l">- l -</a></h3><ul>
<li>latency()
: <a class="el" href="classandroid_1_1_audio_stream_out.html#c698a3d95cf0829dcfe283cd5ea437cb">android::AudioStreamOut</a>
</ul>
<h3><a class="anchor" name="index_o">- o -</a></h3><ul>
<li>openInputStream()
: <a class="el" href="classandroid_1_1_audio_hardware_interface.html#efb777d192fcbcd65458fa4f2d976476">android::AudioHardwareInterface</a>
<li>openOutputStream()
: <a class="el" href="classandroid_1_1_audio_hardware_interface.html#eda0986e145c8dd68d21cb79051f94f9">android::AudioHardwareInterface</a>
</ul>
<h3><a class="anchor" name="index_r">- r -</a></h3><ul>
<li>read()
: <a class="el" href="classandroid_1_1_audio_stream_in.html#7c313cbfbb47dafd90f3225bcd26e592">android::AudioStreamIn</a>
<li>release()
: <a class="el" href="classandroid_1_1_camera_hardware_interface.html#df65310b8aa176e0ce5f08b87d6b7eb8">android::CameraHardwareInterface</a>
</ul>
<h3><a class="anchor" name="index_s">- s -</a></h3><ul>
<li>sampleRate()
: <a class="el" href="classandroid_1_1_audio_stream_out.html#6bb028e125d13289f26d3d74f851c921">android::AudioStreamOut</a>
<li>setGain()
: <a class="el" href="classandroid_1_1_audio_stream_in.html#339822afb3f2f2ac1b4c775d31d12440">android::AudioStreamIn</a>
<li>setMasterVolume()
: <a class="el" href="classandroid_1_1_audio_hardware_interface.html#925092e556eb89f304bcebb09f90c9a3">android::AudioHardwareInterface</a>
<li>setMicMute()
: <a class="el" href="classandroid_1_1_audio_hardware_interface.html#be35b7cb738531939a3ac9abc5514621">android::AudioHardwareInterface</a>
<li>setMode()
: <a class="el" href="classandroid_1_1_audio_hardware_interface.html#aaf2a429c240f00b21836794849b430f">android::AudioHardwareInterface</a>
<li>setParameter()
: <a class="el" href="classandroid_1_1_audio_hardware_interface.html#a1b477901df48b3a27103a77e6bb39c8">android::AudioHardwareInterface</a>
<li>setParameters()
: <a class="el" href="classandroid_1_1_camera_hardware_interface.html#82e54ede14bd263274bbc8777bafc384">android::CameraHardwareInterface</a>
<li>setRouting()
: <a class="el" href="classandroid_1_1_audio_hardware_interface.html#39b2690e19219425b8cff093ef83bfb1">android::AudioHardwareInterface</a>
<li>setVoiceVolume()
: <a class="el" href="classandroid_1_1_audio_hardware_interface.html#7b7418072df1eeaacc89cd0c725755f6">android::AudioHardwareInterface</a>
<li>setVolume()
: <a class="el" href="classandroid_1_1_audio_stream_out.html#e6d301925d193c25561b42239c7f44b6">android::AudioStreamOut</a>
<li>standby()
: <a class="el" href="classandroid_1_1_audio_hardware_interface.html#61121d365bb4d182bdec2c1b12fb1178">android::AudioHardwareInterface</a>
, <a class="el" href="classandroid_1_1_audio_stream_in.html#93fab46e8afdbaedd4d20cc6ee2b7c41">android::AudioStreamIn</a>
<li>startPreview()
: <a class="el" href="classandroid_1_1_camera_hardware_interface.html#62def8031dee8bdab7933770708a6312">android::CameraHardwareInterface</a>
<li>stopPreview()
: <a class="el" href="classandroid_1_1_camera_hardware_interface.html#34faa77065f415b93cb1acf84fc788bf">android::CameraHardwareInterface</a>
</ul>
<h3><a class="anchor" name="index_t">- t -</a></h3><ul>
<li>takePicture()
: <a class="el" href="classandroid_1_1_camera_hardware_interface.html#2aedf65cad695ce439029f37a7cb66c4">android::CameraHardwareInterface</a>
</ul>
<h3><a class="anchor" name="index_w">- w -</a></h3><ul>
<li>write()
: <a class="el" href="classandroid_1_1_audio_stream_out.html#cba177e4a4a35a87ab9f8aa2a9c0e78e">android::AudioStreamOut</a>
</ul>
<h3><a class="anchor" name="index_~">- ~ -</a></h3><ul>
<li>~AudioStreamIn()
: <a class="el" href="classandroid_1_1_audio_stream_in.html#72067577568bbdd0163c1369fe80f101">android::AudioStreamIn</a>
<li>~AudioStreamOut()
: <a class="el" href="classandroid_1_1_audio_stream_out.html#09074dbae95b82d4f83c513035a0034f">android::AudioStreamOut</a>
<li>~CameraHardwareInterface()
: <a class="el" href="classandroid_1_1_camera_hardware_interface.html#99f4ab74b58cd4b23e0fb00a46a60cb1">android::CameraHardwareInterface</a>
</ul>
</div>
</body>
</html>

View File

@@ -1,158 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Doxygen-Generated Content</title>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
.navigation {
display: none;
}
-->
</style>
</head>
<body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li class="current"><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li class="current"><a href="functions.html"><span>Data&nbsp;Fields</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="functions.html"><span>All</span></a></li>
<li><a href="functions_func.html"><span>Functions</span></a></li>
<li class="current"><a href="functions_vars.html"><span>Variables</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="#index_a"><span>a</span></a></li>
<li><a href="#index_b"><span>b</span></a></li>
<li><a href="#index_c"><span>c</span></a></li>
<li><a href="#index_d"><span>d</span></a></li>
<li><a href="#index_e"><span>e</span></a></li>
<li><a href="#index_f"><span>f</span></a></li>
<li><a href="#index_g"><span>g</span></a></li>
<li><a href="#index_i"><span>i</span></a></li>
<li><a href="#index_l"><span>l</span></a></li>
<li><a href="#index_n"><span>n</span></a></li>
<li><a href="#index_p"><span>p</span></a></li>
<li><a href="#index_s"><span>s</span></a></li>
<li><a href="#index_t"><span>t</span></a></li>
<li><a href="#index_u"><span>u</span></a></li>
</ul>
</div>
</div>
<div class="contents">
&nbsp;
<p>
<h3><a class="anchor" name="index_a">- a -</a></h3><ul>
<li>accuracy
: <a class="el" href="struct_gps_location.html#801ec0db8ee69fa263a63528876d773b">GpsLocation</a>
<li>almanac_mask
: <a class="el" href="struct_gps_sv_status.html#6ed4b741a9882ecc2852e94e8ad60310">GpsSvStatus</a>
<li>altitude
: <a class="el" href="struct_gps_location.html#cb3cc5ad378a6a3864e47ae67df38778">GpsLocation</a>
<li>azimuth
: <a class="el" href="struct_gps_sv_info.html#94755ad36e31a012269459d5a4ef0594">GpsSvInfo</a>
</ul>
<h3><a class="anchor" name="index_b">- b -</a></h3><ul>
<li>bearing
: <a class="el" href="struct_gps_location.html#b71bf9b61cf55f10ffcf34ba1654d082">GpsLocation</a>
</ul>
<h3><a class="anchor" name="index_c">- c -</a></h3><ul>
<li>cleanup
: <a class="el" href="struct_gps_interface.html#2911808e36c70259dc0db162de02dc13">GpsInterface</a>
</ul>
<h3><a class="anchor" name="index_d">- d -</a></h3><ul>
<li>delete_aiding_data
: <a class="el" href="struct_gps_interface.html#a3a9b81a8a719b628ac8049344f50b58">GpsInterface</a>
<li>download_request_cb
: <a class="el" href="struct_gps_xtra_callbacks.html#7e879ba4c3e32c52eaa0fb04fb9c226f">GpsXtraCallbacks</a>
</ul>
<h3><a class="anchor" name="index_e">- e -</a></h3><ul>
<li>elevation
: <a class="el" href="struct_gps_sv_info.html#0634009d0476b2f06f27568b0722a04d">GpsSvInfo</a>
<li>ephemeris_mask
: <a class="el" href="struct_gps_sv_status.html#4751f70f8e275241dece99db0df4ab5b">GpsSvStatus</a>
</ul>
<h3><a class="anchor" name="index_f">- f -</a></h3><ul>
<li>flags
: <a class="el" href="struct_gps_location.html#07d55fee34dc28cff50062e9ac42c717">GpsLocation</a>
</ul>
<h3><a class="anchor" name="index_g">- g -</a></h3><ul>
<li>get_extension
: <a class="el" href="struct_gps_interface.html#19af32bd9d01ebbcdb196e36514b0e98">GpsInterface</a>
</ul>
<h3><a class="anchor" name="index_i">- i -</a></h3><ul>
<li>init
: <a class="el" href="struct_gps_interface.html#d5139fa13b75108bdedd8a2717f37135">GpsInterface</a>
, <a class="el" href="struct_gps_xtra_interface.html#5532e662c68e1d3df7db86570df96bf0">GpsXtraInterface</a>
<li>inject_time
: <a class="el" href="struct_gps_interface.html#e731891e96a916271a4275eaaea47ad8">GpsInterface</a>
<li>inject_xtra_data
: <a class="el" href="struct_gps_xtra_interface.html#2b1962c8a5a2751702937cf469dc7435">GpsXtraInterface</a>
</ul>
<h3><a class="anchor" name="index_l">- l -</a></h3><ul>
<li>latitude
: <a class="el" href="struct_gps_location.html#3a7da06efae47c66428fa2815a3eb4bd">GpsLocation</a>
<li>location_cb
: <a class="el" href="struct_gps_callbacks.html#1f59b4f8eeaca50620f94761536dabd3">GpsCallbacks</a>
<li>longitude
: <a class="el" href="struct_gps_location.html#3672d2d19087d62d7ea9b0b71418da40">GpsLocation</a>
</ul>
<h3><a class="anchor" name="index_n">- n -</a></h3><ul>
<li>num_svs
: <a class="el" href="struct_gps_sv_status.html#b90eb63a499039de996c95d98afad545">GpsSvStatus</a>
</ul>
<h3><a class="anchor" name="index_p">- p -</a></h3><ul>
<li>prn
: <a class="el" href="struct_gps_sv_info.html#5c94e86f2efc3ed08fb5a40735a2440b">GpsSvInfo</a>
</ul>
<h3><a class="anchor" name="index_s">- s -</a></h3><ul>
<li>set_apn
: <a class="el" href="struct_gps_supl_interface.html#145834775007930d644086393a6b9dce">GpsSuplInterface</a>
<li>set_fix_frequency
: <a class="el" href="struct_gps_interface.html#1e727f5862ae7132f12af44ebdfa76b2">GpsInterface</a>
<li>set_position_mode
: <a class="el" href="struct_gps_interface.html#924bff47462a773b669d310d87b75734">GpsInterface</a>
<li>snr
: <a class="el" href="struct_gps_sv_info.html#eebf16140beb95390733529bd5e7db58">GpsSvInfo</a>
<li>speed
: <a class="el" href="struct_gps_location.html#38ae20b9c5e7be995513dce25ed87016">GpsLocation</a>
<li>start
: <a class="el" href="struct_gps_interface.html#2b212721e0d160e24944330b2d830790">GpsInterface</a>
<li>status
: <a class="el" href="struct_gps_status.html#64c9e8cd609d97533bee5c5e8ca78608">GpsStatus</a>
<li>status_cb
: <a class="el" href="struct_gps_callbacks.html#7b15a1bf4f9b989677fef84f4d8141df">GpsCallbacks</a>
<li>stop
: <a class="el" href="struct_gps_interface.html#d20b0cfcbf976d8cec17bf4ea0a027f1">GpsInterface</a>
<li>sv_list
: <a class="el" href="struct_gps_sv_status.html#7a3fe2114e7a603b96fd9675adf0c5b5">GpsSvStatus</a>
<li>sv_status_cb
: <a class="el" href="struct_gps_callbacks.html#fb34f60ad58e80de5c04790b107bb93d">GpsCallbacks</a>
</ul>
<h3><a class="anchor" name="index_t">- t -</a></h3><ul>
<li>timestamp
: <a class="el" href="struct_gps_location.html#3e16861f64869d6f0e15e4300bb2658b">GpsLocation</a>
</ul>
<h3><a class="anchor" name="index_u">- u -</a></h3><ul>
<li>used_in_fix_mask
: <a class="el" href="struct_gps_sv_status.html#9090a26639d97eec2b59bcd0446659c0">GpsSvStatus</a>
</ul>
</div>
</body>
</html>

View File

@@ -1,91 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Doxygen-Generated Content</title>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
.navigation {
display: none;
}
-->
</style>
</head>
<body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li class="current"><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="files.html"><span>File&nbsp;List</span></a></li>
<li class="current"><a href="globals.html"><span>Globals</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li class="current"><a href="globals.html"><span>All</span></a></li>
<li><a href="globals_func.html"><span>Functions</span></a></li>
<li><a href="globals_type.html"><span>Typedefs</span></a></li>
</ul>
</div>
</div>
<div class="contents">
Here is a list of all functions, variables, defines, enums, and typedefs with links to the files they belong to:
<p>
<ul>
<li>do_dhcp_request()
: <a class="el" href="wifi_8h.html#c6876a5403aaeee922d000043a47b25a">wifi.h</a>
<li>get_dhcp_error_string()
: <a class="el" href="wifi_8h.html#8f25ea8ec313efb45affe65fd7c108ee">wifi.h</a>
<li>gps_get_hardware_interface()
: <a class="el" href="gps_8h.html#6d15bb02f1f91dd760e3e172bd7711a1">gps.h</a>
<li>gps_get_interface()
: <a class="el" href="gps_8h.html#b582931ddf4bafa2cc5044963be66987">gps.h</a>
<li>gps_get_qemu_interface()
: <a class="el" href="gps_8h.html#f73f4a220fb97545e81d82fbff54b47e">gps.h</a>
<li>gps_location_callback
: <a class="el" href="gps_8h.html#88f19d3da70dc0e951b51091ce0631ae">gps.h</a>
<li>gps_status_callback
: <a class="el" href="gps_8h.html#1d9ef60ab0b91f7c106867a6aa1e4412">gps.h</a>
<li>gps_sv_status_callback
: <a class="el" href="gps_8h.html#67274e784834c6c2547f4b5344fc4ea9">gps.h</a>
<li>gps_xtra_download_request
: <a class="el" href="gps_8h.html#08fcfb3f85c2ac3008c9c73cf9136515">gps.h</a>
<li>GpsAidingData
: <a class="el" href="gps_8h.html#93f0283aeabd20211499991a29db7377">gps.h</a>
<li>GpsLocationFlags
: <a class="el" href="gps_8h.html#4ae31616d5e232ad7a346a2d4e723e31">gps.h</a>
<li>GpsPositionMode
: <a class="el" href="gps_8h.html#2461a6f0dd56a1f7dc94e93207a1f740">gps.h</a>
<li>GpsStatusValue
: <a class="el" href="gps_8h.html#de8fa0020d3aa1748a8e26759b768ec5">gps.h</a>
<li>GpsUtcTime
: <a class="el" href="gps_8h.html#f2b0ea531a44c010f81a4abd27504c15">gps.h</a>
<li>wifi_close_supplicant_connection()
: <a class="el" href="wifi_8h.html#a3f8c99b26cfd95e90012cae63ec4826">wifi.h</a>
<li>wifi_command()
: <a class="el" href="wifi_8h.html#b84f92e035b7bc6a5d669b3738c93e32">wifi.h</a>
<li>wifi_connect_to_supplicant()
: <a class="el" href="wifi_8h.html#d81473c3f314ba581e88bb9f1ae37904">wifi.h</a>
<li>wifi_load_driver()
: <a class="el" href="wifi_8h.html#ef0be2b5d0603acb8e0ab99051969bb7">wifi.h</a>
<li>wifi_start_supplicant()
: <a class="el" href="wifi_8h.html#3372e235a7899484912d7f85887e8a47">wifi.h</a>
<li>wifi_stop_supplicant()
: <a class="el" href="wifi_8h.html#08b97e58f2909489f1f3d59fb31f2c19">wifi.h</a>
<li>wifi_unload_driver()
: <a class="el" href="wifi_8h.html#a0c054da650a0162e40f327eb05679cb">wifi.h</a>
<li>wifi_wait_for_event()
: <a class="el" href="wifi_8h.html#656495e1beea1e39a144cdff776cdb96">wifi.h</a>
</ul>
</div>
</body>
</html>

View File

@@ -1,73 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Doxygen-Generated Content</title>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
.navigation {
display: none;
}
-->
</style>
</head>
<body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li class="current"><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="files.html"><span>File&nbsp;List</span></a></li>
<li class="current"><a href="globals.html"><span>Globals</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="globals.html"><span>All</span></a></li>
<li class="current"><a href="globals_func.html"><span>Functions</span></a></li>
<li><a href="globals_type.html"><span>Typedefs</span></a></li>
</ul>
</div>
</div>
<div class="contents">
&nbsp;
<p>
<ul>
<li>do_dhcp_request()
: <a class="el" href="wifi_8h.html#c6876a5403aaeee922d000043a47b25a">wifi.h</a>
<li>get_dhcp_error_string()
: <a class="el" href="wifi_8h.html#8f25ea8ec313efb45affe65fd7c108ee">wifi.h</a>
<li>gps_get_hardware_interface()
: <a class="el" href="gps_8h.html#6d15bb02f1f91dd760e3e172bd7711a1">gps.h</a>
<li>gps_get_interface()
: <a class="el" href="gps_8h.html#b582931ddf4bafa2cc5044963be66987">gps.h</a>
<li>gps_get_qemu_interface()
: <a class="el" href="gps_8h.html#f73f4a220fb97545e81d82fbff54b47e">gps.h</a>
<li>wifi_close_supplicant_connection()
: <a class="el" href="wifi_8h.html#a3f8c99b26cfd95e90012cae63ec4826">wifi.h</a>
<li>wifi_command()
: <a class="el" href="wifi_8h.html#b84f92e035b7bc6a5d669b3738c93e32">wifi.h</a>
<li>wifi_connect_to_supplicant()
: <a class="el" href="wifi_8h.html#d81473c3f314ba581e88bb9f1ae37904">wifi.h</a>
<li>wifi_load_driver()
: <a class="el" href="wifi_8h.html#ef0be2b5d0603acb8e0ab99051969bb7">wifi.h</a>
<li>wifi_start_supplicant()
: <a class="el" href="wifi_8h.html#3372e235a7899484912d7f85887e8a47">wifi.h</a>
<li>wifi_stop_supplicant()
: <a class="el" href="wifi_8h.html#08b97e58f2909489f1f3d59fb31f2c19">wifi.h</a>
<li>wifi_unload_driver()
: <a class="el" href="wifi_8h.html#a0c054da650a0162e40f327eb05679cb">wifi.h</a>
<li>wifi_wait_for_event()
: <a class="el" href="wifi_8h.html#656495e1beea1e39a144cdff776cdb96">wifi.h</a>
</ul>
</div>
</body>
</html>

View File

@@ -1,65 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Doxygen-Generated Content</title>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
.navigation {
display: none;
}
-->
</style>
</head>
<body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li class="current"><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="files.html"><span>File&nbsp;List</span></a></li>
<li class="current"><a href="globals.html"><span>Globals</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="globals.html"><span>All</span></a></li>
<li><a href="globals_func.html"><span>Functions</span></a></li>
<li class="current"><a href="globals_type.html"><span>Typedefs</span></a></li>
</ul>
</div>
</div>
<div class="contents">
&nbsp;
<p>
<ul>
<li>gps_location_callback
: <a class="el" href="gps_8h.html#88f19d3da70dc0e951b51091ce0631ae">gps.h</a>
<li>gps_status_callback
: <a class="el" href="gps_8h.html#1d9ef60ab0b91f7c106867a6aa1e4412">gps.h</a>
<li>gps_sv_status_callback
: <a class="el" href="gps_8h.html#67274e784834c6c2547f4b5344fc4ea9">gps.h</a>
<li>gps_xtra_download_request
: <a class="el" href="gps_8h.html#08fcfb3f85c2ac3008c9c73cf9136515">gps.h</a>
<li>GpsAidingData
: <a class="el" href="gps_8h.html#93f0283aeabd20211499991a29db7377">gps.h</a>
<li>GpsLocationFlags
: <a class="el" href="gps_8h.html#4ae31616d5e232ad7a346a2d4e723e31">gps.h</a>
<li>GpsPositionMode
: <a class="el" href="gps_8h.html#2461a6f0dd56a1f7dc94e93207a1f740">gps.h</a>
<li>GpsStatusValue
: <a class="el" href="gps_8h.html#de8fa0020d3aa1748a8e26759b768ec5">gps.h</a>
<li>GpsUtcTime
: <a class="el" href="gps_8h.html#f2b0ea531a44c010f81a4abd27504c15">gps.h</a>
</ul>
</div>
</body>
</html>

View File

@@ -1,298 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Doxygen-Generated Content</title>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
.navigation {
display: none;
}
-->
</style>
</head>
<body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li class="current"><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
</div>
<h1>gps.h</h1><a href="gps_8h.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="comment">/*</span>
<a name="l00002"></a>00002 <span class="comment"> * Copyright (C) 2008 The Android Open Source Project</span>
<a name="l00003"></a>00003 <span class="comment"> *</span>
<a name="l00004"></a>00004 <span class="comment"> * Licensed under the Apache License, Version 2.0 (the "License");</span>
<a name="l00005"></a>00005 <span class="comment"> * you may not use this file except in compliance with the License.</span>
<a name="l00006"></a>00006 <span class="comment"> * You may obtain a copy of the License at</span>
<a name="l00007"></a>00007 <span class="comment"> *</span>
<a name="l00008"></a>00008 <span class="comment"> * http://www.apache.org/licenses/LICENSE-2.0</span>
<a name="l00009"></a>00009 <span class="comment"> *</span>
<a name="l00010"></a>00010 <span class="comment"> * Unless required by applicable law or agreed to in writing, software</span>
<a name="l00011"></a>00011 <span class="comment"> * distributed under the License is distributed on an "AS IS" BASIS,</span>
<a name="l00012"></a>00012 <span class="comment"> * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.</span>
<a name="l00013"></a>00013 <span class="comment"> * See the License for the specific language governing permissions and</span>
<a name="l00014"></a>00014 <span class="comment"> * limitations under the License.</span>
<a name="l00015"></a>00015 <span class="comment"> */</span>
<a name="l00016"></a>00016
<a name="l00017"></a>00017 <span class="preprocessor">#ifndef _HARDWARE_GPS_H</span>
<a name="l00018"></a>00018 <span class="preprocessor"></span><span class="preprocessor">#define _HARDWARE_GPS_H</span>
<a name="l00019"></a>00019 <span class="preprocessor"></span>
<a name="l00020"></a>00020 <span class="preprocessor">#include &lt;stdint.h&gt;</span>
<a name="l00021"></a>00021
<a name="l00022"></a>00022 <span class="preprocessor">#if __cplusplus</span>
<a name="l00023"></a>00023 <span class="preprocessor"></span><span class="keyword">extern</span> <span class="stringliteral">"C"</span> {
<a name="l00024"></a>00024 <span class="preprocessor">#endif</span>
<a name="l00025"></a>00025 <span class="preprocessor"></span><span class="comment"></span>
<a name="l00026"></a>00026 <span class="comment">/** Milliseconds since January 1, 1970 */</span>
<a name="l00027"></a><a class="code" href="gps_8h.html#f2b0ea531a44c010f81a4abd27504c15">00027</a> <span class="keyword">typedef</span> int64_t <a class="code" href="gps_8h.html#f2b0ea531a44c010f81a4abd27504c15" title="Milliseconds since January 1, 1970.">GpsUtcTime</a>;
<a name="l00028"></a>00028 <span class="comment"></span>
<a name="l00029"></a>00029 <span class="comment">/** Maximum number of SVs for gps_sv_status_callback(). */</span>
<a name="l00030"></a>00030 <span class="preprocessor">#define GPS_MAX_SVS 32</span>
<a name="l00031"></a>00031 <span class="preprocessor"></span><span class="comment"></span>
<a name="l00032"></a>00032 <span class="comment">/** Requested mode for GPS operation. */</span>
<a name="l00033"></a><a class="code" href="gps_8h.html#2461a6f0dd56a1f7dc94e93207a1f740">00033</a> <span class="keyword">typedef</span> uint16_t <a class="code" href="gps_8h.html#2461a6f0dd56a1f7dc94e93207a1f740" title="Requested mode for GPS operation.">GpsPositionMode</a>;
<a name="l00034"></a>00034 <span class="comment">// IMPORTANT: Note that the following values must match</span>
<a name="l00035"></a>00035 <span class="comment">// constants in GpsLocationProvider.java.</span><span class="comment"></span>
<a name="l00036"></a>00036 <span class="comment">/** Mode for running GPS standalone (no assistance). */</span>
<a name="l00037"></a>00037 <span class="preprocessor">#define GPS_POSITION_MODE_STANDALONE 0</span>
<a name="l00038"></a>00038 <span class="preprocessor"></span><span class="comment">/** SUPL MS-Based mode. */</span>
<a name="l00039"></a>00039 <span class="preprocessor">#define GPS_POSITION_MODE_MS_BASED 1</span>
<a name="l00040"></a>00040 <span class="preprocessor"></span><span class="comment">/** SUPL MS-Assisted mode. */</span>
<a name="l00041"></a>00041 <span class="preprocessor">#define GPS_POSITION_MODE_MS_ASSISTED 2</span>
<a name="l00042"></a>00042 <span class="preprocessor"></span><span class="comment"></span>
<a name="l00043"></a>00043 <span class="comment">/** GPS status event values. */</span>
<a name="l00044"></a><a class="code" href="gps_8h.html#de8fa0020d3aa1748a8e26759b768ec5">00044</a> <span class="keyword">typedef</span> uint16_t <a class="code" href="gps_8h.html#de8fa0020d3aa1748a8e26759b768ec5" title="GPS status event values.">GpsStatusValue</a>;
<a name="l00045"></a>00045 <span class="comment">// IMPORTANT: Note that the following values must match</span>
<a name="l00046"></a>00046 <span class="comment">// constants in GpsLocationProvider.java.</span><span class="comment"></span>
<a name="l00047"></a>00047 <span class="comment">/** GPS status unknown. */</span>
<a name="l00048"></a>00048 <span class="preprocessor">#define GPS_STATUS_NONE 0</span>
<a name="l00049"></a>00049 <span class="preprocessor"></span><span class="comment">/** GPS has begun navigating. */</span>
<a name="l00050"></a>00050 <span class="preprocessor">#define GPS_STATUS_SESSION_BEGIN 1</span>
<a name="l00051"></a>00051 <span class="preprocessor"></span><span class="comment">/** GPS has stopped navigating. */</span>
<a name="l00052"></a>00052 <span class="preprocessor">#define GPS_STATUS_SESSION_END 2</span>
<a name="l00053"></a>00053 <span class="preprocessor"></span><span class="comment">/** GPS has powered on but is not navigating. */</span>
<a name="l00054"></a>00054 <span class="preprocessor">#define GPS_STATUS_ENGINE_ON 3</span>
<a name="l00055"></a>00055 <span class="preprocessor"></span><span class="comment">/** GPS is powered off. */</span>
<a name="l00056"></a>00056 <span class="preprocessor">#define GPS_STATUS_ENGINE_OFF 4</span>
<a name="l00057"></a>00057 <span class="preprocessor"></span><span class="comment"></span>
<a name="l00058"></a>00058 <span class="comment">/** Flags to indicate which values are valid in a GpsLocation. */</span>
<a name="l00059"></a><a class="code" href="gps_8h.html#4ae31616d5e232ad7a346a2d4e723e31">00059</a> <span class="keyword">typedef</span> uint16_t <a class="code" href="gps_8h.html#4ae31616d5e232ad7a346a2d4e723e31" title="Flags to indicate which values are valid in a GpsLocation.">GpsLocationFlags</a>;
<a name="l00060"></a>00060 <span class="comment">// IMPORTANT: Note that the following values must match</span>
<a name="l00061"></a>00061 <span class="comment">// constants in GpsLocationProvider.java.</span><span class="comment"></span>
<a name="l00062"></a>00062 <span class="comment">/** GpsLocation has valid latitude and longitude. */</span>
<a name="l00063"></a>00063 <span class="preprocessor">#define GPS_LOCATION_HAS_LAT_LONG 0x0001</span>
<a name="l00064"></a>00064 <span class="preprocessor"></span><span class="comment">/** GpsLocation has valid altitude. */</span>
<a name="l00065"></a>00065 <span class="preprocessor">#define GPS_LOCATION_HAS_ALTITUDE 0x0002</span>
<a name="l00066"></a>00066 <span class="preprocessor"></span><span class="comment">/** GpsLocation has valid speed. */</span>
<a name="l00067"></a>00067 <span class="preprocessor">#define GPS_LOCATION_HAS_SPEED 0x0004</span>
<a name="l00068"></a>00068 <span class="preprocessor"></span><span class="comment">/** GpsLocation has valid bearing. */</span>
<a name="l00069"></a>00069 <span class="preprocessor">#define GPS_LOCATION_HAS_BEARING 0x0008</span>
<a name="l00070"></a>00070 <span class="preprocessor"></span><span class="comment">/** GpsLocation has valid accuracy. */</span>
<a name="l00071"></a>00071 <span class="preprocessor">#define GPS_LOCATION_HAS_ACCURACY 0x0010</span>
<a name="l00072"></a>00072 <span class="preprocessor"></span><span class="comment"></span>
<a name="l00073"></a>00073 <span class="comment">/** Flags used to specify which aiding data to delete</span>
<a name="l00074"></a>00074 <span class="comment"> when calling delete_aiding_data(). */</span>
<a name="l00075"></a><a class="code" href="gps_8h.html#93f0283aeabd20211499991a29db7377">00075</a> <span class="keyword">typedef</span> uint16_t <a class="code" href="gps_8h.html#93f0283aeabd20211499991a29db7377" title="Flags used to specify which aiding data to delete when calling delete_aiding_data()...">GpsAidingData</a>;
<a name="l00076"></a>00076 <span class="comment">// IMPORTANT: Note that the following values must match</span>
<a name="l00077"></a>00077 <span class="comment">// constants in GpsLocationProvider.java.</span>
<a name="l00078"></a>00078 <span class="preprocessor">#define GPS_DELETE_EPHEMERIS 0x0001</span>
<a name="l00079"></a>00079 <span class="preprocessor"></span><span class="preprocessor">#define GPS_DELETE_ALMANAC 0x0002</span>
<a name="l00080"></a>00080 <span class="preprocessor"></span><span class="preprocessor">#define GPS_DELETE_POSITION 0x0004</span>
<a name="l00081"></a>00081 <span class="preprocessor"></span><span class="preprocessor">#define GPS_DELETE_TIME 0x0008</span>
<a name="l00082"></a>00082 <span class="preprocessor"></span><span class="preprocessor">#define GPS_DELETE_IONO 0x0010</span>
<a name="l00083"></a>00083 <span class="preprocessor"></span><span class="preprocessor">#define GPS_DELETE_UTC 0x0020</span>
<a name="l00084"></a>00084 <span class="preprocessor"></span><span class="preprocessor">#define GPS_DELETE_HEALTH 0x0040</span>
<a name="l00085"></a>00085 <span class="preprocessor"></span><span class="preprocessor">#define GPS_DELETE_SVDIR 0x0080</span>
<a name="l00086"></a>00086 <span class="preprocessor"></span><span class="preprocessor">#define GPS_DELETE_SVSTEER 0x0100</span>
<a name="l00087"></a>00087 <span class="preprocessor"></span><span class="preprocessor">#define GPS_DELETE_SADATA 0x0200</span>
<a name="l00088"></a>00088 <span class="preprocessor"></span><span class="preprocessor">#define GPS_DELETE_RTI 0x0400</span>
<a name="l00089"></a>00089 <span class="preprocessor"></span><span class="preprocessor">#define GPS_DELETE_CELLDB_INFO 0x8000</span>
<a name="l00090"></a>00090 <span class="preprocessor"></span><span class="preprocessor">#define GPS_DELETE_ALL 0xFFFF</span>
<a name="l00091"></a>00091 <span class="preprocessor"></span><span class="comment"></span>
<a name="l00092"></a>00092 <span class="comment">/**</span>
<a name="l00093"></a>00093 <span class="comment"> * Name for the GPS XTRA interface.</span>
<a name="l00094"></a>00094 <span class="comment"> */</span>
<a name="l00095"></a>00095 <span class="preprocessor">#define GPS_XTRA_INTERFACE "gps-xtra"</span>
<a name="l00096"></a>00096 <span class="preprocessor"></span><span class="comment"></span>
<a name="l00097"></a>00097 <span class="comment">/**</span>
<a name="l00098"></a>00098 <span class="comment"> * Name for the GPS SUPL interface.</span>
<a name="l00099"></a>00099 <span class="comment"> */</span>
<a name="l00100"></a>00100 <span class="preprocessor">#define GPS_SUPL_INTERFACE "gps-supl"</span>
<a name="l00101"></a>00101 <span class="preprocessor"></span><span class="comment"></span>
<a name="l00102"></a>00102 <span class="comment">/** Represents a location. */</span>
<a name="l00103"></a><a class="code" href="struct_gps_location.html">00103</a> <span class="keyword">typedef</span> <span class="keyword">struct </span>{<span class="comment"></span>
<a name="l00104"></a>00104 <span class="comment"> /** Contains GpsLocationFlags bits. */</span>
<a name="l00105"></a><a class="code" href="struct_gps_location.html#07d55fee34dc28cff50062e9ac42c717">00105</a> uint16_t flags;<span class="comment"></span>
<a name="l00106"></a>00106 <span class="comment"> /** Represents latitude in degrees. */</span>
<a name="l00107"></a><a class="code" href="struct_gps_location.html#3a7da06efae47c66428fa2815a3eb4bd">00107</a> <span class="keywordtype">double</span> latitude;<span class="comment"></span>
<a name="l00108"></a>00108 <span class="comment"> /** Represents longitude in degrees. */</span>
<a name="l00109"></a><a class="code" href="struct_gps_location.html#3672d2d19087d62d7ea9b0b71418da40">00109</a> <span class="keywordtype">double</span> longitude;<span class="comment"></span>
<a name="l00110"></a>00110 <span class="comment"> /** Represents altitude in meters above the WGS 84 reference</span>
<a name="l00111"></a>00111 <span class="comment"> * ellipsoid. */</span>
<a name="l00112"></a><a class="code" href="struct_gps_location.html#cb3cc5ad378a6a3864e47ae67df38778">00112</a> <span class="keywordtype">double</span> altitude;<span class="comment"></span>
<a name="l00113"></a>00113 <span class="comment"> /** Represents speed in meters per second. */</span>
<a name="l00114"></a><a class="code" href="struct_gps_location.html#38ae20b9c5e7be995513dce25ed87016">00114</a> <span class="keywordtype">float</span> speed;<span class="comment"></span>
<a name="l00115"></a>00115 <span class="comment"> /** Represents heading in degrees. */</span>
<a name="l00116"></a><a class="code" href="struct_gps_location.html#b71bf9b61cf55f10ffcf34ba1654d082">00116</a> <span class="keywordtype">float</span> bearing;<span class="comment"></span>
<a name="l00117"></a>00117 <span class="comment"> /** Represents expected accuracy in meters. */</span>
<a name="l00118"></a><a class="code" href="struct_gps_location.html#801ec0db8ee69fa263a63528876d773b">00118</a> <span class="keywordtype">float</span> accuracy;<span class="comment"></span>
<a name="l00119"></a>00119 <span class="comment"> /** Timestamp for the location fix. */</span>
<a name="l00120"></a><a class="code" href="struct_gps_location.html#3e16861f64869d6f0e15e4300bb2658b">00120</a> GpsUtcTime timestamp;
<a name="l00121"></a>00121 } <a class="code" href="struct_gps_location.html" title="Represents a location.">GpsLocation</a>;
<a name="l00122"></a>00122 <span class="comment"></span>
<a name="l00123"></a>00123 <span class="comment">/** Represents the status. */</span>
<a name="l00124"></a><a class="code" href="struct_gps_status.html">00124</a> <span class="keyword">typedef</span> <span class="keyword">struct </span>{
<a name="l00125"></a><a class="code" href="struct_gps_status.html#64c9e8cd609d97533bee5c5e8ca78608">00125</a> GpsStatusValue status;
<a name="l00126"></a>00126 } <a class="code" href="struct_gps_status.html" title="Represents the status.">GpsStatus</a>;
<a name="l00127"></a>00127 <span class="comment"></span>
<a name="l00128"></a>00128 <span class="comment">/** Represents SV information. */</span>
<a name="l00129"></a><a class="code" href="struct_gps_sv_info.html">00129</a> <span class="keyword">typedef</span> <span class="keyword">struct </span>{<span class="comment"></span>
<a name="l00130"></a>00130 <span class="comment"> /** Pseudo-random number for the SV. */</span>
<a name="l00131"></a><a class="code" href="struct_gps_sv_info.html#5c94e86f2efc3ed08fb5a40735a2440b">00131</a> <span class="keywordtype">int</span> prn;<span class="comment"></span>
<a name="l00132"></a>00132 <span class="comment"> /** Signal to noise ratio. */</span>
<a name="l00133"></a><a class="code" href="struct_gps_sv_info.html#eebf16140beb95390733529bd5e7db58">00133</a> <span class="keywordtype">float</span> snr;<span class="comment"></span>
<a name="l00134"></a>00134 <span class="comment"> /** Elevation of SV in degrees. */</span>
<a name="l00135"></a><a class="code" href="struct_gps_sv_info.html#0634009d0476b2f06f27568b0722a04d">00135</a> <span class="keywordtype">float</span> elevation;<span class="comment"></span>
<a name="l00136"></a>00136 <span class="comment"> /** Azimuth of SV in degrees. */</span>
<a name="l00137"></a><a class="code" href="struct_gps_sv_info.html#94755ad36e31a012269459d5a4ef0594">00137</a> <span class="keywordtype">float</span> azimuth;
<a name="l00138"></a>00138 } <a class="code" href="struct_gps_sv_info.html" title="Represents SV information.">GpsSvInfo</a>;
<a name="l00139"></a>00139 <span class="comment"></span>
<a name="l00140"></a>00140 <span class="comment">/** Represents SV status. */</span>
<a name="l00141"></a><a class="code" href="struct_gps_sv_status.html">00141</a> <span class="keyword">typedef</span> <span class="keyword">struct </span>{<span class="comment"></span>
<a name="l00142"></a>00142 <span class="comment"> /** Number of SVs currently visible. */</span>
<a name="l00143"></a><a class="code" href="struct_gps_sv_status.html#b90eb63a499039de996c95d98afad545">00143</a> <span class="keywordtype">int</span> num_svs;
<a name="l00144"></a>00144 <span class="comment"></span>
<a name="l00145"></a>00145 <span class="comment"> /** Contains an array of SV information. */</span>
<a name="l00146"></a><a class="code" href="struct_gps_sv_status.html#7a3fe2114e7a603b96fd9675adf0c5b5">00146</a> <a class="code" href="struct_gps_sv_info.html" title="Represents SV information.">GpsSvInfo</a> sv_list[GPS_MAX_SVS];
<a name="l00147"></a>00147 <span class="comment"></span>
<a name="l00148"></a>00148 <span class="comment"> /** Represents a bit mask indicating which SVs</span>
<a name="l00149"></a>00149 <span class="comment"> * have ephemeris data.</span>
<a name="l00150"></a>00150 <span class="comment"> */</span>
<a name="l00151"></a><a class="code" href="struct_gps_sv_status.html#4751f70f8e275241dece99db0df4ab5b">00151</a> uint32_t ephemeris_mask;
<a name="l00152"></a>00152 <span class="comment"></span>
<a name="l00153"></a>00153 <span class="comment"> /** Represents a bit mask indicating which SVs</span>
<a name="l00154"></a>00154 <span class="comment"> * have almanac data.</span>
<a name="l00155"></a>00155 <span class="comment"> */</span>
<a name="l00156"></a><a class="code" href="struct_gps_sv_status.html#6ed4b741a9882ecc2852e94e8ad60310">00156</a> uint32_t almanac_mask;
<a name="l00157"></a>00157 <span class="comment"></span>
<a name="l00158"></a>00158 <span class="comment"> /**</span>
<a name="l00159"></a>00159 <span class="comment"> * Represents a bit mask indicating which SVs</span>
<a name="l00160"></a>00160 <span class="comment"> * were used for computing the most recent position fix.</span>
<a name="l00161"></a>00161 <span class="comment"> */</span>
<a name="l00162"></a><a class="code" href="struct_gps_sv_status.html#9090a26639d97eec2b59bcd0446659c0">00162</a> uint32_t used_in_fix_mask;
<a name="l00163"></a>00163 } <a class="code" href="struct_gps_sv_status.html" title="Represents SV status.">GpsSvStatus</a>;
<a name="l00164"></a>00164 <span class="comment"></span>
<a name="l00165"></a>00165 <span class="comment">/** Callback with location information. */</span>
<a name="l00166"></a><a class="code" href="gps_8h.html#88f19d3da70dc0e951b51091ce0631ae">00166</a> <span class="keyword">typedef</span> void (* <a class="code" href="gps_8h.html#88f19d3da70dc0e951b51091ce0631ae" title="Callback with location information.">gps_location_callback</a>)(<a class="code" href="struct_gps_location.html" title="Represents a location.">GpsLocation</a>* location);
<a name="l00167"></a>00167 <span class="comment"></span>
<a name="l00168"></a>00168 <span class="comment">/** Callback with status information. */</span>
<a name="l00169"></a><a class="code" href="gps_8h.html#1d9ef60ab0b91f7c106867a6aa1e4412">00169</a> <span class="keyword">typedef</span> void (* <a class="code" href="gps_8h.html#1d9ef60ab0b91f7c106867a6aa1e4412" title="Callback with status information.">gps_status_callback</a>)(<a class="code" href="struct_gps_status.html" title="Represents the status.">GpsStatus</a>* status);
<a name="l00170"></a>00170 <span class="comment"></span>
<a name="l00171"></a>00171 <span class="comment">/** Callback with SV status information. */</span>
<a name="l00172"></a><a class="code" href="gps_8h.html#67274e784834c6c2547f4b5344fc4ea9">00172</a> <span class="keyword">typedef</span> void (* <a class="code" href="gps_8h.html#67274e784834c6c2547f4b5344fc4ea9" title="Callback with SV status information.">gps_sv_status_callback</a>)(<a class="code" href="struct_gps_sv_status.html" title="Represents SV status.">GpsSvStatus</a>* sv_info);
<a name="l00173"></a>00173 <span class="comment"></span>
<a name="l00174"></a>00174 <span class="comment">/** GPS callback structure. */</span>
<a name="l00175"></a><a class="code" href="struct_gps_callbacks.html">00175</a> <span class="keyword">typedef</span> <span class="keyword">struct </span>{
<a name="l00176"></a><a class="code" href="struct_gps_callbacks.html#1f59b4f8eeaca50620f94761536dabd3">00176</a> <a class="code" href="gps_8h.html#88f19d3da70dc0e951b51091ce0631ae" title="Callback with location information.">gps_location_callback</a> location_cb;
<a name="l00177"></a><a class="code" href="struct_gps_callbacks.html#7b15a1bf4f9b989677fef84f4d8141df">00177</a> <a class="code" href="gps_8h.html#1d9ef60ab0b91f7c106867a6aa1e4412" title="Callback with status information.">gps_status_callback</a> status_cb;
<a name="l00178"></a><a class="code" href="struct_gps_callbacks.html#fb34f60ad58e80de5c04790b107bb93d">00178</a> <a class="code" href="gps_8h.html#67274e784834c6c2547f4b5344fc4ea9" title="Callback with SV status information.">gps_sv_status_callback</a> sv_status_cb;
<a name="l00179"></a>00179 } <a class="code" href="struct_gps_callbacks.html" title="GPS callback structure.">GpsCallbacks</a>;
<a name="l00180"></a>00180
<a name="l00181"></a>00181 <span class="comment"></span>
<a name="l00182"></a>00182 <span class="comment">/** Represents the standard GPS interface. */</span>
<a name="l00183"></a><a class="code" href="struct_gps_interface.html">00183</a> <span class="keyword">typedef</span> <span class="keyword">struct </span>{<span class="comment"></span>
<a name="l00184"></a>00184 <span class="comment"> /**</span>
<a name="l00185"></a>00185 <span class="comment"> * Opens the interface and provides the callback routines</span>
<a name="l00186"></a>00186 <span class="comment"> * to the implemenation of this interface.</span>
<a name="l00187"></a>00187 <span class="comment"> */</span>
<a name="l00188"></a>00188 int (*init)( <a class="code" href="struct_gps_callbacks.html" title="GPS callback structure.">GpsCallbacks</a>* callbacks );
<a name="l00189"></a>00189 <span class="comment"></span>
<a name="l00190"></a>00190 <span class="comment"> /** Starts navigating. */</span>
<a name="l00191"></a>00191 int (*start)( void );
<a name="l00192"></a>00192 <span class="comment"></span>
<a name="l00193"></a>00193 <span class="comment"> /** Stops navigating. */</span>
<a name="l00194"></a>00194 int (*stop)( void );
<a name="l00195"></a>00195 <span class="comment"></span>
<a name="l00196"></a>00196 <span class="comment"> /** Sets requested frequency of fixes in seconds. */</span>
<a name="l00197"></a>00197 void (*set_fix_frequency)( <span class="keywordtype">int</span> frequency );
<a name="l00198"></a>00198 <span class="comment"></span>
<a name="l00199"></a>00199 <span class="comment"> /** Closes the interface. */</span>
<a name="l00200"></a>00200 void (*cleanup)( void );
<a name="l00201"></a>00201 <span class="comment"></span>
<a name="l00202"></a>00202 <span class="comment"> /** Injects the current time. */</span>
<a name="l00203"></a>00203 int (*inject_time)(GpsUtcTime time, int64_t timeReference,
<a name="l00204"></a>00204 <span class="keywordtype">int</span> uncertainty);
<a name="l00205"></a>00205 <span class="comment"></span>
<a name="l00206"></a>00206 <span class="comment"> /**</span>
<a name="l00207"></a>00207 <span class="comment"> * Specifies that the next call to start will not use the</span>
<a name="l00208"></a>00208 <span class="comment"> * information defined in the flags. GPS_DELETE_ALL is passed for</span>
<a name="l00209"></a>00209 <span class="comment"> * a cold start.</span>
<a name="l00210"></a>00210 <span class="comment"> */</span>
<a name="l00211"></a>00211 void (*delete_aiding_data)(GpsAidingData flags);
<a name="l00212"></a>00212 <span class="comment"></span>
<a name="l00213"></a>00213 <span class="comment"> /**</span>
<a name="l00214"></a>00214 <span class="comment"> * fix_frequency represents the time between fixes in seconds.</span>
<a name="l00215"></a>00215 <span class="comment"> * Set fix_frequency to zero for a single-shot fix.</span>
<a name="l00216"></a>00216 <span class="comment"> */</span>
<a name="l00217"></a>00217 int (*set_position_mode)(GpsPositionMode mode, <span class="keywordtype">int</span> fix_frequency);
<a name="l00218"></a>00218 <span class="comment"></span>
<a name="l00219"></a>00219 <span class="comment"> /** Get a pointer to extension information. */</span>
<a name="l00220"></a>00220 <span class="keyword">const</span> <span class="keywordtype">void</span>* (*get_extension)(<span class="keyword">const</span> <span class="keywordtype">char</span>* name);
<a name="l00221"></a>00221 } <a class="code" href="struct_gps_interface.html" title="Represents the standard GPS interface.">GpsInterface</a>;
<a name="l00222"></a>00222 <span class="comment"></span>
<a name="l00223"></a>00223 <span class="comment">/** Callback to request the client to download XTRA data.</span>
<a name="l00224"></a>00224 <span class="comment"> The client should download XTRA data and inject it by calling</span>
<a name="l00225"></a>00225 <span class="comment"> inject_xtra_data(). */</span>
<a name="l00226"></a><a class="code" href="gps_8h.html#08fcfb3f85c2ac3008c9c73cf9136515">00226</a> <span class="keyword">typedef</span> void (* <a class="code" href="gps_8h.html#08fcfb3f85c2ac3008c9c73cf9136515" title="Callback to request the client to download XTRA data.">gps_xtra_download_request</a>)();
<a name="l00227"></a>00227 <span class="comment"></span>
<a name="l00228"></a>00228 <span class="comment">/** Callback structure for the XTRA interface. */</span>
<a name="l00229"></a><a class="code" href="struct_gps_xtra_callbacks.html">00229</a> <span class="keyword">typedef</span> <span class="keyword">struct </span>{
<a name="l00230"></a><a class="code" href="struct_gps_xtra_callbacks.html#7e879ba4c3e32c52eaa0fb04fb9c226f">00230</a> <a class="code" href="gps_8h.html#08fcfb3f85c2ac3008c9c73cf9136515" title="Callback to request the client to download XTRA data.">gps_xtra_download_request</a> download_request_cb;
<a name="l00231"></a>00231 } <a class="code" href="struct_gps_xtra_callbacks.html" title="Callback structure for the XTRA interface.">GpsXtraCallbacks</a>;
<a name="l00232"></a>00232 <span class="comment"></span>
<a name="l00233"></a>00233 <span class="comment">/** Extended interface for XTRA support. */</span>
<a name="l00234"></a><a class="code" href="struct_gps_xtra_interface.html">00234</a> <span class="keyword">typedef</span> <span class="keyword">struct </span>{<span class="comment"></span>
<a name="l00235"></a>00235 <span class="comment"> /**</span>
<a name="l00236"></a>00236 <span class="comment"> * Opens the XTRA interface and provides the callback routines</span>
<a name="l00237"></a>00237 <span class="comment"> * to the implemenation of this interface.</span>
<a name="l00238"></a>00238 <span class="comment"> */</span>
<a name="l00239"></a>00239 int (*init)( <a class="code" href="struct_gps_xtra_callbacks.html" title="Callback structure for the XTRA interface.">GpsXtraCallbacks</a>* callbacks );<span class="comment"></span>
<a name="l00240"></a>00240 <span class="comment"> /** Injects XTRA data into the GPS. */</span>
<a name="l00241"></a>00241 int (*inject_xtra_data)( <span class="keywordtype">char</span>* data, <span class="keywordtype">int</span> length );
<a name="l00242"></a>00242 } <a class="code" href="struct_gps_xtra_interface.html" title="Extended interface for XTRA support.">GpsXtraInterface</a>;
<a name="l00243"></a>00243 <span class="comment"></span>
<a name="l00244"></a>00244 <span class="comment">/** Extended interface for SUPL support. */</span>
<a name="l00245"></a><a class="code" href="struct_gps_supl_interface.html">00245</a> <span class="keyword">typedef</span> <span class="keyword">struct </span>{<span class="comment"></span>
<a name="l00246"></a>00246 <span class="comment"> /**</span>
<a name="l00247"></a>00247 <span class="comment"> * Sets the name of the APN to be used for SUPL.</span>
<a name="l00248"></a>00248 <span class="comment"> */</span>
<a name="l00249"></a>00249 int (*set_apn)( <span class="keyword">const</span> <span class="keywordtype">char</span>* apn );
<a name="l00250"></a>00250 } <a class="code" href="struct_gps_supl_interface.html" title="Extended interface for SUPL support.">GpsSuplInterface</a>;
<a name="l00251"></a>00251 <span class="comment"></span>
<a name="l00252"></a>00252 <span class="comment">/** Returns the hardware GPS interface. */</span>
<a name="l00253"></a>00253 <span class="keyword">const</span> <a class="code" href="struct_gps_interface.html" title="Represents the standard GPS interface.">GpsInterface</a>* <a class="code" href="gps_8h.html#6d15bb02f1f91dd760e3e172bd7711a1" title="Returns the hardware GPS interface.">gps_get_hardware_interface</a>();
<a name="l00254"></a>00254 <span class="comment"></span>
<a name="l00255"></a>00255 <span class="comment">/**</span>
<a name="l00256"></a>00256 <span class="comment"> * Returns the qemu emulated GPS interface.</span>
<a name="l00257"></a>00257 <span class="comment"> */</span>
<a name="l00258"></a>00258 <span class="keyword">const</span> <a class="code" href="struct_gps_interface.html" title="Represents the standard GPS interface.">GpsInterface</a>* <a class="code" href="gps_8h.html#f73f4a220fb97545e81d82fbff54b47e" title="Returns the qemu emulated GPS interface.">gps_get_qemu_interface</a>();
<a name="l00259"></a>00259 <span class="comment"></span>
<a name="l00260"></a>00260 <span class="comment">/**</span>
<a name="l00261"></a>00261 <span class="comment"> * Returns the default GPS interface.</span>
<a name="l00262"></a>00262 <span class="comment"> */</span>
<a name="l00263"></a>00263 <span class="keyword">const</span> <a class="code" href="struct_gps_interface.html" title="Represents the standard GPS interface.">GpsInterface</a>* <a class="code" href="gps_8h.html#b582931ddf4bafa2cc5044963be66987" title="Returns the default GPS interface.">gps_get_interface</a>();
<a name="l00264"></a>00264
<a name="l00265"></a>00265 <span class="preprocessor">#if __cplusplus</span>
<a name="l00266"></a>00266 <span class="preprocessor"></span>} <span class="comment">// extern "C"</span>
<a name="l00267"></a>00267 <span class="preprocessor">#endif</span>
<a name="l00268"></a>00268 <span class="preprocessor"></span>
<a name="l00269"></a>00269 <span class="preprocessor">#endif // _HARDWARE_GPS_H</span>
</pre></div></div>
</body>
</html>

View File

@@ -1,337 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Doxygen-Generated Content</title>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
.navigation {
display: none;
}
-->
</style>
</head>
<body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li class="current"><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
</div>
<div class="contents">
<h1>gps.h File Reference</h1>
<p>
<a href="gps_8h-source.html">Go to the source code of this file.</a><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Data Structures</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">struct &nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_location.html">GpsLocation</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Represents a location. <a href="struct_gps_location.html#_details">More...</a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">struct &nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_status.html">GpsStatus</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Represents the status. <a href="struct_gps_status.html#_details">More...</a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">struct &nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_sv_info.html">GpsSvInfo</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Represents SV information. <a href="struct_gps_sv_info.html#_details">More...</a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">struct &nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_sv_status.html">GpsSvStatus</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Represents SV status. <a href="struct_gps_sv_status.html#_details">More...</a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">struct &nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_callbacks.html">GpsCallbacks</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">GPS callback structure. <a href="struct_gps_callbacks.html#_details">More...</a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">struct &nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_interface.html">GpsInterface</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Represents the standard GPS interface. <a href="struct_gps_interface.html#_details">More...</a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">struct &nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_xtra_callbacks.html">GpsXtraCallbacks</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Callback structure for the XTRA interface. <a href="struct_gps_xtra_callbacks.html#_details">More...</a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">struct &nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_xtra_interface.html">GpsXtraInterface</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Extended interface for XTRA support. <a href="struct_gps_xtra_interface.html#_details">More...</a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">struct &nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_supl_interface.html">GpsSuplInterface</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Extended interface for SUPL support. <a href="struct_gps_supl_interface.html#_details">More...</a><br></td></tr>
<tr><td colspan="2"><br><h2>Typedefs</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef int64_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="gps_8h.html#f2b0ea531a44c010f81a4abd27504c15">GpsUtcTime</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Milliseconds since January 1, 1970. <a href="#f2b0ea531a44c010f81a4abd27504c15"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef uint16_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="gps_8h.html#2461a6f0dd56a1f7dc94e93207a1f740">GpsPositionMode</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Requested mode for GPS operation. <a href="#2461a6f0dd56a1f7dc94e93207a1f740"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef uint16_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="gps_8h.html#de8fa0020d3aa1748a8e26759b768ec5">GpsStatusValue</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">GPS status event values. <a href="#de8fa0020d3aa1748a8e26759b768ec5"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef uint16_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="gps_8h.html#4ae31616d5e232ad7a346a2d4e723e31">GpsLocationFlags</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Flags to indicate which values are valid in a <a class="el" href="struct_gps_location.html" title="Represents a location.">GpsLocation</a>. <a href="#4ae31616d5e232ad7a346a2d4e723e31"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef uint16_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="gps_8h.html#93f0283aeabd20211499991a29db7377">GpsAidingData</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Flags used to specify which aiding data to delete when calling delete_aiding_data(). <a href="#93f0283aeabd20211499991a29db7377"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef void(*&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="gps_8h.html#88f19d3da70dc0e951b51091ce0631ae">gps_location_callback</a> )(<a class="el" href="struct_gps_location.html">GpsLocation</a> *location)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Callback with location information. <a href="#88f19d3da70dc0e951b51091ce0631ae"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef void(*&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="gps_8h.html#1d9ef60ab0b91f7c106867a6aa1e4412">gps_status_callback</a> )(<a class="el" href="struct_gps_status.html">GpsStatus</a> *status)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Callback with status information. <a href="#1d9ef60ab0b91f7c106867a6aa1e4412"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef void(*&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="gps_8h.html#67274e784834c6c2547f4b5344fc4ea9">gps_sv_status_callback</a> )(<a class="el" href="struct_gps_sv_status.html">GpsSvStatus</a> *sv_info)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Callback with SV status information. <a href="#67274e784834c6c2547f4b5344fc4ea9"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef void(*&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="gps_8h.html#08fcfb3f85c2ac3008c9c73cf9136515">gps_xtra_download_request</a> )()</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Callback to request the client to download XTRA data. <a href="#08fcfb3f85c2ac3008c9c73cf9136515"></a><br></td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">const <a class="el" href="struct_gps_interface.html">GpsInterface</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="gps_8h.html#6d15bb02f1f91dd760e3e172bd7711a1">gps_get_hardware_interface</a> ()</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns the hardware GPS interface. <a href="#6d15bb02f1f91dd760e3e172bd7711a1"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">const <a class="el" href="struct_gps_interface.html">GpsInterface</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="gps_8h.html#f73f4a220fb97545e81d82fbff54b47e">gps_get_qemu_interface</a> ()</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns the qemu emulated GPS interface. <a href="#f73f4a220fb97545e81d82fbff54b47e"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">const <a class="el" href="struct_gps_interface.html">GpsInterface</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="gps_8h.html#b582931ddf4bafa2cc5044963be66987">gps_get_interface</a> ()</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns the default GPS interface. <a href="#b582931ddf4bafa2cc5044963be66987"></a><br></td></tr>
</table>
<hr><h2>Typedef Documentation</h2>
<a class="anchor" name="88f19d3da70dc0e951b51091ce0631ae"></a><!-- doxytag: member="gps.h::gps_location_callback" ref="88f19d3da70dc0e951b51091ce0631ae" args=")(GpsLocation *location)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef void(* <a class="el" href="gps_8h.html#88f19d3da70dc0e951b51091ce0631ae">gps_location_callback</a>)(<a class="el" href="struct_gps_location.html">GpsLocation</a> *location) </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Callback with location information.
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00166">166</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
</div>
</div><p>
<a class="anchor" name="1d9ef60ab0b91f7c106867a6aa1e4412"></a><!-- doxytag: member="gps.h::gps_status_callback" ref="1d9ef60ab0b91f7c106867a6aa1e4412" args=")(GpsStatus *status)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef void(* <a class="el" href="gps_8h.html#1d9ef60ab0b91f7c106867a6aa1e4412">gps_status_callback</a>)(<a class="el" href="struct_gps_status.html">GpsStatus</a> *status) </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Callback with status information.
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00169">169</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
</div>
</div><p>
<a class="anchor" name="67274e784834c6c2547f4b5344fc4ea9"></a><!-- doxytag: member="gps.h::gps_sv_status_callback" ref="67274e784834c6c2547f4b5344fc4ea9" args=")(GpsSvStatus *sv_info)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef void(* <a class="el" href="gps_8h.html#67274e784834c6c2547f4b5344fc4ea9">gps_sv_status_callback</a>)(<a class="el" href="struct_gps_sv_status.html">GpsSvStatus</a> *sv_info) </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Callback with SV status information.
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00172">172</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
</div>
</div><p>
<a class="anchor" name="08fcfb3f85c2ac3008c9c73cf9136515"></a><!-- doxytag: member="gps.h::gps_xtra_download_request" ref="08fcfb3f85c2ac3008c9c73cf9136515" args=")()" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef void(* <a class="el" href="gps_8h.html#08fcfb3f85c2ac3008c9c73cf9136515">gps_xtra_download_request</a>)() </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Callback to request the client to download XTRA data.
<p>
The client should download XTRA data and inject it by calling inject_xtra_data().
<p>Definition at line <a class="el" href="gps_8h-source.html#l00226">226</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
</div>
</div><p>
<a class="anchor" name="93f0283aeabd20211499991a29db7377"></a><!-- doxytag: member="gps.h::GpsAidingData" ref="93f0283aeabd20211499991a29db7377" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef uint16_t <a class="el" href="gps_8h.html#93f0283aeabd20211499991a29db7377">GpsAidingData</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Flags used to specify which aiding data to delete when calling delete_aiding_data().
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00075">75</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
</div>
</div><p>
<a class="anchor" name="4ae31616d5e232ad7a346a2d4e723e31"></a><!-- doxytag: member="gps.h::GpsLocationFlags" ref="4ae31616d5e232ad7a346a2d4e723e31" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef uint16_t <a class="el" href="gps_8h.html#4ae31616d5e232ad7a346a2d4e723e31">GpsLocationFlags</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Flags to indicate which values are valid in a <a class="el" href="struct_gps_location.html" title="Represents a location.">GpsLocation</a>.
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00059">59</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
</div>
</div><p>
<a class="anchor" name="2461a6f0dd56a1f7dc94e93207a1f740"></a><!-- doxytag: member="gps.h::GpsPositionMode" ref="2461a6f0dd56a1f7dc94e93207a1f740" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef uint16_t <a class="el" href="gps_8h.html#2461a6f0dd56a1f7dc94e93207a1f740">GpsPositionMode</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Requested mode for GPS operation.
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00033">33</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
</div>
</div><p>
<a class="anchor" name="de8fa0020d3aa1748a8e26759b768ec5"></a><!-- doxytag: member="gps.h::GpsStatusValue" ref="de8fa0020d3aa1748a8e26759b768ec5" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef uint16_t <a class="el" href="gps_8h.html#de8fa0020d3aa1748a8e26759b768ec5">GpsStatusValue</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
GPS status event values.
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00044">44</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
</div>
</div><p>
<a class="anchor" name="f2b0ea531a44c010f81a4abd27504c15"></a><!-- doxytag: member="gps.h::GpsUtcTime" ref="f2b0ea531a44c010f81a4abd27504c15" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef int64_t <a class="el" href="gps_8h.html#f2b0ea531a44c010f81a4abd27504c15">GpsUtcTime</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Milliseconds since January 1, 1970.
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00027">27</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
</div>
</div><p>
<hr><h2>Function Documentation</h2>
<a class="anchor" name="6d15bb02f1f91dd760e3e172bd7711a1"></a><!-- doxytag: member="gps.h::gps_get_hardware_interface" ref="6d15bb02f1f91dd760e3e172bd7711a1" args="()" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">const <a class="el" href="struct_gps_interface.html">GpsInterface</a>* gps_get_hardware_interface </td>
<td>(</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Returns the hardware GPS interface.
<p>
</div>
</div><p>
<a class="anchor" name="b582931ddf4bafa2cc5044963be66987"></a><!-- doxytag: member="gps.h::gps_get_interface" ref="b582931ddf4bafa2cc5044963be66987" args="()" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">const <a class="el" href="struct_gps_interface.html">GpsInterface</a>* gps_get_interface </td>
<td>(</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Returns the default GPS interface.
<p>
</div>
</div><p>
<a class="anchor" name="f73f4a220fb97545e81d82fbff54b47e"></a><!-- doxytag: member="gps.h::gps_get_qemu_interface" ref="f73f4a220fb97545e81d82fbff54b47e" args="()" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">const <a class="el" href="struct_gps_interface.html">GpsInterface</a>* gps_get_qemu_interface </td>
<td>(</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Returns the qemu emulated GPS interface.
<p>
</div>
</div><p>
</div>
</body>
</html>

View File

@@ -1,33 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Doxygen-Generated Content</title>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
.navigation {
display: none;
}
-->
</style>
</head>
<body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li class="current"><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
</div>
<div class="contents">
<h1>groups.dox File Reference</h1><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
</table>
</div>
</body>
</html>

View File

@@ -1,33 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Doxygen-Generated Content</title>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
.navigation {
display: none;
}
-->
</style>
</head>
<body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li class="current"><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
</div>
<div class="contents">
<h1>main.dox File Reference</h1><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
</table>
</div>
</body>
</html>

View File

@@ -1,214 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Doxygen-Generated Content</title>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
.navigation {
display: none;
}
-->
</style>
</head>
<body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li class="current"><a href="namespaces.html"><span>Namespaces</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="namespaces.html"><span>Namespace List</span></a></li>
<li><a href="namespacemembers.html"><span>Namespace&nbsp;Members</span></a></li>
</ul>
</div>
</div>
<div class="contents">
<h1>android Namespace Reference</h1>
<p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Data Structures</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">class &nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_stream_out.html">AudioStreamOut</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight"><a class="el" href="classandroid_1_1_audio_stream_out.html" title="AudioStreamOut is the abstraction interface for the audio output hardware.">AudioStreamOut</a> is the abstraction interface for the audio output hardware. <a href="classandroid_1_1_audio_stream_out.html#_details">More...</a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">class &nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_stream_in.html">AudioStreamIn</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight"><a class="el" href="classandroid_1_1_audio_stream_in.html" title="AudioStreamIn is the abstraction interface for the audio input hardware.">AudioStreamIn</a> is the abstraction interface for the audio input hardware. <a href="classandroid_1_1_audio_stream_in.html#_details">More...</a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">class &nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_audio_hardware_interface.html">AudioHardwareInterface</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight"><a class="el" href="_audio_hardware_interface_8h.html">AudioHardwareInterface.h</a> defines the interface to the audio hardware abstraction layer. <a href="classandroid_1_1_audio_hardware_interface.html#_details">More...</a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">class &nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classandroid_1_1_camera_hardware_interface.html">CameraHardwareInterface</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight"><a class="el" href="_camera_hardware_interface_8h.html">CameraHardwareInterface.h</a> defines the interface to the camera hardware abstraction layer, used for setting and getting parameters, live previewing, and taking pictures. <a href="classandroid_1_1_camera_hardware_interface.html#_details">More...</a><br></td></tr>
<tr><td colspan="2"><br><h2>Typedefs</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef void(*&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceandroid.html#d32b08663d42356404e2eb971e271636">preview_callback</a> )(const sp&lt; IMemory &gt; &amp;mem, void *user)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Callback for startPreview(). <a href="#d32b08663d42356404e2eb971e271636"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef void(*&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceandroid.html#04c83209c2627e2d303320712ca9ee65">shutter_callback</a> )(void *user)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Callback for takePicture(). <a href="#04c83209c2627e2d303320712ca9ee65"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef void(*&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceandroid.html#a97926709e452d66360cb9b24736969e">raw_callback</a> )(const sp&lt; IMemory &gt; &amp;mem, void *user)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Callback for takePicture(). <a href="#a97926709e452d66360cb9b24736969e"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef void(*&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceandroid.html#c21980d4be1e0cc458399ecf5374d473">jpeg_callback</a> )(const sp&lt; IMemory &gt; &amp;mem, void *user)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Callback for takePicture(). <a href="#c21980d4be1e0cc458399ecf5374d473"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef void(*&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceandroid.html#4dca8d8b824ca9a684358133da0ec8f2">autofocus_callback</a> )(bool focused, void *user)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Callback for autoFocus(). <a href="#4dca8d8b824ca9a684358133da0ec8f2"></a><br></td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="el" href="classandroid_1_1_audio_hardware_interface.html">AudioHardwareInterface</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceandroid.html#dcc80314ddffcb0981a9e9c5468662f8">createAudioHardware</a> (void)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">sp&lt; <a class="el" href="classandroid_1_1_camera_hardware_interface.html">CameraHardwareInterface</a> &gt;&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceandroid.html#24c243f7f9ba0d1d881be17ae06254a2">openCameraHardware</a> ()</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">factory function to instantiate a camera hardware object <a href="#24c243f7f9ba0d1d881be17ae06254a2"></a><br></td></tr>
</table>
<hr><h2>Typedef Documentation</h2>
<a class="anchor" name="4dca8d8b824ca9a684358133da0ec8f2"></a><!-- doxytag: member="android::autofocus_callback" ref="4dca8d8b824ca9a684358133da0ec8f2" args=")(bool focused, void *user)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef void(* <a class="el" href="namespaceandroid.html#4dca8d8b824ca9a684358133da0ec8f2">android::autofocus_callback</a>)(bool focused, void *user) </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Callback for autoFocus().
<p>
<p>Definition at line <a class="el" href="_camera_hardware_interface_8h-source.html#l00039">39</a> of file <a class="el" href="_camera_hardware_interface_8h-source.html">CameraHardwareInterface.h</a>.</p>
</div>
</div><p>
<a class="anchor" name="c21980d4be1e0cc458399ecf5374d473"></a><!-- doxytag: member="android::jpeg_callback" ref="c21980d4be1e0cc458399ecf5374d473" args=")(const sp&lt; IMemory &gt; &amp;mem, void *user)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef void(* <a class="el" href="namespaceandroid.html#c21980d4be1e0cc458399ecf5374d473">android::jpeg_callback</a>)(const sp&lt; IMemory &gt; &amp;mem, void *user) </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Callback for takePicture().
<p>
<p>Definition at line <a class="el" href="_camera_hardware_interface_8h-source.html#l00036">36</a> of file <a class="el" href="_camera_hardware_interface_8h-source.html">CameraHardwareInterface.h</a>.</p>
</div>
</div><p>
<a class="anchor" name="d32b08663d42356404e2eb971e271636"></a><!-- doxytag: member="android::preview_callback" ref="d32b08663d42356404e2eb971e271636" args=")(const sp&lt; IMemory &gt; &amp;mem, void *user)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef void(* <a class="el" href="namespaceandroid.html#d32b08663d42356404e2eb971e271636">android::preview_callback</a>)(const sp&lt; IMemory &gt; &amp;mem, void *user) </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Callback for startPreview().
<p>
<p>Definition at line <a class="el" href="_camera_hardware_interface_8h-source.html#l00027">27</a> of file <a class="el" href="_camera_hardware_interface_8h-source.html">CameraHardwareInterface.h</a>.</p>
</div>
</div><p>
<a class="anchor" name="a97926709e452d66360cb9b24736969e"></a><!-- doxytag: member="android::raw_callback" ref="a97926709e452d66360cb9b24736969e" args=")(const sp&lt; IMemory &gt; &amp;mem, void *user)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef void(* <a class="el" href="namespaceandroid.html#a97926709e452d66360cb9b24736969e">android::raw_callback</a>)(const sp&lt; IMemory &gt; &amp;mem, void *user) </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Callback for takePicture().
<p>
<p>Definition at line <a class="el" href="_camera_hardware_interface_8h-source.html#l00033">33</a> of file <a class="el" href="_camera_hardware_interface_8h-source.html">CameraHardwareInterface.h</a>.</p>
</div>
</div><p>
<a class="anchor" name="04c83209c2627e2d303320712ca9ee65"></a><!-- doxytag: member="android::shutter_callback" ref="04c83209c2627e2d303320712ca9ee65" args=")(void *user)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef void(* <a class="el" href="namespaceandroid.html#04c83209c2627e2d303320712ca9ee65">android::shutter_callback</a>)(void *user) </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Callback for takePicture().
<p>
<p>Definition at line <a class="el" href="_camera_hardware_interface_8h-source.html#l00030">30</a> of file <a class="el" href="_camera_hardware_interface_8h-source.html">CameraHardwareInterface.h</a>.</p>
</div>
</div><p>
<hr><h2>Function Documentation</h2>
<a class="anchor" name="dcc80314ddffcb0981a9e9c5468662f8"></a><!-- doxytag: member="android::createAudioHardware" ref="dcc80314ddffcb0981a9e9c5468662f8" args="(void)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classandroid_1_1_audio_hardware_interface.html">AudioHardwareInterface</a>* android::createAudioHardware </td>
<td>(</td>
<td class="paramtype">void&nbsp;</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
</div>
</div><p>
<a class="anchor" name="24c243f7f9ba0d1d881be17ae06254a2"></a><!-- doxytag: member="android::openCameraHardware" ref="24c243f7f9ba0d1d881be17ae06254a2" args="()" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">sp&lt;<a class="el" href="classandroid_1_1_camera_hardware_interface.html">CameraHardwareInterface</a>&gt; android::openCameraHardware </td>
<td>(</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
factory function to instantiate a camera hardware object
<p>
</div>
</div><p>
</div>
</body>
</html>

View File

@@ -1,61 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Doxygen-Generated Content</title>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
.navigation {
display: none;
}
-->
</style>
</head>
<body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li class="current"><a href="namespaces.html"><span>Namespaces</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="namespaces.html"><span>Namespace List</span></a></li>
<li class="current"><a href="namespacemembers.html"><span>Namespace&nbsp;Members</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li class="current"><a href="namespacemembers.html"><span>All</span></a></li>
<li><a href="namespacemembers_func.html"><span>Functions</span></a></li>
<li><a href="namespacemembers_type.html"><span>Typedefs</span></a></li>
</ul>
</div>
</div>
<div class="contents">
Here is a list of all namespace members with links to the namespace documentation for each member:
<p>
<ul>
<li>autofocus_callback
: <a class="el" href="namespaceandroid.html#4dca8d8b824ca9a684358133da0ec8f2">android</a>
<li>createAudioHardware()
: <a class="el" href="namespaceandroid.html#dcc80314ddffcb0981a9e9c5468662f8">android</a>
<li>jpeg_callback
: <a class="el" href="namespaceandroid.html#c21980d4be1e0cc458399ecf5374d473">android</a>
<li>openCameraHardware()
: <a class="el" href="namespaceandroid.html#24c243f7f9ba0d1d881be17ae06254a2">android</a>
<li>preview_callback
: <a class="el" href="namespaceandroid.html#d32b08663d42356404e2eb971e271636">android</a>
<li>raw_callback
: <a class="el" href="namespaceandroid.html#a97926709e452d66360cb9b24736969e">android</a>
<li>shutter_callback
: <a class="el" href="namespaceandroid.html#04c83209c2627e2d303320712ca9ee65">android</a>
</ul>
</div>
</body>
</html>

View File

@@ -1,51 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Doxygen-Generated Content</title>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
.navigation {
display: none;
}
-->
</style>
</head>
<body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li class="current"><a href="namespaces.html"><span>Namespaces</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="namespaces.html"><span>Namespace List</span></a></li>
<li class="current"><a href="namespacemembers.html"><span>Namespace&nbsp;Members</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="namespacemembers.html"><span>All</span></a></li>
<li class="current"><a href="namespacemembers_func.html"><span>Functions</span></a></li>
<li><a href="namespacemembers_type.html"><span>Typedefs</span></a></li>
</ul>
</div>
</div>
<div class="contents">
&nbsp;
<p>
<ul>
<li>createAudioHardware()
: <a class="el" href="namespaceandroid.html#dcc80314ddffcb0981a9e9c5468662f8">android</a>
<li>openCameraHardware()
: <a class="el" href="namespaceandroid.html#24c243f7f9ba0d1d881be17ae06254a2">android</a>
</ul>
</div>
</body>
</html>

View File

@@ -1,57 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Doxygen-Generated Content</title>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
.navigation {
display: none;
}
-->
</style>
</head>
<body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li class="current"><a href="namespaces.html"><span>Namespaces</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="namespaces.html"><span>Namespace List</span></a></li>
<li class="current"><a href="namespacemembers.html"><span>Namespace&nbsp;Members</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="namespacemembers.html"><span>All</span></a></li>
<li><a href="namespacemembers_func.html"><span>Functions</span></a></li>
<li class="current"><a href="namespacemembers_type.html"><span>Typedefs</span></a></li>
</ul>
</div>
</div>
<div class="contents">
&nbsp;
<p>
<ul>
<li>autofocus_callback
: <a class="el" href="namespaceandroid.html#4dca8d8b824ca9a684358133da0ec8f2">android</a>
<li>jpeg_callback
: <a class="el" href="namespaceandroid.html#c21980d4be1e0cc458399ecf5374d473">android</a>
<li>preview_callback
: <a class="el" href="namespaceandroid.html#d32b08663d42356404e2eb971e271636">android</a>
<li>raw_callback
: <a class="el" href="namespaceandroid.html#a97926709e452d66360cb9b24736969e">android</a>
<li>shutter_callback
: <a class="el" href="namespaceandroid.html#04c83209c2627e2d303320712ca9ee65">android</a>
</ul>
</div>
</body>
</html>

View File

@@ -1,39 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Doxygen-Generated Content</title>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
.navigation {
display: none;
}
-->
</style>
</head>
<body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li class="current"><a href="namespaces.html"><span>Namespaces</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li class="current"><a href="namespaces.html"><span>Namespace List</span></a></li>
<li><a href="namespacemembers.html"><span>Namespace&nbsp;Members</span></a></li>
</ul>
</div>
</div>
<div class="contents">
<h1>Namespace List</h1>Here is a list of all namespaces with brief descriptions:<table>
<tr><td class="indexkey"><a class="el" href="namespaceandroid.html">android</a></td><td class="indexvalue"></td></tr>
</table>
</div>
</body>
</html>

View File

@@ -1,110 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Doxygen-Generated Content</title>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
.navigation {
display: none;
}
-->
</style>
</head>
<body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li class="current"><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="functions.html"><span>Data&nbsp;Fields</span></a></li>
</ul>
</div>
</div>
<div class="contents">
<h1>GpsCallbacks Struct Reference</h1><!-- doxytag: class="GpsCallbacks" -->GPS callback structure.
<a href="#_details">More...</a>
<p>
<code>#include &lt;<a class="el" href="gps_8h-source.html">gps.h</a>&gt;</code>
<p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Data Fields</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="el" href="gps_8h.html#88f19d3da70dc0e951b51091ce0631ae">gps_location_callback</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_callbacks.html#1f59b4f8eeaca50620f94761536dabd3">location_cb</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="el" href="gps_8h.html#1d9ef60ab0b91f7c106867a6aa1e4412">gps_status_callback</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_callbacks.html#7b15a1bf4f9b989677fef84f4d8141df">status_cb</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="el" href="gps_8h.html#67274e784834c6c2547f4b5344fc4ea9">gps_sv_status_callback</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_callbacks.html#fb34f60ad58e80de5c04790b107bb93d">sv_status_cb</a></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
GPS callback structure.
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00175">175</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
<hr><h2>Field Documentation</h2>
<a class="anchor" name="1f59b4f8eeaca50620f94761536dabd3"></a><!-- doxytag: member="GpsCallbacks::location_cb" ref="1f59b4f8eeaca50620f94761536dabd3" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="gps_8h.html#88f19d3da70dc0e951b51091ce0631ae">gps_location_callback</a> <a class="el" href="struct_gps_callbacks.html#1f59b4f8eeaca50620f94761536dabd3">GpsCallbacks::location_cb</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00176">176</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
</div>
</div><p>
<a class="anchor" name="7b15a1bf4f9b989677fef84f4d8141df"></a><!-- doxytag: member="GpsCallbacks::status_cb" ref="7b15a1bf4f9b989677fef84f4d8141df" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="gps_8h.html#1d9ef60ab0b91f7c106867a6aa1e4412">gps_status_callback</a> <a class="el" href="struct_gps_callbacks.html#7b15a1bf4f9b989677fef84f4d8141df">GpsCallbacks::status_cb</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00177">177</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
</div>
</div><p>
<a class="anchor" name="fb34f60ad58e80de5c04790b107bb93d"></a><!-- doxytag: member="GpsCallbacks::sv_status_cb" ref="fb34f60ad58e80de5c04790b107bb93d" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="gps_8h.html#67274e784834c6c2547f4b5344fc4ea9">gps_sv_status_callback</a> <a class="el" href="struct_gps_callbacks.html#fb34f60ad58e80de5c04790b107bb93d">GpsCallbacks::sv_status_cb</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00178">178</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
</div>
</div><p>
<hr>The documentation for this struct was generated from the following file:<ul>
<li><a class="el" href="gps_8h-source.html">gps.h</a></ul>
</div>
</body>
</html>

View File

@@ -1,233 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Doxygen-Generated Content</title>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
.navigation {
display: none;
}
-->
</style>
</head>
<body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li class="current"><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="functions.html"><span>Data&nbsp;Fields</span></a></li>
</ul>
</div>
</div>
<div class="contents">
<h1>GpsInterface Struct Reference</h1><!-- doxytag: class="GpsInterface" -->Represents the standard GPS interface.
<a href="#_details">More...</a>
<p>
<code>#include &lt;<a class="el" href="gps_8h-source.html">gps.h</a>&gt;</code>
<p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Data Fields</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int(*&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_interface.html#d5139fa13b75108bdedd8a2717f37135">init</a> )(<a class="el" href="struct_gps_callbacks.html">GpsCallbacks</a> *callbacks)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Opens the interface and provides the callback routines to the implemenation of this interface. <a href="#d5139fa13b75108bdedd8a2717f37135"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int(*&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_interface.html#2b212721e0d160e24944330b2d830790">start</a> )(void)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Starts navigating. <a href="#2b212721e0d160e24944330b2d830790"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int(*&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_interface.html#d20b0cfcbf976d8cec17bf4ea0a027f1">stop</a> )(void)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Stops navigating. <a href="#d20b0cfcbf976d8cec17bf4ea0a027f1"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void(*&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_interface.html#1e727f5862ae7132f12af44ebdfa76b2">set_fix_frequency</a> )(int frequency)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Sets requested frequency of fixes in seconds. <a href="#1e727f5862ae7132f12af44ebdfa76b2"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void(*&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_interface.html#2911808e36c70259dc0db162de02dc13">cleanup</a> )(void)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Closes the interface. <a href="#2911808e36c70259dc0db162de02dc13"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int(*&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_interface.html#e731891e96a916271a4275eaaea47ad8">inject_time</a> )(<a class="el" href="gps_8h.html#f2b0ea531a44c010f81a4abd27504c15">GpsUtcTime</a> time, int64_t timeReference, int uncertainty)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Injects the current time. <a href="#e731891e96a916271a4275eaaea47ad8"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void(*&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_interface.html#a3a9b81a8a719b628ac8049344f50b58">delete_aiding_data</a> )(<a class="el" href="gps_8h.html#93f0283aeabd20211499991a29db7377">GpsAidingData</a> flags)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Specifies that the next call to start will not use the information defined in the flags. <a href="#a3a9b81a8a719b628ac8049344f50b58"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int(*&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_interface.html#924bff47462a773b669d310d87b75734">set_position_mode</a> )(<a class="el" href="gps_8h.html#2461a6f0dd56a1f7dc94e93207a1f740">GpsPositionMode</a> mode, int fix_frequency)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">fix_frequency represents the time between fixes in seconds. <a href="#924bff47462a773b669d310d87b75734"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">const void *(*&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_interface.html#19af32bd9d01ebbcdb196e36514b0e98">get_extension</a> )(const char *name)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Get a pointer to extension information. <a href="#19af32bd9d01ebbcdb196e36514b0e98"></a><br></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
Represents the standard GPS interface.
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00183">183</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
<hr><h2>Field Documentation</h2>
<a class="anchor" name="d5139fa13b75108bdedd8a2717f37135"></a><!-- doxytag: member="GpsInterface::init" ref="d5139fa13b75108bdedd8a2717f37135" args=")(GpsCallbacks *callbacks)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int(* <a class="el" href="struct_gps_interface.html#d5139fa13b75108bdedd8a2717f37135">GpsInterface::init</a>)(<a class="el" href="struct_gps_callbacks.html">GpsCallbacks</a> *callbacks) </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Opens the interface and provides the callback routines to the implemenation of this interface.
<p>
</div>
</div><p>
<a class="anchor" name="2b212721e0d160e24944330b2d830790"></a><!-- doxytag: member="GpsInterface::start" ref="2b212721e0d160e24944330b2d830790" args=")(void)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int(* <a class="el" href="struct_gps_interface.html#2b212721e0d160e24944330b2d830790">GpsInterface::start</a>)(void) </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Starts navigating.
<p>
</div>
</div><p>
<a class="anchor" name="d20b0cfcbf976d8cec17bf4ea0a027f1"></a><!-- doxytag: member="GpsInterface::stop" ref="d20b0cfcbf976d8cec17bf4ea0a027f1" args=")(void)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int(* <a class="el" href="struct_gps_interface.html#d20b0cfcbf976d8cec17bf4ea0a027f1">GpsInterface::stop</a>)(void) </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Stops navigating.
<p>
</div>
</div><p>
<a class="anchor" name="1e727f5862ae7132f12af44ebdfa76b2"></a><!-- doxytag: member="GpsInterface::set_fix_frequency" ref="1e727f5862ae7132f12af44ebdfa76b2" args=")(int frequency)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void(* <a class="el" href="struct_gps_interface.html#1e727f5862ae7132f12af44ebdfa76b2">GpsInterface::set_fix_frequency</a>)(int frequency) </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Sets requested frequency of fixes in seconds.
<p>
</div>
</div><p>
<a class="anchor" name="2911808e36c70259dc0db162de02dc13"></a><!-- doxytag: member="GpsInterface::cleanup" ref="2911808e36c70259dc0db162de02dc13" args=")(void)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void(* <a class="el" href="struct_gps_interface.html#2911808e36c70259dc0db162de02dc13">GpsInterface::cleanup</a>)(void) </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Closes the interface.
<p>
</div>
</div><p>
<a class="anchor" name="e731891e96a916271a4275eaaea47ad8"></a><!-- doxytag: member="GpsInterface::inject_time" ref="e731891e96a916271a4275eaaea47ad8" args=")(GpsUtcTime time, int64_t timeReference, int uncertainty)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int(* <a class="el" href="struct_gps_interface.html#e731891e96a916271a4275eaaea47ad8">GpsInterface::inject_time</a>)(<a class="el" href="gps_8h.html#f2b0ea531a44c010f81a4abd27504c15">GpsUtcTime</a> time, int64_t timeReference, int uncertainty) </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Injects the current time.
<p>
</div>
</div><p>
<a class="anchor" name="a3a9b81a8a719b628ac8049344f50b58"></a><!-- doxytag: member="GpsInterface::delete_aiding_data" ref="a3a9b81a8a719b628ac8049344f50b58" args=")(GpsAidingData flags)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void(* <a class="el" href="struct_gps_interface.html#a3a9b81a8a719b628ac8049344f50b58">GpsInterface::delete_aiding_data</a>)(<a class="el" href="gps_8h.html#93f0283aeabd20211499991a29db7377">GpsAidingData</a> flags) </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Specifies that the next call to start will not use the information defined in the flags.
<p>
GPS_DELETE_ALL is passed for a cold start.
</div>
</div><p>
<a class="anchor" name="924bff47462a773b669d310d87b75734"></a><!-- doxytag: member="GpsInterface::set_position_mode" ref="924bff47462a773b669d310d87b75734" args=")(GpsPositionMode mode, int fix_frequency)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int(* <a class="el" href="struct_gps_interface.html#924bff47462a773b669d310d87b75734">GpsInterface::set_position_mode</a>)(<a class="el" href="gps_8h.html#2461a6f0dd56a1f7dc94e93207a1f740">GpsPositionMode</a> mode, int fix_frequency) </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
fix_frequency represents the time between fixes in seconds.
<p>
Set fix_frequency to zero for a single-shot fix.
</div>
</div><p>
<a class="anchor" name="19af32bd9d01ebbcdb196e36514b0e98"></a><!-- doxytag: member="GpsInterface::get_extension" ref="19af32bd9d01ebbcdb196e36514b0e98" args=")(const char *name)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">const void*(* <a class="el" href="struct_gps_interface.html#19af32bd9d01ebbcdb196e36514b0e98">GpsInterface::get_extension</a>)(const char *name) </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Get a pointer to extension information.
<p>
</div>
</div><p>
<hr>The documentation for this struct was generated from the following file:<ul>
<li><a class="el" href="gps_8h-source.html">gps.h</a></ul>
</div>
</body>
</html>

View File

@@ -1,229 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Doxygen-Generated Content</title>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
.navigation {
display: none;
}
-->
</style>
</head>
<body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li class="current"><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="functions.html"><span>Data&nbsp;Fields</span></a></li>
</ul>
</div>
</div>
<div class="contents">
<h1>GpsLocation Struct Reference</h1><!-- doxytag: class="GpsLocation" -->Represents a location.
<a href="#_details">More...</a>
<p>
<code>#include &lt;<a class="el" href="gps_8h-source.html">gps.h</a>&gt;</code>
<p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Data Fields</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">uint16_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_location.html#07d55fee34dc28cff50062e9ac42c717">flags</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Contains GpsLocationFlags bits. <a href="#07d55fee34dc28cff50062e9ac42c717"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">double&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_location.html#3a7da06efae47c66428fa2815a3eb4bd">latitude</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Represents latitude in degrees. <a href="#3a7da06efae47c66428fa2815a3eb4bd"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">double&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_location.html#3672d2d19087d62d7ea9b0b71418da40">longitude</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Represents longitude in degrees. <a href="#3672d2d19087d62d7ea9b0b71418da40"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">double&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_location.html#cb3cc5ad378a6a3864e47ae67df38778">altitude</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Represents altitude in meters above the WGS 84 reference ellipsoid. <a href="#cb3cc5ad378a6a3864e47ae67df38778"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">float&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_location.html#38ae20b9c5e7be995513dce25ed87016">speed</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Represents speed in meters per second. <a href="#38ae20b9c5e7be995513dce25ed87016"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">float&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_location.html#b71bf9b61cf55f10ffcf34ba1654d082">bearing</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Represents heading in degrees. <a href="#b71bf9b61cf55f10ffcf34ba1654d082"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">float&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_location.html#801ec0db8ee69fa263a63528876d773b">accuracy</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Represents expected accuracy in meters. <a href="#801ec0db8ee69fa263a63528876d773b"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="el" href="gps_8h.html#f2b0ea531a44c010f81a4abd27504c15">GpsUtcTime</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_location.html#3e16861f64869d6f0e15e4300bb2658b">timestamp</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Timestamp for the location fix. <a href="#3e16861f64869d6f0e15e4300bb2658b"></a><br></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
Represents a location.
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00103">103</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
<hr><h2>Field Documentation</h2>
<a class="anchor" name="07d55fee34dc28cff50062e9ac42c717"></a><!-- doxytag: member="GpsLocation::flags" ref="07d55fee34dc28cff50062e9ac42c717" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">uint16_t <a class="el" href="struct_gps_location.html#07d55fee34dc28cff50062e9ac42c717">GpsLocation::flags</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Contains GpsLocationFlags bits.
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00105">105</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
</div>
</div><p>
<a class="anchor" name="3a7da06efae47c66428fa2815a3eb4bd"></a><!-- doxytag: member="GpsLocation::latitude" ref="3a7da06efae47c66428fa2815a3eb4bd" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">double <a class="el" href="struct_gps_location.html#3a7da06efae47c66428fa2815a3eb4bd">GpsLocation::latitude</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Represents latitude in degrees.
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00107">107</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
</div>
</div><p>
<a class="anchor" name="3672d2d19087d62d7ea9b0b71418da40"></a><!-- doxytag: member="GpsLocation::longitude" ref="3672d2d19087d62d7ea9b0b71418da40" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">double <a class="el" href="struct_gps_location.html#3672d2d19087d62d7ea9b0b71418da40">GpsLocation::longitude</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Represents longitude in degrees.
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00109">109</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
</div>
</div><p>
<a class="anchor" name="cb3cc5ad378a6a3864e47ae67df38778"></a><!-- doxytag: member="GpsLocation::altitude" ref="cb3cc5ad378a6a3864e47ae67df38778" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">double <a class="el" href="struct_gps_location.html#cb3cc5ad378a6a3864e47ae67df38778">GpsLocation::altitude</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Represents altitude in meters above the WGS 84 reference ellipsoid.
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00112">112</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
</div>
</div><p>
<a class="anchor" name="38ae20b9c5e7be995513dce25ed87016"></a><!-- doxytag: member="GpsLocation::speed" ref="38ae20b9c5e7be995513dce25ed87016" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">float <a class="el" href="struct_gps_location.html#38ae20b9c5e7be995513dce25ed87016">GpsLocation::speed</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Represents speed in meters per second.
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00114">114</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
</div>
</div><p>
<a class="anchor" name="b71bf9b61cf55f10ffcf34ba1654d082"></a><!-- doxytag: member="GpsLocation::bearing" ref="b71bf9b61cf55f10ffcf34ba1654d082" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">float <a class="el" href="struct_gps_location.html#b71bf9b61cf55f10ffcf34ba1654d082">GpsLocation::bearing</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Represents heading in degrees.
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00116">116</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
</div>
</div><p>
<a class="anchor" name="801ec0db8ee69fa263a63528876d773b"></a><!-- doxytag: member="GpsLocation::accuracy" ref="801ec0db8ee69fa263a63528876d773b" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">float <a class="el" href="struct_gps_location.html#801ec0db8ee69fa263a63528876d773b">GpsLocation::accuracy</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Represents expected accuracy in meters.
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00118">118</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
</div>
</div><p>
<a class="anchor" name="3e16861f64869d6f0e15e4300bb2658b"></a><!-- doxytag: member="GpsLocation::timestamp" ref="3e16861f64869d6f0e15e4300bb2658b" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="gps_8h.html#f2b0ea531a44c010f81a4abd27504c15">GpsUtcTime</a> <a class="el" href="struct_gps_location.html#3e16861f64869d6f0e15e4300bb2658b">GpsLocation::timestamp</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Timestamp for the location fix.
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00120">120</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
</div>
</div><p>
<hr>The documentation for this struct was generated from the following file:<ul>
<li><a class="el" href="gps_8h-source.html">gps.h</a></ul>
</div>
</body>
</html>

View File

@@ -1,72 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Doxygen-Generated Content</title>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
.navigation {
display: none;
}
-->
</style>
</head>
<body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li class="current"><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="functions.html"><span>Data&nbsp;Fields</span></a></li>
</ul>
</div>
</div>
<div class="contents">
<h1>GpsStatus Struct Reference</h1><!-- doxytag: class="GpsStatus" -->Represents the status.
<a href="#_details">More...</a>
<p>
<code>#include &lt;<a class="el" href="gps_8h-source.html">gps.h</a>&gt;</code>
<p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Data Fields</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="el" href="gps_8h.html#de8fa0020d3aa1748a8e26759b768ec5">GpsStatusValue</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_status.html#64c9e8cd609d97533bee5c5e8ca78608">status</a></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
Represents the status.
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00124">124</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
<hr><h2>Field Documentation</h2>
<a class="anchor" name="64c9e8cd609d97533bee5c5e8ca78608"></a><!-- doxytag: member="GpsStatus::status" ref="64c9e8cd609d97533bee5c5e8ca78608" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="gps_8h.html#de8fa0020d3aa1748a8e26759b768ec5">GpsStatusValue</a> <a class="el" href="struct_gps_status.html#64c9e8cd609d97533bee5c5e8ca78608">GpsStatus::status</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00125">125</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
</div>
</div><p>
<hr>The documentation for this struct was generated from the following file:<ul>
<li><a class="el" href="gps_8h-source.html">gps.h</a></ul>
</div>
</body>
</html>

View File

@@ -1,141 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Doxygen-Generated Content</title>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
.navigation {
display: none;
}
-->
</style>
</head>
<body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li class="current"><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="functions.html"><span>Data&nbsp;Fields</span></a></li>
</ul>
</div>
</div>
<div class="contents">
<h1>GpsSvInfo Struct Reference</h1><!-- doxytag: class="GpsSvInfo" -->Represents SV information.
<a href="#_details">More...</a>
<p>
<code>#include &lt;<a class="el" href="gps_8h-source.html">gps.h</a>&gt;</code>
<p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Data Fields</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_sv_info.html#5c94e86f2efc3ed08fb5a40735a2440b">prn</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Pseudo-random number for the SV. <a href="#5c94e86f2efc3ed08fb5a40735a2440b"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">float&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_sv_info.html#eebf16140beb95390733529bd5e7db58">snr</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Signal to noise ratio. <a href="#eebf16140beb95390733529bd5e7db58"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">float&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_sv_info.html#0634009d0476b2f06f27568b0722a04d">elevation</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Elevation of SV in degrees. <a href="#0634009d0476b2f06f27568b0722a04d"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">float&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_sv_info.html#94755ad36e31a012269459d5a4ef0594">azimuth</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Azimuth of SV in degrees. <a href="#94755ad36e31a012269459d5a4ef0594"></a><br></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
Represents SV information.
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00129">129</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
<hr><h2>Field Documentation</h2>
<a class="anchor" name="5c94e86f2efc3ed08fb5a40735a2440b"></a><!-- doxytag: member="GpsSvInfo::prn" ref="5c94e86f2efc3ed08fb5a40735a2440b" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int <a class="el" href="struct_gps_sv_info.html#5c94e86f2efc3ed08fb5a40735a2440b">GpsSvInfo::prn</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Pseudo-random number for the SV.
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00131">131</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
</div>
</div><p>
<a class="anchor" name="eebf16140beb95390733529bd5e7db58"></a><!-- doxytag: member="GpsSvInfo::snr" ref="eebf16140beb95390733529bd5e7db58" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">float <a class="el" href="struct_gps_sv_info.html#eebf16140beb95390733529bd5e7db58">GpsSvInfo::snr</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Signal to noise ratio.
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00133">133</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
</div>
</div><p>
<a class="anchor" name="0634009d0476b2f06f27568b0722a04d"></a><!-- doxytag: member="GpsSvInfo::elevation" ref="0634009d0476b2f06f27568b0722a04d" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">float <a class="el" href="struct_gps_sv_info.html#0634009d0476b2f06f27568b0722a04d">GpsSvInfo::elevation</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Elevation of SV in degrees.
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00135">135</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
</div>
</div><p>
<a class="anchor" name="94755ad36e31a012269459d5a4ef0594"></a><!-- doxytag: member="GpsSvInfo::azimuth" ref="94755ad36e31a012269459d5a4ef0594" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">float <a class="el" href="struct_gps_sv_info.html#94755ad36e31a012269459d5a4ef0594">GpsSvInfo::azimuth</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Azimuth of SV in degrees.
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00137">137</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
</div>
</div><p>
<hr>The documentation for this struct was generated from the following file:<ul>
<li><a class="el" href="gps_8h-source.html">gps.h</a></ul>
</div>
</body>
</html>

View File

@@ -1,163 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Doxygen-Generated Content</title>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
.navigation {
display: none;
}
-->
</style>
</head>
<body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li class="current"><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="functions.html"><span>Data&nbsp;Fields</span></a></li>
</ul>
</div>
</div>
<div class="contents">
<h1>GpsSvStatus Struct Reference</h1><!-- doxytag: class="GpsSvStatus" -->Represents SV status.
<a href="#_details">More...</a>
<p>
<code>#include &lt;<a class="el" href="gps_8h-source.html">gps.h</a>&gt;</code>
<p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Data Fields</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_sv_status.html#b90eb63a499039de996c95d98afad545">num_svs</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Number of SVs currently visible. <a href="#b90eb63a499039de996c95d98afad545"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="el" href="struct_gps_sv_info.html">GpsSvInfo</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_sv_status.html#7a3fe2114e7a603b96fd9675adf0c5b5">sv_list</a> [GPS_MAX_SVS]</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Contains an array of SV information. <a href="#7a3fe2114e7a603b96fd9675adf0c5b5"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">uint32_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_sv_status.html#4751f70f8e275241dece99db0df4ab5b">ephemeris_mask</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Represents a bit mask indicating which SVs have ephemeris data. <a href="#4751f70f8e275241dece99db0df4ab5b"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">uint32_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_sv_status.html#6ed4b741a9882ecc2852e94e8ad60310">almanac_mask</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Represents a bit mask indicating which SVs have almanac data. <a href="#6ed4b741a9882ecc2852e94e8ad60310"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">uint32_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_sv_status.html#9090a26639d97eec2b59bcd0446659c0">used_in_fix_mask</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Represents a bit mask indicating which SVs were used for computing the most recent position fix. <a href="#9090a26639d97eec2b59bcd0446659c0"></a><br></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
Represents SV status.
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00141">141</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
<hr><h2>Field Documentation</h2>
<a class="anchor" name="b90eb63a499039de996c95d98afad545"></a><!-- doxytag: member="GpsSvStatus::num_svs" ref="b90eb63a499039de996c95d98afad545" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int <a class="el" href="struct_gps_sv_status.html#b90eb63a499039de996c95d98afad545">GpsSvStatus::num_svs</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Number of SVs currently visible.
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00143">143</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
</div>
</div><p>
<a class="anchor" name="7a3fe2114e7a603b96fd9675adf0c5b5"></a><!-- doxytag: member="GpsSvStatus::sv_list" ref="7a3fe2114e7a603b96fd9675adf0c5b5" args="[GPS_MAX_SVS]" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="struct_gps_sv_info.html">GpsSvInfo</a> <a class="el" href="struct_gps_sv_status.html#7a3fe2114e7a603b96fd9675adf0c5b5">GpsSvStatus::sv_list</a>[GPS_MAX_SVS] </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Contains an array of SV information.
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00146">146</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
</div>
</div><p>
<a class="anchor" name="4751f70f8e275241dece99db0df4ab5b"></a><!-- doxytag: member="GpsSvStatus::ephemeris_mask" ref="4751f70f8e275241dece99db0df4ab5b" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">uint32_t <a class="el" href="struct_gps_sv_status.html#4751f70f8e275241dece99db0df4ab5b">GpsSvStatus::ephemeris_mask</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Represents a bit mask indicating which SVs have ephemeris data.
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00151">151</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
</div>
</div><p>
<a class="anchor" name="6ed4b741a9882ecc2852e94e8ad60310"></a><!-- doxytag: member="GpsSvStatus::almanac_mask" ref="6ed4b741a9882ecc2852e94e8ad60310" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">uint32_t <a class="el" href="struct_gps_sv_status.html#6ed4b741a9882ecc2852e94e8ad60310">GpsSvStatus::almanac_mask</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Represents a bit mask indicating which SVs have almanac data.
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00156">156</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
</div>
</div><p>
<a class="anchor" name="9090a26639d97eec2b59bcd0446659c0"></a><!-- doxytag: member="GpsSvStatus::used_in_fix_mask" ref="9090a26639d97eec2b59bcd0446659c0" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">uint32_t <a class="el" href="struct_gps_sv_status.html#9090a26639d97eec2b59bcd0446659c0">GpsSvStatus::used_in_fix_mask</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Represents a bit mask indicating which SVs were used for computing the most recent position fix.
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00162">162</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
</div>
</div><p>
<hr>The documentation for this struct was generated from the following file:<ul>
<li><a class="el" href="gps_8h-source.html">gps.h</a></ul>
</div>
</body>
</html>

View File

@@ -1,72 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Doxygen-Generated Content</title>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
.navigation {
display: none;
}
-->
</style>
</head>
<body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li class="current"><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="functions.html"><span>Data&nbsp;Fields</span></a></li>
</ul>
</div>
</div>
<div class="contents">
<h1>GpsXtraCallbacks Struct Reference</h1><!-- doxytag: class="GpsXtraCallbacks" -->Callback structure for the XTRA interface.
<a href="#_details">More...</a>
<p>
<code>#include &lt;<a class="el" href="gps_8h-source.html">gps.h</a>&gt;</code>
<p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Data Fields</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="el" href="gps_8h.html#08fcfb3f85c2ac3008c9c73cf9136515">gps_xtra_download_request</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_xtra_callbacks.html#7e879ba4c3e32c52eaa0fb04fb9c226f">download_request_cb</a></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
Callback structure for the XTRA interface.
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00229">229</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
<hr><h2>Field Documentation</h2>
<a class="anchor" name="7e879ba4c3e32c52eaa0fb04fb9c226f"></a><!-- doxytag: member="GpsXtraCallbacks::download_request_cb" ref="7e879ba4c3e32c52eaa0fb04fb9c226f" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="gps_8h.html#08fcfb3f85c2ac3008c9c73cf9136515">gps_xtra_download_request</a> <a class="el" href="struct_gps_xtra_callbacks.html#7e879ba4c3e32c52eaa0fb04fb9c226f">GpsXtraCallbacks::download_request_cb</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00230">230</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
</div>
</div><p>
<hr>The documentation for this struct was generated from the following file:<ul>
<li><a class="el" href="gps_8h-source.html">gps.h</a></ul>
</div>
</body>
</html>

View File

@@ -1,93 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Doxygen-Generated Content</title>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
.navigation {
display: none;
}
-->
</style>
</head>
<body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li class="current"><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="functions.html"><span>Data&nbsp;Fields</span></a></li>
</ul>
</div>
</div>
<div class="contents">
<h1>GpsXtraInterface Struct Reference</h1><!-- doxytag: class="GpsXtraInterface" -->Extended interface for XTRA support.
<a href="#_details">More...</a>
<p>
<code>#include &lt;<a class="el" href="gps_8h-source.html">gps.h</a>&gt;</code>
<p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Data Fields</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int(*&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_xtra_interface.html#5532e662c68e1d3df7db86570df96bf0">init</a> )(<a class="el" href="struct_gps_xtra_callbacks.html">GpsXtraCallbacks</a> *callbacks)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Opens the XTRA interface and provides the callback routines to the implemenation of this interface. <a href="#5532e662c68e1d3df7db86570df96bf0"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int(*&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_gps_xtra_interface.html#2b1962c8a5a2751702937cf469dc7435">inject_xtra_data</a> )(char *data, int length)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Injects XTRA data into the GPS. <a href="#2b1962c8a5a2751702937cf469dc7435"></a><br></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
Extended interface for XTRA support.
<p>
<p>Definition at line <a class="el" href="gps_8h-source.html#l00234">234</a> of file <a class="el" href="gps_8h-source.html">gps.h</a>.</p>
<hr><h2>Field Documentation</h2>
<a class="anchor" name="5532e662c68e1d3df7db86570df96bf0"></a><!-- doxytag: member="GpsXtraInterface::init" ref="5532e662c68e1d3df7db86570df96bf0" args=")(GpsXtraCallbacks *callbacks)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int(* <a class="el" href="struct_gps_xtra_interface.html#5532e662c68e1d3df7db86570df96bf0">GpsXtraInterface::init</a>)(<a class="el" href="struct_gps_xtra_callbacks.html">GpsXtraCallbacks</a> *callbacks) </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Opens the XTRA interface and provides the callback routines to the implemenation of this interface.
<p>
</div>
</div><p>
<a class="anchor" name="2b1962c8a5a2751702937cf469dc7435"></a><!-- doxytag: member="GpsXtraInterface::inject_xtra_data" ref="2b1962c8a5a2751702937cf469dc7435" args=")(char *data, int length)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int(* <a class="el" href="struct_gps_xtra_interface.html#2b1962c8a5a2751702937cf469dc7435">GpsXtraInterface::inject_xtra_data</a>)(char *data, int length) </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Injects XTRA data into the GPS.
<p>
</div>
</div><p>
<hr>The documentation for this struct was generated from the following file:<ul>
<li><a class="el" href="gps_8h-source.html">gps.h</a></ul>
</div>
</body>
</html>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 35 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 706 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.5 KiB

View File

@@ -1,102 +0,0 @@
/* tabs styles, based on http://www.alistapart.com/articles/slidingdoors */
DIV.tabs
{
float : left;
width : 100%;
background : url("tab_b.gif") repeat-x bottom;
margin-bottom : 4px;
}
DIV.tabs UL
{
margin : 0px;
padding-left : 10px;
list-style : none;
}
DIV.tabs LI, DIV.tabs FORM
{
display : inline;
margin : 0px;
padding : 0px;
}
DIV.tabs FORM
{
float : right;
}
DIV.tabs A
{
float : left;
background : url("tab_r.gif") no-repeat right top;
border-bottom : 1px solid #84B0C7;
font-size : x-small;
font-weight : bold;
text-decoration : none;
}
DIV.tabs A:hover
{
background-position: 100% -150px;
}
DIV.tabs A:link, DIV.tabs A:visited,
DIV.tabs A:active, DIV.tabs A:hover
{
color: #1A419D;
}
DIV.tabs SPAN
{
float : left;
display : block;
background : url("tab_l.gif") no-repeat left top;
padding : 5px 9px;
white-space : nowrap;
}
DIV.tabs INPUT
{
float : right;
display : inline;
font-size : 1em;
}
DIV.tabs TD
{
font-size : x-small;
font-weight : bold;
text-decoration : none;
}
/* Commented Backslash Hack hides rule from IE5-Mac \*/
DIV.tabs SPAN {float : none;}
/* End IE5-Mac hack */
DIV.tabs A:hover SPAN
{
background-position: 0% -150px;
}
DIV.tabs LI.current A
{
background-position: 100% -150px;
border-width : 0px;
}
DIV.tabs LI.current SPAN
{
background-position: 0% -150px;
padding-bottom : 6px;
}
DIV.navpath
{
background : none;
border : none;
border-bottom : 1px solid #84B0C7;
}

View File

@@ -1,200 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Doxygen-Generated Content</title>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
.navigation {
display: none;
}
-->
</style>
</head>
<body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li class="current"><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
</div>
<h1>wifi.h</h1><a href="wifi_8h.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="comment">/*</span>
<a name="l00002"></a>00002 <span class="comment"> * Copyright (C) 2008 The Android Open Source Project</span>
<a name="l00003"></a>00003 <span class="comment"> *</span>
<a name="l00004"></a>00004 <span class="comment"> * Licensed under the Apache License, Version 2.0 (the "License");</span>
<a name="l00005"></a>00005 <span class="comment"> * you may not use this file except in compliance with the License.</span>
<a name="l00006"></a>00006 <span class="comment"> * You may obtain a copy of the License at</span>
<a name="l00007"></a>00007 <span class="comment"> *</span>
<a name="l00008"></a>00008 <span class="comment"> * http://www.apache.org/licenses/LICENSE-2.0</span>
<a name="l00009"></a>00009 <span class="comment"> *</span>
<a name="l00010"></a>00010 <span class="comment"> * Unless required by applicable law or agreed to in writing, software</span>
<a name="l00011"></a>00011 <span class="comment"> * distributed under the License is distributed on an "AS IS" BASIS,</span>
<a name="l00012"></a>00012 <span class="comment"> * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.</span>
<a name="l00013"></a>00013 <span class="comment"> * See the License for the specific language governing permissions and</span>
<a name="l00014"></a>00014 <span class="comment"> * limitations under the License.</span>
<a name="l00015"></a>00015 <span class="comment"> */</span>
<a name="l00016"></a>00016
<a name="l00017"></a>00017 <span class="preprocessor">#ifndef _WIFI_H</span>
<a name="l00018"></a>00018 <span class="preprocessor"></span><span class="preprocessor">#define _WIFI_H</span>
<a name="l00019"></a>00019 <span class="preprocessor"></span>
<a name="l00020"></a>00020 <span class="preprocessor">#if __cplusplus</span>
<a name="l00021"></a>00021 <span class="preprocessor"></span><span class="keyword">extern</span> <span class="stringliteral">"C"</span> {
<a name="l00022"></a>00022 <span class="preprocessor">#endif</span>
<a name="l00023"></a>00023 <span class="preprocessor"></span><span class="comment"></span>
<a name="l00024"></a>00024 <span class="comment">/**</span>
<a name="l00025"></a>00025 <span class="comment"> * Load the Wi-Fi driver.</span>
<a name="l00026"></a>00026 <span class="comment"> *</span>
<a name="l00027"></a>00027 <span class="comment"> * @return 0 on success, &lt; 0 on failure.</span>
<a name="l00028"></a>00028 <span class="comment"> */</span>
<a name="l00029"></a>00029 <span class="keywordtype">int</span> <a class="code" href="wifi_8h.html#ef0be2b5d0603acb8e0ab99051969bb7" title="Load the Wi-Fi driver.">wifi_load_driver</a>();
<a name="l00030"></a>00030 <span class="comment"></span>
<a name="l00031"></a>00031 <span class="comment">/**</span>
<a name="l00032"></a>00032 <span class="comment"> * Unload the Wi-Fi driver.</span>
<a name="l00033"></a>00033 <span class="comment"> *</span>
<a name="l00034"></a>00034 <span class="comment"> * @return 0 on success, &lt; 0 on failure.</span>
<a name="l00035"></a>00035 <span class="comment"> */</span>
<a name="l00036"></a>00036 <span class="keywordtype">int</span> <a class="code" href="wifi_8h.html#a0c054da650a0162e40f327eb05679cb" title="Unload the Wi-Fi driver.">wifi_unload_driver</a>();
<a name="l00037"></a>00037 <span class="comment"></span>
<a name="l00038"></a>00038 <span class="comment">/**</span>
<a name="l00039"></a>00039 <span class="comment"> * Start supplicant.</span>
<a name="l00040"></a>00040 <span class="comment"> *</span>
<a name="l00041"></a>00041 <span class="comment"> * @return 0 on success, &lt; 0 on failure.</span>
<a name="l00042"></a>00042 <span class="comment"> */</span>
<a name="l00043"></a>00043 <span class="keywordtype">int</span> <a class="code" href="wifi_8h.html#3372e235a7899484912d7f85887e8a47" title="Start supplicant.">wifi_start_supplicant</a>();
<a name="l00044"></a>00044 <span class="comment"></span>
<a name="l00045"></a>00045 <span class="comment">/**</span>
<a name="l00046"></a>00046 <span class="comment"> * Stop supplicant.</span>
<a name="l00047"></a>00047 <span class="comment"> *</span>
<a name="l00048"></a>00048 <span class="comment"> * @return 0 on success, &lt; 0 on failure.</span>
<a name="l00049"></a>00049 <span class="comment"> */</span>
<a name="l00050"></a>00050 <span class="keywordtype">int</span> <a class="code" href="wifi_8h.html#08b97e58f2909489f1f3d59fb31f2c19" title="Stop supplicant.">wifi_stop_supplicant</a>();
<a name="l00051"></a>00051 <span class="comment"></span>
<a name="l00052"></a>00052 <span class="comment">/**</span>
<a name="l00053"></a>00053 <span class="comment"> * Open a connection to supplicant.</span>
<a name="l00054"></a>00054 <span class="comment"> *</span>
<a name="l00055"></a>00055 <span class="comment"> * @return 0 on success, &lt; 0 on failure.</span>
<a name="l00056"></a>00056 <span class="comment"> */</span>
<a name="l00057"></a>00057 <span class="keywordtype">int</span> <a class="code" href="wifi_8h.html#d81473c3f314ba581e88bb9f1ae37904" title="Open a connection to supplicant.">wifi_connect_to_supplicant</a>();
<a name="l00058"></a>00058 <span class="comment"></span>
<a name="l00059"></a>00059 <span class="comment">/**</span>
<a name="l00060"></a>00060 <span class="comment"> * Close connection supplicant.</span>
<a name="l00061"></a>00061 <span class="comment"> *</span>
<a name="l00062"></a>00062 <span class="comment"> * @return 0 on success, &lt; 0 on failure.</span>
<a name="l00063"></a>00063 <span class="comment"> */</span>
<a name="l00064"></a>00064 <span class="keywordtype">void</span> <a class="code" href="wifi_8h.html#a3f8c99b26cfd95e90012cae63ec4826" title="Close connection supplicant.">wifi_close_supplicant_connection</a>();
<a name="l00065"></a>00065 <span class="comment"></span>
<a name="l00066"></a>00066 <span class="comment">/**</span>
<a name="l00067"></a>00067 <span class="comment"> * wifi_wait_for_event() performs a blocking call to </span>
<a name="l00068"></a>00068 <span class="comment"> * get a Wi-Fi event and returns a string representing </span>
<a name="l00069"></a>00069 <span class="comment"> * a Wi-Fi event when it occurs.</span>
<a name="l00070"></a>00070 <span class="comment"> *</span>
<a name="l00071"></a>00071 <span class="comment"> * @param buf is the buffer that receives the event</span>
<a name="l00072"></a>00072 <span class="comment"> * @param len is the maximum length of the buffer</span>
<a name="l00073"></a>00073 <span class="comment"> *</span>
<a name="l00074"></a>00074 <span class="comment"> * @returns number of bytes in buffer, 0 if no</span>
<a name="l00075"></a>00075 <span class="comment"> * event (for instance, no connection), and less than 0</span>
<a name="l00076"></a>00076 <span class="comment"> * if there is an error.</span>
<a name="l00077"></a>00077 <span class="comment"> */</span>
<a name="l00078"></a>00078 <span class="keywordtype">int</span> <a class="code" href="wifi_8h.html#656495e1beea1e39a144cdff776cdb96" title="wifi_wait_for_event() performs a blocking call to get a Wi-Fi event and returns a...">wifi_wait_for_event</a>(<span class="keywordtype">char</span> *buf, <span class="keywordtype">size_t</span> len);
<a name="l00079"></a>00079 <span class="comment"></span>
<a name="l00080"></a>00080 <span class="comment">/**</span>
<a name="l00081"></a>00081 <span class="comment"> * wifi_command() issues a command to the Wi-Fi driver.</span>
<a name="l00082"></a>00082 <span class="comment"> *</span>
<a name="l00083"></a>00083 <span class="comment"> * Android extends the standard commands listed at </span>
<a name="l00084"></a>00084 <span class="comment"> * /link http://hostap.epitest.fi/wpa_supplicant/devel/ctrl_iface_page.html </span>
<a name="l00085"></a>00085 <span class="comment"> * to include support for sending commands to the driver:</span>
<a name="l00086"></a>00086 <span class="comment"> *</span>
<a name="l00087"></a>00087 <span class="comment"> * &lt;table border="2" cellspacing="2" cellpadding="2"&gt;</span>
<a name="l00088"></a>00088 <span class="comment"> * &lt;tr&gt;</span>
<a name="l00089"></a>00089 <span class="comment"> * &lt;td&gt;&lt;strong&gt;Command / Command summary&lt;/strong&gt;&lt;/td&gt;</span>
<a name="l00090"></a>00090 <span class="comment"> * &lt;td&gt;&lt;strong&gt;Form of Response&lt;/strong&gt;&lt;/td&gt;</span>
<a name="l00091"></a>00091 <span class="comment"> * &lt;td&gt;&lt;strong&gt;Processing&lt;/strong&gt;&lt;/td&gt;</span>
<a name="l00092"></a>00092 <span class="comment"> * &lt;/tr&gt;</span>
<a name="l00093"></a>00093 <span class="comment"> * &lt;tr&gt;</span>
<a name="l00094"></a>00094 <span class="comment"> * &lt;td&gt;DRIVER START&lt;BR&gt;&amp;nbsp;&amp;nbsp;Turn on Wi-Fi Hardware&lt;/td&gt;</span>
<a name="l00095"></a>00095 <span class="comment"> * &lt;td&gt;OK if successful&lt;/td&gt;</span>
<a name="l00096"></a>00096 <span class="comment"> * &lt;td&gt;OK ? true : false&lt;/td&gt;</span>
<a name="l00097"></a>00097 <span class="comment"> * &lt;/tr&gt;</span>
<a name="l00098"></a>00098 <span class="comment"> * &lt;tr&gt;</span>
<a name="l00099"></a>00099 <span class="comment"> * &lt;td&gt;DRIVER STOP&lt;BR&gt;&amp;nbsp;&amp;nbsp;Turn off Wi-Fi hardware&lt;/td&gt;</span>
<a name="l00100"></a>00100 <span class="comment"> * &lt;td&gt;OK if successful&lt;/td&gt;</span>
<a name="l00101"></a>00101 <span class="comment"> * &lt;td&gt;OK ? true : false&lt;/td&gt;</span>
<a name="l00102"></a>00102 <span class="comment"> * &lt;/tr&gt;</span>
<a name="l00103"></a>00103 <span class="comment"> * &lt;tr&gt;</span>
<a name="l00104"></a>00104 <span class="comment"> * &lt;td&gt;DRIVER RSSI&lt;BR&gt;&amp;nbsp;&amp;nbsp;Return received signal strength indicator in -db for current AP&lt;/td&gt;</span>
<a name="l00105"></a>00105 <span class="comment"> * &lt;td&gt;&amp;lt;ssid&amp;gt; Rssi xx&lt;/td&gt;</span>
<a name="l00106"></a>00106 <span class="comment"> * &lt;td&gt;%*s %*s %d", &amp;rssi&lt;/td&gt;</span>
<a name="l00107"></a>00107 <span class="comment"> * &lt;/tr&gt;</span>
<a name="l00108"></a>00108 <span class="comment"> * &lt;tr&gt;</span>
<a name="l00109"></a>00109 <span class="comment"> * &lt;td&gt;DRIVER LINKSPEED&lt;BR&gt;&amp;nbsp;&amp;nbsp;Return link speed in MBPS&lt;/td&gt;</span>
<a name="l00110"></a>00110 <span class="comment"> * &lt;td&gt;LinkSpeed xx&lt;/td&gt;</span>
<a name="l00111"></a>00111 <span class="comment"> * &lt;td&gt;%*s %d", &amp;linkspd&lt;/td&gt;</span>
<a name="l00112"></a>00112 <span class="comment"> * &lt;/tr&gt;</span>
<a name="l00113"></a>00113 <span class="comment"> * &lt;tr&gt;</span>
<a name="l00114"></a>00114 <span class="comment"> * &lt;td&gt;DRIVER MACADDR&lt;BR&gt;&amp;nbsp;&amp;nbsp;Return mac address of the station&lt;/td&gt;</span>
<a name="l00115"></a>00115 <span class="comment"> * &lt;td&gt;Macaddr = xx.xx.xx.xx.xx.xx&lt;/td&gt;</span>
<a name="l00116"></a>00116 <span class="comment"> * &lt;td&gt;"%*s = %s", &amp;macadr&lt;/td&gt;</span>
<a name="l00117"></a>00117 <span class="comment"> * &lt;/tr&gt;</span>
<a name="l00118"></a>00118 <span class="comment"> * &lt;tr&gt;</span>
<a name="l00119"></a>00119 <span class="comment"> * &lt;td&gt;DRIVER SCAN-ACTIVE&lt;BR&gt;&amp;nbsp;&amp;nbsp;Set scan type to active&lt;/td&gt;</span>
<a name="l00120"></a>00120 <span class="comment"> * &lt;td&gt;"OK" if successful&lt;/td&gt;</span>
<a name="l00121"></a>00121 <span class="comment"> * &lt;td&gt;"OK" ? true : false&lt;/td&gt;</span>
<a name="l00122"></a>00122 <span class="comment"> * &lt;/tr&gt;</span>
<a name="l00123"></a>00123 <span class="comment"> * &lt;tr&gt;</span>
<a name="l00124"></a>00124 <span class="comment"> * &lt;td&gt;DRIVER SCAN-PASSIVE&lt;BR&gt;&amp;nbsp;&amp;nbsp;Set scan type to passive&lt;/td&gt;</span>
<a name="l00125"></a>00125 <span class="comment"> * &lt;td&gt;"OK" if successful&lt;/td&gt;</span>
<a name="l00126"></a>00126 <span class="comment"> * &lt;td&gt;"OK" ? true : false&lt;/td&gt;</span>
<a name="l00127"></a>00127 <span class="comment"> * &lt;/tr&gt;</span>
<a name="l00128"></a>00128 <span class="comment"> * &lt;/table&gt;</span>
<a name="l00129"></a>00129 <span class="comment"> *</span>
<a name="l00130"></a>00130 <span class="comment"> * See libs/android_runtime/android_net_wifi_Wifi.cpp for more information</span>
<a name="l00131"></a>00131 <span class="comment"> * describing how these and other commands are invoked.</span>
<a name="l00132"></a>00132 <span class="comment"> *</span>
<a name="l00133"></a>00133 <span class="comment"> * @param command is the string command</span>
<a name="l00134"></a>00134 <span class="comment"> * @param reply is a buffer to receive a reply string</span>
<a name="l00135"></a>00135 <span class="comment"> * @param reply_len on entry, this is the maximum length of</span>
<a name="l00136"></a>00136 <span class="comment"> * the reply buffer. On exit, the number of</span>
<a name="l00137"></a>00137 <span class="comment"> * bytes in the reply buffer.</span>
<a name="l00138"></a>00138 <span class="comment"> *</span>
<a name="l00139"></a>00139 <span class="comment"> * @return 0 if successful, &lt; 0 if an error.</span>
<a name="l00140"></a>00140 <span class="comment"> */</span>
<a name="l00141"></a>00141 <span class="keywordtype">int</span> <a class="code" href="wifi_8h.html#b84f92e035b7bc6a5d669b3738c93e32" title="wifi_command() issues a command to the Wi-Fi driver.">wifi_command</a>(<span class="keyword">const</span> <span class="keywordtype">char</span> *command, <span class="keywordtype">char</span> *reply, <span class="keywordtype">size_t</span> *reply_len);
<a name="l00142"></a>00142 <span class="comment"></span>
<a name="l00143"></a>00143 <span class="comment">/**</span>
<a name="l00144"></a>00144 <span class="comment"> * do_dhcp_request() issues a dhcp request and returns the acquired</span>
<a name="l00145"></a>00145 <span class="comment"> * information. </span>
<a name="l00146"></a>00146 <span class="comment"> * </span>
<a name="l00147"></a>00147 <span class="comment"> * All IPV4 addresses/mask are in network byte order.</span>
<a name="l00148"></a>00148 <span class="comment"> *</span>
<a name="l00149"></a>00149 <span class="comment"> * @param ipaddr return the assigned IPV4 address</span>
<a name="l00150"></a>00150 <span class="comment"> * @param gateway return the gateway being used</span>
<a name="l00151"></a>00151 <span class="comment"> * @param mask return the IPV4 mask</span>
<a name="l00152"></a>00152 <span class="comment"> * @param dns1 return the IPV4 address of a DNS server</span>
<a name="l00153"></a>00153 <span class="comment"> * @param dns2 return the IPV4 address of a DNS server</span>
<a name="l00154"></a>00154 <span class="comment"> * @param server return the IPV4 address of DHCP server</span>
<a name="l00155"></a>00155 <span class="comment"> * @param lease return the length of lease in seconds.</span>
<a name="l00156"></a>00156 <span class="comment"> *</span>
<a name="l00157"></a>00157 <span class="comment"> * @return 0 if successful, &lt; 0 if error.</span>
<a name="l00158"></a>00158 <span class="comment"> */</span>
<a name="l00159"></a>00159 <span class="keywordtype">int</span> <a class="code" href="wifi_8h.html#c6876a5403aaeee922d000043a47b25a" title="do_dhcp_request() issues a dhcp request and returns the acquired information.">do_dhcp_request</a>(<span class="keywordtype">int</span> *ipaddr, <span class="keywordtype">int</span> *gateway, <span class="keywordtype">int</span> *mask,
<a name="l00160"></a>00160 <span class="keywordtype">int</span> *dns1, <span class="keywordtype">int</span> *dns2, <span class="keywordtype">int</span> *server, <span class="keywordtype">int</span> *lease);
<a name="l00161"></a>00161 <span class="comment"></span>
<a name="l00162"></a>00162 <span class="comment">/**</span>
<a name="l00163"></a>00163 <span class="comment"> * Return the error string of the last do_dhcp_request().</span>
<a name="l00164"></a>00164 <span class="comment"> */</span>
<a name="l00165"></a>00165 <span class="keyword">const</span> <span class="keywordtype">char</span> *<a class="code" href="wifi_8h.html#8f25ea8ec313efb45affe65fd7c108ee" title="Return the error string of the last do_dhcp_request().">get_dhcp_error_string</a>();
<a name="l00166"></a>00166
<a name="l00167"></a>00167 <span class="preprocessor">#if __cplusplus</span>
<a name="l00168"></a>00168 <span class="preprocessor"></span>}; <span class="comment">// extern "C"</span>
<a name="l00169"></a>00169 <span class="preprocessor">#endif</span>
<a name="l00170"></a>00170 <span class="preprocessor"></span>
<a name="l00171"></a>00171 <span class="preprocessor">#endif // _WIFI_H</span>
</pre></div></div>
</body>
</html>

View File

@@ -1,405 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Doxygen-Generated Content</title>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
.navigation {
display: none;
}
-->
</style>
</head>
<body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li class="current"><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
</div>
<div class="contents">
<h1>wifi.h File Reference</h1>
<p>
<a href="wifi_8h-source.html">Go to the source code of this file.</a><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="wifi_8h.html#ef0be2b5d0603acb8e0ab99051969bb7">wifi_load_driver</a> ()</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Load the Wi-Fi driver. <a href="#ef0be2b5d0603acb8e0ab99051969bb7"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="wifi_8h.html#a0c054da650a0162e40f327eb05679cb">wifi_unload_driver</a> ()</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Unload the Wi-Fi driver. <a href="#a0c054da650a0162e40f327eb05679cb"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="wifi_8h.html#3372e235a7899484912d7f85887e8a47">wifi_start_supplicant</a> ()</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Start supplicant. <a href="#3372e235a7899484912d7f85887e8a47"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="wifi_8h.html#08b97e58f2909489f1f3d59fb31f2c19">wifi_stop_supplicant</a> ()</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Stop supplicant. <a href="#08b97e58f2909489f1f3d59fb31f2c19"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="wifi_8h.html#d81473c3f314ba581e88bb9f1ae37904">wifi_connect_to_supplicant</a> ()</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Open a connection to supplicant. <a href="#d81473c3f314ba581e88bb9f1ae37904"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="wifi_8h.html#a3f8c99b26cfd95e90012cae63ec4826">wifi_close_supplicant_connection</a> ()</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Close connection supplicant. <a href="#a3f8c99b26cfd95e90012cae63ec4826"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="wifi_8h.html#656495e1beea1e39a144cdff776cdb96">wifi_wait_for_event</a> (char *buf, size_t len)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight"><a class="el" href="wifi_8h.html#656495e1beea1e39a144cdff776cdb96" title="wifi_wait_for_event() performs a blocking call to get a Wi-Fi event and returns a...">wifi_wait_for_event()</a> performs a blocking call to get a Wi-Fi event and returns a string representing a Wi-Fi event when it occurs. <a href="#656495e1beea1e39a144cdff776cdb96"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="wifi_8h.html#b84f92e035b7bc6a5d669b3738c93e32">wifi_command</a> (const char *command, char *reply, size_t *reply_len)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight"><a class="el" href="wifi_8h.html#b84f92e035b7bc6a5d669b3738c93e32" title="wifi_command() issues a command to the Wi-Fi driver.">wifi_command()</a> issues a command to the Wi-Fi driver. <a href="#b84f92e035b7bc6a5d669b3738c93e32"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="wifi_8h.html#c6876a5403aaeee922d000043a47b25a">do_dhcp_request</a> (int *ipaddr, int *gateway, int *mask, int *dns1, int *dns2, int *server, int *lease)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight"><a class="el" href="wifi_8h.html#c6876a5403aaeee922d000043a47b25a" title="do_dhcp_request() issues a dhcp request and returns the acquired information.">do_dhcp_request()</a> issues a dhcp request and returns the acquired information. <a href="#c6876a5403aaeee922d000043a47b25a"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">const char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="wifi_8h.html#8f25ea8ec313efb45affe65fd7c108ee">get_dhcp_error_string</a> ()</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Return the error string of the last <a class="el" href="wifi_8h.html#c6876a5403aaeee922d000043a47b25a" title="do_dhcp_request() issues a dhcp request and returns the acquired information.">do_dhcp_request()</a>. <a href="#8f25ea8ec313efb45affe65fd7c108ee"></a><br></td></tr>
</table>
<hr><h2>Function Documentation</h2>
<a class="anchor" name="c6876a5403aaeee922d000043a47b25a"></a><!-- doxytag: member="wifi.h::do_dhcp_request" ref="c6876a5403aaeee922d000043a47b25a" args="(int *ipaddr, int *gateway, int *mask, int *dns1, int *dns2, int *server, int *lease)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int do_dhcp_request </td>
<td>(</td>
<td class="paramtype">int *&nbsp;</td>
<td class="paramname"> <em>ipaddr</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int *&nbsp;</td>
<td class="paramname"> <em>gateway</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int *&nbsp;</td>
<td class="paramname"> <em>mask</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int *&nbsp;</td>
<td class="paramname"> <em>dns1</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int *&nbsp;</td>
<td class="paramname"> <em>dns2</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int *&nbsp;</td>
<td class="paramname"> <em>server</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int *&nbsp;</td>
<td class="paramname"> <em>lease</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
<a class="el" href="wifi_8h.html#c6876a5403aaeee922d000043a47b25a" title="do_dhcp_request() issues a dhcp request and returns the acquired information.">do_dhcp_request()</a> issues a dhcp request and returns the acquired information.
<p>
All IPV4 addresses/mask are in network byte order.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>ipaddr</em>&nbsp;</td><td>return the assigned IPV4 address </td></tr>
<tr><td valign="top"></td><td valign="top"><em>gateway</em>&nbsp;</td><td>return the gateway being used </td></tr>
<tr><td valign="top"></td><td valign="top"><em>mask</em>&nbsp;</td><td>return the IPV4 mask </td></tr>
<tr><td valign="top"></td><td valign="top"><em>dns1</em>&nbsp;</td><td>return the IPV4 address of a DNS server </td></tr>
<tr><td valign="top"></td><td valign="top"><em>dns2</em>&nbsp;</td><td>return the IPV4 address of a DNS server </td></tr>
<tr><td valign="top"></td><td valign="top"><em>server</em>&nbsp;</td><td>return the IPV4 address of DHCP server </td></tr>
<tr><td valign="top"></td><td valign="top"><em>lease</em>&nbsp;</td><td>return the length of lease in seconds.</td></tr>
</table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>0 if successful, &lt; 0 if error. </dd></dl>
</div>
</div><p>
<a class="anchor" name="8f25ea8ec313efb45affe65fd7c108ee"></a><!-- doxytag: member="wifi.h::get_dhcp_error_string" ref="8f25ea8ec313efb45affe65fd7c108ee" args="()" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">const char* get_dhcp_error_string </td>
<td>(</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Return the error string of the last <a class="el" href="wifi_8h.html#c6876a5403aaeee922d000043a47b25a" title="do_dhcp_request() issues a dhcp request and returns the acquired information.">do_dhcp_request()</a>.
<p>
</div>
</div><p>
<a class="anchor" name="a3f8c99b26cfd95e90012cae63ec4826"></a><!-- doxytag: member="wifi.h::wifi_close_supplicant_connection" ref="a3f8c99b26cfd95e90012cae63ec4826" args="()" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void wifi_close_supplicant_connection </td>
<td>(</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Close connection supplicant.
<p>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>0 on success, &lt; 0 on failure. </dd></dl>
</div>
</div><p>
<a class="anchor" name="b84f92e035b7bc6a5d669b3738c93e32"></a><!-- doxytag: member="wifi.h::wifi_command" ref="b84f92e035b7bc6a5d669b3738c93e32" args="(const char *command, char *reply, size_t *reply_len)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int wifi_command </td>
<td>(</td>
<td class="paramtype">const char *&nbsp;</td>
<td class="paramname"> <em>command</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">char *&nbsp;</td>
<td class="paramname"> <em>reply</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">size_t *&nbsp;</td>
<td class="paramname"> <em>reply_len</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
<a class="el" href="wifi_8h.html#b84f92e035b7bc6a5d669b3738c93e32" title="wifi_command() issues a command to the Wi-Fi driver.">wifi_command()</a> issues a command to the Wi-Fi driver.
<p>
Android extends the standard commands listed at /link <a href="http://hostap.epitest.fi/wpa_supplicant/devel/ctrl_iface_page.html">http://hostap.epitest.fi/wpa_supplicant/devel/ctrl_iface_page.html</a> to include support for sending commands to the driver:<p>
<table border="2" cellspacing="2" cellpadding="2">
<tr>
<td><b>Command / Command summary</b> </td><td><b>Form of Response</b> </td><td><b>Processing</b> </td></tr>
<tr>
<td>DRIVER START<br>
&nbsp;&nbsp;Turn on Wi-Fi Hardware </td><td>OK if successful </td><td>OK ? true : false </td></tr>
<tr>
<td>DRIVER STOP<br>
&nbsp;&nbsp;Turn off Wi-Fi hardware </td><td>OK if successful </td><td>OK ? true : false </td></tr>
<tr>
<td>DRIVER RSSI<br>
&nbsp;&nbsp;Return received signal strength indicator in -db for current AP </td><td>&lt;ssid&gt; Rssi xx </td><td>*s *s d", &amp;rssi </td></tr>
<tr>
<td>DRIVER LINKSPEED<br>
&nbsp;&nbsp;Return link speed in MBPS </td><td>LinkSpeed xx </td><td>*s d", &amp;linkspd </td></tr>
<tr>
<td>DRIVER MACADDR<br>
&nbsp;&nbsp;Return mac address of the station </td><td>Macaddr = xx.xx.xx.xx.xx.xx </td><td>"%*s = %s", &amp;macadr </td></tr>
<tr>
<td>DRIVER SCAN-ACTIVE<br>
&nbsp;&nbsp;Set scan type to active </td><td>"OK" if successful </td><td>"OK" ? true : false </td></tr>
<tr>
<td>DRIVER SCAN-PASSIVE<br>
&nbsp;&nbsp;Set scan type to passive </td><td>"OK" if successful </td><td>"OK" ? true : false </td></tr>
</table>
<p>
See libs/android_runtime/android_net_wifi_Wifi.cpp for more information describing how these and other commands are invoked.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>command</em>&nbsp;</td><td>is the string command </td></tr>
<tr><td valign="top"></td><td valign="top"><em>reply</em>&nbsp;</td><td>is a buffer to receive a reply string </td></tr>
<tr><td valign="top"></td><td valign="top"><em>reply_len</em>&nbsp;</td><td>on entry, this is the maximum length of the reply buffer. On exit, the number of bytes in the reply buffer.</td></tr>
</table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>0 if successful, &lt; 0 if an error. </dd></dl>
</div>
</div><p>
<a class="anchor" name="d81473c3f314ba581e88bb9f1ae37904"></a><!-- doxytag: member="wifi.h::wifi_connect_to_supplicant" ref="d81473c3f314ba581e88bb9f1ae37904" args="()" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int wifi_connect_to_supplicant </td>
<td>(</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Open a connection to supplicant.
<p>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>0 on success, &lt; 0 on failure. </dd></dl>
</div>
</div><p>
<a class="anchor" name="ef0be2b5d0603acb8e0ab99051969bb7"></a><!-- doxytag: member="wifi.h::wifi_load_driver" ref="ef0be2b5d0603acb8e0ab99051969bb7" args="()" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int wifi_load_driver </td>
<td>(</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Load the Wi-Fi driver.
<p>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>0 on success, &lt; 0 on failure. </dd></dl>
</div>
</div><p>
<a class="anchor" name="3372e235a7899484912d7f85887e8a47"></a><!-- doxytag: member="wifi.h::wifi_start_supplicant" ref="3372e235a7899484912d7f85887e8a47" args="()" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int wifi_start_supplicant </td>
<td>(</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Start supplicant.
<p>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>0 on success, &lt; 0 on failure. </dd></dl>
</div>
</div><p>
<a class="anchor" name="08b97e58f2909489f1f3d59fb31f2c19"></a><!-- doxytag: member="wifi.h::wifi_stop_supplicant" ref="08b97e58f2909489f1f3d59fb31f2c19" args="()" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int wifi_stop_supplicant </td>
<td>(</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Stop supplicant.
<p>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>0 on success, &lt; 0 on failure. </dd></dl>
</div>
</div><p>
<a class="anchor" name="a0c054da650a0162e40f327eb05679cb"></a><!-- doxytag: member="wifi.h::wifi_unload_driver" ref="a0c054da650a0162e40f327eb05679cb" args="()" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int wifi_unload_driver </td>
<td>(</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Unload the Wi-Fi driver.
<p>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>0 on success, &lt; 0 on failure. </dd></dl>
</div>
</div><p>
<a class="anchor" name="656495e1beea1e39a144cdff776cdb96"></a><!-- doxytag: member="wifi.h::wifi_wait_for_event" ref="656495e1beea1e39a144cdff776cdb96" args="(char *buf, size_t len)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int wifi_wait_for_event </td>
<td>(</td>
<td class="paramtype">char *&nbsp;</td>
<td class="paramname"> <em>buf</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">size_t&nbsp;</td>
<td class="paramname"> <em>len</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
<a class="el" href="wifi_8h.html#656495e1beea1e39a144cdff776cdb96" title="wifi_wait_for_event() performs a blocking call to get a Wi-Fi event and returns a...">wifi_wait_for_event()</a> performs a blocking call to get a Wi-Fi event and returns a string representing a Wi-Fi event when it occurs.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>buf</em>&nbsp;</td><td>is the buffer that receives the event </td></tr>
<tr><td valign="top"></td><td valign="top"><em>len</em>&nbsp;</td><td>is the maximum length of the buffer</td></tr>
</table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>number of bytes in buffer, 0 if no event (for instance, no connection), and less than 0 if there is an error. </dd></dl>
</div>
</div><p>
</div>
</body>
</html>

View File

@@ -0,0 +1,3 @@
/*!
*/

View File

@@ -0,0 +1,5 @@
/*! \mainpage Google Client Location Library (CLL): location Interface
* <p>This documentation is part of Google's Client Location Library (CLL) Getting Started Guide.</p>
* <p>In most cases, this Doxygen-generated content opens in a new window (or tab), so look for this window's parent to return to the Getting Started guide. If you maintained
* the original directory structure when you unzipped the documentation, you may also return to the Getting Started guide by clicking <a href="../cll_getting_started.html">Client Location Library (CLL) Getting Started Guide</a>.</p>
*/

View File

@@ -0,0 +1,50 @@
#---------------------------------------------------------------------------
# Project related configuration options
#---------------------------------------------------------------------------
DOXYFILE_ENCODING = UTF-8
PROJECT_NAME = pdk
PROJECT_NUMBER =
INPUT = sources \
docsfiles
OUTPUT_DIRECTORY = generatedDocs
HTML_HEADER = header.html
HTML_FOOTER = footer.html
# FILL IN PATH TO HEADER BLOB WANTED IN EVERY FILE
# RELATIVE PATH TO WHER ERUNNING DOXYGEN FROM
HTML_STYLESHEET =
# PATH TO STYLE SHEET\
BRIEF_MEMBER_DESC = YES
REPEAT_BRIEF = YES
OPTIMIZE_OUTPUT_FOR_C = YES
ALWAYS_DETAILED_SEC = YES
INLINE_INHERITED_MEMB = NO
FULL_PATH_NAMES = NO
STRIP_FROM_PATH =
STRIP_FROM_INC_PATH =
SHORT_NAMES = NO
JAVADOC_AUTOBRIEF = YES
QT_AUTOBRIEF = NO
MULTILINE_CPP_IS_BRIEF = NO
DETAILS_AT_TOP = NO
INHERIT_DOCS = YES
SEPARATE_MEMBER_PAGES = NO
QUIET = NO
WARNINGS = YES
SOURCE_BROWSER = YES
GENERATE_HTML = YES
ENABLE_PREPROCESSING = NO
# ADDED JULY 08 TO TRY TO FIGURE OUT DOCUMENING C FILES
EXTRACT_ALL = YES
STRIP_CODE_COMMENTS = NO

View File

@@ -0,0 +1,273 @@
# Doxyfile 1.5.6
#---------------------------------------------------------------------------
# Project related configuration options
#---------------------------------------------------------------------------
DOXYFILE_ENCODING = UTF-8
PROJECT_NAME = pdk
PROJECT_NUMBER =
OUTPUT_DIRECTORY =
CREATE_SUBDIRS = NO
OUTPUT_LANGUAGE = English
BRIEF_MEMBER_DESC = YES
REPEAT_BRIEF = YES
ABBREVIATE_BRIEF = "The $name class" \
"The $name widget" \
"The $name file" \
is \
provides \
specifies \
contains \
represents \
a \
an \
the
ALWAYS_DETAILED_SEC = YES
INLINE_INHERITED_MEMB = NO
FULL_PATH_NAMES = NO
STRIP_FROM_PATH =
STRIP_FROM_INC_PATH =
SHORT_NAMES = NO
JAVADOC_AUTOBRIEF = YES
QT_AUTOBRIEF = NO
MULTILINE_CPP_IS_BRIEF = NO
DETAILS_AT_TOP = NO
INHERIT_DOCS = YES
SEPARATE_MEMBER_PAGES = NO
TAB_SIZE = 8
ALIASES =
OPTIMIZE_OUTPUT_FOR_C = NO
OPTIMIZE_OUTPUT_JAVA = NO
OPTIMIZE_FOR_FORTRAN = NO
OPTIMIZE_OUTPUT_VHDL = NO
BUILTIN_STL_SUPPORT = NO
CPP_CLI_SUPPORT = NO
SIP_SUPPORT = NO
IDL_PROPERTY_SUPPORT = YES
DISTRIBUTE_GROUP_DOC = NO
SUBGROUPING = YES
TYPEDEF_HIDES_STRUCT = NO
#---------------------------------------------------------------------------
# Build related configuration options
#---------------------------------------------------------------------------
EXTRACT_ALL = YES
EXTRACT_PRIVATE = NO
EXTRACT_STATIC = NO
EXTRACT_LOCAL_CLASSES = NO
EXTRACT_LOCAL_METHODS = NO
EXTRACT_ANON_NSPACES = YES
HIDE_UNDOC_MEMBERS = NO
HIDE_UNDOC_CLASSES = NO
HIDE_FRIEND_COMPOUNDS = NO
HIDE_IN_BODY_DOCS = NO
INTERNAL_DOCS = NO
CASE_SENSE_NAMES = YES
HIDE_SCOPE_NAMES = NO
SHOW_INCLUDE_FILES = NO
# MIGHT WANT TO TWEAK LEATER
INLINE_INFO = YES
SORT_MEMBER_DOCS = YES
SORT_BRIEF_DOCS = YES
SORT_GROUP_NAMES = NO
SORT_BY_SCOPE_NAME = NO
GENERATE_TODOLIST = NO
GENERATE_TESTLIST = NO
GENERATE_BUGLIST = NO
GENERATE_DEPRECATEDLIST= YES
ENABLED_SECTIONS =
MAX_INITIALIZER_LINES = 30
SHOW_USED_FILES = NO
SHOW_DIRECTORIES = NO
SHOW_FILES = YES
SHOW_NAMESPACES = YES
FILE_VERSION_FILTER =
#---------------------------------------------------------------------------
# configuration options related to warning and progress messages
#---------------------------------------------------------------------------
QUIET = NO
WARNINGS = YES
WARN_IF_UNDOCUMENTED = YES
WARN_IF_DOC_ERROR = YES
WARN_NO_PARAMDOC = NO
WARN_FORMAT = "$file:$line: $text"
WARN_LOGFILE =
#---------------------------------------------------------------------------
# configuration options related to the input files
#---------------------------------------------------------------------------
INPUT =
INPUT_ENCODING = UTF-8
FILE_PATTERNS = *.c \
*.cpp \
*.dox \
*.h \
*.htm \
*.html
RECURSIVE = YES
EXCLUDE =
# ecxlude entire directories or files
EXCLUDE_SYMLINKS = NO
EXCLUDE_PATTERNS =
EXCLUDE_SYMBOLS =
EXAMPLE_PATH =
EXAMPLE_PATTERNS = *
EXAMPLE_RECURSIVE = NO
IMAGE_PATH =
INPUT_FILTER =
FILTER_PATTERNS =
FILTER_SOURCE_FILES = NO
#---------------------------------------------------------------------------
# configuration options related to source browsing
#---------------------------------------------------------------------------
SOURCE_BROWSER = YES
INLINE_SOURCES = NO
STRIP_CODE_COMMENTS = YES
REFERENCED_BY_RELATION = NO
REFERENCES_RELATION = YES
REFERENCES_LINK_SOURCE = NO
USE_HTAGS = NO
VERBATIM_HEADERS = NO
#---------------------------------------------------------------------------
# configuration options related to the alphabetical class index
#---------------------------------------------------------------------------
ALPHABETICAL_INDEX = NO
COLS_IN_ALPHA_INDEX = 1
IGNORE_PREFIX =
#---------------------------------------------------------------------------
# configuration options related to the HTML output
#---------------------------------------------------------------------------
GENERATE_HTML = YES
HTML_OUTPUT = html
HTML_FILE_EXTENSION = .html
HTML_HEADER =
# FILL IN PATH TO HEADER BLOB WANTED IN EVERY FILE
# RELATIVE PATH TO WHER ERUNNING DOXYGEN FROM
HTML_FOOTER =
HTML_STYLESHEET =
# PATH TO STYLE SHEET
HTML_ALIGN_MEMBERS = YES
GENERATE_HTMLHELP = NO
GENERATE_DOCSET = NO
DOCSET_FEEDNAME = "Doxygen generated docs"
DOCSET_BUNDLE_ID = org.doxygen.Project
HTML_DYNAMIC_SECTIONS = NO
CHM_FILE =
HHC_LOCATION =
GENERATE_CHI = NO
CHM_INDEX_ENCODING =
BINARY_TOC = NO
TOC_EXPAND = NO
DISABLE_INDEX = NO
ENUM_VALUES_PER_LINE = 4
GENERATE_TREEVIEW = NONE
TREEVIEW_WIDTH = 250
FORMULA_FONTSIZE = 10
#---------------------------------------------------------------------------
# configuration options related to the LaTeX output
#---------------------------------------------------------------------------
GENERATE_LATEX = NO
LATEX_OUTPUT = latex
LATEX_CMD_NAME = latex
MAKEINDEX_CMD_NAME = makeindex
COMPACT_LATEX = NO
PAPER_TYPE = a4wide
EXTRA_PACKAGES =
LATEX_HEADER =
PDF_HYPERLINKS = YES
USE_PDFLATEX = YES
LATEX_BATCHMODE = NO
LATEX_HIDE_INDICES = NO
#---------------------------------------------------------------------------
# configuration options related to the RTF output
#---------------------------------------------------------------------------
GENERATE_RTF = NO
RTF_OUTPUT = rtf
COMPACT_RTF = NO
RTF_HYPERLINKS = NO
RTF_STYLESHEET_FILE =
RTF_EXTENSIONS_FILE =
#---------------------------------------------------------------------------
# configuration options related to the man page output
#---------------------------------------------------------------------------
GENERATE_MAN = NO
MAN_OUTPUT = man
MAN_EXTENSION = .3
MAN_LINKS = NO
#---------------------------------------------------------------------------
# configuration options related to the XML output
#---------------------------------------------------------------------------
GENERATE_XML = NO
XML_OUTPUT = xml
XML_SCHEMA =
XML_DTD =
XML_PROGRAMLISTING = YES
#---------------------------------------------------------------------------
# configuration options for the AutoGen Definitions output
#---------------------------------------------------------------------------
GENERATE_AUTOGEN_DEF = NO
#---------------------------------------------------------------------------
# configuration options related to the Perl module output
#---------------------------------------------------------------------------
GENERATE_PERLMOD = NO
PERLMOD_LATEX = NO
PERLMOD_PRETTY = YES
PERLMOD_MAKEVAR_PREFIX =
#---------------------------------------------------------------------------
# Configuration options related to the preprocessor
#---------------------------------------------------------------------------
ENABLE_PREPROCESSING = NO
# KEY CONSIDERATION TWEAK BACK AND FORTH. function in an # if/def preprocessor directive. Processor evalutes whether true. Should doxygen follow compiles behavior or document everything?
# usually have optional things that people may want to tweak.
MACRO_EXPANSION = YES
EXPAND_ONLY_PREDEF = YES
SEARCH_INCLUDES = NO
INCLUDE_PATH =
INCLUDE_FILE_PATTERNS =
PREDEFINED =
#to mimic preprocessor behaviors.
EXPAND_AS_DEFINED =
SKIP_FUNCTION_MACROS = YES
#---------------------------------------------------------------------------
# Configuration::additions related to external references
#---------------------------------------------------------------------------
TAGFILES =
GENERATE_TAGFILE =
ALLEXTERNALS = NO
EXTERNAL_GROUPS = NO
PERL_PATH =
#---------------------------------------------------------------------------
# Configuration options related to the dot tool
#---------------------------------------------------------------------------
CLASS_DIAGRAMS = NO
#CHANGE WHEN HAVE DIAGRAMS
MSCGEN_PATH = YES
HIDE_UNDOC_RELATIONS = YES
HAVE_DOT = NO
DOT_FONTNAME = FreeSans
DOT_FONTPATH =
CLASS_GRAPH = YES
COLLABORATION_GRAPH = YES
GROUP_GRAPHS = YES
UML_LOOK = NO
TEMPLATE_RELATIONS = NO
INCLUDE_GRAPH = YES
INCLUDED_BY_GRAPH = YES
CALL_GRAPH = NO
CALLER_GRAPH = NO
GRAPHICAL_HIERARCHY = YES
DIRECTORY_GRAPH = YES
DOT_IMAGE_FORMAT = png
DOT_PATH =
DOTFILE_DIRS =
DOT_GRAPH_MAX_NODES = 50
MAX_DOT_GRAPH_DEPTH = 1000
DOT_TRANSPARENT = YES
DOT_MULTI_TARGETS = NO
GENERATE_LEGEND = YES
DOT_CLEANUP = YES
#---------------------------------------------------------------------------
# Configuration::additions related to the search engine
#---------------------------------------------------------------------------
SEARCHENGINE = NO
@INCLUDE = overrideconfig.conf
# relative to where running doxygen from
# @INCLUDE = $(PROJECTCONF)

View File

@@ -60,7 +60,7 @@ endef
# The JNI-only version is provided for partners that want to create shared # The JNI-only version is provided for partners that want to create shared
# libraries that can be packaged with APK files and called from Java code. # libraries that can be packaged with APK files and called from Java code.
LOCAL_PATH := $(my-dir) LOCAL_PATH := $(call my-dir)
# Source trees for the ndk # Source trees for the ndk
samples_src_dir := $(LOCAL_PATH)/samples samples_src_dir := $(LOCAL_PATH)/samples
@@ -183,9 +183,9 @@ ndk_with_src: $(ndk_with_src_tarfile_zipped)
ndk_jni_with_src: $(ndk_jni_with_src_tarfile_zipped) ndk_jni_with_src: $(ndk_jni_with_src_tarfile_zipped)
# Put the ndk zip files in the distribution directory # Put the ndk zip files in the distribution directory
$(call dist-for-goals,pdk,$(ndk_tarfile_zipped)) $(call dist-for-goals,ndk,$(ndk_tarfile_zipped))
$(call dist-for-goals,pdk,$(ndk_with_src_tarfile_zipped)) $(call dist-for-goals,ndk,$(ndk_with_src_tarfile_zipped))
$(call dist-for-goals,pdk,$(ndk_jni_with_src_tarfile_zipped)) $(call dist-for-goals,ndk,$(ndk_jni_with_src_tarfile_zipped))
# zip up tar files # zip up tar files
%.tar.gz: %.tar %.tar.gz: %.tar

View File

@@ -152,6 +152,15 @@
</intent-filter> </intent-filter>
</activity> </activity>
<!-- Intent Samples -->
<activity android:name=".app.Intents" android:label="@string/activity_intents">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.SAMPLE_CODE" />
</intent-filter>
</activity>
<!-- Service Samples --> <!-- Service Samples -->
<service android:name=".app.LocalService" /> <service android:name=".app.LocalService" />

View File

@@ -0,0 +1,37 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (C) 2008 The Android Open Source Project
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<!-- Demonstrates launching various intents.
See corresponding Java code com.example.android.apis.app.Intents.java. -->
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical" android:padding="4dip"
android:gravity="center_horizontal"
android:layout_width="fill_parent" android:layout_height="fill_parent">
<TextView
android:layout_width="fill_parent" android:layout_height="wrap_content"
android:layout_weight="0"
android:paddingBottom="4dip"
android:text="@string/intents"/>
<Button android:id="@+id/get_music"
android:layout_width="wrap_content" android:layout_height="wrap_content"
android:text="@string/get_music">
<requestFocus />
</Button>
</LinearLayout>

View File

@@ -205,6 +205,14 @@
<string name="activity_themes">Content/Resources/Themes</string> <string name="activity_themes">Content/Resources/Themes</string>
<string name="activity_resources">Content/Resources/Resources</string> <string name="activity_resources">Content/Resources/Resources</string>
<!-- ============================== -->
<!-- app/intents examples strings -->
<!-- ============================== -->
<string name="activity_intents">App/Intents</string>
<string name="intents">Example of launching various Intents.</string>
<string name="get_music">Get Music</string>
<!-- =================================== --> <!-- =================================== -->
<!-- app/notification examples strings --> <!-- app/notification examples strings -->
<!-- =================================== --> <!-- =================================== -->

View File

@@ -1,5 +1,5 @@
/* /*
* Copyright (C) 2008 Google Inc. * Copyright (C) 2008 The Android Open Source Project
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License. * you may not use this file except in compliance with the License.
@@ -29,7 +29,10 @@ import com.example.android.apis.R;
import java.util.ArrayList; import java.util.ArrayList;
public class VoiceRecognition extends Activity { /**
* Sample code that invokes the speech recognition intent API.
*/
public class VoiceRecognition extends Activity implements OnClickListener {
private static final int VOICE_RECOGNITION_REQUEST_CODE = 1234; private static final int VOICE_RECOGNITION_REQUEST_CODE = 1234;
@@ -51,34 +54,41 @@ public class VoiceRecognition extends Activity {
mList = (ListView) findViewById(R.id.list); mList = (ListView) findViewById(R.id.list);
// Attach actions to buttons // Attach actions to buttons
speakButton.setOnClickListener(new OnClickListener() { speakButton.setOnClickListener(this);
public void onClick(View v) {
startVoiceRecognitionActivity();
}
});
} }
void startVoiceRecognitionActivity() { /**
Intent intent = new Intent("android.intent.action.VOICE_RECOGNITION"); * Handle the click on the start recognition button.
this.startActivityForResult(intent, VOICE_RECOGNITION_REQUEST_CODE); */
public void onClick(View v) {
if (v.getId() == R.id.btn_speak) {
startVoiceRecognitionActivity();
}
} }
/**
* Fire an intent to start the speech recognition activity.
*/
private void startVoiceRecognitionActivity() {
//TODO Get these values from constants
Intent intent = new Intent("android.speech.action.RECOGNIZE_SPEECH");
intent.putExtra("language_model", "free_form");
intent.putExtra("prompt", "Speech recognition demo");
startActivityForResult(intent, VOICE_RECOGNITION_REQUEST_CODE);
}
/**
* Handle the results from the recognition activity.
*/
@Override @Override
protected void onActivityResult(int requestCode, int resultCode, Intent data) { protected void onActivityResult(int requestCode, int resultCode, Intent data) {
android.util.Log.d("mike", "************** onActivityResult" + data );
if (requestCode == VOICE_RECOGNITION_REQUEST_CODE && resultCode == RESULT_OK) { if (requestCode == VOICE_RECOGNITION_REQUEST_CODE && resultCode == RESULT_OK) {
ArrayList<String>matches = data.getStringArrayListExtra("queries"); //TODO get the value from a constant
ArrayList<String>matches = data.getStringArrayListExtra("results");
mList.setAdapter(new ArrayAdapter<String>(this, android.R.layout.simple_list_item_1,
android.util.Log.d("mike", "************** onActivityResult" + matches); matches));
mList.setAdapter(new ArrayAdapter<String>(this,
android.R.layout.simple_list_item_1, matches));
} }
super.onActivityResult(requestCode, resultCode, data); super.onActivityResult(requestCode, resultCode, data);
} }
} }

View File

@@ -0,0 +1,47 @@
/*
* Copyright (C) 2008 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package com.example.android.apis.app;
import com.example.android.apis.R;
import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Button;
public class Intents extends Activity {
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.intents);
// Watch for button clicks.
Button button = (Button)findViewById(R.id.get_music);
button.setOnClickListener(mGetMusicListener);
}
private OnClickListener mGetMusicListener = new OnClickListener() {
public void onClick(View v) {
Intent intent = new Intent(Intent.ACTION_GET_CONTENT);
intent.setType("audio/*");
startActivity(Intent.createChooser(intent, "Select music"));
}
};
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.1 KiB

View File

@@ -388,13 +388,13 @@ public class Home extends Activity {
super.onCreateOptionsMenu(menu); super.onCreateOptionsMenu(menu);
menu.add(0, MENU_WALLPAPER_SETTINGS, 0, R.string.menu_wallpaper) menu.add(0, MENU_WALLPAPER_SETTINGS, 0, R.string.menu_wallpaper)
.setIcon(R.drawable.ic_menu_gallery) .setIcon(android.R.drawable.ic_menu_gallery)
.setAlphabeticShortcut('W'); .setAlphabeticShortcut('W');
menu.add(0, MENU_SEARCH, 0, R.string.menu_search) menu.add(0, MENU_SEARCH, 0, R.string.menu_search)
.setIcon(android.R.drawable.ic_search_category_default) .setIcon(android.R.drawable.ic_search_category_default)
.setAlphabeticShortcut(SearchManager.MENU_KEY); .setAlphabeticShortcut(SearchManager.MENU_KEY);
menu.add(0, MENU_SETTINGS, 0, R.string.menu_settings) menu.add(0, MENU_SETTINGS, 0, R.string.menu_settings)
.setIcon(R.drawable.ic_menu_preferences) .setIcon(android.R.drawable.ic_menu_preferences)
.setIntent(new Intent(android.provider.Settings.ACTION_SETTINGS)); .setIntent(new Intent(android.provider.Settings.ACTION_SETTINGS));
return true; return true;

View File

@@ -34,6 +34,23 @@ LOCAL_SRC_FILES := $(call all-java-files-under, java)
include $(BUILD_JAVA_LIBRARY) include $(BUILD_JAVA_LIBRARY)
# ============================================================
include $(CLEAR_VARS)
LOCAL_MODULE := com.example.android.platform_library.xml
LOCAL_MODULE_TAGS := samples
LOCAL_MODULE_CLASS := ETC
# This will install the file in /system/etc/permissions
#
LOCAL_MODULE_PATH := $(TARGET_OUT_ETC)/permissions
LOCAL_SRC_FILES := $(LOCAL_MODULE)
include $(BUILD_PREBUILT)
# ============================================================ # ============================================================
# Also build all of the sub-targets under this one: the library's # Also build all of the sub-targets under this one: the library's

View File

@@ -12,18 +12,14 @@ create a system image that will be delivered on a device which will include
a custom library as shown here. It can not be used to create a third party a custom library as shown here. It can not be used to create a third party
shared library, which is not currently supported in Android. shared library, which is not currently supported in Android.
Note that while this example is almost entirely self-contained -- you can To declare your library to the framework, you must place a file with a .xml
build it and run the client app without any changes to the framework -- there extension in the /system/etc/permissions directory with the following contents:
is one change you must make so that the system will recognize your library:
In frameworks/base/data/etc/permissions.xml is a list of all of the optional
shared libraries available in the system. You will need to add an entry at
the bottom of this file for your own shared library, which looks like this
for our sample code here:
<?xml version="1.0" encoding="utf-8"?>
<permissions>
<library name="com.example.android.platform_library" <library name="com.example.android.platform_library"
file="/system/framework/com.example.android.platform_library.jar"/> file="/system/framework/com.example.android.platform_library.jar"/>
</permissions>
There are three major parts of this example, supplying three distinct There are three major parts of this example, supplying three distinct
build targets and corresponding build outputs: build targets and corresponding build outputs:

View File

@@ -0,0 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<permissions>
<library name="com.example.android.platform_library"
file="/system/framework/com.example.android.platform_library.jar"/>
</permissions>

View File

@@ -21,4 +21,5 @@
<resources> <resources>
<dimen name="key_height">50px</dimen> <dimen name="key_height">50px</dimen>
<dimen name="candidate_font_height">16sp</dimen> <dimen name="candidate_font_height">16sp</dimen>
<dimen name="candidate_vertical_padding">6sp</dimen>
</resources> </resources>

View File

@@ -55,6 +55,7 @@ public class CandidateView extends View {
private int mColorNormal; private int mColorNormal;
private int mColorRecommended; private int mColorRecommended;
private int mColorOther; private int mColorOther;
private int mVerticalPadding;
private Paint mPaint; private Paint mPaint;
private boolean mScrolled; private boolean mScrolled;
private int mTargetScrollX; private int mTargetScrollX;
@@ -86,6 +87,7 @@ public class CandidateView extends View {
mColorNormal = r.getColor(R.color.candidate_normal); mColorNormal = r.getColor(R.color.candidate_normal);
mColorRecommended = r.getColor(R.color.candidate_recommended); mColorRecommended = r.getColor(R.color.candidate_recommended);
mColorOther = r.getColor(R.color.candidate_other); mColorOther = r.getColor(R.color.candidate_other);
mVerticalPadding = r.getDimensionPixelSize(R.dimen.candidate_vertical_padding);
mPaint = new Paint(); mPaint = new Paint();
mPaint.setColor(mColorNormal); mPaint.setColor(mColorNormal);
@@ -139,7 +141,7 @@ public class CandidateView extends View {
// not have a divider below) // not have a divider below)
Rect padding = new Rect(); Rect padding = new Rect();
mSelectionHighlight.getPadding(padding); mSelectionHighlight.getPadding(padding);
final int desiredHeight = ((int)mPaint.getTextSize()) + 1 final int desiredHeight = ((int)mPaint.getTextSize()) + mVerticalPadding
+ padding.top + padding.bottom; + padding.top + padding.bottom;
// Maximum possible width and desired height // Maximum possible width and desired height
@@ -174,7 +176,7 @@ public class CandidateView extends View {
final int scrollX = getScrollX(); final int scrollX = getScrollX();
final boolean scrolled = mScrolled; final boolean scrolled = mScrolled;
final boolean typedWordValid = mTypedWordValid; final boolean typedWordValid = mTypedWordValid;
final int y = (int) (height + mPaint.getTextSize()) / 2; final int y = (int) (((height - mPaint.getTextSize()) / 2) - mPaint.ascent());
for (int i = 0; i < count; i++) { for (int i = 0; i < count; i++) {
String suggestion = mSuggestions.get(i); String suggestion = mSuggestions.get(i);

View File

@@ -20,8 +20,9 @@ import android.content.Context;
import android.inputmethodservice.InputMethodService; import android.inputmethodservice.InputMethodService;
import android.inputmethodservice.Keyboard; import android.inputmethodservice.Keyboard;
import android.inputmethodservice.KeyboardView; import android.inputmethodservice.KeyboardView;
import android.text.TextUtils; import android.text.method.MetaKeyKeyListener;
import android.util.Log; import android.util.Log;
import android.view.KeyCharacterMap;
import android.view.KeyEvent; import android.view.KeyEvent;
import android.view.View; import android.view.View;
import android.view.WindowManager; import android.view.WindowManager;
@@ -48,12 +49,12 @@ public class SoftKeyboard extends InputMethodService
private CompletionInfo[] mCompletions; private CompletionInfo[] mCompletions;
private StringBuilder mComposing = new StringBuilder(); private StringBuilder mComposing = new StringBuilder();
private boolean mPredicting;
private boolean mPredictionOn; private boolean mPredictionOn;
private boolean mCompletionOn; private boolean mCompletionOn;
private int mLastDisplayWidth; private int mLastDisplayWidth;
private boolean mCapsLock; private boolean mCapsLock;
private long mLastShiftTime; private long mLastShiftTime;
private long mMetaState;
private Keyboard mSymbolsKeyboard; private Keyboard mSymbolsKeyboard;
private Keyboard mSymbolsShiftedKeyboard; private Keyboard mSymbolsShiftedKeyboard;
@@ -61,8 +62,6 @@ public class SoftKeyboard extends InputMethodService
private String mWordSeparators; private String mWordSeparators;
private InputConnection mOldConnection;
private void makeKeyboards() { private void makeKeyboards() {
// Configuration change is coming after the keyboard gets recreated. So don't rely on that. // Configuration change is coming after the keyboard gets recreated. So don't rely on that.
// If keyboards have already been made, check if we have a screen width change and // If keyboards have already been made, check if we have a screen width change and
@@ -80,7 +79,6 @@ public class SoftKeyboard extends InputMethodService
@Override public void onCreate() { @Override public void onCreate() {
super.onCreate(); super.onCreate();
//setStatusIcon(R.drawable.ime_qwerty);
makeKeyboards(); makeKeyboards();
mWordSeparators = getResources().getString(R.string.word_separators); mWordSeparators = getResources().getString(R.string.word_separators);
} }
@@ -97,7 +95,6 @@ public class SoftKeyboard extends InputMethodService
@Override @Override
public View onCreateCandidatesView() { public View onCreateCandidatesView() {
makeKeyboards();
mCandidateView = new CandidateView(this); mCandidateView = new CandidateView(this);
mCandidateView.setService(this); mCandidateView.setService(this);
return mCandidateView; return mCandidateView;
@@ -105,33 +102,28 @@ public class SoftKeyboard extends InputMethodService
@Override @Override
public void onStartInputView(EditorInfo attribute, boolean restarting) { public void onStartInputView(EditorInfo attribute, boolean restarting) {
// In landscape mode, this method gets called without the input view being created. mComposing.setLength(0);
if (mInputView == null) { updateCandidates();
return;
} if (!restarting) {
// Clear shift states.
if (mQwertyKeyboard == null) { mMetaState = 0;
makeKeyboards();
}
if (mOldConnection != null) {
commitTyped(mOldConnection);
} }
mPredictionOn = false; mPredictionOn = false;
mCompletionOn = false; mCompletionOn = false;
mCompletions = null; mCompletions = null;
Keyboard keyboard;
switch (attribute.inputType&EditorInfo.TYPE_MASK_CLASS) { switch (attribute.inputType&EditorInfo.TYPE_MASK_CLASS) {
case EditorInfo.TYPE_CLASS_NUMBER: case EditorInfo.TYPE_CLASS_NUMBER:
case EditorInfo.TYPE_CLASS_DATETIME: case EditorInfo.TYPE_CLASS_DATETIME:
mInputView.setKeyboard(mSymbolsKeyboard); keyboard = mSymbolsKeyboard;
break; break;
case EditorInfo.TYPE_CLASS_PHONE: case EditorInfo.TYPE_CLASS_PHONE:
mInputView.setKeyboard(mSymbolsKeyboard); keyboard = mSymbolsKeyboard;
break; break;
default: default:
mInputView.setKeyboard(mQwertyKeyboard); keyboard = mQwertyKeyboard;
//startPrediction();
mPredictionOn = true; mPredictionOn = true;
// Make sure that passwords are not displayed in candidate view // Make sure that passwords are not displayed in candidate view
int variation = attribute.inputType & EditorInfo.TYPE_MASK_VARIATION; int variation = attribute.inputType & EditorInfo.TYPE_MASK_VARIATION;
@@ -149,34 +141,49 @@ public class SoftKeyboard extends InputMethodService
updateShiftKeyState(attribute); updateShiftKeyState(attribute);
break; break;
} }
mInputView.closing();
if (mInputView != null) {
mInputView.setKeyboard(keyboard);
mInputView.closing();
}
mComposing.setLength(0); mComposing.setLength(0);
mCandidateView.setSuggestions(null, false, false); setSuggestions(null, false, false);
mOldConnection = getCurrentInputConnection();
setCandidatesViewShown(mPredictionOn || mCompletionOn);
} }
@Override @Override
public void onFinishInput() { public void onFinishInput() {
super.onFinishInput(); super.onFinishInput();
commitTyped(mOldConnection); mComposing.setLength(0);
updateCandidates();
if (mInputView != null) { if (mInputView != null) {
mInputView.closing(); mInputView.closing();
} }
} }
@Override @Override
public void onDisplayCompletions(CompletionInfo[] completions) { public void onUpdateSelection(int oldSelStart, int oldSelEnd,
if (false) { int newSelStart, int newSelEnd,
Log.i("foo", "Received completions:"); int candidatesStart, int candidatesEnd) {
for (int i=0; i<(completions != null ? completions.length : 0); i++) { // If the current selection in the text view changes, we should
Log.i("foo", " #" + i + ": " + completions[i]); // clear whatever candidate text we have.
if (mComposing.length() > 0 && (newSelStart != candidatesEnd
|| newSelEnd != candidatesEnd)) {
mComposing.setLength(0);
updateCandidates();
InputConnection ic = getCurrentInputConnection();
if (ic != null) {
ic.finishComposingText();
} }
} }
}
@Override
public void onDisplayCompletions(CompletionInfo[] completions) {
if (mCompletionOn) { if (mCompletionOn) {
mCompletions = completions; mCompletions = completions;
if (completions == null) { if (completions == null) {
mCandidateView.setSuggestions(null, false, false); setSuggestions(null, false, false);
return; return;
} }
@@ -185,10 +192,42 @@ public class SoftKeyboard extends InputMethodService
CompletionInfo ci = completions[i]; CompletionInfo ci = completions[i];
if (ci != null) stringList.add(ci.getText().toString()); if (ci != null) stringList.add(ci.getText().toString());
} }
mCandidateView.setSuggestions(stringList, true, true); setSuggestions(stringList, true, true);
} }
} }
private boolean translateKeyDown(int keyCode, KeyEvent event) {
mMetaState = MetaKeyKeyListener.handleKeyDown(mMetaState,
keyCode, event);
int c = event.getUnicodeChar(MetaKeyKeyListener.getMetaState(mMetaState));
mMetaState = MetaKeyKeyListener.adjustMetaAfterKeypress(mMetaState);
InputConnection ic = getCurrentInputConnection();
if (c == 0 || ic == null) {
return false;
}
boolean dead = false;
if ((c & KeyCharacterMap.COMBINING_ACCENT) != 0) {
dead = true;
c = c & KeyCharacterMap.COMBINING_ACCENT_MASK;
}
if (mComposing.length() > 0) {
char accent = mComposing.charAt(mComposing.length() -1 );
int composed = KeyEvent.getDeadChar(accent, c);
if (composed != 0) {
c = composed;
mComposing.setLength(mComposing.length()-1);
}
}
onKey(c, null);
return true;
}
@Override @Override
public boolean onKeyDown(int keyCode, KeyEvent event) { public boolean onKeyDown(int keyCode, KeyEvent event) {
switch (keyCode) { switch (keyCode) {
@@ -199,12 +238,16 @@ public class SoftKeyboard extends InputMethodService
} }
} }
break; break;
case KeyEvent.KEYCODE_DPAD_DOWN: case KeyEvent.KEYCODE_DEL:
case KeyEvent.KEYCODE_DPAD_UP: if (mComposing.length() > 0) {
case KeyEvent.KEYCODE_DPAD_LEFT: onKey(Keyboard.KEYCODE_DELETE, null);
case KeyEvent.KEYCODE_DPAD_RIGHT: return true;
abortComposition(); }
break; break;
default:
if (mPredictionOn && translateKeyDown(keyCode, event)) {
return true;
}
} }
return super.onKeyDown(keyCode, event); return super.onKeyDown(keyCode, event);
} }
@@ -225,6 +268,11 @@ public class SoftKeyboard extends InputMethodService
return true; return true;
} }
break; break;
default:
if (mPredictionOn) {
mMetaState = MetaKeyKeyListener.handleKeyUp(mMetaState,
keyCode, event);
}
} }
return super.onKeyUp(keyCode, event); return super.onKeyUp(keyCode, event);
} }
@@ -262,7 +310,7 @@ public class SoftKeyboard extends InputMethodService
private void sendKey(int keyCode) { private void sendKey(int keyCode) {
switch (keyCode) { switch (keyCode) {
case 10: case '\n':
keyDownUp(KeyEvent.KEYCODE_ENTER); keyDownUp(KeyEvent.KEYCODE_ENTER);
break; break;
default: default:
@@ -280,11 +328,11 @@ public class SoftKeyboard extends InputMethodService
public void onKey(int primaryCode, int[] keyCodes) { public void onKey(int primaryCode, int[] keyCodes) {
if (isWordSeparator(primaryCode)) { if (isWordSeparator(primaryCode)) {
// Handle separator // Handle separator
if (mPredicting) { if (mComposing.length() > 0) {
commitTyped(getCurrentInputConnection()); commitTyped(getCurrentInputConnection());
} }
sendKey(primaryCode); sendKey(primaryCode);
updateShiftKeyState(getCurrentInputInfo()); updateShiftKeyState(getCurrentInputEditorInfo());
} else if (primaryCode == Keyboard.KEYCODE_DELETE) { } else if (primaryCode == Keyboard.KEYCODE_DELETE) {
handleBackspace(); handleBackspace();
} else if (primaryCode == Keyboard.KEYCODE_SHIFT) { } else if (primaryCode == Keyboard.KEYCODE_SHIFT) {
@@ -294,7 +342,8 @@ public class SoftKeyboard extends InputMethodService
return; return;
} else if (primaryCode == LatinKeyboardView.KEYCODE_OPTIONS) { } else if (primaryCode == LatinKeyboardView.KEYCODE_OPTIONS) {
// Show a menu or somethin' // Show a menu or somethin'
} else if (primaryCode == Keyboard.KEYCODE_MODE_CHANGE) { } else if (primaryCode == Keyboard.KEYCODE_MODE_CHANGE
&& mInputView != null) {
Keyboard current = mInputView.getKeyboard(); Keyboard current = mInputView.getKeyboard();
if (current == mSymbolsKeyboard || current == mSymbolsShiftedKeyboard) { if (current == mSymbolsKeyboard || current == mSymbolsShiftedKeyboard) {
current = mQwertyKeyboard; current = mQwertyKeyboard;
@@ -320,34 +369,47 @@ public class SoftKeyboard extends InputMethodService
if (mComposing.length() > 0) { if (mComposing.length() > 0) {
ArrayList<String> list = new ArrayList<String>(); ArrayList<String> list = new ArrayList<String>();
list.add(mComposing.toString()); list.add(mComposing.toString());
mCandidateView.setSuggestions(list, true, true); setSuggestions(list, true, true);
} else { } else {
mCandidateView.setSuggestions(null, false, false); setSuggestions(null, false, false);
} }
} }
} }
public void setSuggestions(List<String> suggestions, boolean completions,
boolean typedWordValid) {
mCandidateView.setSuggestions(suggestions, completions, typedWordValid);
if (suggestions != null && suggestions.size() > 0) {
setCandidatesViewShown(true);
} else if (isFullscreenMode()) {
setCandidatesViewShown(true);
} else {
setCandidatesViewShown(false);
}
}
private void handleBackspace() { private void handleBackspace() {
if (mPredicting) { final int length = mComposing.length();
final int length = mComposing.length(); if (length > 1) {
if (length > 0) { mComposing.delete(length - 1, length);
mComposing.delete(length - 1, length); getCurrentInputConnection().setComposingText(mComposing, mComposing.length());
getCurrentInputConnection().setComposingText(mComposing, mComposing.length()); updateCandidates();
updateCandidates(); } else if (length > 0) {
if (mComposing.length() == 0) { mComposing.setLength(0);
mPredicting = false; getCurrentInputConnection().commitText("", 0);
} updateCandidates();
} else {
getCurrentInputConnection().deleteSurroundingText(1, 0);
}
} else { } else {
//getCurrentInputConnection().deleteSurroundingText(1, 0); //getCurrentInputConnection().deleteSurroundingText(1, 0);
keyDownUp(KeyEvent.KEYCODE_DEL); keyDownUp(KeyEvent.KEYCODE_DEL);
} }
updateShiftKeyState(getCurrentInputInfo()); updateShiftKeyState(getCurrentInputEditorInfo());
} }
private void handleShift() { private void handleShift() {
if (mInputView == null) {
return;
}
Keyboard currentKeyboard = mInputView.getKeyboard(); Keyboard currentKeyboard = mInputView.getKeyboard();
if (mQwertyKeyboard == currentKeyboard) { if (mQwertyKeyboard == currentKeyboard) {
// Alphabet keyboard // Alphabet keyboard
@@ -365,19 +427,20 @@ public class SoftKeyboard extends InputMethodService
} }
private void handleCharacter(int primaryCode, int[] keyCodes) { private void handleCharacter(int primaryCode, int[] keyCodes) {
if (isAlphabet(primaryCode) && mPredictionOn && !isCursorTouchingWord()) { if (isInputViewShown()) {
if (!mPredicting) { if (mInputView.isShifted()) {
mPredicting = true; primaryCode = Character.toUpperCase(primaryCode);
mComposing.setLength(0);
} }
} }
if (mInputView.isShifted()) { if (isAlphabet(primaryCode) && mPredictionOn) {
primaryCode = Character.toUpperCase(primaryCode); mComposing.append((char) primaryCode);
getCurrentInputConnection().setComposingText(mComposing, mComposing.length());
updateShiftKeyState(getCurrentInputEditorInfo());
updateCandidates();
} else {
getCurrentInputConnection().commitText(
String.valueOf((char) primaryCode), 0);
} }
mComposing.append((char) primaryCode);
getCurrentInputConnection().setComposingText(mComposing, mComposing.length());
updateShiftKeyState(getCurrentInputInfo());
updateCandidates();
} }
private void handleClose() { private void handleClose() {
@@ -396,20 +459,6 @@ public class SoftKeyboard extends InputMethodService
} }
} }
private boolean isCursorTouchingWord() {
CharSequence toLeft = getCurrentInputConnection().getTextBeforeCursor(1);
CharSequence toRight = getCurrentInputConnection().getTextAfterCursor(1);
if (!TextUtils.isEmpty(toLeft)
&& !isWordSeparator(toLeft.charAt(0))) {
return true;
}
if (!TextUtils.isEmpty(toRight)
&& !isWordSeparator(toRight.charAt(0))) {
return true;
}
return false;
}
protected String getWordSeparators() { protected String getWordSeparators() {
return mWordSeparators; return mWordSeparators;
} }
@@ -431,7 +480,12 @@ public class SoftKeyboard extends InputMethodService
if (mCandidateView != null) { if (mCandidateView != null) {
mCandidateView.clear(); mCandidateView.clear();
} }
updateShiftKeyState(getCurrentInputInfo()); updateShiftKeyState(getCurrentInputEditorInfo());
} else if (mComposing.length() > 0) {
// If we were generating candidate suggestions for the current
// text, we would commit one of them here. But for this sample,
// we will just commit the current text.
commitTyped(getCurrentInputConnection());
} }
} }
@@ -452,10 +506,4 @@ public class SoftKeyboard extends InputMethodService
public void swipeUp() { public void swipeUp() {
// ? // ?
} }
private void abortComposition() {
commitTyped(getCurrentInputConnection());
mComposing.setLength(0); // Don't want to allow uncommit after this
updateCandidates();
}
} }

View File

@@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="src" path="src"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
<classpathentry combineaccessrules="false" kind="src" path="/SdkLib"/>
<classpathentry kind="var" path="ANDROID_SRC/prebuilt/common/ant/ant.jar"/>
<classpathentry kind="output" path="bin"/>
</classpath>

17
tools/anttasks/.project Normal file
View File

@@ -0,0 +1,17 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>ant-tasks</name>
<comment></comment>
<projects>
</projects>
<buildSpec>
<buildCommand>
<name>org.eclipse.jdt.core.javabuilder</name>
<arguments>
</arguments>
</buildCommand>
</buildSpec>
<natures>
<nature>org.eclipse.jdt.core.javanature</nature>
</natures>
</projectDescription>

17
tools/anttasks/Android.mk Normal file
View File

@@ -0,0 +1,17 @@
#
# Copyright (C) 2008 The Android Open Source Project
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
ANTTASKS_LOCAL_DIR := $(call my-dir)
include $(ANTTASKS_LOCAL_DIR)/src/Android.mk

View File

@@ -0,0 +1,28 @@
#
# Copyright (C) 2008 The Android Open Source Project
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
LOCAL_PATH := $(call my-dir)
include $(CLEAR_VARS)
LOCAL_SRC_FILES := $(call all-subdir-java-files)
LOCAL_JAVA_LIBRARIES := \
sdklib \
ant
LOCAL_MODULE := anttasks
include $(BUILD_HOST_JAVA_LIBRARY)

View File

@@ -0,0 +1,150 @@
/*
* Copyright (C) 2008 The Android Open Source Project
*
* Licensed under the Eclipse Public License, Version 1.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.eclipse.org/org/documents/epl-v10.php
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package com.android.ant;
import com.android.sdklib.IAndroidTarget;
import com.android.sdklib.ISdkLog;
import com.android.sdklib.SdkManager;
import com.android.sdklib.project.ProjectProperties;
import org.apache.tools.ant.BuildException;
import org.apache.tools.ant.Project;
import org.apache.tools.ant.taskdefs.ImportTask;
import java.io.File;
import java.util.ArrayList;
/**
* Import Target Ant task. This task accomplishes:
* <ul>
* <li>Gets the project target hash string from {@link ProjectProperties#PROPERTY_TARGET},
* and resolves it.</li>
* <li>Sets up ant properties so that the rest of the Ant scripts finds:
* <ul>
* <li>Path to the underlying platform to access the build rules ('android-platform')<li>
* </ul>
* </li>
* </ul>
*
* This is used in build.xml/template.
*
*/
public class AndroidInitTask extends ImportTask {
private final static String ANDROID_RULES = "android_rules.xml";
private final static String PROPERTY_ANDROID_JAR = "android-jar";
private final static String PROPERTY_ANDROID_AIDL = "android-aidl";
@Override
public void execute() throws BuildException {
Project antProject = getProject();
// get the SDK location
String sdkLocation = antProject.getProperty(ProjectProperties.PROPERTY_SDK);
// check if it's valid and exists
if (sdkLocation == null || sdkLocation.length() == 0) {
throw new BuildException("SDK Location is not set.");
}
File sdk = new File(sdkLocation);
if (sdk.isDirectory() == false) {
throw new BuildException(String.format("SDK Location '%s' is not valid.", sdkLocation));
}
// get the target property value
String targetHashString = antProject.getProperty(ProjectProperties.PROPERTY_TARGET);
if (targetHashString == null) {
throw new BuildException("Android Target is not set.");
}
// load up the sdk targets.
final ArrayList<String> messages = new ArrayList<String>();
SdkManager manager = SdkManager.createManager(sdkLocation, new ISdkLog() {
public void error(Throwable t, String errorFormat, Object... args) {
if (errorFormat != null) {
messages.add(String.format("Error: " + errorFormat, args));
}
if (t != null) {
messages.add("Error: " + t.getMessage());
}
}
public void printf(String msgFormat, Object... args) {
messages.add(String.format(msgFormat, args));
}
public void warning(String warningFormat, Object... args) {
messages.add(String.format("Warning: " + warningFormat, args));
}
});
if (manager == null) {
// since we failed to parse the SDK, lets display the parsing output.
for (String msg : messages) {
System.out.println(msg);
}
throw new BuildException("Failed to parse SDK content.");
}
// resolve it
IAndroidTarget androidTarget = manager.getTargetFromHashString(targetHashString);
if (androidTarget == null) {
throw new BuildException(String.format(
"Unable to resolve target '%s'", targetHashString));
}
// display it
System.out.println("Project Target: " + androidTarget.getName());
if (androidTarget.isPlatform() == false) {
System.out.println("Vendor: " + androidTarget.getVendor());
}
System.out.println("Platform Version: " + androidTarget.getApiVersionName());
System.out.println("API level: " + androidTarget.getApiVersionNumber());
// sets up the properties.
String androidJar = androidTarget.getPath(IAndroidTarget.ANDROID_JAR);
String androidAidl = androidTarget.getPath(IAndroidTarget.ANDROID_AIDL);
antProject.setProperty(PROPERTY_ANDROID_JAR, androidJar);
antProject.setProperty(PROPERTY_ANDROID_AIDL, androidAidl);
// find the file to import, and import it.
String templateFolder = androidTarget.getPath(IAndroidTarget.TEMPLATES);
// make sure the file exists.
File templates = new File(templateFolder);
if (templates.isDirectory() == false) {
throw new BuildException(String.format("Template directory '%s' is missing.",
templateFolder));
}
// now check the rules file exists.
File rules = new File(templateFolder, ANDROID_RULES);
if (rules.isFile() == false) {
throw new BuildException(String.format("Build rules file '%s' is missing.",
templateFolder));
}
// set the file location to import
setFile(rules.getAbsolutePath());
// and import it
super.execute();
}
}

View File

@@ -69,6 +69,9 @@ public final class Device implements IDevice {
/** Serial number of the device */ /** Serial number of the device */
String serialNumber = null; String serialNumber = null;
/** Name of the vm */
String mVmName = null;
/** State of the device. */ /** State of the device. */
DeviceState state = null; DeviceState state = null;
@@ -91,6 +94,11 @@ public final class Device implements IDevice {
return serialNumber; return serialNumber;
} }
public String getVmName() {
return mVmName;
}
/* /*
* (non-Javadoc) * (non-Javadoc)
* @see com.android.ddmlib.IDevice#getState() * @see com.android.ddmlib.IDevice#getState()

View File

@@ -349,7 +349,7 @@ final class DeviceMonitor {
} }
if (device.getPropertyCount() == 0) { if (device.getPropertyCount() == 0) {
queryForBuild(device); queryNewDeviceForInfo(device);
} }
} }
} }
@@ -387,7 +387,7 @@ final class DeviceMonitor {
// look for their build info. // look for their build info.
if (newDevice.isOnline()) { if (newDevice.isOnline()) {
queryForBuild(newDevice); queryNewDeviceForInfo(newDevice);
} }
} }
} }
@@ -413,11 +413,20 @@ final class DeviceMonitor {
* Queries a device for its build info. * Queries a device for its build info.
* @param device the device to query. * @param device the device to query.
*/ */
private void queryForBuild(Device device) { private void queryNewDeviceForInfo(Device device) {
// TODO: do this in a separate thread. // TODO: do this in a separate thread.
try { try {
// first get the list of properties.
device.executeShellCommand(GetPropReceiver.GETPROP_COMMAND, device.executeShellCommand(GetPropReceiver.GETPROP_COMMAND,
new GetPropReceiver(device)); new GetPropReceiver(device));
// now get the emulator VM name (if applicable).
if (device.isEmulator()) {
EmulatorConsole console = EmulatorConsole.getConsole(device);
if (console != null) {
device.mVmName = console.getVmName();
}
}
} catch (IOException e) { } catch (IOException e) {
// if we can't get the build info, it doesn't matter too much // if we can't get the build info, it doesn't matter too much
} }

View File

@@ -54,6 +54,7 @@ public final class EmulatorConsole {
private final static String HOST = "127.0.0.1"; //$NON-NLS-1$ private final static String HOST = "127.0.0.1"; //$NON-NLS-1$
private final static String COMMAND_PING = "help\r\n"; //$NON-NLS-1$ private final static String COMMAND_PING = "help\r\n"; //$NON-NLS-1$
private final static String COMMAND_VM_NAME = "vm name\r\n"; //$NON-NLS-1$
private final static String COMMAND_KILL = "kill\r\n"; //$NON-NLS-1$ private final static String COMMAND_KILL = "kill\r\n"; //$NON-NLS-1$
private final static String COMMAND_GSM_STATUS = "gsm status\r\n"; //$NON-NLS-1$ private final static String COMMAND_GSM_STATUS = "gsm status\r\n"; //$NON-NLS-1$
private final static String COMMAND_GSM_CALL = "gsm call %1$s\r\n"; //$NON-NLS-1$ private final static String COMMAND_GSM_CALL = "gsm call %1$s\r\n"; //$NON-NLS-1$
@@ -307,6 +308,24 @@ public final class EmulatorConsole {
RemoveConsole(mPort); RemoveConsole(mPort);
} }
} }
public synchronized String getVmName() {
if (sendCommand(COMMAND_VM_NAME)) {
String[] result = readLines();
if (result != null && result.length == 2) { // this should be the name on first line,
// and ok on 2nd line
return result[0];
} else {
// try to see if there's a message after KO
Matcher m = RE_KO.matcher(result[result.length-1]);
if (m.matches()) {
return m.group(1);
}
}
}
return null;
}
/** /**
* Get the network status of the emulator. * Get the network status of the emulator.

View File

@@ -44,6 +44,15 @@ public interface IDevice {
* Returns the serial number of the device. * Returns the serial number of the device.
*/ */
public String getSerialNumber(); public String getSerialNumber();
/**
* Returns the name of the VM the emulator is running.
* <p/>This is only valid if {@link #isEmulator()} returns true.
* <p/>If the emulator is not running any VM (for instance it's running from an Android source
* tree build), this method will return "<code>&lt;build&gt;</code>".
* @return the name of the VM or <code>null</code> if there isn't any.
*/
public String getVmName();
/** /**
* Returns the state of the device. * Returns the state of the device.

View File

@@ -201,6 +201,10 @@ public class RemoteAndroidTestRunnerTest extends TestCase {
throw new UnsupportedOperationException(); throw new UnsupportedOperationException();
} }
public String getVmName() {
return "";
}
} }
/** An empty implementation of TestRunListener /** An empty implementation of TestRunListener

View File

@@ -200,12 +200,22 @@ public final class DevicePanel extends Panel implements IDebugBridgeChangeListen
case DEVICE_COL_STATE: case DEVICE_COL_STATE:
return getStateString(device); return getStateString(device);
case DEVICE_COL_BUILD: { case DEVICE_COL_BUILD: {
String vmName = device.getVmName();
String debuggable = device.getProperty(Device.PROP_DEBUGGABLE); String debuggable = device.getProperty(Device.PROP_DEBUGGABLE);
String version = device.getProperty(Device.PROP_BUILD_VERSION); String version = device.getProperty(Device.PROP_BUILD_VERSION);
if (debuggable != null && debuggable.equals("1")) { //$NON-NLS-1$ if (device.isEmulator()) {
return String.format("%1$s (debug)", version); //$NON-NLS-1$ if (debuggable != null && debuggable.equals("1")) { //$NON-NLS-1$
return String.format("%1$s [%2$s, debug]", vmName, //$NON-NLS-1$
version);
} else {
return String.format("%1$s [%2$s]", vmName, version); //$NON-NLS-1$
}
} else { } else {
return String.format("%1$s", version); //$NON-NLS-1$ if (debuggable != null && debuggable.equals("1")) { //$NON-NLS-1$
return String.format("%1$s, debug", version); //$NON-NLS-1$
} else {
return String.format("%1$s", version); //$NON-NLS-1$
}
} }
} }
} }

View File

@@ -40,6 +40,13 @@
<import plugin="org.eclipse.ui"/> <import plugin="org.eclipse.ui"/>
<import plugin="org.eclipse.ui.ide"/> <import plugin="org.eclipse.ui.ide"/>
<import plugin="org.eclipse.ui.forms"/> <import plugin="org.eclipse.ui.forms"/>
<import plugin="org.eclipse.gef"/>
<import plugin="org.eclipse.ui.browser"/>
<import plugin="org.eclipse.ui.views"/>
<import plugin="org.eclipse.wst.sse.core"/>
<import plugin="org.eclipse.wst.sse.ui"/>
<import plugin="org.eclipse.wst.xml.core"/>
<import plugin="org.eclipse.wst.xml.ui"/>
</requires> </requires>
<plugin <plugin

View File

@@ -16,6 +16,7 @@
package com.android.ide.eclipse.adt; package com.android.ide.eclipse.adt;
import com.android.ide.eclipse.adt.project.internal.AndroidClasspathContainerInitializer;
/** /**
@@ -42,8 +43,8 @@ public class AdtConstants {
/** Marker for Android Target errors. /** Marker for Android Target errors.
* This is not cleared on each like other markers. Instead, it's cleared * This is not cleared on each like other markers. Instead, it's cleared
* when a ContainerClasspathInitialized has succeeded in creating an * when an {@link AndroidClasspathContainerInitializer} has succeeded in creating an
* {@link AndroidClasspathContainer}*/ * AndroidClasspathContainer */
public final static String MARKER_TARGET = AdtPlugin.PLUGIN_ID + ".targetProblem"; //$NON-NLS-1$ public final static String MARKER_TARGET = AdtPlugin.PLUGIN_ID + ".targetProblem"; //$NON-NLS-1$
/** Build verbosity "Always". Those messages are always displayed. */ /** Build verbosity "Always". Those messages are always displayed. */

View File

@@ -1201,7 +1201,7 @@ public class AdtPlugin extends AbstractUIPlugin {
if (file.getFullPath().segmentCount() == 4) { if (file.getFullPath().segmentCount() == 4) {
// check if we are inside the res folder. // check if we are inside the res folder.
String segment = file.getFullPath().segment(1); String segment = file.getFullPath().segment(1);
if (segment.equalsIgnoreCase(AndroidConstants.FD_RESOURCES)) { if (segment.equalsIgnoreCase(SdkConstants.FD_RESOURCES)) {
// we are inside a res/ folder, get the actual ResourceFolder // we are inside a res/ folder, get the actual ResourceFolder
ProjectResources resources = ResourceManager.getInstance(). ProjectResources resources = ResourceManager.getInstance().
getProjectResources(file.getProject()); getProjectResources(file.getProject());

View File

@@ -31,6 +31,7 @@ import com.android.jarutils.DebugKeyProvider.KeytoolException;
import com.android.jarutils.SignedJarBuilder.IZipEntryFilter; import com.android.jarutils.SignedJarBuilder.IZipEntryFilter;
import com.android.prefs.AndroidLocation.AndroidLocationException; import com.android.prefs.AndroidLocation.AndroidLocationException;
import com.android.sdklib.IAndroidTarget; import com.android.sdklib.IAndroidTarget;
import com.android.sdklib.SdkConstants;
import org.eclipse.core.resources.IContainer; import org.eclipse.core.resources.IContainer;
import org.eclipse.core.resources.IFile; import org.eclipse.core.resources.IFile;
@@ -120,6 +121,10 @@ public class ApkBuilder extends BaseBuilder {
} }
} }
/**
* {@inheritDoc}
* @throws CoreException
*/
public boolean visit(IResourceDelta delta) throws CoreException { public boolean visit(IResourceDelta delta) throws CoreException {
// no need to keep looking if we already know we need to convert // no need to keep looking if we already know we need to convert
// to dex and make the final package. // to dex and make the final package.
@@ -589,7 +594,7 @@ public class ApkBuilder extends BaseBuilder {
* @param osBinPath the path to the output folder of the project * @param osBinPath the path to the output folder of the project
* @param osOutFilePath the path of the dex file to create. * @param osOutFilePath the path of the dex file to create.
* @param referencedJavaProjects the list of referenced projects for this project. * @param referencedJavaProjects the list of referenced projects for this project.
* @return *
* @throws CoreException * @throws CoreException
*/ */
private boolean executeDx(IJavaProject javaProject, String osBinPath, String osOutFilePath, private boolean executeDx(IJavaProject javaProject, String osBinPath, String osOutFilePath,
@@ -756,8 +761,7 @@ public class ApkBuilder extends BaseBuilder {
// now write the native libraries. // now write the native libraries.
// First look if the lib folder is there. // First look if the lib folder is there.
IResource libFolder = javaProject.getProject().findMember( IResource libFolder = javaProject.getProject().findMember(SdkConstants.FD_NATIVE_LIBS);
AndroidConstants.FD_NATIVE_LIBS);
if (libFolder != null && libFolder.exists() && if (libFolder != null && libFolder.exists() &&
libFolder.getType() == IResource.FOLDER) { libFolder.getType() == IResource.FOLDER) {
// look inside and put .so in lib/* by keeping the relative folder path. // look inside and put .so in lib/* by keeping the relative folder path.
@@ -829,7 +833,7 @@ public class ApkBuilder extends BaseBuilder {
* lib folder directly goes in this "lib" folder in the archive. * lib folder directly goes in this "lib" folder in the archive.
* *
* *
* @param rooSegmentCount The number of segment of the path of the folder containing the * @param rootSegmentCount The number of segment of the path of the folder containing the
* libraries. This is used to compute the path in the archive. * libraries. This is used to compute the path in the archive.
* @param jarBuilder the {@link SignedJarBuilder} used to create the archive. * @param jarBuilder the {@link SignedJarBuilder} used to create the archive.
* @param resource the IResource to write. * @param resource the IResource to write.
@@ -847,7 +851,7 @@ public class ApkBuilder extends BaseBuilder {
path = path.removeFirstSegments(rootSegmentCount); path = path.removeFirstSegments(rootSegmentCount);
// add it to the archive. // add it to the archive.
IPath apkPath = new Path(AndroidConstants.FD_APK_NATIVE_LIBS); IPath apkPath = new Path(SdkConstants.FD_APK_NATIVE_LIBS);
apkPath = apkPath.append(path); apkPath = apkPath.append(path);
// writes the file in the apk. // writes the file in the apk.

View File

@@ -18,6 +18,7 @@ package com.android.ide.eclipse.adt.build;
import com.android.ide.eclipse.adt.build.BaseBuilder.BaseDeltaVisitor; import com.android.ide.eclipse.adt.build.BaseBuilder.BaseDeltaVisitor;
import com.android.ide.eclipse.common.AndroidConstants; import com.android.ide.eclipse.common.AndroidConstants;
import com.android.sdklib.SdkConstants;
import org.eclipse.core.resources.IFile; import org.eclipse.core.resources.IFile;
import org.eclipse.core.resources.IFolder; import org.eclipse.core.resources.IFolder;
@@ -98,17 +99,17 @@ public class ApkDeltaVisitor extends BaseDeltaVisitor
mOutputPath = outputfolder.getFullPath(); mOutputPath = outputfolder.getFullPath();
} }
IResource assetFolder = builder.getProject().findMember(AndroidConstants.FD_ASSETS); IResource assetFolder = builder.getProject().findMember(SdkConstants.FD_ASSETS);
if (assetFolder != null) { if (assetFolder != null) {
mAssetPath = assetFolder.getFullPath(); mAssetPath = assetFolder.getFullPath();
} }
IResource resFolder = builder.getProject().findMember(AndroidConstants.FD_RESOURCES); IResource resFolder = builder.getProject().findMember(SdkConstants.FD_RESOURCES);
if (resFolder != null) { if (resFolder != null) {
mResPath = resFolder.getFullPath(); mResPath = resFolder.getFullPath();
} }
IResource libFolder = builder.getProject().findMember(AndroidConstants.FD_NATIVE_LIBS); IResource libFolder = builder.getProject().findMember(SdkConstants.FD_NATIVE_LIBS);
if (libFolder != null) { if (libFolder != null) {
mLibFolder = libFolder.getFullPath(); mLibFolder = libFolder.getFullPath();
} }
@@ -126,8 +127,9 @@ public class ApkDeltaVisitor extends BaseDeltaVisitor
return mMakeFinalPackage; return mMakeFinalPackage;
} }
/* /**
* (non-Javadoc) * {@inheritDoc}
* @throws CoreException
* *
* @see org.eclipse.core.resources.IResourceDeltaVisitor * @see org.eclipse.core.resources.IResourceDeltaVisitor
* #visit(org.eclipse.core.resources.IResourceDelta) * #visit(org.eclipse.core.resources.IResourceDelta)

View File

@@ -69,15 +69,15 @@ abstract class BaseBuilder extends IncrementalProjectBuilder {
/** /**
* First line of dual line aapt error.<br> * First line of dual line aapt error.<br>
* "ERROR at line &lt;line&gt;: &lt;error&gt;"<br> * "ERROR at line &lt;line&gt;: &lt;error&gt;"<br>
* " (Occured while parsing &lt;path&gt;)" * " (Occurred while parsing &lt;path&gt;)"
*/ */
private final static Pattern sPattern1Line1 = Pattern.compile( private final static Pattern sPattern1Line1 = Pattern.compile(
"^ERROR\\s+at\\s+line\\s+(\\d+):\\s+(.*)$"); //$NON-NLS-1$ "^ERROR\\s+at\\s+line\\s+(\\d+):\\s+(.*)$"); //$NON-NLS-1$
/** /**
* Second line of dual line aapt error.<br> * Second line of dual line aapt error.<br>
* "ERROR at line &lt;line&gt;: &lt;error&gt;"<br> * "ERROR at line &lt;line&gt;: &lt;error&gt;"<br>
* " (Occured while parsing &lt;path&gt;)"<br> * " (Occurred while parsing &lt;path&gt;)"<br>
* @see sPattern1Line1 * @see #sPattern1Line1
*/ */
private final static Pattern sPattern1Line2 = Pattern.compile( private final static Pattern sPattern1Line2 = Pattern.compile(
"^\\s+\\(Occurred while parsing\\s+(.*)\\)$"); //$NON-NLS-1$ "^\\s+\\(Occurred while parsing\\s+(.*)\\)$"); //$NON-NLS-1$
@@ -92,7 +92,7 @@ abstract class BaseBuilder extends IncrementalProjectBuilder {
* Second line of dual line aapt error.<br> * Second line of dual line aapt error.<br>
* "ERROR: &lt;error&gt;"<br> * "ERROR: &lt;error&gt;"<br>
* "Defined at file &lt;path&gt; line &lt;line&gt;"<br> * "Defined at file &lt;path&gt; line &lt;line&gt;"<br>
* @see sPattern2Line1 * @see #sPattern2Line1
*/ */
private final static Pattern sPattern2Line2 = Pattern.compile( private final static Pattern sPattern2Line2 = Pattern.compile(
"Defined\\s+at\\s+file\\s+(.+)\\s+line\\s+(\\d+)"); //$NON-NLS-1$ "Defined\\s+at\\s+file\\s+(.+)\\s+line\\s+(\\d+)"); //$NON-NLS-1$
@@ -113,7 +113,7 @@ abstract class BaseBuilder extends IncrementalProjectBuilder {
* Second line of dual line aapt error.<br> * Second line of dual line aapt error.<br>
* "ERROR parsing XML file &lt;path&gt;"<br> * "ERROR parsing XML file &lt;path&gt;"<br>
* "&lt;error&gt; at line &lt;line&gt;"<br> * "&lt;error&gt; at line &lt;line&gt;"<br>
* @see sPattern4Line1 * @see #sPattern4Line1
*/ */
private final static Pattern sPattern4Line2 = Pattern.compile( private final static Pattern sPattern4Line2 = Pattern.compile(
"^(.+)\\s+at\\s+line\\s+(\\d+)$"); //$NON-NLS-1$ "^(.+)\\s+at\\s+line\\s+(\\d+)$"); //$NON-NLS-1$
@@ -263,7 +263,7 @@ abstract class BaseBuilder extends IncrementalProjectBuilder {
/** /**
* Adds a marker to the current project. * Adds a marker to the current project.
* @param file the file to be marked *
* @param markerId The id of the marker to add. * @param markerId The id of the marker to add.
* @param message the message associated with the mark * @param message the message associated with the mark
* @param severity the severity of the marker. * @param severity the severity of the marker.
@@ -292,12 +292,11 @@ abstract class BaseBuilder extends IncrementalProjectBuilder {
/** /**
* Removes markers from a container and its children. * Removes markers from a container and its children.
* @param container The container from which to delete the markers. * @param folder The container from which to delete the markers.
* @param markerId The id of the markers to remove. If null, all marker of * @param markerId The id of the markers to remove. If null, all marker of
* type <code>IMarker.PROBLEM</code> will be removed. * type <code>IMarker.PROBLEM</code> will be removed.
*/ */
protected final void removeMarkersFromContainer(IContainer folder, protected final void removeMarkersFromContainer(IContainer folder, String markerId) {
String markerId) {
try { try {
if (folder.exists()) { if (folder.exists()) {
folder.deleteMarkers(markerId, true, IResource.DEPTH_INFINITE); folder.deleteMarkers(markerId, true, IResource.DEPTH_INFINITE);

View File

@@ -1128,10 +1128,8 @@ public class PreCompilerBuilder extends BaseBuilder {
* Finish a file created/modified by an outside command line process. * Finish a file created/modified by an outside command line process.
* The file is marked as modified by Android, and the parent folder is refreshed, so that, * The file is marked as modified by Android, and the parent folder is refreshed, so that,
* in case the file didn't exist beforehand, the file appears in the package explorer. * in case the file didn't exist beforehand, the file appears in the package explorer.
* @param file The file to "finish". * @param rFile The R file to "finish".
* @param parent The parent container. Can be null (in which case it'll be * @param manifestFile The manifest file to "finish".
* figured out from the file's IResource.
* @param monitor a monitor to display progress.
* @throws CoreException * @throws CoreException
*/ */
private void finishJavaFilesAfterExternalModification(IFile rFile, IFile manifestFile) private void finishJavaFilesAfterExternalModification(IFile rFile, IFile manifestFile)
@@ -1150,9 +1148,7 @@ public class PreCompilerBuilder extends BaseBuilder {
* The file is marked as modified by Android, and the parent folder is refreshed, so that, * The file is marked as modified by Android, and the parent folder is refreshed, so that,
* in case the file didn't exist beforehand, the file appears in the package explorer. * in case the file didn't exist beforehand, the file appears in the package explorer.
* @param file The file to "finish". * @param file The file to "finish".
* @param parent The parent container. Can be null (in which case it'll be * @param aidlFile The AIDL file to "finish".
* figured out from the file's IResource.
* @param monitor a monitor to display progress.
* @throws CoreException * @throws CoreException
*/ */
private void finishFileAfterExternalModification(IFile file, IFile aidlFile) private void finishFileAfterExternalModification(IFile file, IFile aidlFile)

View File

@@ -23,6 +23,7 @@ import com.android.ide.eclipse.adt.project.ProjectHelper;
import com.android.ide.eclipse.common.AndroidConstants; import com.android.ide.eclipse.common.AndroidConstants;
import com.android.ide.eclipse.common.project.AndroidManifestParser; import com.android.ide.eclipse.common.project.AndroidManifestParser;
import com.android.ide.eclipse.common.project.BaseProjectHelper; import com.android.ide.eclipse.common.project.BaseProjectHelper;
import com.android.sdklib.SdkConstants;
import org.eclipse.core.resources.IContainer; import org.eclipse.core.resources.IContainer;
import org.eclipse.core.resources.IFile; import org.eclipse.core.resources.IFile;
@@ -154,7 +155,7 @@ class PreCompilerDeltaVisitor extends BaseDeltaVisitor implements
// then we are not yet in a source or resource folder // then we are not yet in a source or resource folder
mInRes = mInSrc = false; mInRes = mInSrc = false;
if (AndroidConstants.FD_RESOURCES.equalsIgnoreCase(segments[1])) { if (SdkConstants.FD_RESOURCES.equalsIgnoreCase(segments[1])) {
// this is the resource folder that was modified. we want to // this is the resource folder that was modified. we want to
// see its content. // see its content.

View File

@@ -31,8 +31,12 @@ import com.android.ide.eclipse.adt.AdtPlugin;
import com.android.ide.eclipse.adt.debug.launching.DeviceChooserDialog.DeviceChooserResponse; import com.android.ide.eclipse.adt.debug.launching.DeviceChooserDialog.DeviceChooserResponse;
import com.android.ide.eclipse.adt.debug.ui.EmulatorConfigTab; import com.android.ide.eclipse.adt.debug.ui.EmulatorConfigTab;
import com.android.ide.eclipse.adt.project.ProjectHelper; import com.android.ide.eclipse.adt.project.ProjectHelper;
import com.android.ide.eclipse.adt.sdk.Sdk;
import com.android.ide.eclipse.common.project.AndroidManifestHelper; import com.android.ide.eclipse.common.project.AndroidManifestHelper;
import com.android.sdklib.SdkConstants; import com.android.sdklib.IAndroidTarget;
import com.android.sdklib.SdkManager;
import com.android.sdklib.vm.VmManager;
import com.android.sdklib.vm.VmManager.VmInfo;
import org.eclipse.core.resources.IFile; import org.eclipse.core.resources.IFile;
import org.eclipse.core.resources.IProject; import org.eclipse.core.resources.IProject;
@@ -58,6 +62,7 @@ import java.io.IOException;
import java.io.InputStreamReader; import java.io.InputStreamReader;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.HashMap; import java.util.HashMap;
import java.util.Map.Entry;
import java.util.regex.Matcher; import java.util.regex.Matcher;
import java.util.regex.Pattern; import java.util.regex.Pattern;
@@ -69,9 +74,9 @@ import java.util.regex.Pattern;
public final class AndroidLaunchController implements IDebugBridgeChangeListener, public final class AndroidLaunchController implements IDebugBridgeChangeListener,
IDeviceChangeListener, IClientChangeListener { IDeviceChangeListener, IClientChangeListener {
private static final String FLAG_VM = "-vm"; //$NON-NLS-1$
private static final String FLAG_NETDELAY = "-netdelay"; //$NON-NLS-1$ private static final String FLAG_NETDELAY = "-netdelay"; //$NON-NLS-1$
private static final String FLAG_NETSPEED = "-netspeed"; //$NON-NLS-1$ private static final String FLAG_NETSPEED = "-netspeed"; //$NON-NLS-1$
private static final String FLAG_SKIN = "-skin"; //$NON-NLS-1$
private static final String FLAG_WIPE_DATA = "-wipe-data"; //$NON-NLS-1$ private static final String FLAG_WIPE_DATA = "-wipe-data"; //$NON-NLS-1$
private static final String FLAG_NO_BOOT_ANIM = "-no-boot-anim"; //$NON-NLS-1$ private static final String FLAG_NO_BOOT_ANIM = "-no-boot-anim"; //$NON-NLS-1$
@@ -223,11 +228,10 @@ public final class AndroidLaunchController implements IDebugBridgeChangeListener
public boolean mNoBootAnim = LaunchConfigDelegate.DEFAULT_NO_BOOT_ANIM; public boolean mNoBootAnim = LaunchConfigDelegate.DEFAULT_NO_BOOT_ANIM;
/** /**
* Screen size parameters. * Vm Name.
* This value can be provided to the emulator directly for the option "-skin"
*/ */
public String mSkin = null; public String mVmName = null;
public String mNetworkSpeed = EmulatorConfigTab.getSpeed( public String mNetworkSpeed = EmulatorConfigTab.getSpeed(
LaunchConfigDelegate.DEFAULT_SPEED); LaunchConfigDelegate.DEFAULT_SPEED);
public String mNetworkDelay = EmulatorConfigTab.getDelay( public String mNetworkDelay = EmulatorConfigTab.getDelay(
@@ -258,12 +262,8 @@ public final class AndroidLaunchController implements IDebugBridgeChangeListener
} }
try { try {
mSkin = config.getAttribute(LaunchConfigDelegate.ATTR_SKIN, mSkin); mVmName = config.getAttribute(LaunchConfigDelegate.ATTR_VM_NAME, mVmName);
if (mSkin == null) {
mSkin = SdkConstants.SKIN_DEFAULT;
}
} catch (CoreException e) { } catch (CoreException e) {
mSkin = SdkConstants.SKIN_DEFAULT;
} }
int index = LaunchConfigDelegate.DEFAULT_SPEED; int index = LaunchConfigDelegate.DEFAULT_SPEED;
@@ -526,11 +526,14 @@ public final class AndroidLaunchController implements IDebugBridgeChangeListener
// set the launch mode to default. // set the launch mode to default.
wc.setAttribute(LaunchConfigDelegate.ATTR_LAUNCH_ACTION, wc.setAttribute(LaunchConfigDelegate.ATTR_LAUNCH_ACTION,
LaunchConfigDelegate.DEFAULT_LAUNCH_ACTION); LaunchConfigDelegate.DEFAULT_LAUNCH_ACTION);
// set default target mode // set default target mode
wc.setAttribute(LaunchConfigDelegate.ATTR_TARGET_MODE, wc.setAttribute(LaunchConfigDelegate.ATTR_TARGET_MODE,
LaunchConfigDelegate.DEFAULT_TARGET_MODE); LaunchConfigDelegate.DEFAULT_TARGET_MODE);
// default VM: None
wc.setAttribute(LaunchConfigDelegate.ATTR_VM_NAME, (String)null);
// set the default network speed // set the default network speed
wc.setAttribute(LaunchConfigDelegate.ATTR_SPEED, wc.setAttribute(LaunchConfigDelegate.ATTR_SPEED,
LaunchConfigDelegate.DEFAULT_SPEED); LaunchConfigDelegate.DEFAULT_SPEED);
@@ -539,9 +542,6 @@ public final class AndroidLaunchController implements IDebugBridgeChangeListener
wc.setAttribute(LaunchConfigDelegate.ATTR_DELAY, wc.setAttribute(LaunchConfigDelegate.ATTR_DELAY,
LaunchConfigDelegate.DEFAULT_DELAY); LaunchConfigDelegate.DEFAULT_DELAY);
// default skin
wc.setAttribute(LaunchConfigDelegate.ATTR_SKIN, SdkConstants.SKIN_DEFAULT);
// default wipe data mode // default wipe data mode
wc.setAttribute(LaunchConfigDelegate.ATTR_WIPE_DATA, wc.setAttribute(LaunchConfigDelegate.ATTR_WIPE_DATA,
LaunchConfigDelegate.DEFAULT_WIPE_DATA); LaunchConfigDelegate.DEFAULT_WIPE_DATA);
@@ -627,32 +627,171 @@ public final class AndroidLaunchController implements IDebugBridgeChangeListener
// set the debug mode // set the debug mode
launchInfo.mDebugMode = mode.equals(ILaunchManager.DEBUG_MODE); launchInfo.mDebugMode = mode.equals(ILaunchManager.DEBUG_MODE);
// device chooser response. // get the SDK
Sdk currentSdk = Sdk.getCurrent();
VmManager vmManager = currentSdk.getVmManager();
// get the project target
final IAndroidTarget projectTarget = currentSdk.getTarget(project);
// FIXME: check errors on missing sdk, vm manager, or project target.
// device chooser response object.
final DeviceChooserResponse response = new DeviceChooserResponse(); final DeviceChooserResponse response = new DeviceChooserResponse();
/*
* Launch logic:
* - Manually Mode
* Always display a UI that lets a user see the current running emulators/devices.
* The UI must show which devices are compatibles, and allow launching new emulators
* with compatible (and not yet running) VM.
* - Automatic Way
* * Preferred VM set.
* If Preferred VM is not running: launch it.
* Launch the application on the preferred VM.
* * No preferred VM.
* Count the number of compatible emulators/devices.
* If != 1, display a UI similar to manual mode.
* If == 1, launch the application on this VM/device.
*/
if (config.mTargetMode == AndroidLaunchConfiguration.AUTO_TARGET_MODE) { if (config.mTargetMode == AndroidLaunchConfiguration.AUTO_TARGET_MODE) {
// if we are in automatic target mode, we need to find the current devices // if we are in automatic target mode, we need to find the current devices
Device[] devices = AndroidDebugBridge.getBridge().getDevices(); Device[] devices = AndroidDebugBridge.getBridge().getDevices();
// depending on the number of devices, we'll simulate an automatic choice // first check if we have a preferred VM name, and if it actually exists, and is valid
// from the device chooser or simply show up the device chooser. // (ie able to run the project).
if (devices.length == 0) { // We need to check this in case the VM was recreated with a different target that is
// if zero devices, we launch the device. // not compatible.
AdtPlugin.printToConsole(project, "Automatic Target Mode: launching new emulator."); VmInfo preferredVm = null;
if (config.mVmName != null) {
preferredVm = vmManager.getVm(config.mVmName);
if (projectTarget.isCompatibleBaseFor(preferredVm.getTarget()) == false) {
preferredVm = null;
AdtPlugin.printErrorToConsole(project, String.format(
"Preferred VM '%1$s' is not compatible with the project target '%2$s'. Looking for a compatible VM...",
config.mVmName, projectTarget.getName()));
}
}
if (preferredVm != null) {
// look for a matching device
for (Device d : devices) {
String deviceVm = d.getVmName();
if (deviceVm != null && deviceVm.equals(config.mVmName)) {
response.mustContinue = true;
response.mustLaunchEmulator = false;
response.deviceToUse = d;
AdtPlugin.printToConsole(project, String.format(
"Automatic Target Mode: Preferred VM '%1$s' is available on emulator '%2$s'",
config.mVmName, d));
continueLaunch(response, project, launch, launchInfo, config);
return;
}
}
// at this point we have a valid preferred VM that is not running.
// We need to start it.
response.mustContinue = true; response.mustContinue = true;
response.mustLaunchEmulator = true; response.mustLaunchEmulator = true;
response.vmToLaunch = preferredVm;
AdtPlugin.printToConsole(project, String.format(
"Automatic Target Mode: Preferred VM '%1$s' is not available. Launching new emulator.",
config.mVmName));
continueLaunch(response, project, launch, launchInfo, config); continueLaunch(response, project, launch, launchInfo, config);
return; return;
} else if (devices.length == 1) { }
// no (valid) preferred VM? look for one.
HashMap<Device, VmInfo> compatibleRunningVms = new HashMap<Device, VmInfo>();
boolean hasDevice = false; // if there's 1+ device running, we may force manual mode,
// as we cannot always detect proper compatibility with
// devices. This is the case if the project target is not
// a standard platform
for (Device d : devices) {
String deviceVm = d.getVmName();
if (deviceVm != null) { // physical devices return null.
VmInfo info = vmManager.getVm(deviceVm);
if (info != null && projectTarget.isCompatibleBaseFor(info.getTarget())) {
compatibleRunningVms.put(d, info);
}
} else {
if (projectTarget.isPlatform()) { // means this can run on any device as long
// as api level is high enough
String apiString = d.getProperty(SdkManager.PROP_VERSION_SDK);
try {
int apiNumber = Integer.parseInt(apiString);
if (apiNumber >= projectTarget.getApiVersionNumber()) {
// device is compatible with project
compatibleRunningVms.put(d, null);
continue;
}
} catch (NumberFormatException e) {
// do nothing, we'll consider it a non compatible device below.
}
}
hasDevice = true;
}
}
// depending on the number of devices, we'll simulate an automatic choice
// from the device chooser or simply show up the device chooser.
if (hasDevice == false && compatibleRunningVms.size() == 0) {
// if zero emulators/devices, we launch an emulator.
// We need to figure out which VM first.
// we are going to take the closest VM. ie a compatible VM that has the API level
// closest to the project target.
VmInfo[] vms = vmManager.getVms();
VmInfo defaultVm = null;
for (VmInfo vm : vms) {
if (projectTarget.isCompatibleBaseFor(vm.getTarget())) {
if (defaultVm == null ||
vm.getTarget().getApiVersionNumber() <
defaultVm.getTarget().getApiVersionNumber()) {
defaultVm = vm;
}
}
}
if (defaultVm != null) {
response.mustContinue = true;
response.mustLaunchEmulator = true;
response.vmToLaunch = defaultVm;
AdtPlugin.printToConsole(project, String.format(
"Automatic Target Mode: launching new emulator with compatible VM '%1$s'",
defaultVm.getName()));
continueLaunch(response, project, launch, launchInfo, config);
return;
} else {
// FIXME: ask the user if he wants to create a VM.
// we found no compatible VM.
AdtPlugin.printErrorToConsole(project, String.format(
"Failed to find a VM compatible with target '%1$s'. Launch aborted.",
projectTarget.getName()));
launch.stopLaunch();
return;
}
} else if (hasDevice == false && compatibleRunningVms.size() == 1) {
Entry<Device, VmInfo> e = compatibleRunningVms.entrySet().iterator().next();
response.mustContinue = true; response.mustContinue = true;
response.mustLaunchEmulator = false; response.mustLaunchEmulator = false;
response.deviceToUse = devices[0]; response.deviceToUse = e.getKey();
if (response.deviceToUse.isEmulator()) { // get the VmInfo, if null, the device is a physical device.
message = String.format("Automatic Target Mode: using existing emulator: %1$s", VmInfo vmInfo = e.getValue();
response.deviceToUse); if (vmInfo != null) {
message = String.format("Automatic Target Mode: using existing emulator '%1$s' running compatible VM '%2$s'",
response.deviceToUse, e.getValue().getName());
} else { } else {
message = String.format("Automatic Target Mode: using existing device: %1$s", message = String.format("Automatic Target Mode: using device '%1$s'",
response.deviceToUse); response.deviceToUse);
} }
AdtPlugin.printToConsole(project, message); AdtPlugin.printToConsole(project, message);
@@ -662,8 +801,13 @@ public final class AndroidLaunchController implements IDebugBridgeChangeListener
} }
// if more than one device, we'll bring up the DeviceChooser dialog below. // if more than one device, we'll bring up the DeviceChooser dialog below.
AdtPlugin.printToConsole(project, if (compatibleRunningVms.size() >= 2) {
"Automatic Target Mode: user selection for 2+ devices."); message = "Automatic Target Mode: Several compatible targets. Please select a target device.";
} else if (hasDevice) {
message = "Automatic Target Mode: Unable to detect device compatibility. Please select a target device.";
}
AdtPlugin.printToConsole(project, message);
} }
// bring up the device chooser. // bring up the device chooser.
@@ -671,7 +815,7 @@ public final class AndroidLaunchController implements IDebugBridgeChangeListener
public void run() { public void run() {
DeviceChooserDialog dialog = new DeviceChooserDialog( DeviceChooserDialog dialog = new DeviceChooserDialog(
AdtPlugin.getDisplay().getActiveShell()); AdtPlugin.getDisplay().getActiveShell());
dialog.open(response, project, launch, launchInfo, config); dialog.open(response, project, projectTarget, launch, launchInfo, config);
} }
}); });
@@ -705,7 +849,7 @@ public final class AndroidLaunchController implements IDebugBridgeChangeListener
synchronized (sListLock) { synchronized (sListLock) {
mWaitingForEmulatorLaunches.add(launchInfo); mWaitingForEmulatorLaunches.add(launchInfo);
AdtPlugin.printToConsole(project, "Launching a new emulator."); AdtPlugin.printToConsole(project, "Launching a new emulator.");
boolean status = launchEmulator(config); boolean status = launchEmulator(config, response.vmToLaunch);
if (status == false) { if (status == false) {
// launching the emulator failed! // launching the emulator failed!
@@ -775,9 +919,6 @@ public final class AndroidLaunchController implements IDebugBridgeChangeListener
* the device requires it and it is not set in the manifest, the launch will be forced to * the device requires it and it is not set in the manifest, the launch will be forced to
* "release" mode instead of "debug"</li> * "release" mode instead of "debug"</li>
* <ul> * <ul>
* @param launchInfo
* @param device
* @return
*/ */
private boolean checkBuildInfo(DelayedLaunchInfo launchInfo, Device device) { private boolean checkBuildInfo(DelayedLaunchInfo launchInfo, Device device) {
if (device != null) { if (device != null) {
@@ -1122,7 +1263,7 @@ public final class AndroidLaunchController implements IDebugBridgeChangeListener
/** /**
* launches an application on a device or emulator * launches an application on a device or emulator
* *
* @param classToLaunch the fully-qualified name of the activity to launch * @param info the {@link DelayedLaunchInfo} that indicates the activity to launch
* @param device the device or emulator to launch the application on * @param device the device or emulator to launch the application on
*/ */
private void launchApp(final DelayedLaunchInfo info, Device device) { private void launchApp(final DelayedLaunchInfo info, Device device) {
@@ -1182,7 +1323,7 @@ public final class AndroidLaunchController implements IDebugBridgeChangeListener
} }
} }
private boolean launchEmulator(AndroidLaunchConfiguration config) { private boolean launchEmulator(AndroidLaunchConfiguration config, VmInfo vmToLaunch) {
// split the custom command line in segments // split the custom command line in segments
ArrayList<String> customArgs = new ArrayList<String>(); ArrayList<String> customArgs = new ArrayList<String>();
@@ -1212,10 +1353,8 @@ public final class AndroidLaunchController implements IDebugBridgeChangeListener
ArrayList<String> list = new ArrayList<String>(); ArrayList<String> list = new ArrayList<String>();
list.add(AdtPlugin.getOsAbsoluteEmulator()); list.add(AdtPlugin.getOsAbsoluteEmulator());
if (config.mSkin != null) { list.add(FLAG_VM);
list.add(FLAG_SKIN); list.add(vmToLaunch.getName());
list.add(config.mSkin);
}
if (config.mNetworkSpeed != null) { if (config.mNetworkSpeed != null) {
list.add(FLAG_NETSPEED); list.add(FLAG_NETSPEED);
@@ -1329,7 +1468,7 @@ public final class AndroidLaunchController implements IDebugBridgeChangeListener
* @param debugPort The port to connect the debugger to * @param debugPort The port to connect the debugger to
* @param androidLaunch The associated AndroidLaunch object. * @param androidLaunch The associated AndroidLaunch object.
* @param monitor A Progress monitor * @param monitor A Progress monitor
* @see connectRemoveDebugger() * @see #connectRemoteDebugger(int, AndroidLaunch, IProgressMonitor)
*/ */
public static void launchRemoteDebugger( final int debugPort, final AndroidLaunch androidLaunch, public static void launchRemoteDebugger( final int debugPort, final AndroidLaunch androidLaunch,
final IProgressMonitor monitor) { final IProgressMonitor monitor) {
@@ -1352,7 +1491,7 @@ public final class AndroidLaunchController implements IDebugBridgeChangeListener
* This is sent from a non UI thread. * This is sent from a non UI thread.
* @param bridge the new {@link AndroidDebugBridge} object. * @param bridge the new {@link AndroidDebugBridge} object.
* *
* @see IDebugBridgeChangeListener#serverChanged(AndroidDebugBridge) * @see IDebugBridgeChangeListener#bridgeChanged(AndroidDebugBridge)
*/ */
public void bridgeChanged(AndroidDebugBridge bridge) { public void bridgeChanged(AndroidDebugBridge bridge) {
// The adb server has changed. We cancel any pending launches. // The adb server has changed. We cancel any pending launches.
@@ -1447,7 +1586,7 @@ public final class AndroidLaunchController implements IDebugBridgeChangeListener
* @param device the device that was updated. * @param device the device that was updated.
* @param changeMask the mask indicating what changed. * @param changeMask the mask indicating what changed.
* *
* @see IDeviceChangeListener#deviceChanged(Device) * @see IDeviceChangeListener#deviceChanged(Device, int)
*/ */
public void deviceChanged(Device device, int changeMask) { public void deviceChanged(Device device, int changeMask) {
// We could check if any starting device we care about is now ready, but we can wait for // We could check if any starting device we care about is now ready, but we can wait for
@@ -1622,7 +1761,6 @@ public final class AndroidLaunchController implements IDebugBridgeChangeListener
* Get the stderr/stdout outputs of a process and return when the process is done. * Get the stderr/stdout outputs of a process and return when the process is done.
* Both <b>must</b> be read or the process will block on windows. * Both <b>must</b> be read or the process will block on windows.
* @param process The process to get the ouput from * @param process The process to get the ouput from
* @throws InterruptedException
*/ */
private void grabEmulatorOutput(final Process process) { private void grabEmulatorOutput(final Process process) {
// read the lines as they come. if null is returned, it's // read the lines as they come. if null is returned, it's

View File

@@ -19,6 +19,7 @@ package com.android.ide.eclipse.adt.debug.launching;
import com.android.ddmlib.AndroidDebugBridge; import com.android.ddmlib.AndroidDebugBridge;
import com.android.ddmlib.Client; import com.android.ddmlib.Client;
import com.android.ddmlib.Device; import com.android.ddmlib.Device;
import com.android.ddmlib.IDevice;
import com.android.ddmlib.AndroidDebugBridge.IDeviceChangeListener; import com.android.ddmlib.AndroidDebugBridge.IDeviceChangeListener;
import com.android.ddmlib.Device.DeviceState; import com.android.ddmlib.Device.DeviceState;
import com.android.ddmuilib.IImageLoader; import com.android.ddmuilib.IImageLoader;
@@ -27,7 +28,10 @@ import com.android.ddmuilib.TableHelper;
import com.android.ide.eclipse.adt.AdtPlugin; import com.android.ide.eclipse.adt.AdtPlugin;
import com.android.ide.eclipse.adt.debug.launching.AndroidLaunchController.AndroidLaunchConfiguration; import com.android.ide.eclipse.adt.debug.launching.AndroidLaunchController.AndroidLaunchConfiguration;
import com.android.ide.eclipse.adt.debug.launching.AndroidLaunchController.DelayedLaunchInfo; import com.android.ide.eclipse.adt.debug.launching.AndroidLaunchController.DelayedLaunchInfo;
import com.android.ide.eclipse.adt.sdk.Sdk;
import com.android.ide.eclipse.ddms.DdmsPlugin; import com.android.ide.eclipse.ddms.DdmsPlugin;
import com.android.sdklib.IAndroidTarget;
import com.android.sdklib.vm.VmManager.VmInfo;
import org.eclipse.core.resources.IProject; import org.eclipse.core.resources.IProject;
import org.eclipse.jface.preference.IPreferenceStore; import org.eclipse.jface.preference.IPreferenceStore;
@@ -67,19 +71,26 @@ public class DeviceChooserDialog extends Dialog implements IDeviceChangeListener
private final static String PREFS_COL_SERIAL = "deviceChooser.serial"; //$NON-NLS-1$ private final static String PREFS_COL_SERIAL = "deviceChooser.serial"; //$NON-NLS-1$
private final static String PREFS_COL_STATE = "deviceChooser.state"; //$NON-NLS-1$ private final static String PREFS_COL_STATE = "deviceChooser.state"; //$NON-NLS-1$
private final static String PREFS_COL_BUILD = "deviceChooser.build"; //$NON-NLS-1$ private final static String PREFS_COL_VM = "deviceChooser.vm"; //$NON-NLS-1$
private final static String PREFS_COL_TARGET = "deviceChooser.target"; //$NON-NLS-1$
private final static String PREFS_COL_DEBUG = "deviceChooser.debug"; //$NON-NLS-1$
private Table mDeviceTable; private Table mDeviceTable;
private TableViewer mViewer; private TableViewer mViewer;
private Image mDeviceImage; private Image mDeviceImage;
private Image mEmulatorImage; private Image mEmulatorImage;
private Image mMatchImage;
private Image mNoMatchImage;
private Image mWarningImage;
private Button mOkButton; private Button mOkButton;
private Button mCreateButton; private Button mCreateButton;
private DeviceChooserResponse mResponse; private DeviceChooserResponse mResponse;
private DelayedLaunchInfo mLaunchInfo; private DelayedLaunchInfo mLaunchInfo;
private IAndroidTarget mProjectTarget;
private Sdk mSdk;
/** /**
* Basic Content Provider for a table full of {@link Device} objects. The input is * Basic Content Provider for a table full of {@link Device} objects. The input is
@@ -111,13 +122,44 @@ public class DeviceChooserDialog extends Dialog implements IDeviceChangeListener
private class LabelProvider implements ITableLabelProvider { private class LabelProvider implements ITableLabelProvider {
public Image getColumnImage(Object element, int columnIndex) { public Image getColumnImage(Object element, int columnIndex) {
if (columnIndex == 0 && element instanceof Device) { if (element instanceof Device) {
if (((Device)element).isEmulator()) { Device device = (Device)element;
return mEmulatorImage; switch (columnIndex) {
case 0:
return device.isEmulator() ? mEmulatorImage : mDeviceImage;
case 2:
// check for compatibility.
if (device.isEmulator() == false) { // physical device
// get the api level of the device
try {
String apiValue = device.getProperty(
IDevice.PROP_BUILD_VERSION_NUMBER);
int api = Integer.parseInt(apiValue);
if (api >= mProjectTarget.getApiVersionNumber()) {
// if the project is compiling against an add-on, the optional
// API may be missing from the device.
return mProjectTarget.isPlatform() ?
mMatchImage : mWarningImage;
} else {
return mNoMatchImage;
}
} catch (NumberFormatException e) {
// lets consider the device non compatible
return mNoMatchImage;
}
} else {
// get the VmInfo
VmInfo info = mSdk.getVmManager().getVm(device.getVmName());
if (info == null) {
return mWarningImage;
}
return mProjectTarget.isCompatibleBaseFor(info.getTarget()) ?
mMatchImage : mNoMatchImage;
}
} }
return mDeviceImage;
} }
return null; return null;
} }
@@ -128,15 +170,30 @@ public class DeviceChooserDialog extends Dialog implements IDeviceChangeListener
case 0: case 0:
return device.getSerialNumber(); return device.getSerialNumber();
case 1: case 1:
return getStateString(device); if (device.isEmulator()) {
case 2: return device.getVmName();
String debuggable = device.getProperty(Device.PROP_DEBUGGABLE);
String version = device.getProperty(Device.PROP_BUILD_VERSION);
if (debuggable != null && debuggable.equals("1")) { //$NON-NLS-1$
return String.format("%1$s (debug)", version); //$NON-NLS-1$
} else { } else {
return String.format("%1$s", version); //$NON-NLS-1$ return "N/A"; // devices don't have VM names.
} }
case 2:
if (device.isEmulator()) {
VmInfo info = mSdk.getVmManager().getVm(device.getVmName());
if (info == null) {
return "?";
}
return info.getTarget().getFullName();
} else {
return device.getProperty(IDevice.PROP_BUILD_VERSION);
}
case 3:
String debuggable = device.getProperty(IDevice.PROP_DEBUGGABLE);
if (debuggable != null && debuggable.equals("1")) { //$NON-NLS-1$
return "Yes";
} else {
return "";
}
case 4:
return getStateString(device);
} }
} }
@@ -164,6 +221,7 @@ public class DeviceChooserDialog extends Dialog implements IDeviceChangeListener
public static class DeviceChooserResponse { public static class DeviceChooserResponse {
public boolean mustContinue; public boolean mustContinue;
public boolean mustLaunchEmulator; public boolean mustLaunchEmulator;
public VmInfo vmToLaunch;
public Device deviceToUse; public Device deviceToUse;
} }
@@ -175,14 +233,18 @@ public class DeviceChooserDialog extends Dialog implements IDeviceChangeListener
* Prepare and display the dialog. * Prepare and display the dialog.
* @param response * @param response
* @param project * @param project
* @param projectTarget
* @param launch * @param launch
* @param launchInfo * @param launchInfo
* @param config * @param config
*/ */
public void open(DeviceChooserResponse response, IProject project, public void open(DeviceChooserResponse response, IProject project,
AndroidLaunch launch, DelayedLaunchInfo launchInfo, AndroidLaunchConfiguration config) { IAndroidTarget projectTarget, AndroidLaunch launch, DelayedLaunchInfo launchInfo,
AndroidLaunchConfiguration config) {
mResponse = response; mResponse = response;
mProjectTarget = projectTarget;
mLaunchInfo = launchInfo; mLaunchInfo = launchInfo;
mSdk = Sdk.getCurrent();
Shell parent = getParent(); Shell parent = getParent();
Shell shell = new Shell(parent, getStyle()); Shell shell = new Shell(parent, getStyle());
@@ -218,6 +280,9 @@ public class DeviceChooserDialog extends Dialog implements IDeviceChangeListener
mEmulatorImage.dispose(); mEmulatorImage.dispose();
mDeviceImage.dispose(); mDeviceImage.dispose();
mMatchImage.dispose();
mNoMatchImage.dispose();
mWarningImage.dispose();
AndroidLaunchController.getInstance().continueLaunch(response, project, launch, AndroidLaunchController.getInstance().continueLaunch(response, project, launch,
launchInfo, config); launchInfo, config);
@@ -249,14 +314,22 @@ public class DeviceChooserDialog extends Dialog implements IDeviceChangeListener
SWT.LEFT, "AAA+AAAAAAAAAAAAAAAAAAA", //$NON-NLS-1$ SWT.LEFT, "AAA+AAAAAAAAAAAAAAAAAAA", //$NON-NLS-1$
PREFS_COL_SERIAL, store); PREFS_COL_SERIAL, store);
TableHelper.createTableColumn(mDeviceTable, "VM Name",
SWT.LEFT, "engineering", //$NON-NLS-1$
PREFS_COL_VM, store);
TableHelper.createTableColumn(mDeviceTable, "Target",
SWT.LEFT, "AAA+Android 9.9.9", //$NON-NLS-1$
PREFS_COL_TARGET, store);
TableHelper.createTableColumn(mDeviceTable, "Debug",
SWT.LEFT, "Debug", //$NON-NLS-1$
PREFS_COL_DEBUG, store);
TableHelper.createTableColumn(mDeviceTable, "State", TableHelper.createTableColumn(mDeviceTable, "State",
SWT.LEFT, "bootloader", //$NON-NLS-1$ SWT.LEFT, "bootloader", //$NON-NLS-1$
PREFS_COL_STATE, store); PREFS_COL_STATE, store);
TableHelper.createTableColumn(mDeviceTable, "Build Info",
SWT.LEFT, "engineering", //$NON-NLS-1$
PREFS_COL_BUILD, store);
// create the viewer for it // create the viewer for it
mViewer = new TableViewer(mDeviceTable); mViewer = new TableViewer(mDeviceTable);
mViewer.setContentProvider(new ContentProvider()); mViewer.setContentProvider(new ContentProvider());
@@ -357,20 +430,42 @@ public class DeviceChooserDialog extends Dialog implements IDeviceChangeListener
} }
private void loadImages() { private void loadImages() {
IImageLoader loader = DdmsPlugin.getImageLoader(); IImageLoader ddmsLoader = DdmsPlugin.getImageLoader();
Display display = DdmsPlugin.getDisplay(); Display display = DdmsPlugin.getDisplay();
IImageLoader adtLoader = AdtPlugin.getImageLoader();
if (mDeviceImage == null) { if (mDeviceImage == null) {
mDeviceImage = ImageHelper.loadImage(loader, display, mDeviceImage = ImageHelper.loadImage(ddmsLoader, display,
"device.png", //$NON-NLS-1$ "device.png", //$NON-NLS-1$
ICON_WIDTH, ICON_WIDTH, ICON_WIDTH, ICON_WIDTH,
display.getSystemColor(SWT.COLOR_RED)); display.getSystemColor(SWT.COLOR_RED));
} }
if (mEmulatorImage == null) { if (mEmulatorImage == null) {
mEmulatorImage = ImageHelper.loadImage(loader, display, mEmulatorImage = ImageHelper.loadImage(ddmsLoader, display,
"emulator.png", ICON_WIDTH, ICON_WIDTH, //$NON-NLS-1$ "emulator.png", ICON_WIDTH, ICON_WIDTH, //$NON-NLS-1$
display.getSystemColor(SWT.COLOR_BLUE)); display.getSystemColor(SWT.COLOR_BLUE));
} }
if (mMatchImage == null) {
mMatchImage = ImageHelper.loadImage(adtLoader, display,
"match.png", //$NON-NLS-1$
ICON_WIDTH, ICON_WIDTH,
display.getSystemColor(SWT.COLOR_GREEN));
}
if (mNoMatchImage == null) {
mNoMatchImage = ImageHelper.loadImage(adtLoader, display,
"error.png", //$NON-NLS-1$
ICON_WIDTH, ICON_WIDTH,
display.getSystemColor(SWT.COLOR_RED));
}
if (mWarningImage == null) {
mWarningImage = ImageHelper.loadImage(adtLoader, display,
"warning.png", //$NON-NLS-1$
ICON_WIDTH, ICON_WIDTH,
display.getSystemColor(SWT.COLOR_YELLOW));
}
} }
@@ -438,7 +533,7 @@ public class DeviceChooserDialog extends Dialog implements IDeviceChangeListener
* @param device the device that was updated. * @param device the device that was updated.
* @param changeMask the mask indicating what changed. * @param changeMask the mask indicating what changed.
* *
* @see IDeviceChangeListener#deviceChanged(Device) * @see IDeviceChangeListener#deviceChanged(Device, int)
*/ */
public void deviceChanged(final Device device, int changeMask) { public void deviceChanged(final Device device, int changeMask) {
if ((changeMask & (Device.CHANGE_STATE | Device.CHANGE_BUILD_INFO)) != 0) { if ((changeMask & (Device.CHANGE_STATE | Device.CHANGE_BUILD_INFO)) != 0) {

View File

@@ -80,9 +80,8 @@ public class LaunchConfigDelegate extends LaunchConfigurationDelegate {
*/ */
public static final String ATTR_ACTIVITY = AdtPlugin.PLUGIN_ID + ".activity"; //$NON-NLS-1$ public static final String ATTR_ACTIVITY = AdtPlugin.PLUGIN_ID + ".activity"; //$NON-NLS-1$
/** Skin to be used to launch the emulator */ public static final String ATTR_VM_NAME = AdtPlugin.PLUGIN_ID + ".vm"; //$NON-NLS-1$
public static final String ATTR_SKIN = AdtPlugin.PLUGIN_ID + ".skin"; //$NON-NLS-1$
public static final String ATTR_SPEED = AdtPlugin.PLUGIN_ID + ".speed"; //$NON-NLS-1$ public static final String ATTR_SPEED = AdtPlugin.PLUGIN_ID + ".speed"; //$NON-NLS-1$
/** /**
@@ -317,6 +316,10 @@ public class LaunchConfigDelegate extends LaunchConfigurationDelegate {
1 /* code, unused */, "Can't find the project!", null /* exception */)); 1 /* code, unused */, "Can't find the project!", null /* exception */));
} }
/**
* {@inheritDoc}
* @throws CoreException
*/
@Override @Override
public ILaunch getLaunch(ILaunchConfiguration configuration, String mode) public ILaunch getLaunch(ILaunchConfiguration configuration, String mode)
throws CoreException { throws CoreException {
@@ -406,8 +409,6 @@ public class LaunchConfigDelegate extends LaunchConfigurationDelegate {
/** /**
* Returns the name of the activity. * Returns the name of the activity.
* @param configuration
* @return
*/ */
private String getActivityName(ILaunchConfiguration configuration) { private String getActivityName(ILaunchConfiguration configuration) {
String empty = ""; String empty = "";

View File

@@ -22,7 +22,9 @@ import com.android.ide.eclipse.adt.sdk.Sdk;
import com.android.ide.eclipse.common.project.BaseProjectHelper; import com.android.ide.eclipse.common.project.BaseProjectHelper;
import com.android.ide.eclipse.ddms.DdmsPlugin; import com.android.ide.eclipse.ddms.DdmsPlugin;
import com.android.sdklib.IAndroidTarget; import com.android.sdklib.IAndroidTarget;
import com.android.sdklib.SdkConstants; import com.android.sdklib.vm.VmManager;
import com.android.sdklib.vm.VmManager.VmInfo;
import com.android.sdkuilib.VmSelector;
import org.eclipse.core.resources.IProject; import org.eclipse.core.resources.IProject;
import org.eclipse.core.runtime.CoreException; import org.eclipse.core.runtime.CoreException;
@@ -70,6 +72,11 @@ public class EmulatorConfigTab extends AbstractLaunchConfigurationTab {
{ "UMTS", "umts" }, //$NON-NLS-2$ { "UMTS", "umts" }, //$NON-NLS-2$
}; };
private Button mAutoTargetButton;
private Button mManualTargetButton;
private VmSelector mPreferredVmSelector;
private Combo mSpeedCombo; private Combo mSpeedCombo;
private Combo mDelayCombo; private Combo mDelayCombo;
@@ -78,18 +85,10 @@ public class EmulatorConfigTab extends AbstractLaunchConfigurationTab {
private Text mEmulatorCLOptions; private Text mEmulatorCLOptions;
private Combo mSkinCombo;
private Button mAutoTargetButton;
private Button mManualTargetButton;
private Button mWipeDataButton; private Button mWipeDataButton;
private Button mNoBootAnimButton; private Button mNoBootAnimButton;
private IAndroidTarget mTarget;
/** /**
* Returns the emulator ready speed option value. * Returns the emulator ready speed option value.
* @param value The index of the combo selection. * @param value The index of the combo selection.
@@ -147,6 +146,11 @@ public class EmulatorConfigTab extends AbstractLaunchConfigurationTab {
targetModeGroup.setLayout(layout); targetModeGroup.setLayout(layout);
targetModeGroup.setFont(font); targetModeGroup.setFont(font);
mManualTargetButton = new Button(targetModeGroup, SWT.RADIO);
mManualTargetButton.setText("Manual");
// Since there are only 2 radio buttons, we can put a listener on only one (they
// are both called on select and unselect event.
// add the radio button // add the radio button
mAutoTargetButton = new Button(targetModeGroup, SWT.RADIO); mAutoTargetButton = new Button(targetModeGroup, SWT.RADIO);
mAutoTargetButton.setText("Automatic"); mAutoTargetButton.setText("Automatic");
@@ -159,11 +163,16 @@ public class EmulatorConfigTab extends AbstractLaunchConfigurationTab {
} }
}); });
mManualTargetButton = new Button(targetModeGroup, SWT.RADIO); new Label(targetModeGroup, SWT.NONE).setText("Preferred VM");
mManualTargetButton.setText("Manual"); VmInfo[] vms = new VmInfo[0];
// Since there are only 2 radio buttons, we can put a listener on only mPreferredVmSelector = new VmSelector(targetModeGroup, vms,
// one (they false /*allowMultipleSelection*/);
// are both called on select and unselect event. mPreferredVmSelector.setSelectionListener(new SelectionAdapter() {
@Override
public void widgetSelected(SelectionEvent e) {
updateLaunchConfigurationDialog();
}
});
// emulator size // emulator size
mEmulatorOptionsGroup = new Group(topComp, SWT.NONE); mEmulatorOptionsGroup = new Group(topComp, SWT.NONE);
@@ -174,17 +183,6 @@ public class EmulatorConfigTab extends AbstractLaunchConfigurationTab {
mEmulatorOptionsGroup.setLayout(layout); mEmulatorOptionsGroup.setLayout(layout);
mEmulatorOptionsGroup.setFont(font); mEmulatorOptionsGroup.setFont(font);
new Label(mEmulatorOptionsGroup, SWT.NONE).setText("Screen Size:");
mSkinCombo = new Combo(mEmulatorOptionsGroup, SWT.READ_ONLY);
mSkinCombo.addSelectionListener(new SelectionAdapter() {
// called when selection changes
@Override
public void widgetSelected(SelectionEvent e) {
updateLaunchConfigurationDialog();
}
});
// network options // network options
new Label(mEmulatorOptionsGroup, SWT.NONE).setText("Network Speed:"); new Label(mEmulatorOptionsGroup, SWT.NONE).setText("Network Speed:");
@@ -279,8 +277,9 @@ public class EmulatorConfigTab extends AbstractLaunchConfigurationTab {
* @see org.eclipse.debug.ui.ILaunchConfigurationTab#initializeFrom(org.eclipse.debug.core.ILaunchConfiguration) * @see org.eclipse.debug.ui.ILaunchConfigurationTab#initializeFrom(org.eclipse.debug.core.ILaunchConfiguration)
*/ */
public void initializeFrom(ILaunchConfiguration configuration) { public void initializeFrom(ILaunchConfiguration configuration) {
boolean value = LaunchConfigDelegate.DEFAULT_TARGET_MODE; // true == VmManager vmManager = Sdk.getCurrent().getVmManager();
// automatic
boolean value = LaunchConfigDelegate.DEFAULT_TARGET_MODE; // true == automatic
try { try {
value = configuration.getAttribute(LaunchConfigDelegate.ATTR_TARGET_MODE, value); value = configuration.getAttribute(LaunchConfigDelegate.ATTR_TARGET_MODE, value);
} catch (CoreException e) { } catch (CoreException e) {
@@ -290,11 +289,12 @@ public class EmulatorConfigTab extends AbstractLaunchConfigurationTab {
mManualTargetButton.setSelection(!value); mManualTargetButton.setSelection(!value);
// look for the project name to get its target. // look for the project name to get its target.
String projectName = ""; String stringValue = "";
try { try {
projectName = configuration.getAttribute( stringValue = configuration.getAttribute(
IJavaLaunchConfigurationConstants.ATTR_PROJECT_NAME, projectName); IJavaLaunchConfigurationConstants.ATTR_PROJECT_NAME, stringValue);
} catch (CoreException ce) { } catch (CoreException ce) {
// let's not do anything here, we'll use the default value
} }
IProject project = null; IProject project = null;
@@ -304,25 +304,41 @@ public class EmulatorConfigTab extends AbstractLaunchConfigurationTab {
if (projects != null) { if (projects != null) {
// look for the project whose name we read from the configuration. // look for the project whose name we read from the configuration.
for (IJavaProject p : projects) { for (IJavaProject p : projects) {
if (p.getElementName().equals(projectName)) { if (p.getElementName().equals(stringValue)) {
project = p.getProject(); project = p.getProject();
break; break;
} }
} }
} }
mSkinCombo.removeAll(); // update the VM list
VmInfo[] vms = null;
if (vmManager != null) {
vms = vmManager.getVms();
}
IAndroidTarget projectTarget = null;
if (project != null) { if (project != null) {
mTarget = Sdk.getCurrent().getTarget(project); projectTarget = Sdk.getCurrent().getTarget(project);
if (mTarget != null) { } else {
String[] skins = mTarget.getSkins(); vms = null; // no project? we don't want to display any "compatible" VMs.
if (skins != null) { }
for (String skin : skins) {
mSkinCombo.add(skin); mPreferredVmSelector.setVms(vms, projectTarget);
}
mSkinCombo.pack(); stringValue = "";
} try {
} stringValue = configuration.getAttribute(LaunchConfigDelegate.ATTR_VM_NAME,
stringValue);
} catch (CoreException e) {
// let's not do anything here, we'll use the default value
}
if (stringValue != null && stringValue.length() > 0 && vmManager != null) {
VmInfo targetVm = vmManager.getVm(stringValue);
mPreferredVmSelector.setSelection(targetVm);
} else {
mPreferredVmSelector.setSelection(null);
} }
value = LaunchConfigDelegate.DEFAULT_WIPE_DATA; value = LaunchConfigDelegate.DEFAULT_WIPE_DATA;
@@ -342,23 +358,6 @@ public class EmulatorConfigTab extends AbstractLaunchConfigurationTab {
mNoBootAnimButton.setSelection(value); mNoBootAnimButton.setSelection(value);
int index = -1; int index = -1;
try {
String skin = configuration.getAttribute(LaunchConfigDelegate.ATTR_SKIN, (String)null);
if (skin == null) {
skin = SdkConstants.SKIN_DEFAULT;
}
index = getSkinIndex(skin);
} catch (CoreException e) {
index = getSkinIndex(SdkConstants.SKIN_DEFAULT);
}
if (index == -1) {
mSkinCombo.select(0);
updateLaunchConfigurationDialog();
} else {
mSkinCombo.select(index);
}
index = LaunchConfigDelegate.DEFAULT_SPEED; index = LaunchConfigDelegate.DEFAULT_SPEED;
try { try {
@@ -405,8 +404,12 @@ public class EmulatorConfigTab extends AbstractLaunchConfigurationTab {
public void performApply(ILaunchConfigurationWorkingCopy configuration) { public void performApply(ILaunchConfigurationWorkingCopy configuration) {
configuration.setAttribute(LaunchConfigDelegate.ATTR_TARGET_MODE, configuration.setAttribute(LaunchConfigDelegate.ATTR_TARGET_MODE,
mAutoTargetButton.getSelection()); mAutoTargetButton.getSelection());
configuration.setAttribute(LaunchConfigDelegate.ATTR_SKIN, VmInfo vm = mPreferredVmSelector.getFirstSelected();
getSkinNameByIndex(mSkinCombo.getSelectionIndex())); if (vm != null) {
configuration.setAttribute(LaunchConfigDelegate.ATTR_VM_NAME, vm.getName());
} else {
configuration.setAttribute(LaunchConfigDelegate.ATTR_VM_NAME, (String)null);
}
configuration.setAttribute(LaunchConfigDelegate.ATTR_SPEED, configuration.setAttribute(LaunchConfigDelegate.ATTR_SPEED,
mSpeedCombo.getSelectionIndex()); mSpeedCombo.getSelectionIndex());
configuration.setAttribute(LaunchConfigDelegate.ATTR_DELAY, configuration.setAttribute(LaunchConfigDelegate.ATTR_DELAY,
@@ -425,8 +428,6 @@ public class EmulatorConfigTab extends AbstractLaunchConfigurationTab {
public void setDefaults(ILaunchConfigurationWorkingCopy configuration) { public void setDefaults(ILaunchConfigurationWorkingCopy configuration) {
configuration.setAttribute(LaunchConfigDelegate.ATTR_TARGET_MODE, configuration.setAttribute(LaunchConfigDelegate.ATTR_TARGET_MODE,
LaunchConfigDelegate.DEFAULT_TARGET_MODE); LaunchConfigDelegate.DEFAULT_TARGET_MODE);
configuration.setAttribute(LaunchConfigDelegate.ATTR_SKIN,
SdkConstants.SKIN_DEFAULT);
configuration.setAttribute(LaunchConfigDelegate.ATTR_SPEED, configuration.setAttribute(LaunchConfigDelegate.ATTR_SPEED,
LaunchConfigDelegate.DEFAULT_SPEED); LaunchConfigDelegate.DEFAULT_SPEED);
configuration.setAttribute(LaunchConfigDelegate.ATTR_DELAY, configuration.setAttribute(LaunchConfigDelegate.ATTR_DELAY,
@@ -440,33 +441,4 @@ public class EmulatorConfigTab extends AbstractLaunchConfigurationTab {
String emuOptions = store.getString(AdtPlugin.PREFS_EMU_OPTIONS); String emuOptions = store.getString(AdtPlugin.PREFS_EMU_OPTIONS);
configuration.setAttribute(LaunchConfigDelegate.ATTR_COMMANDLINE, emuOptions); configuration.setAttribute(LaunchConfigDelegate.ATTR_COMMANDLINE, emuOptions);
} }
private String getSkinNameByIndex(int index) {
if (mTarget != null && index > 0) {
String[] skins = mTarget.getSkins();
if (skins != null && index < skins.length) {
return skins[index];
}
}
return null;
}
private int getSkinIndex(String name) {
if (mTarget != null) {
String[] skins = mTarget.getSkins();
if (skins != null) {
int index = 0;
for (String skin : skins) {
if (skin.equalsIgnoreCase(name)) {
return index;
}
index++;
}
}
}
return -1;
}
} }

View File

@@ -398,11 +398,13 @@ public class MainLaunchConfigTab extends AbstractLaunchConfigurationTab {
config.setMappedResources(resources); config.setMappedResources(resources);
} }
/** Loads the ui with the activities of the specified project, and store the /**
* activities in <code>mActivities</code> * Loads the ui with the activities of the specified project, and stores the
* activities in <code>mActivities</code>.
* <p/>
* First activity is selected by default if present. * First activity is selected by default if present.
* @param project The project to load the activities from *
* @return The array of activities or null if none could be found. * @param project The project to load the activities from.
*/ */
private void loadActivities(IProject project) { private void loadActivities(IProject project) {
if (project != null) { if (project != null) {

View File

@@ -199,7 +199,7 @@ public class BuildPreferencePage extends FieldEditorPreferencePage implements
*/ */
private void handleException(Throwable t) { private void handleException(Throwable t) {
String msg = t.getMessage(); String msg = t.getMessage();
if (t == null) { if (msg == null) {
Throwable cause = t.getCause(); Throwable cause = t.getCause();
if (cause != null) { if (cause != null) {
handleException(cause); handleException(cause);

View File

@@ -18,6 +18,7 @@ package com.android.ide.eclipse.adt.project;
import com.android.ide.eclipse.adt.AdtPlugin; import com.android.ide.eclipse.adt.AdtPlugin;
import com.android.ide.eclipse.common.AndroidConstants; import com.android.ide.eclipse.common.AndroidConstants;
import com.android.sdklib.SdkConstants;
import org.eclipse.core.resources.IFolder; import org.eclipse.core.resources.IFolder;
import org.eclipse.core.resources.IProject; import org.eclipse.core.resources.IProject;
@@ -53,13 +54,13 @@ public class FolderDecorator implements ILightweightLabelDecorator {
// check the folder is directly under the project. // check the folder is directly under the project.
if (folder.getParent().getType() == IResource.PROJECT) { if (folder.getParent().getType() == IResource.PROJECT) {
String name = folder.getName(); String name = folder.getName();
if (name.equals(AndroidConstants.FD_ASSETS)) { if (name.equals(SdkConstants.FD_ASSETS)) {
decorate(decoration, " [Android assets]"); decorate(decoration, " [Android assets]");
decoration.addOverlay(mDescriptor, IDecoration.TOP_RIGHT); decoration.addOverlay(mDescriptor, IDecoration.TOP_RIGHT);
} else if (name.equals(AndroidConstants.FD_RESOURCES)) { } else if (name.equals(SdkConstants.FD_RESOURCES)) {
decorate(decoration, " [Android resources]"); decorate(decoration, " [Android resources]");
decoration.addOverlay(mDescriptor, IDecoration.TOP_RIGHT); decoration.addOverlay(mDescriptor, IDecoration.TOP_RIGHT);
} else if (name.equals(AndroidConstants.FD_NATIVE_LIBS)) { } else if (name.equals(SdkConstants.FD_NATIVE_LIBS)) {
decorate(decoration, " [Native Libraries]"); decorate(decoration, " [Native Libraries]");
} }
} }

View File

@@ -493,7 +493,7 @@ public final class ExportWizard extends Wizard implements IExportWizard {
} }
// no more cause and still no message. display the first exception. // no more cause and still no message. display the first exception.
return cause.getClass().getCanonicalName(); return t.getClass().getCanonicalName();
} }
return message; return message;

View File

@@ -256,7 +256,6 @@ final class ProjectCheckPage extends ExportWizardPage {
/** /**
* Checks the parameters for correctness, and update the error message and buttons. * Checks the parameters for correctness, and update the error message and buttons.
* @return the current IProject of this launch config.
*/ */
private void handleProjectNameChange() { private void handleProjectNameChange() {
setPageComplete(false); setPageComplete(false);

View File

@@ -28,8 +28,12 @@ import org.eclipse.core.resources.IProject;
import org.eclipse.core.resources.IResource; import org.eclipse.core.resources.IResource;
import org.eclipse.core.runtime.CoreException; import org.eclipse.core.runtime.CoreException;
import org.eclipse.core.runtime.IPath; import org.eclipse.core.runtime.IPath;
import org.eclipse.core.runtime.IProgressMonitor;
import org.eclipse.core.runtime.IStatus;
import org.eclipse.core.runtime.NullProgressMonitor; import org.eclipse.core.runtime.NullProgressMonitor;
import org.eclipse.core.runtime.Path; import org.eclipse.core.runtime.Path;
import org.eclipse.core.runtime.Status;
import org.eclipse.core.runtime.jobs.Job;
import org.eclipse.jdt.core.ClasspathContainerInitializer; import org.eclipse.jdt.core.ClasspathContainerInitializer;
import org.eclipse.jdt.core.IAccessRule; import org.eclipse.jdt.core.IAccessRule;
import org.eclipse.jdt.core.IClasspathAttribute; import org.eclipse.jdt.core.IClasspathAttribute;
@@ -125,7 +129,7 @@ public class AndroidClasspathContainerInitializer extends ClasspathContainerInit
*/ */
private static IClasspathContainer allocateAndroidContainer(String containerId, private static IClasspathContainer allocateAndroidContainer(String containerId,
IJavaProject javaProject) { IJavaProject javaProject) {
IProject iProject = javaProject.getProject(); final IProject iProject = javaProject.getProject();
// remove potential MARKER_TARGETs. // remove potential MARKER_TARGETs.
try { try {
@@ -139,7 +143,9 @@ public class AndroidClasspathContainerInitializer extends ClasspathContainerInit
} }
// first we check if the SDK has been loaded // First we check if the SDK has been loaded.
// By passing the javaProject to getSdkLoadStatus(), we ensure that, should the SDK
// not be loaded yet, the classpath container will be resolved again once the SDK is loaded.
boolean sdkIsLoaded = AdtPlugin.getDefault().getSdkLoadStatus(javaProject) == boolean sdkIsLoaded = AdtPlugin.getDefault().getSdkLoadStatus(javaProject) ==
LoadStatus.LOADED; LoadStatus.LOADED;
@@ -172,8 +178,14 @@ public class AndroidClasspathContainerInitializer extends ClasspathContainerInit
String message = null; String message = null;
boolean outputToConsole = true; boolean outputToConsole = true;
if (hashString == null || hashString.length() == 0) { if (hashString == null || hashString.length() == 0) {
message = String.format( // if there is no hash string we only show this if the SDK is loaded.
"Project has no target set. Edit the project properties to set one."); // For a project opened at start-up with no target, this would be displayed twice,
// once when the project is opened, and once after the SDK has finished loading.
// By testing the sdk is loaded, we only show this once in the console.
if (sdkIsLoaded) {
message = String.format(
"Project has no target set. Edit the project properties to set one.");
}
} else if (sdkIsLoaded) { } else if (sdkIsLoaded) {
message = String.format( message = String.format(
"Unable to resolve target '%s'", hashString); "Unable to resolve target '%s'", hashString);
@@ -187,23 +199,41 @@ public class AndroidClasspathContainerInitializer extends ClasspathContainerInit
// and it's expected. (we do keep the error marker though). // and it's expected. (we do keep the error marker though).
outputToConsole = false; outputToConsole = false;
} }
if (message != null) {
// log the error and put the marker on the project if we can.
if (outputToConsole) {
AdtPlugin.printBuildToConsole(AdtConstants.BUILD_ALWAYS, iProject, message);
}
try {
BaseProjectHelper.addMarker(iProject, AdtConstants.MARKER_TARGET, message, -1,
IMarker.SEVERITY_ERROR, IMarker.PRIORITY_HIGH);
} catch (CoreException e) {
// In some cases, the workspace may be locked for modification when we pass here.
// We schedule a new job to put the marker after.
final String fmessage = message;
Job markerJob = new Job("Android SDK: Resolving error markers") {
@SuppressWarnings("unchecked")
@Override
protected IStatus run(IProgressMonitor monitor) {
try {
BaseProjectHelper.addMarker(iProject, AdtConstants.MARKER_TARGET,
fmessage, -1, IMarker.SEVERITY_ERROR, IMarker.PRIORITY_HIGH);
} catch (CoreException e2) {
return e2.getStatus();
}
// log the error and put the marker on the project return Status.OK_STATUS;
if (outputToConsole) { }
AdtPlugin.printBuildToConsole(AdtConstants.BUILD_ALWAYS, iProject, message); };
// build jobs are run after other interactive jobs
markerJob.setPriority(Job.BUILD);
markerJob.schedule();
}
} }
IMarker marker = BaseProjectHelper.addMarker(iProject, AdtConstants.MARKER_TARGET, message,
IMarker.SEVERITY_ERROR);
// add a marker priority as this is an more important error than the error that will
// spring from the lack of library
try {
marker.setAttribute(IMarker.PRIORITY, IMarker.PRIORITY_HIGH);
} catch (CoreException e) {
// just log the error
AdtPlugin.log(e, "Error changing target marker priority.");
}
// return a dummy container to replace the one we may have had before. // return a dummy container to replace the one we may have had before.
return new IClasspathContainer() { return new IClasspathContainer() {
public IClasspathEntry[] getClasspathEntries() { public IClasspathEntry[] getClasspathEntries() {

Some files were not shown because too many files have changed in this diff Show More