How to get the 433 Mhz RF Modules to work with the attiny85-10pu ?

I am currently a high school student enrolled in an engineering class that focuses the whole year on one project. For this part of the year I have been working with Arduino and the RF Modules. I have successfully sent and received messages between two Arduino boards (using virtual wire library and help from YouTube) but now need to shrink my project. I found an attiny85 10pu microcontroller that would be a perfect size for my project.
I do not need the microcontroller to receive and print characters. All that is needed is the microcontroller go through a series of functions (blinking lights, noise, etc.) when it has received a certain signal from the transmitting module. I had tried using my programs that worked on the Arduino UNO (removed all serial commands) but it was unsuccessful.
I am unsure of the limitations the Attiny has with programming commands. Any help pointing me in the right direction would be appreciated, I have only had about 3 weeks of experience with Arduino so I have a limited knowledge but I am willing to learn.

Suggestion, when working with the tiny85, code libraries from Trinket and from Diguspark are your friends. I assume you have ArduinoUSP working, you may not want to use their bootloaders... If not, be aware that the digispark normally runs at 16.5 MHz on USB and 16MHz on Freeboot.
http://digistump.com/wiki/digispark/tricks

http://174.129.210.187/board/index.php?topic=879.0

Ray

TWeiss33, can you upload your code you were using on the Arduino Uno? We'll see if there is anything ATTiny85 unfriendly about it :slight_smile:

It should be possible to make that work.
The VirtualWire is made to work also on a ATtiny85.
The Trinket is a ATtiny85.

What about the clock speeds ? You have to use the same speed for the wireless signal.

Are you able to program the ATtiny85 ? Can you make it blink lights and so ?

@mrburnette- In the specifications the max speed it will run at is 10 Mhz. below i have gone through something i noticed when uploading a simple blinking light sketch. Will this library that is supposed to run at 8Mhz work for my chip? Sorry for the most likely stupid question, but I am brand new to this stuff.
@DorianMcCarthy I have the program i am trying to upload below. The core of the program is from Kevin Darrah on youtube. He posted a video about using RF modules and it has been easier for me to use and completely understand his program up to this point (in comparison to virtual wire). I have other variations to this program but all i need for my class so far is to get a simple beep after transmitting a signal.
@Caltoa I have also noticed that the timing changes when I select 8Mhz over 1Mhz on the board selection in Arduino. The maximum Mhz the Attiny can run at is 10Mhz, but the timing seems to be elongated when I choose the 8 Mhz option rather than the 1 Mhz. i noticed the timing difference when i uploaded a simple blink program. What was supposed to be 1 second of LED on was more like 12 seconds on. I'm guessing this clock speed affects the rate at which the micro-controller can process the signals coming from the RF module?

Thank you for your help guys!

Tyler

int i, good, k;
byte data_in;
void setup(){
attachInterrupt(1,data_incoming,CHANGE);
pinMode(1, INPUT);
pinMode(0, OUTPUT);
}

void loop(){
}

void data_incoming(){

for(i=0; i<100; i++){
delayMicroseconds(20);
good=1;
if(digitalRead(3)==LOW){
good=0;
i=100;
}
}

if(good==1){
detachInterrupt(1);
while(1){
if(digitalRead(1)==LOW){
delayMicroseconds(750);

for(i=0; i<8; i++){
if(digitalRead(1)==HIGH)
bitWrite(data_in, i, 1);
else
bitWrite(data_in, i, 0);
delayMicroseconds(1000);
}//for
if(data_in=='t'){
digitalWrite(1, HIGH);
delay(1000);
digitalWrite(1, LOW);
}
break;
}
}
}
attachInterrupt(1,data_incoming,CHANGE);
}

@mrburnette- In the specifications the max speed it will run at is 10 Mhz. below i have gone through something i noticed when uploading a simple blinking light sketch. Will this library that is supposed to run at 8Mhz work for my chip? Sorry for the most likely stupid question, but I am brand new to this stuff.

Trinket libraries are 8 & 16 MHz.

Digispark:
http://digistump.com/wiki/digispark/tricks

> but I am brand new to this stuff.

Opinion: these "tiny" implementations are hacks and not core Arduino. It is nice that Arduino can be applied to a large number of AVR chips, but this is really an advanced use.

Ray