X-Git-Url: http://git.droids-corp.org/?p=aversive.git;a=blobdiff_plain;f=projects%2Fmicrob2010%2Fmainboard%2Fstrat_avoid.h;fp=projects%2Fmicrob2010%2Fmainboard%2Fstrat_avoid.h;h=4afe0320bff98737701a549473590cd2e4f8e12d;hp=0000000000000000000000000000000000000000;hb=17aadc4c8c3e60c2b5e6bbba91c8542849addbd7;hpb=f1b54a67a3317295704f25e2a802e5f86646f4d5 diff --git a/projects/microb2010/mainboard/strat_avoid.h b/projects/microb2010/mainboard/strat_avoid.h new file mode 100644 index 0000000..4afe032 --- /dev/null +++ b/projects/microb2010/mainboard/strat_avoid.h @@ -0,0 +1,47 @@ +/* + * Copyright Droids, Microb Technology (2010) + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + * Revision : $Id: strat.c,v 1.6 2009-11-08 17:24:33 zer0 Exp $ + * + * Olivier MATZ + */ + +#ifndef _STRAT_AVOID_H_ +#define _STRAT_AVOID_H_ +#define MAX_CIRCUIT_WPLINE 15 + +struct wp_coord { + uint8_t i:4; + uint8_t j:3; + uint8_t end:1; +}; + +struct wp_line { + uint8_t line_num:4; + uint8_t dir:4; +}; + +int8_t browse_circuits(uint8_t i, uint8_t j, + const struct wp_coord **selected_circuit, + int8_t *selected_face); + +/* harvest on the best circuit */ +uint8_t strat_harvest_circuit(void); + +void test_strat_avoid(void); + +#endif