I've recently started to learn SDR. In order to understand signal processing, and study about modulation,encoding, ... I used my Arduino along with a 433MHz radio frequency transmitter for sending some simple data. On the other hand, I managed to capture those signals via a R820T2 SDR dongle.
I recorded signals with Gnuradio and opened that with Audacity. It seemed to me that the modulation is AM, thus, I added a AM demodulation component to Gnuradio diagram and recorded signals again.
I tried to figure out what encoding is used, and extract binary data from signals. However, I cannot realize the encoding!! the binary code of 0 is 00110000, but recorded signals doesn't represent that!
I'm not sure if I assumed the AM modulation wrongly, or the transmitter uses an especial encoding, or anything else!
I will be grateful if some can give me some hints, or explain what is going on that I cannot make out!
I suspect you need to study the datasheet for whatever transmitter you are using. The Arduino board and the Arduino program has no need to know anything about wireless stuff.
As far as I know the digital modulation is done by software part. If you mean about analog modulation (amplitude modulation for example), yes you are right, that is a part of hardware (transmitter) tasks.
But, I need to know about the digital modulation to decode digital signals to binary.
I still don't understand. Can you post a link to the datasheet for the wireless module you are using with your Arduino.
My own experience has been with the nRF24L01+ modules which use an SPI connection with the Arduino. I believe some of the other modules (HC-12 for example) use a serial connection.
Please check the attached datasheet. It says the the transmitter support ASK and OOK modulation, but, the captured signals don't seem one of those modulation (I already attached a picture of signals in first post).
So you have a radio transmitter and you are trying to use an SDR to decode (or make sense of) the data that an SDR application called 'GNURadio' is receiving ?
srnet:
So you have a radio transmitter and you are trying to use an SDR to decode (or make sense of) the data that an SDR application called 'GNURadio' is receiving ?
I can see a preamble (as expected), followed by what seems to be time based encoding where a 1 is a longer pulse than a 0?
The modules do the ASK/OOK demodulation/modulation for you...you are just seeing the raw binary output once modulation has been dealt with.
Otherwise your receiver would simply be a length of wire...
PS: The GNURadio forum/whoever will probably just be able to give a lot more depth that what anyone here can provide with an audacity packet capture of just a single "0". Do you even mean a 0 or an ASCII 0...like char "0" or bit 0?
Tried sending raw bytes? Is that possible with this GNURadio?
The info in the (brief) datasheet imply that all that you can do with it is set the data input high, in which case the transmitter sends a 315MHz carrier for as long as the data pin is held high. Otherwise the transmitter is off. That is, it can send OOK which is a special case of ASK.
The thing you really need to read is the documentation and source code for the RadioHead library because that is what determines the actual transmitted bitstream. From what I have seen of it, it is not sending a simple input data bit = 1 for carrier on, input data bit = 0 for carrier off. It is converting each 4 bits of the input data into 6 transmitted data bits as described by this comment in RH_ASK.cpp
// 4 bit to 6 bit symbol converter table
// Used to convert the high and low nybbles of the transmitted data
// into 6 bit symbols for transmission. Each 6-bit symbol has 3 1s and 3 0s
// with at most 3 consecutive identical bits
It might also be doing Manchester encoding of the output stream after that initial encoding but for sure it is adding a CRC.
It definitely is complicated enough that it's unlikely that you'll be able to decode a signal just by looking at an image such as is shown in your sig.png.
el_supremo:
It definitely is complicated enough that it's unlikely that you'll be able to decode a signal just by looking at an image such as is shown in your sig.png.
Pete
A quick scan of the GNURadio site (never heard of it before) and it seems it is far more advanced than simple "A 1 is a 11 and a 0 is a 10"). Yeah, it will have ASK/OOK, Manchester and say CRCs and all sorts.
There is this page here that may lead some insight...but sniffing these GNU radio packets with personally written code seems like quite an undertaking.
Simple OOK transmitters always use manchester coding, or similar to remove the DC component which exists in normal binary data.
Transmitting data with DC components via OOK radio is inherantly unreliable due to the way
OOK receivers work.
Manchester coding halves the effective bit rate while providing a simple but fairly effective form of error detection, and removes any DC component from the raw baseband data.
That puts me out of my depth. My idea of a wireless device is one that accepts "hello world" from one Arduino and magically delivers it to another Arduino.