And … it works :-)

It took me a some (little) time to rewrite the code I already wrote for the RFBee (Arduino), but at the moment I actually can receive the messages sent over the air.

What does the application do until now?

  • Sets up the registers of the CC1101 and triggers a reset.
  • Blocking wait for a RX FIFO overflow, meaning that the synch word of the message was received and that the “raw” message now is in the RX FIFO.
  • Reading out the RX FIFO, removed start- and stop-bits of the bitstream and changed the bit order (in fact the received signal is a 38400 baud serial data stream).
  • Manchester-decode the message and print it on the console.

The output currently looks as follows:

Reseting CC1101
Command strobe 30 read returned 6F
Done. Command strobe 3A read returned 00
Command strobe 34 read returned 00
Final message: 18 10 71 E8 FF FF FF 31 50 02 02 00 FD
Command strobe 3A read returned 61
Command strobe 34 read returned 00
Final message: 16 FF FF FF 2A 1F 09 03 00 0B E0 AD
Command strobe 3A read returned 61
Command strobe 34 read returned 00
Final message: 18 10 71 E8 FF FF FF 10 60 03 02 FF 01 0D
Command strobe 3A read returned 61
Command strobe 34 read returned 00
Final message: 18 00 A1 C9 32 B4 4A 23 09 03 02 06 A4 73
Command strobe 3A read returned 61
Command strobe 34 read returned 00
Final message: 18 10 71 E8 FF FF FF 31 50 02 02 00 FD
Command strobe 3A read returned 61
Command strobe 34 read returned 00 Final message: 16 32 B4 4A 57 1F 09 03 00 08 57 D9
Command strobe 3A read returned 61
Command strobe 34 read returned 00
Final message: 18 10 71 E8 FF FF FF 23 09 03 02 06 40 0B
Advertisements

14 thoughts on “And … it works :-)

  1. Looks great you sorted it out! Can you share to help my project along. I wanted to start the same for hom energy monitoring

    • At the moment I don’t want to share the code, as it is neither complete nor very elegant. However, I currently work on a character device driver for the RPi that will make it very easy to configure the registers of the CC1101 and then just do a (blocking) read operation on the device file. Please hold the line …

  2. Would really love to see some of your code, I’m struggling quite a bit trying to do much the same as you’ve done. Any idea when you’ll be willing to post it up? Thanks for the interesting blog, gives me hope!

  3. Hi I am trying to use this transceiver to receive a code from 433Mhz transmitters on my Raspberry pi. Your site appears to be the best resource I have come across so far. Great work! Have you tried this on the Raspberry Pi and can you share an example? I was thinking of doing blocking reads till I receive something and then see if it matches what I care about. I was trying out your code and it is currently designed for the RFBee. Any help will be appreciated.

    • There must be a misunderstanding: The project IS targeted on RPi and the code can already be used to receive data. But in fact currently it is tailored to decode messages in the RFBee format, making it easy to communicate with the RFBee and its (default) firmware. I tried to structure the code in a modular way, so you may just want to replace the RFBee decoder with your own implementation of a decoder.
      Please come back to me if you need detail instructions.

    • I forgot to mention something: The implementation currently only supports a VariableLengthModeProtocol. This means, the first byte the sender transmits over the air has to specify the number of bytes to follow. If your sender does not behave this way, you probably won’t receive anything in most cases. Someone needs to implement the FixedLengthModeProtocol, where we just try to receive a predefined number of bytes.

      • Thanks for the clarification. I will try to read up on the code a bit more to see what I can do here. I am not sure what you are using GPIO25 for in your code though – that doesn’t map to any of the SPI pins on the RPi.

      • GPIO25 is physically wired up to pin GDO2 of the CC1101. So I don’t need to poll for incoming data all the time. Instead, I can do a blocking read operation, which is much more elegant.

      • I used the SmartRF tool from TI to give me the programming for the config registers for my application (433Mhz) but I am trying to understand how you came up with the details for the packet format. All I want to do is for the cc1100 to print out whatever packet it receives from 433mhz transmitters (door sensors in this case)..

      • Do you have physical access to the sender? It is much easier to open the sender, check what RF components are inside, and attach a logic analyzer to the signal lines.

  4. I realise that this is an old thread but I was wondering if you’ve gotten any farther with your code. I bought two of these transmitters and currently, I’d just be happy if I can transmit and then pic up a signal with an SDR. There is almost no easily found documentation or code for these little RF1100SE or the chipset C1101.

    Thanks.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s