Skip to content

Commit

Permalink
change file paths for doxygen
Browse files Browse the repository at this point in the history
  • Loading branch information
amaxilat committed May 18, 2012
1 parent 7b531b6 commit fac92a5
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 92 deletions.
2 changes: 1 addition & 1 deletion Doxyfile
Original file line number Diff line number Diff line change
Expand Up @@ -581,7 +581,7 @@ WARN_LOGFILE =
# directories like "/usr/src/myproject". Separate the files or directories
# with spaces.

INPUT = iSenseApps
INPUT = iSense TelosB

# This tag can be used to specify the character encoding of the source files
# that doxygen parses. Internally doxygen uses the UTF-8 encoding, which is
Expand Down
3 changes: 0 additions & 3 deletions TelosB/collector/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,6 @@ msp430:
@make -f Makefile.msp430
@echo "----- Done ------"

push:
scp bin/msp430/TelosBCollectorApp.ihex testbedruntime@gold.cti.gr:/home/testbedruntime/dataCollector/

clean: clean-msp430

clean-msp430:
Expand Down
4 changes: 2 additions & 2 deletions TelosB/collector/Makefile.properties
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ export ISENSE_PATH=/home/amaxilatis/sdks/iSenseTelosb
#-- TODO: Add your Source (.c/.cpp) files here
#------------------------------------------------------------------------------

TARGET = TelosBCollectorApp
TARGET = collector
SRC_PATH = src

BLDSRCS = TelosBCollectorApp.cpp
BLDSRCS = collector.cpp
4 changes: 2 additions & 2 deletions iSense/collector/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ all: isense
# all: tinyos-tossim
# all: tinyos-micaz

export APP_SRC=sensor_test.cpp
export BIN_OUT=sensor_test
export APP_SRC=collector.cpp
export BIN_OUT=collector

include ../Makefile
86 changes: 2 additions & 84 deletions iSense/collector/collector.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ typedef wiselib::OSMODEL Os;
typedef wiselib::Echo<Os, Os::TxRadio, Os::Timer, Os::Debug> nb_t;

//MESSAGE_TYPES
#include "../../../messages/collector_message_new.h"
#include "../../messages/collector_message_new.h"
typedef wiselib::CollectorMsg<Os, Os::TxRadio> collectorMsg_t;
typedef wiselib::BroadcastMsg<Os, Os::TxRadio> broadcastMsg_t;

Expand Down Expand Up @@ -47,7 +47,6 @@ typedef Os::TxRadio::block_data_t block_data_t;
class Application
:
public isense::SensorHandler,
//public isense::BufferDataHandler,
public isense::Int8DataHandler,
public isense::Uint32DataHandler {
public:
Expand Down Expand Up @@ -192,28 +191,10 @@ public isense::Uint32DataHandler {
int16 temp = em_->temp_sensor()->temperature();
if (temp < 100) {
send_reading(0xffff, "temperature", temp);
// collectorMsg_t mess;
// mess.set_source(radio_->id());
// char temp_string[30];
// sprintf(temp_string, "%s", "temperature");
// mess.set_capability(temp_string);
// sprintf(temp_string, "%d", temp);
// mess.set_value(temp_string);
// // debug_->debug("Contains temp %s -> %s %x", mess.capability(), mess.value(), mygateway_);
// radio_->send(mygateway_, mess.length(), (uint8*) & mess);
}
uint32 lux = em_->light_sensor()->luminance();
if (lux < 20000) {
send_reading(0xffff, "light", lux);
// collectorMsg_t mess;
// mess.set_source(radio_->id());
// char temp_string[30];
// sprintf(temp_string, "%s", "light");
// mess.set_capability(temp_string);
// sprintf(temp_string, "%d", lux);
// mess.set_value(temp_string);
// // debug_->debug("Contains temp %s -> %s to %d ", mess.capability(), mess.value(), mess.msg_id());
// radio_->send(mygateway_, mess.length(), (uint8*) & mess);
}

} else {
Expand Down Expand Up @@ -278,38 +259,10 @@ public isense::Uint32DataHandler {
// debug_->debug("pir event");
if (!is_gateway()) {
send_reading(0xffff, "pir", 1);
// collectorMsg_t mess;
// mess.set_source(radio_->id());
// char temp_string[30];
// sprintf(temp_string, "%s", "pir");
// mess.set_capability(temp_string);
// sprintf(temp_string, "%d", 1);
// mess.set_value(temp_string);
// // debug_->debug("Contains temp %s -> %s to %x", mess.capability(), mess.value(), mygateway_);
// radio_->send(mygateway_, mess.length(), (uint8*) & mess);
} else {
// isense::Time event_time = clock_->time();
// debug_->debug("id::%x EM_E 1 %d ", radio_->id(), event_time.sec_ * 1000 + event_time.ms_);
debug_->debug("node::%x pir 1 ", radio_->id());
}
}
//
// /**
// * Handles a new accelerometer event
// * @param acceleration in 3 axis
// */
// virtual void handle_buffer_data(isense::BufferData* data) {
// if (!is_gateway()) {
// collectorMsg_t mess1;
// mess1.set_collector_type_id(collectorMsg_t::ACCELEROMETER);
// // radio_->send(mygateway_, mess1.buffer_size(), (uint8*) & mess1);
// } else {
// debug_->debug("id::%x EM_A 1 ", radio_->id());
// }
//
// //return from continuous mode to threshold mode
// accelerometer_->set_mode(MODE_THRESHOLD);
// }

/**
* Handles a new neighborhood event
Expand All @@ -324,33 +277,13 @@ public isense::Uint32DataHandler {
send_reading(from, "status", 1);

send_reading(from, "lqi", nb_.get_lqi(from));
// collectorMsg_t mess;
// mess.set_source(radio_->id());
// mess.set_target(from);
// char temp_string[30];
// sprintf(temp_string, "%s", "status");
// mess.set_capability(temp_string);
// sprintf(temp_string, "%d", 1);
// mess.set_value(temp_string);
// // debug_->debug("Contains bidi %s -> %s ", mess.capability(), mess.value());
// radio_->send(mygateway_, mess.length(), (uint8*) & mess);
} else {
debug_->debug("node::%x,%x status %d ", radio_->id(), from, 1);

}
} else if ((event == nb_t::LOST_NB_BIDI) || (event == nb_t::DROPPED_NB)) {
if (!is_gateway()) {
send_reading(from, "status", 0);
// collectorMsg_t mess;
// mess.set_source(radio_->id());
// mess.set_target(from);
// char temp_string[30];
// sprintf(temp_string, "%s", "status");
// mess.set_capability(temp_string);
// sprintf(temp_string, "%d", 0);
// mess.set_value(temp_string);
// // debug_->debug("Contains bidi %s -> %s ", mess.capability(), mess.value());
// radio_->send(mygateway_, mess.length(), (uint8*) & mess);
} else {
debug_->debug("node::%x,%x status %d ", radio_->id(), from, 0);
}
Expand All @@ -363,13 +296,6 @@ public isense::Uint32DataHandler {
* @param mess payload buffer
*/
void handle_uart_msg(Os::Uart::size_t len, Os::Uart::block_data_t *mess) {
//if (mess[0] == 9) {
// cm_->led_on();
//} else if (mess[0] == 10) {
// cm_->led_off();
//} else {


node_id_t node;
memcpy(&node, mess, sizeof (node_id_t));
radio_->send(node, len - 2, (uint8*) mess + 2);
Expand All @@ -383,10 +309,6 @@ public isense::Uint32DataHandler {
buffer[bytes_written] = '\0';
debug_->debug("FORWARDING to %x %s", node, buffer);
}
//}



}

/**
Expand All @@ -408,15 +330,13 @@ public isense::Uint32DataHandler {
debug_->debug("case1");
return;
}

if (check_air_quality(src_addr, len, buf)) {
debug_->debug("check_air_quality");
return;
}

check_collector(src_addr, len, buf);
}

}

bool check_led(node_id_t src_addr, Os::TxRadio::size_t len, block_data_t * buf) {
Expand All @@ -432,7 +352,6 @@ public isense::Uint32DataHandler {
return true;
}
}

}
return false;
}
Expand Down Expand Up @@ -483,7 +402,6 @@ public isense::Uint32DataHandler {
} else {
debug_->debug("node::%x,%x %s %s ", mess->source(), mess->target(), mess->capability(), mess->value());
}

}
}

Expand Down Expand Up @@ -525,7 +443,7 @@ public isense::Uint32DataHandler {
case 0xc7a: //0.2
case 0x99ad: //3,1
case 0x8978: //1.1
// case 0x181: //1.1
// case 0x181: //1.1
return true;
default:
return false;
Expand Down

0 comments on commit fac92a5

Please sign in to comment.