Blank program for Pi Swarm Robot
Dependencies: Pi_Swarm_Library mbed
main.h@1:37502eb3b70f, 2014-02-02 (annotated)
- Committer:
- jah128
- Date:
- Sun Feb 02 21:18:16 2014 +0000
- Revision:
- 1:37502eb3b70f
- Parent:
- 0:46cd1498a39a
- Child:
- 2:e806b595f9ce
added comms;
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
jah128 | 1:37502eb3b70f | 1 | /* University of York Robot Lab Pi Swarm Robot Library |
jah128 | 1:37502eb3b70f | 2 | * |
jah128 | 1:37502eb3b70f | 3 | * (C) Dr James Hilder, Dept. Electronics & Computer Science, University of York |
jah128 | 1:37502eb3b70f | 4 | * |
jah128 | 1:37502eb3b70f | 5 | * Version 0.4 January 2014 |
jah128 | 1:37502eb3b70f | 6 | * |
jah128 | 1:37502eb3b70f | 7 | * Designed for use with the Pi Swarm Board (enhanced MBED sensor board) v1.1 |
jah128 | 1:37502eb3b70f | 8 | * |
jah128 | 1:37502eb3b70f | 9 | * Based on the original m3pi library, Copyright (c) 2007-2010 cstyles (see copyright notice at end of file) * |
jah128 | 1:37502eb3b70f | 10 | */ |
jah128 | 1:37502eb3b70f | 11 | |
jah128 | 1:37502eb3b70f | 12 | #ifndef MAIN_H |
jah128 | 1:37502eb3b70f | 13 | #define MAIN_H |
jah128 | 1:37502eb3b70f | 14 | |
jah128 | 1:37502eb3b70f | 15 | #include "piswarm.h" |
jah128 | 1:37502eb3b70f | 16 | |
jah128 | 1:37502eb3b70f | 17 | #define SWARM_SIZE 32 |
jah128 | 1:37502eb3b70f | 18 | #define USE_COMMUNICATION_STACK 1 |
jah128 | 1:37502eb3b70f | 19 | #define CALIBRATE_COLOURS 1 |
jah128 | 1:37502eb3b70f | 20 | #define CENTER_LED_BRIGHTNESS 30 |
jah128 | 1:37502eb3b70f | 21 | #define OUTER_LED_BRIGHTNESS 50 |
jah128 | 1:37502eb3b70f | 22 | #define PC_BAUD 115200 |
jah128 | 1:37502eb3b70f | 23 | #define RF_ALLOW_COMMANDS 1 |
jah128 | 1:37502eb3b70f | 24 | #define RF_USE_LEDS 1 |
jah128 | 1:37502eb3b70f | 25 | #define RF_USE_TDMA 1 |
jah128 | 1:37502eb3b70f | 26 | #define RF_TDMA_TIME_PERIOD_US 15625 |
jah128 | 1:37502eb3b70f | 27 | #define PISWARM_DEBUG 1 |
jah128 | 1:37502eb3b70f | 28 | #define RF_DEBUG 1 |
jah128 | 1:37502eb3b70f | 29 | #define RF_VERBOSE 1 |
jah128 | 1:37502eb3b70f | 30 | #define START_RADIO_ON_BOOT 1 |
jah128 | 1:37502eb3b70f | 31 | #define RF_FREQUENCY 435000000 |
jah128 | 1:37502eb3b70f | 32 | #define RF_DATARATE 57600 |
jah128 | 1:37502eb3b70f | 33 | |
jah128 | 1:37502eb3b70f | 34 | void handleUserRFCommand(char * data, char length); |
jah128 | 1:37502eb3b70f | 35 | void handleUserRFCommand(char sender, char broadcast_message, char request_response, char id, char is_command, char function, char * data, char length); |
jah128 | 1:37502eb3b70f | 36 | void handleUserRFResponse(char sender, char broadcast_message, char request_response, char id, char is_command, char function, char * data, char length); |
jah128 | 1:37502eb3b70f | 37 | void processRawRFData(char * rstring, char cCount); |
jah128 | 1:37502eb3b70f | 38 | |
jah128 | 1:37502eb3b70f | 39 | void switch_pressed ( void ); |
jah128 | 1:37502eb3b70f | 40 | |
jah128 | 1:37502eb3b70f | 41 | #endif //MAIN_H |