00001 00009 /* 00010 * The contents of this file are subject to the Mozilla Public License 00011 * Version 1.0 (the "License"); you may not use this file except in 00012 * compliance with the License. You may obtain a copy of the License 00013 * at http://www.mozilla.org/MPL/ 00014 * 00015 * Software distributed under the License is distributed on an "AS IS" 00016 * basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See 00017 * the License for the specific language governing rights and 00018 * limitations under the License. 00019 * 00020 * Contributor(s): Mark Falco (falcom@onebox.com) 00021 */ 00022 00023 #ifndef DIRPD_H 00024 #define DIRPD_H 00025 00026 //0xdec0 - sampled value for object to left 00027 #define DIRPD_LEFT_S 0xd000 00028 #define DIRPD_LEFT_E 0xe000 00029 00030 //0xb700 - sampled value for object to right 00031 #define DIRPD_RIGHT_S 0xb000 00032 #define DIRPD_RIGHT_E 0xbfff 00033 00034 //0xffc0 - sampled value for object to center 00035 #define DIRPD_CENTER_S 0xf000 00036 #define DIRPD_CENTER_E 0xffff 00037 00038 //0x8d40 - sampled value for no object 00039 #define DIRPD_NONE_S 0x8000 00040 #define DIRPD_NONE_E 0x8fff 00041 00042 00043 //pass in a value obtained from an active sensor 00044 00045 #define DIRPD_LEFT(araw) (araw >= DIRPD_LEFT_S && araw <= DIRPD_LEFT_E) 00046 #define DIRPD_RIGHT(araw) (araw >= DIRPD_RIGHT_S && araw <= DIRPD_RIGHT_E) 00047 #define DIRPD_CENTER(araw) (araw >= DIRPD_CENTER_S && araw <= DIRPD_CENTER_E) 00048 #define DIRPD_NONE(araw) (araw >= DIRPD_NONE_S && araw <= DIRPD_NONE_E) 00049 00050 00051 #endif //DIRPD_H
brickOS is released under the
Mozilla Public License.
Original code copyright 1998-2002 by the authors. |