Giter Site home page Giter Site logo

sysmick / esp-idf-cc1101 Goto Github PK

View Code? Open in Web Editor NEW

This project forked from nopnop2002/esp-idf-cc1101

0.0 0.0 0.0 147 KB

CC1101 Low-Power Sub-1 GHz RF Transceiver driver for esp-idf

License: GNU Lesser General Public License v3.0

Shell 0.74% C++ 10.61% Python 2.48% C 83.91% Makefile 0.57% CMake 1.69%

esp-idf-cc1101's Introduction

esp-idf-cc1101

CC1101 Low-Power Sub-1 GHz RF Transceiver driver for esp-idf.

I ported from this.

  • 433MHz module(2.54mm pitch) CC1101-433MHz-2 54mm

  • 433MHz module(1.27mm pitch) CC1101-433MHz-1 27mm

  • 868MHz module(2mm pitch) CC1101-868MHz

Software requirements

ESP-IDF V4.4/V5.x.
ESP-IDF V5.0 is required when using ESP32-C2.
ESP-IDF V5.1 is required when using ESP32-C6.

Installation

git clone https://github.com/nopnop2002/esp-idf-cc1101
cd esp-idf-cc1101/basic
idf.py set-target {esp32/esp32s2/esp32s3/esp32c2/esp32c3/esp32c6}
idf.py menuconfig
idf.py flash

Note for ESP32C3
For some reason, there are development boards that cannot use GPIO06, GPIO08, GPIO09, GPIO19 for SPI clock pins.
According to the ESP32C3 specifications, these pins can also be used as SPI clocks.
I used a raw ESP-C3-13 to verify that these pins could be used as SPI clocks.

Configuration for Transceiver

config-cc1101-1 config-cc1101-2

Frequency selection

config-cc1101-3

Modulation speed selection

config-cc1101-4

Enable output high power

Default Power Setting is 0xC6.
Enabling this results in 0xC0.

Setting 868 MHz 915 MHz
0xC6 29.4mA 28.7mA
0xC0 34.2mA 33.4mA

config-cc1101-6

SPI BUS selection

config-cc1101-5

The ESP32 series has three SPI BUSs.
SPI1_HOST is used for communication with Flash memory.
You can use SPI2_HOST and SPI3_HOST freely.
When you use SDSPI(SD Card via SPI), SDSPI uses SPI2_HOST BUS.
When using this module at the same time as SDSPI or other SPI device using SPI2_HOST, it needs to be changed to SPI3_HOST.
When you don't use SDSPI, both SPI2_HOST and SPI3_HOST will work.
Previously it was called HSPI_HOST / VSPI_HOST, but now it is called SPI2_HOST / SPI3_HOST.

Wirering

CC1101 ESP32 ESP32-S2/S3 ESP32-C2/C3/C6
MISO -- GPIO19 GPIO37 GPIO4
SCK -- GPIO18 GPIO36 GPIO3
MOSI -- GPIO23 GPIO35 GPIO2
CSN -- GPIO5 GPIO34 GPIO1
GDO0 -- GPIO15 GPIO33 GPIO0
GDO2 -- N/C N/C N/C
GND -- GND GND GND
VCC -- 3.3V 3.3V 3.3V

You can change it to any pin using menuconfig.

GDO0 needs to be able to use interrupts.
Some GPIOs cannot use interrupts.

Communication with another library

Basically, communication between applications with different register values is not guaranteed.
These settings may differ.

  • Base frequency and channel spacing frequency
  • Packet format configuration
  • Manchester encoding configuration
  • Wireless modulation method
  • The data rate used when transmitting
  • The data rate expected in receive

You need to use this when communicating with the Arduino environment.
Communication with other libraries is not guaranteed.

Comparison of cc2500 and cc1101

cc2500 cc1101
Manufacturer Texas Instrument Texas Instrument
Frequency 2.4GHz 315/433/868/915MHz
Maximum Payload 64Byte 64Byte
FiFo for reception 64Byte*1 64Byte*1
FiFo for transmission 64Byte*1 64Byte*1
CRC Length 16bits 16bits
Acknowledgement Payload No No
Available Modulation format 2-FSK/GFSK/OOK/MSK 2-FSK/4-FSK/GFSK/ASK/OOK/MSK

Comparison of nRF905, cc1101 and si4432

nRF905 cc1101 si4432
Manufacturer Nordic Semiconductor Texas Instrument Silicon Labs
Frequency 433/868/915MHz 315/433/868/915MHz 315/433/868/915MHz
Maximum Payload 32Byte 64Byte 64Byte
FiFo for reception 32Byte*1 64Byte*1 64Byte*1
FiFo for transmission 32Byte*1 64Byte*1 64Byte*1
CRC Length 8/16bits 16bits 8/16bits
Acknowledgement Payload No No No
Available Modulation format GFSK 2-FSK/4-FSK/GFSK/ASK/OOK/MSK FSK/GFSK/OOK
  • GFSK : Gaussian shaped Frequency Shift Keying
  • FSK : Frequency Shift Keying
  • 2-FSK : Binary Frequency Shift Keying
  • 4-FSK : Quaternary Frequency Shift Keying
  • ASK : Amplitude Shift Keying
  • OOK : On-Off Keying
  • MSI : Minimum Shift Keying

esp-idf-cc1101's People

Contributors

nopnop2002 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.