/*
RF02 TX sample for Arduino

in arduino version 022

tested with MLAB modules with ATmega 328 at 16MHz
see RF02 library for a Band and Frequency
*/

//connections RF02:  (TX)
// SDI,  -> RF02   Atmega PB0 Arduino 8  cannot be changed
// SCK,  -> RF02   Atmega PB1 Arduino 9  cannot be changed
// nSEL, -> RF02   Atmega PB2 Arduino 10 cannot be changed
// nIRQ, <- RF02   Atmega PB4 Arduino 12 cannot be changed
// FSK: Pullupto VCC

#include <RF02.h>

void setup() 
{
  Serial.begin(9600);
  Serial.println("\nSTM02 init" );
 
  rf02_prepAll();

  Serial.println("done" );
}

void loop() 
{
  unsigned char _tx_buffer[]="0123456789";
 
  delay(1000);
  
  rf02_txdata( _tx_buffer, sizeof(_tx_buffer));
}