Can you use 433mHz transmitter and receiver without the RadioHead library?

Hi,
I have a 433mHz transmitter and receiver and was going to try and connect them up to my microphone sensor to transmit the signal to another arduino wirelessly. I looked online and found that RadioHead is the program to use for it, but the issue is that it runs too slow for it to be used for audio, as it is only sending around 20 packages per second compared to the 100s-1000s that is required for audio. Is there a way to transmit the anaglogue signal of the microphone wirelessly through them that is fast or do I need a different transmitter and receiver?

Tutorial I followed: RF 433MHz Transmitter/Receiver Module With Arduino | Random Nerd Tutorials

Microphone:


The microphone is plugged into A0 and instead of sending Hello World!, I made it send the microphone signal.

The 433 MHz radios in the link are far too slow for audio. Most radios for the unlicensed ISM bands are intended for short data packets and low power transmissions.

Is there a better transmitter and receiver to use for audio?

Not for the Arduino, which is also not suitable for audio. You can buy commercial wireless microphone transmitter/receiver setups.

Its not to transmit the sound data so it blares it out in a speaker but more so as a volume meter to see how loud it is in that place. I was using it with the microphone wired to the arduino and worked fine. Really, I just want it to transmit data at a very high speed.

How much data? Define "very high speed".

Sending a single number that represents the average volume for 0.1 second, a few transmissions per second, would be reasonable.

It is a single number, and the faster the better. I tried it at 20 times a second but it wouldn't pick up a clap as it was running too slow. 100 would be fine but 1000 is preferable

If you want to pick up a clap, have the transmitting Arduino detect the clap, and send notification.

Your ideas are pretty vague at the moment. You need to experiment with the radio and decide what it is capable of doing. Then set up the project to match.

A typical data rate for packet radios used with Arduino is around 20k bytes per second, in small packets. But the 433 MHz TX/RX pairs in the tutorial you linked can't do that.

Then analyze the signal where it originates, on the Arduino, and send summary reports by 443MHz digital radio.

If this is for any kind of ongoing use, you need to obey the strict regulatory requirements for TX duty cycle in that band. I really hope you're not sending 20 packets a second...

Please post your entire sketch, in code tags please. Then we can talk about specifics.

Its more live situation, (this is a simplier version of the project) where you have the microphone detect a clap, which then in turn turns on an LED and then off again when the clap finishes. But as a clap lasts around 1-10ms, 20 times a second only gives max 50ms range. So is it possible to do it with the components or would I need better ones?

Code for receiver:

#include <SPI.h> // Not actualy used but needed to compile
RH_ASK driver;
void setup()
{
   pinMode(13, OUTPUT);
   Serial.begin(115200);  // Debugging only
   if (!driver.init())
        Serial.println("init failed");
}
void loop()
{
   uint8_t buf[3];
   uint8_t buflen = sizeof(buf);
   if (driver.recv(buf, &buflen)) // Non-blocking
   {
     int i;
     // Message with a good checksum received, dump it.
     Serial.print("Message: ");
     Serial.println((char*)buf);         
     digitalWrite(11, buf);
   }
}

Code for Transmitter:

#include <RH_ASK.h>
#include <SPI.h> // Not actually used but needed to compile
RH_ASK driver;
void setup()
{
  pinMode(A0, INPUT);
    Serial.begin(115200);    // Debugging only
    if (!driver.init())
         Serial.println("init failed");
}
void loop()
{   
  int volume = analogRead(A0);
    const char *msg = volume;
    driver.send((uint8_t *)msg, strlen(msg));
    driver.waitPacketSent();
    Serial.println(volume);
}

The circuit is the same as in the tutorial except with the microphone input in A0 and an LED plugged into 11 on the other board

in code tags please, please read the forum guide

The circuit is the same as in the tutorial except

No, post your own schematic. Verbal deviations from a tutorial present too many unknowns.

It's pretty obvious from your recent post that you did not read or else heed the guide...

While you are catching up with that, yes you need to take audio samples a lot more frequently...

It appears that you placed your code in quote tags, vs. code tags. Read the guide, please.

The Arduino would detect the clap. Then, instead of turning on an LED, send a single byte message to the other Arduino. Doable with any Arduino, and those 433 MHz radios.

But using the RadioHead library, it runs the 'sending' function meaning that it is no longer detecting the sound and so only detects sound every 20 times a second not when there is a clap. It has to be a live feed

You are not following the simple rules of the forum, or engaging with replies. I'm putting you on my permanent ignore list.

I was just asking is there a faster rate transmitter and receiver for arduino

That is entirely your mistake. Write different, more sensible code.

The SX1280 2.4Ghz LoRa device will run at around 25Kbytes/sec transferring files\images.

What throughput you would get if packetising audio, and whether you could send audio, I have no idea.

Since its at 2.4Ghz there are no real issues with duty cycle etc, you could transmit continuously.

Thanks for that, I'll have a look into it :slight_smile: