 	uint8_t id;
 } bmp180_regs;
 
+struct measure_data
+{
+	int32_t pressure;
+	int32_t temperature;
+	float lux;
+};
+
+// init RF24 class
+RF24 radio(CE_PIN, CS_PIN);
+// adress width (in bytes)
+#define RF24_ADDR_WIDTH 4
+// default adresses for base station and slave
+uint16_t adresses[][RF24_ADDR_WIDTH] = {0x0666, 0x7777};
+
 void setup()
 {
-	Serial.begin(115200);
+	// init i2c bus
 	Wire.begin();
+	// init BMP180 pressure sensor and read calibration table
 	bmp180_init();
 	bmp180_read_calibration();
+	// init radio
+	radio.begin();
+	radio.setChannel(127);
+	radio.setAddressWidth(RF24_ADDR_WIDTH);
+	radio.setPALevel(RF24_PA_MAX);
+	#if DEBUG
+	Serial.begin(115200);
 	Serial.println(F("BMP180 inited"));
+	#endif
 }
 
 void loop()
 {
 	uint8_t oss = 0;
-	long int pressure;
-	long int temp;
 	uint16_t lux;
-	float lux_h;
-
-	pressure = bmp180_get_pressure(oss);
-	Serial.print(F("Pressure: "));
-	Serial.print(pressure);
-	Serial.println(F(" Pa"));
-	delay(1000);
-
-	temp = bmp180_get_temp();
-	Serial.print(F("Temp: "));
-	Serial.println(temp);
-	delay(1000);
-
+	struct measure_data measured;
+
+	measured.pressure = bmp180_get_pressure(oss);
+	measured.temperature = bmp180_get_temp();
+	/*
 	lux = bh1750_meas_Lmode();
 	Serial.print(F("Ambient light LR: "));
 	Serial.println(lux);

	bmp180_regs.id = bmp180_read8(BMP180_REG_ADDR_ID);
	if (bmp180_regs.id != 0x55)
	{
		Serial.println(F("Not BMP180 device ID !!!"));
		Serial.println(bmp180_regs.id);
		return;
	}
	bmp180_regs.ctrl = bmp180_read8(BMP180_REG_ADDR_CTRL_MEAS);

#include <SPI.h>
#include <nRF24L01.h>
#include <RF24.h>
#include <RF24_config.h>
#include <Wire.h>
// BMP180 read/write i2c bus addres
#define BMP180_READ_ADDR 0xF7
