ATTiny85 2 ATTiny85 using MANCHESTER lib

Hi all,

I am realy stuck now...

I've been working with arduino for quit a wail now, but now i'm stuck on a maybe simple thing. I am no programmer and English is not my native language, so maybe u can see something i don't see. I have never asked anything before, now i have to.

I want 1 "simple" thing....

I have: 2 ATTiny85's at 8 mhz suporting the MANCHESTER library. 1 RFlink transmitter, 434 mhz from Sparkfun. 1 RFlink receiver, 434 mhz from Sparkfun. 2 uno's for proramming as ISP. Arduino 0.22, 0.23, 1.01 and 1.5 IDE (using 0.22 to programm and 1.01 for Bootloader)

I want 1 ATTiny85 with a button on any pin to send throu (MANCHESTER/virtualWire) an "1" or "0" to my transmitter. like: if digitalPin 0 == high send "1" else send "0"

And..

1 ATTiny85 to receive this "1" or "0" and make 1 pin HIGH orLOW. like: if (manchester.receive() == 1) digitalWrite 2,HIGH else if manchester.receive() == 0 digitalWrite 2,LOW

I realy hope someone can point me in the right direction becouse i have read almost all pages about this...

Similar to: http://www.instructables.com/id/Cheap-Wireless-Motion-Sensor-Device/?ALLSTEPS

Ray

THANKS Ray !

Google did not show me this one.
I tried with the uno as transmitter and this did not word but with 2 tiny’s… SUCCES!

I got 1 tiny85 with transmitter

#include <MANCHESTER.h> //include the library to comunicate
#define TxPin 2 //the pin that is used to send data

unsigned int Tdata = 0; //begin the data in 0

void setup()
{
  MANCHESTER.SetTxPin (TxPin); //set the pin of comunication
}

void loop()
{
    Tdata = 50; 
    MANCHESTER.Transmit(Tdata); //transmit the signal
    delay(200);
    Tdata = 0; 
    MANCHESTER.Transmit(Tdata); //transmit the signal
    delay(200);
}

And 1 tiny85 with the receiver

#include <MANCHESTER.h> //include the comunication library
#define RxPin 4 // dubbel checked this pin

void setup()
{
MANCHESTER.SetRxPin(RxPin); //user sets rx pin default 6
MANCHESTER.SetTimeOut(1000); //user sets timeout default blocks
pinMode(0, OUTPUT); 
}

void loop()
{
unsigned int data = MANCHESTER.Receive();
   if(data==50) //match this number with the sensor number
      {
           digitalWrite(0, HIGH); //turn ON a led on pin D0
      } else {
           digitalWrite(0, LOW); //turn OFF a led
      }
}

Blinking leds… :slight_smile:

Blinking leds.... smiley

"I love it when a plan comes together." - John "Hannibal" Smith, The A-Team

Google did not show me this one.

Google is a fickle Momma.

Ray