{"id":20429529,"url":"https://github.com/xreef/EByte_LoRa_E220_micropython_library","last_synced_at":"2025-05-08T17:32:26.313Z","repository":{"id":149366044,"uuid":"617665162","full_name":"xreef/EByte_LoRa_E220_micropython_library","owner":"xreef","description":"MicroPython LoRa EBYTE E220 LLCC68 device library complete and tested with Arduino, esp8266, esp32, STM32 and Raspberry Pi Pico (rp2040 boards).","archived":false,"fork":false,"pushed_at":"2025-01-29T14:15:13.000Z","size":4468,"stargazers_count":24,"open_issues_count":1,"forks_count":2,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-04-07T04:15:19.056Z","etag":null,"topics":["arduino","arduino-samd-boards","e220","ebyte","esp32","esp8266","llcc68","lora","micropython","pico","python","radio","raspberry","raspberry-pi","rp2040","stm32","uart"],"latest_commit_sha":null,"homepage":"https://www.mischianti.org/category/my-libraries/lora-e220-llcc68-devices/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/xreef.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-03-22T21:17:53.000Z","updated_at":"2025-04-03T04:17:15.000Z","dependencies_parsed_at":null,"dependency_job_id":"ecb2f2e5-8da0-46a8-a22a-6044dde2b10a","html_url":"https://github.com/xreef/EByte_LoRa_E220_micropython_library","commit_stats":{"total_commits":10,"total_committers":1,"mean_commits":10.0,"dds":0.0,"last_synced_commit":"bfb0e2a5023ff6758c79bfb6372142a6aeee5703"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xreef%2FEByte_LoRa_E220_micropython_library","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xreef%2FEByte_LoRa_E220_micropython_library/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xreef%2FEByte_LoRa_E220_micropython_library/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xreef%2FEByte_LoRa_E220_micropython_library/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/xreef","download_url":"https://codeload.github.com/xreef/EByte_LoRa_E220_micropython_library/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253042525,"owners_count":21845182,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["arduino","arduino-samd-boards","e220","ebyte","esp32","esp8266","llcc68","lora","micropython","pico","python","radio","raspberry","raspberry-pi","rp2040","stm32","uart"],"created_at":"2024-11-15T08:00:58.413Z","updated_at":"2025-05-08T17:32:25.510Z","avatar_url":"https://github.com/xreef.png","language":"Python","readme":"\u003cdiv\u003e\n\u003ca href=\"https://www.mischianti.org/forums/forum/mischiantis-libraries/ebyte-lora-e220-uart-devices-llcc68/\"\u003e\u003cimg\n  src=\"https://github.com/xreef/LoRa_E32_Series_Library/raw/master/resources/buttonSupportForumEnglish.png\" alt=\"Support forum EByte e220 English\"\n   align=\"right\"\u003e\u003c/a\u003e\n\u003c/div\u003e\n\u003cdiv\u003e\n\u003ca href=\"https://www.mischianti.org/it/forums/forum/le-librerie-di-mischianti/ebyte-e220-dispositivi-lora-uart-llcc68/\"\u003e\u003cimg\n  src=\"https://github.com/xreef/LoRa_E32_Series_Library/raw/master/resources/buttonSupportForumItaliano.png\" alt=\"Forum supporto EByte e220 italiano\"\n  align=\"right\"\u003e\u003c/a\u003e\n\u003c/div\u003e\n\n\n\u003c/br\u003e\u003c/br\u003e\n\n# EBYTE LoRa E220 devices micropython library (LLCC68)   \n\n\n### Changelog\n - 2023-07-16 0.0.5 Fix retrieve transmisison power [Issue](https://github.com/xreef/EByte_LoRa_E220_python_raspberrypi_library/issues/1)\n - 2023-05-02 0.0.4 Minor fix on data size message\n - 2023-04-18 0.0.3 Fix regular expression models\n - 2023-04-18 0.0.2 Distinct frequency from 900MHz and 915Mhz devices [Forum](https://www.mischianti.org/forums/topic/e32-915t-and-e32-900t-modules/)\n - 2023-03-21 0.0.1 Fully functional library\n\n### Installation\nTo install the library execute the following command:\n\n```bash\npip install ebyte-lora-e220\n```\n\n### Library usage\nHere an example of constructor, you must pass the UART interface and (if you want, but It's reccomended)\nthe AUX pin, M0 and M1.\n\n#### Initialization\n\n```python\nfrom lora_e220 import LoRaE220\nfrom machine import UART\n\nuart2 = UART(2)\nlora = LoRaE220('400T22D', uart2, aux_pin=15, m0_pin=21, m1_pin=19)\n```\n#### Start the module transmission\n\n```python\ncode = lora.begin()\nprint(\"Initialization: {}\", ResponseStatusCode.get_description(code))\n```\n\n#### Get Configuration\n\n```python\nfrom lora_e220 import LoRaE220, print_configuration\nfrom lora_e220_operation_constant import ResponseStatusCode\n\ncode, configuration = lora.get_configuration()\n\nprint(\"Retrieve configuration: {}\", ResponseStatusCode.get_description(code))\n\nprint_configuration(configuration)\n```\n\nThe result\n\n```\n----------------------------------------\nInitialization: {} Success\nRetrieve configuration: {} Success\n----------------------------------------\nHEAD :  0xc1   0x0   0x8\nAddH :  0x0\nAddL :  0x0\nChan :  23  -\u003e  433\nSpeedParityBit :  0b0  -\u003e  8N1 (Default)\nSpeedUARTDatte :  0b11  -\u003e  9600bps (default)\nSpeedAirDataRate :  0b10  -\u003e  2.4kbps (default)\nOptionSubPacketSett:  0b0  -\u003e  200bytes (default)\nOptionTranPower :  0b0  -\u003e  22dBm (Default)\nOptionRSSIAmbientNo:  0b0  -\u003e  Disabled (default)\nTransModeWORPeriod :  0b11  -\u003e  2000ms (default)\nTransModeEnableLBT :  0b0  -\u003e  Disabled (default)\nTransModeEnableRSSI:  0b0  -\u003e  Disabled (default)\nTransModeFixedTrans:  0b0  -\u003e  Transparent transmission (default)\n----------------------------------------\n```\n\n#### Set Configuration\n\nYou can set only the desidered parameter, the other will be set to default value.\n```python\nconfiguration_to_set = Configuration('400T22D')\nconfiguration_to_set.ADDL = 0x02\nconfiguration_to_set.ADDH = 0x01\nconfiguration_to_set.CHAN = 23\n\nconfiguration_to_set.SPED.airDataRate = AirDataRate.AIR_DATA_RATE_100_96\nconfiguration_to_set.SPED.uartParity = UARTParity.MODE_00_8N1\nconfiguration_to_set.SPED.uartBaudRate = UARTBaudRate.BPS_9600\n\nconfiguration_to_set.OPTION.transmissionPower = TransmissionPower('400T22D').\\\n                                                    get_transmission_power().POWER_10\n# or\n# configuration_to_set.OPTION.transmissionPower = TransmissionPower22.POWER_10\n\nconfiguration_to_set.OPTION.RSSIAmbientNoise = RssiAmbientNoiseEnable.RSSI_AMBIENT_NOISE_ENABLED\nconfiguration_to_set.OPTION.subPacketSetting = SubPacketSetting.SPS_064_10\n\nconfiguration_to_set.TRANSMISSION_MODE.fixedTransmission = FixedTransmission.FIXED_TRANSMISSION\nconfiguration_to_set.TRANSMISSION_MODE.WORPeriod = WorPeriod.WOR_1500_010\nconfiguration_to_set.TRANSMISSION_MODE.enableLBT = LbtEnableByte.LBT_DISABLED\nconfiguration_to_set.TRANSMISSION_MODE.enableRSSI = RssiEnableByte.RSSI_ENABLED\n\nconfiguration_to_set.CRYPT.CRYPT_H = 1\nconfiguration_to_set.CRYPT.CRYPT_L = 1\n\n\n# Set the new configuration on the LoRa module and print the updated configuration to the console\ncode, confSetted = lora.set_configuration(configuration_to_set)\n```\n\nI create a CONSTANTS class for each parameter, here a list:\nAirDataRate, UARTBaudRate, UARTParity, TransmissionPower, ForwardErrorCorrectionSwitch, WirelessWakeUpTime, IODriveMode, FixedTransmission\n\n#### Send string message\n\nHere an example of send data, you can pass a string \n```python\nlora.send_transparent_message('pippo')\n```\n\n```python\nlora.send_fixed_message(0, 2, 23, 'pippo')\n```\nHere the receiver code\n```python\nwhile True:\n    if lora.available() \u003e 0:\n        code, value = lora.receive_message()\n        print(ResponseStatusCode.get_description(code))\n\n        print(value)\n        utime.sleep_ms(2000)\n```\n\nIf you want receive RSSI also you must enable it in the configuration\n```python\nconfiguration_to_set.TRANSMISSION_MODE.enableRSSI = RssiEnableByte.RSSI_ENABLED\n```\n\nand set the flag to True in the receive_message method\n```python\ncode, value, rssi = lora.receive_message(True)\n```\n\n\n\nResult\n\n```\nSuccess!\npippo\n```\n\n#### Send dictionary message\n\nHere an example of send data, you can pass a dictionary\n```python\nlora.send_transparent_dict({'pippo': 'fixed', 'pippo2': 'fixed2'})\n```\n\n```python\nlora.send_fixed_dict(0, 0x01, 23, {'pippo': 'fixed', 'pippo2': 'fixed2'})\n```\n\nHere the receiver code\n```python\nwhile True:\n    if lora.available() \u003e 0:\n        code, value = lora.receive_dict()\n        print(ResponseStatusCode.get_description(code))\n        print(value)\n        print(value['pippo'])\n        utime.sleep_ms(2000)\n```\n\nif you want receive RSSI also you must enable it in the configuration\n```python\nconfiguration_to_set.TRANSMISSION_MODE.enableRSSI = RssiEnableByte.RSSI_ENABLED\n```\n\nand set the flag to True in the receive_dict method\n```python\ncode, value, rssi = lora.receive_dict(True)\n```\n\n\nResult\n\n```\nSuccess!\n{'pippo': 'fixed', 'pippo2': 'fixed2'}\nfixed\n```\n\n\n# This is a porting of the Arduino library for EBYTE LoRa E220 devices to Micropython\n\n## Tutorial of the original library  \n\n- [Ebyte LoRa E220 device for Arduino, esp32 or esp8266: settings and basic usage](https://www.mischianti.org/2022/03/11/ebyte-lora-e220-llcc68-device-for-arduino-esp32-or-esp8266-specs-and-basic-use-1/)\n- [Ebyte LoRa E220 device for Arduino, esp32 or esp8266: library](https://www.mischianti.org/2022/03/17/ebyte-lora-e220-llcc68-device-for-arduino-esp32-or-esp8266-library-2/)\n- [Ebyte LoRa E220 device for Arduino, esp32 or esp8266: configuration](https://www.mischianti.org/2022/04/19/ebyte-lora-e220-llcc68-device-for-arduino-esp32-or-esp8266-configuration-3/)\n- [Ebyte LoRa E220 device for Arduino, esp32 or esp8266: fixed transmission, broadcast, monitor, and RSSI](https://www.mischianti.org/2022/04/27/ebyte-lora-e220-device-for-arduino-esp32-or-esp8266-fixed-transmission-broadcast-monitor-and-rssi-4/)\n- [Ebyte LoRa E220 device for Arduino, esp32 or esp8266: power saving and sending structured data](https://www.mischianti.org/2022/05/06/ebyte-lora-e220-device-for-arduino-esp32-or-esp8266-manage-wake-on-radio-and-sends-structured-data-5/)\n- Ebyte LoRa E220 device for Arduino, esp32 or esp8266: WOR microcontroller and Arduino shield\n- Ebyte LoRa E220 device for Arduino, esp32 or esp8266: WOR microcontroller and WeMos D1 shield\n- Ebyte LoRa E220 device for Arduino, esp32 or esp8266: WOR microcontroller and esp32 dev v1 shield\n\n\n\n\u003ch2\u003eLLCC68 \u003c/h2\u003e\n\n\n\n\u003cp\u003eLoRa Smart Home (LLCC68) is a sub-GHz LoRa® RF Transceiver for medium-range indoor and indoor to outdoor wireless applications. SPI interface. Pin-to-pin is compatible with SX1262. SX1261, SX1262, SX1268, and LLCC68 are designed for long battery life with just 4.2 mA of active receive current consumption. The SX1261 can transmit up to +15 dBm, and the SX1262, SX1268, and LLCC68 can transmit up to +22 dBm with highly efficient integrated power\u0026nbsp;amplifiers.\u003c/p\u003e\n\n\n\n\u003cdiv class=\"wp-block-image\"\u003e\n\u003cimg src=\"https://www.mischianti.org/wp-content/uploads/2021/12/EByte-LoRa-E220-LLCC68-photo-3-devices-red-520x331.jpg\"/\u003e\n\u003c/div\u003e\n\n\n\n\u003cp\u003eThese devices support LoRa modulation for LPWAN use cases and (G)FSK modulation for legacy use cases. The devices are highly configurable to meet different application requirements for consumer use. The device provides LoRa modulation compatible with Semtech transceivers used by the LoRaWAN® specification released by the LoRa Alliance®. The radio is suitable for systems targeting compliance with radio regulations, including but not limited to ETSI EN 300 220, FCC CFR 47 Part 15, China regulatory requirements, and the Japanese ARIB T-108. Continuous frequency coverage from 150MHz to 960MHz allows the support of all major sub-GHz ISM bands around the world.\u003c/p\u003e\n\n\n\n\u003ch2\u003eFeatures\u003c/h2\u003e\n\n\n\n\u003cul\u003e\u003cli\u003eThe new LoRa spread spectrum modulation technology developed based on LLCC68, it brings a more extended communication distance and stronger anti-interference ability;\u003c/li\u003e\u003cli\u003eSupport users to set the communication key by themselves, and it cannot be read, which significantly improves the confidentiality of user data;\u003c/li\u003e\u003cli\u003eSupport LBT function, monitor the channel environment noise before sending, which significantly improves the communication success rate of the module in harsh environments;\u003c/li\u003e\u003cli\u003eSupport RSSI signal strength indicator function for evaluating signal quality, improving communication network, and ranging;\u003c/li\u003e\u003cli\u003eSupport air wakeup, that is ultra-low power consumption, suitable for battery-powered applications;\u003c/li\u003e\u003cli\u003eSupport point to point transmission, broadcast transmission, channel sense;\u003c/li\u003e\u003cli\u003eSupport deep sleep, the power consumption of the whole machine is about 5uA in this mode;\u003c/li\u003e\u003cli\u003eThe module has built-in PA+LNA, and the communication distance can reach 5km under ideal conditions;\u003c/li\u003e\u003cli\u003eThe parameters are saved after power-off, and the module will work according to the set parameters after power-on;\u003c/li\u003e\u003cli\u003eEfficient watchdog design, once an exception occurs, the module will automatically restart and continue to work according to the previous parameter settings;\u003c/li\u003e\u003cli\u003eSupport the bit rate of2.4k～62.5kbps;\u003c/li\u003e\u003cli\u003eSupport 3.0～5.5V power supply, power supply greater than 5V can guarantee the best performance;\u003c/li\u003e\u003cli\u003eIndustrial standard design, supporting long-term use at -40～+85℃;\u003c/li\u003e\u003c/ul\u003e\n\n\n\n\u003ch2\u003eComparison\u003c/h2\u003e\n\n\n\n\u003cfigure class=\"wp-block-table mischianti-table-left\"\u003e\u003ctable class=\"has-pale-ocean-gradient-background has-background\"\u003e\u003cthead\u003e\u003ctr\u003e\u003cth\u003e\u003c/th\u003e\u003cth\u003eLLCC68\u003c/th\u003e\u003cth\u003eSX1278-SX1276\u003c/th\u003e\u003c/tr\u003e\u003c/thead\u003e\u003ctbody\u003e\u003ctr\u003e\u003ctd\u003eDistance\u003c/td\u003e\u003ctd\u003e\u0026gt; 11Km\u003c/td\u003e\u003ctd\u003e8Km\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003eRate (LoRa)\u003c/td\u003e\u003ctd\u003e1.76Kbps – 62.5Kbps \u003c/td\u003e\u003ctd\u003e0.3Kbps – 19.2Kbps\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003eSleep power consumption\u003c/td\u003e\u003ctd\u003e2µA \u003c/td\u003e\u003ctd\u003e5µA\u003c/td\u003e\u003c/tr\u003e\u003c/tbody\u003e\u003c/table\u003e\u003c/figure\u003e\n\n\n\n\u003ch1\u003eLibrary\u003c/h1\u003e\n\n\n\n\u003cp\u003eLibrary for Ebyte LoRa E220 LLCC68 device for Arduino, esp32 or esp8266. \u003c/p\u003e\n\n\n\n\u003ch2\u003ePinout\u003c/h2\u003e\n\n\n\n\u003cdiv class=\"wp-block-image\"\u003e\n\u003cimg src=\"https://www.mischianti.org/wp-content/uploads/2019/09/sx1278-sx1276-wireless-lora-uart-module-serial-3000m-arduino-433-rf-robotedu-1705-13-robotedu@101.jpg\"/\u003e\n\u003c/div\u003e\n\n\n\n\u003cfigure class=\"wp-block-table mischianti-table-left\"\u003e\u003ctable class=\"has-very-light-gray-to-cyan-bluish-gray-gradient-background has-background\"\u003e\u003cthead\u003e\u003ctr\u003e\u003cth\u003ePin No.\u003c/th\u003e\u003cth\u003ePin item\u003c/th\u003e\u003cth\u003ePin direction\u003c/th\u003e\u003cth\u003ePin application\u003c/th\u003e\u003c/tr\u003e\u003c/thead\u003e\u003ctbody\u003e\u003ctr\u003e\u003ctd\u003e1\u003c/td\u003e\u003ctd\u003eM0\u003c/td\u003e\u003ctd\u003eInput（weak pull-up）\u003c/td\u003e\u003ctd\u003eWork with M1 \u0026amp; decide the four operating modes. Floating is not allowed; it can be ground.\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e2\u003c/td\u003e\u003ctd\u003eM1\u003c/td\u003e\u003ctd\u003eInput（weak pull-up）\u003c/td\u003e\u003ctd\u003eWork with M0 \u0026amp; decide the four operating modes. Floating is not allowed; it can be ground.\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e3\u003c/td\u003e\u003ctd\u003eRXD\u003c/td\u003e\u003ctd\u003eInput\u003c/td\u003e\u003ctd\u003eTTL UART inputs connect to external (MCU, PC) TXD output pin. It can be configured as open-drain or pull-up input.\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e4\u003c/td\u003e\u003ctd\u003eTXD\u003c/td\u003e\u003ctd\u003eOutput\u003c/td\u003e\u003ctd\u003eTTL UART outputs connect to external RXD (MCU, PC) input pin. Can be configured as open-drain or push-pull output\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e\u003cbr\u003e5\u003c/td\u003e\u003ctd\u003e\u003cbr\u003eAUX\u003c/td\u003e\u003ctd\u003e\u003cbr\u003eOutput\u003c/td\u003e\u003ctd\u003eTo indicate the module’s working status \u0026amp; wake up the external MCU. During the procedure of self-check initialization, the pin outputs a low level. It can be configured as open-drain or push-pull output (floating is allowed).\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e6\u003c/td\u003e\u003ctd\u003eVCC\u003c/td\u003e\u003ctd\u003e\u003c/td\u003e\u003ctd\u003ePower supply 3V~5.5V DC\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e7\u003c/td\u003e\u003ctd\u003eGND\u003c/td\u003e\u003ctd\u003e\u003c/td\u003e\u003ctd\u003eGround\u003c/td\u003e\u003c/tr\u003e\u003c/tbody\u003e\u003c/table\u003e\u003c/figure\u003e\n\n\n\n\u003cp\u003eAs you can see, you can set various modes via M0 and M1 pins.\u003c/p\u003e\n\n\n\n\u003cfigure class=\"wp-block-table is-style-stripes mischianti-table-left\"\u003e\u003ctable class=\"has-very-light-gray-to-cyan-bluish-gray-gradient-background has-background\"\u003e\u003cthead\u003e\u003ctr\u003e\u003cth\u003e\u003cstrong\u003eMode\u003c/strong\u003e\u003c/th\u003e\u003cth\u003e\u003cstrong\u003eM1\u003c/strong\u003e\u003c/th\u003e\u003cth\u003e\u003cstrong\u003eM0\u003c/strong\u003e\u003c/th\u003e\u003cth\u003e\u003cstrong\u003eExplanation\u003c/strong\u003e\u003c/th\u003e\u003c/tr\u003e\u003c/thead\u003e\u003ctbody\u003e\u003ctr\u003e\u003ctd\u003eNormal\u003c/td\u003e\u003ctd\u003e0\u003c/td\u003e\u003ctd\u003e0\u003c/td\u003e\u003ctd\u003eUART and wireless channels are open, and transparent transmission is on\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003eWOR Transmitter\u003c/td\u003e\u003ctd\u003e0\u003c/td\u003e\u003ctd\u003e1\u003c/td\u003e\u003ctd\u003eWOR Transmitter\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003eWOR Receiver\u003c/td\u003e\u003ctd\u003e1\u003c/td\u003e\u003ctd\u003e0\u003c/td\u003e\u003ctd\u003eWOR Receiver (Supports wake up over air)\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003eDeep sleep mode\u003c/td\u003e\u003ctd\u003e1\u003c/td\u003e\u003ctd\u003e1\u003c/td\u003e\u003ctd\u003eThe module goes to sleep (automatically wake up when configuring parameters)\u003c/td\u003e\u003c/tr\u003e\u003c/tbody\u003e\u003c/table\u003e\u003c/figure\u003e\n\n\n\n\u003cp\u003e Some pins can be used statically, but If you connect them to the microcontroller and configure them in the library, you gain in performance and can control all modes via software. Still, we are going to explain better next.\u003c/p\u003e\n\n\n\n\u003ch1\u003eFully connected schema\u003c/h1\u003e\n\n\n\n\u003cp\u003eAs I already said, It’s not essential to connect all pins to the microcontroller’s output; you can put M0 and M1 pins to HIGH or LOW to get the desired configuration. If\u003cstrong\u003e you don’t connect AUX, the library set a reasonable delay to ensure that the operation is complete\u003c/strong\u003e (\u003cstrong\u003eIf you have trouble\u003c/strong\u003e with the \u003cstrong\u003edevice \u003cstrong\u003efreezing\u003c/strong\u003e, \u003c/strong\u003e \u003cstrong\u003eyou must put a pull-up 4.7k resistor or better connect to the device.\u003c/strong\u003e ).\u003c/p\u003e\n\n\n\n\u003ch2\u003eAUX pin\u003c/h2\u003e\n\n\n\n\u003cp\u003eWhen transmitting data can be used to wake up external MCU and return HIGH on data transfer finish.\u003c/p\u003e\n\n\n\n\u003cdiv class=\"wp-block-image\"\u003e\n\u003cimg src=\"https://www.mischianti.org/wp-content/uploads/2019/10/e32auxPinOnTransmission-1024x269.jpg\"/\u003e\n\u003c/div\u003e\n\n\n\n\u003cp\u003eWhen receiving, AUX goes LOW and returns HIGH when the buffer is empty.\u003c/p\u003e\n\n\n\n\u003cdiv class=\"wp-block-image\"\u003e\u003cimg src=\"https://www.mischianti.org/wp-content/uploads/2019/10/e32auxPinOnReception-1024x342.jpg\"/\u003e\u003c/div\u003e\n\n\n\n\u003cp\u003eIt’s also used for self-checking to restore regular operation (on power-on and sleep/program mode).\u003c/p\u003e\n\n\n\n\u003cdiv class=\"wp-block-image\"\u003e\n\u003cimg src=\"https://www.mischianti.org/wp-content/uploads/2019/10/e32auxPinOnSelfCheck-1024x312.jpg\"/\u003e\n\u003c/div\u003e\n\n\n\n\u003ch2\u003e esp8266 \u003c/h2\u003e\n\n\n\n\u003cp\u003eesp8266 connection schema is more straightforward because it works at the same voltage of logical communications (3.3v).\u003c/p\u003e\n\n\n\n\u003cdiv class=\"wp-block-image\"\u003e\n\u003cimg src=\"https://www.mischianti.org/wp-content/uploads/2019/10/LoRa_E32-TTL-100_WemosD1_VD_PU_FullyConnected_bb-e1570517387323.jpg\"/\u003e\n\u003c/div\u003e\n\n\n\n\u003cp\u003eIt’s essential to add a pull-up resistor (4,7Kohm) to get good stability.\u003c/p\u003e\n\n\n\n\u003cfigure class=\"wp-block-table mischianti-table-left\"\u003e\u003ctable\u003e\u003cthead\u003e\u003ctr\u003e\u003cth\u003eE22\u003c/th\u003e\u003cth\u003eesp8266\u003c/th\u003e\u003c/tr\u003e\u003c/thead\u003e\u003ctbody\u003e\u003ctr\u003e\u003ctd\u003eM0\u003c/td\u003e\u003ctd\u003eD7\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003eM1\u003c/td\u003e\u003ctd\u003eD6\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003eTX\u003c/td\u003e\u003ctd\u003ePIN D2 (PullUP 4,7KΩ)\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003eRX\u003c/td\u003e\u003ctd\u003ePIN D3 (PullUP 4,7KΩ)\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003eAUX\u003c/td\u003e\u003ctd\u003ePIN D5 (PullUP 4,7KΩ)\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003eVCC\u003c/td\u003e\u003ctd\u003e5V (but work with less power in 3.3v)\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003eGND\u003c/td\u003e\u003ctd\u003eGND\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e\u003c/td\u003e\u003ctd\u003e\u003c/td\u003e\u003c/tr\u003e\u003c/tbody\u003e\u003c/table\u003e\u003c/figure\u003e\n\n\n\n\u003ch2\u003eesp32\u003c/h2\u003e\n\n\n\n\u003cp\u003eSimilar connection schema for esp32, but for RX and TX, we use RX2 and TX2 because, by default, esp32 doesn’t have SoftwareSerial but has 3 Serial.\u003c/p\u003e\n\n\n\n\u003cdiv class=\"wp-block-image\"\u003e\n\u003cimg src=\"https://www.mischianti.org/wp-content/uploads/2020/08/Ebyte-LoRa-E22-device-esp32-dev-kit-v1-breadboard-full-connection-768x668.jpg\"/\u003e\n\u003c/div\u003e\n\n\n\n\u003cfigure class=\"wp-block-table mischianti-table-left\"\u003e\u003ctable\u003e\u003cthead\u003e\u003ctr\u003e\u003cth\u003eE22\u003c/th\u003e\u003cth\u003eesp32\u003c/th\u003e\u003c/tr\u003e\u003c/thead\u003e\u003ctbody\u003e\u003ctr\u003e\u003ctd\u003eM0\u003c/td\u003e\u003ctd\u003eD21\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003eM1\u003c/td\u003e\u003ctd\u003eD19\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003eTX\u003c/td\u003e\u003ctd\u003ePIN RX2 (PullUP 4,7KΩ)\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003eRX\u003c/td\u003e\u003ctd\u003ePIN TX3 (PullUP 4,7KΩ)\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003eAUX\u003c/td\u003e\u003ctd\u003ePIN D18 (PullUP 4,7KΩ) (D15 to wake up)\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003eVCC\u003c/td\u003e\u003ctd\u003e5V (but work with less power in 3.3v)\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003eGND\u003c/td\u003e\u003ctd\u003eGND\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e\u003c/td\u003e\u003ctd\u003e\u003c/td\u003e\u003c/tr\u003e\u003c/tbody\u003e\u003c/table\u003e\u003c/figure\u003e\n\n\n\n\u003ch2\u003eArduino MKR WiFi 1010 \u003c/h2\u003e\n\n\n\n\u003cdiv class=\"wp-block-image\"\u003e\u003cimg src=\"https://www.mischianti.org/wp-content/uploads/2021/12/Ebyte_LoRa_Exx_Arduino_MKR_WiFi_1010_Fully_connected_breadboard-520x450.jpg\"/\u003e\u003c/div\u003e\n\n\n\n\u003cfigure class=\"wp-block-table mischianti-table-left\"\u003e\u003ctable\u003e\u003ctbody\u003e\u003ctr\u003e\u003ctd\u003eM0\u003c/td\u003e\u003ctd\u003e2 (voltage divider)\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003eM1\u003c/td\u003e\u003ctd\u003e3 (voltage divider)\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003eTX\u003c/td\u003e\u003ctd\u003ePIN 14 Tx (PullUP 4,7KΩ)\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003eRX\u003c/td\u003e\u003ctd\u003ePIN 13 Rx (PullUP 4,7KΩ)\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003eAUX\u003c/td\u003e\u003ctd\u003ePIN 1 (PullUP 4,7KΩ)\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003eVCC\u003c/td\u003e\u003ctd\u003e5V\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003eGND\u003c/td\u003e\u003ctd\u003eGND\u003c/td\u003e\u003c/tr\u003e\u003c/tbody\u003e\u003c/table\u003e\u003c/figure\u003e\n\n\n\n\n\n# An Arduino UNO shield to simplify the use\n![Arduino UNO shield](https://www.mischianti.org/wp-content/uploads/2019/12/ArduinoShieldMountedE32LoRa_min.jpg)\n\nYou can order the PCB  [here](https://www.pcbway.com/project/shareproject/LoRa_E32_Series_device_Arduino_shield.html) \n\nInstruction and assembly video on 6 part of the guide\n\n# An WeMos D1 shield to simplify the use\n![Arduino UNO shield](https://www.mischianti.org/wp-content/uploads/2020/01/WeMosD1ShieldMountedE32LoRa_min.jpg)\n\nYou can order the PCB  [here](https://www.pcbway.com/project/shareproject/LoRa_E32_Series_device_WeMos_D1_mini_shield_RF_8km_range.html) \n\nInstruction and assembly video on 6 part of the guide\n\n\n\n# Ebyte LoRa E220 LLCC68 device for Arduino, esp32 or esp8266: library\n\n\n\n\u003cdiv class=\"amp-wp-article-content\"\u003e\n\t\t\u003cbr\u003e\n\u003cp\u003e\u003cstrong\u003e\u003cstrong\u003eLoRa or Long Range wireless data telemetry\u003c/strong\u003e \u003c/strong\u003eis a technology pioneered by Semtech that operates at a lower frequency than NRF24L01 (433 MHz, 868 MHz, or 916 MHz against 2.4 GHz for the NRF24L01) but at thrice the distance (from 5000m to 11000m).  \u003c/p\u003e\n\n\n      \n\n\u003cdiv class=\"mischianti-forum-button-container\"\u003e\n  \t\u003ca class=\"mischianti-forum-button\" href=\"https://www.mischianti.org/forums/forum/mischiantis-libraries/ebyte-lora-e220-uart-devices-llcc68/\" target=\"_blank\"\u003eSupport Forum\u003c/a\u003e\n\u003c/div\u003e\n\n\n\n\u003cdiv class=\"wp-block-image\"\u003e\n\u003cimg src=\"https://www.mischianti.org/wp-content/uploads/2021/12/Ebyte-LoRa-E220-LLCC68-device-for-Arduino-esp32-or-esp8266-library-520x280.jpg\"/\u003e\n\u003c/div\u003e\n\n\n\u003ch2\u003eBasic configuration option\u003c/h2\u003e\n\n\n\n\u003cfigure class=\"wp-block-table mischianti-table-left\"\u003e\u003ctable class=\"has-electric-grass-gradient-background has-background\"\u003e\u003cthead\u003e\u003ctr\u003e\u003cth\u003eName\u003c/th\u003e\u003cth\u003eDescription\u003c/th\u003e\u003cth\u003eAddress\u003c/th\u003e\u003c/tr\u003e\u003c/thead\u003e\u003ctbody\u003e\u003ctr\u003e\u003ctd\u003eADDH\u003c/td\u003e\u003ctd\u003eHigh address byte of the module (the default 00H)\u003c/td\u003e\u003ctd\u003e00H\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003eADDL\u003c/td\u003e\u003ctd\u003eLow address byte of the module (the default 00H)\u003c/td\u003e\u003ctd\u003e01H\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003eSPED\u003c/td\u003e\u003ctd\u003eInformation about data rate parity bit and Air data rate\u003c/td\u003e\u003ctd\u003e02H\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003eOPTION\u003c/td\u003e\u003ctd\u003e Type of transmission, packet size, allow the special message \u003c/td\u003e\u003ctd\u003e03H \u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003eCHAN\u003c/td\u003e\u003ctd\u003eCommunication channel（410M + CHAN*1M）, default 17H (433MHz),\u0026nbsp;\u003cstrong\u003evalid only for 433MHz device\u003c/strong\u003e\u0026nbsp;check below to check the correct frequency of your device\u003c/td\u003e\u003ctd\u003e04H\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003eOPTION\u003c/td\u003e\u003ctd\u003eType of transmission, packet size, allow the special message\u003c/td\u003e\u003ctd\u003e05H\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003eTRANSMISSION_MODE\u003c/td\u003e\u003ctd\u003eA lot of parameters that specify the transmission modality\u003c/td\u003e\u003ctd\u003e06H\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003eCRYPT\u003c/td\u003e\u003ctd\u003eEncryption to avoid interception\u003c/td\u003e\u003ctd\u003e07H\u003c/td\u003e\u003c/tr\u003e\u003c/tbody\u003e\u003c/table\u003e\u003c/figure\u003e\n\n\n\n\u003ch3\u003eSPED detail\u003c/h3\u003e\n\n\n\n\u003cp\u003eUART Parity bit: \u003cem\u003eUART mode can be different between communication parties\u003c/em\u003e\u003c/p\u003e\n\n\n\n\u003cfigure class=\"wp-block-table mischianti-table-left\"\u003e\u003ctable class=\"has-electric-grass-gradient-background has-background\"\u003e\u003cthead\u003e\u003ctr\u003e\u003cth\u003eUART parity bit\u003c/th\u003e\u003cth\u003eConstant value\u003c/th\u003e\u003c/tr\u003e\u003c/thead\u003e\u003ctbody\u003e\u003ctr\u003e\u003ctd\u003e8N1 (default)\u003c/td\u003e\u003ctd\u003eMODE_00_8N1\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e8O1\u003c/td\u003e\u003ctd\u003eMODE_01_8O1\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e8E1\u003c/td\u003e\u003ctd\u003eMODE_10_8E1\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e8N1 (equal to 00)\u003c/td\u003e\u003ctd\u003eMODE_11_8N1\u003c/td\u003e\u003c/tr\u003e\u003c/tbody\u003e\u003c/table\u003e\u003c/figure\u003e\n\n\n\n\u003cp\u003eUART baud rate: UART baud rate can be different between communication parties (but not reccomended). The UART baud rate has nothing to do with wireless transmission parameters \u0026amp; won’t affect the wireless transmit/receive features.\u003c/p\u003e\u003cdiv class=\"code-block code-block-10 ai-viewport-2 ai-viewport-3 amp-wp-a750a3a\" data-amp-original-style=\"margin: 8px auto; text-align: center; clear: both;\"\u003e\n\u003c/div\u003e\n\u003cdiv class=\"code-block code-block-9 ai-viewport-1 amp-wp-a750a3a\" data-amp-original-style=\"margin: 8px auto; text-align: center; clear: both;\"\u003e\n\u003c/div\u003e\n\n\n\n\n\u003cfigure class=\"wp-block-table mischianti-table-left\"\u003e\u003ctable class=\"has-electric-grass-gradient-background has-background\"\u003e\u003cthead\u003e\u003ctr\u003e\u003cth\u003eTTL UART baud rate（bps）\u003c/th\u003e\u003cth\u003eConstant value\u003c/th\u003e\u003c/tr\u003e\u003c/thead\u003e\u003ctbody\u003e\u003ctr\u003e\u003ctd\u003e1200\u003c/td\u003e\u003ctd\u003eUART_BPS_1200\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e2400\u003c/td\u003e\u003ctd\u003eUART_BPS_2400\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e4800\u003c/td\u003e\u003ctd\u003eUART_BPS_4800\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e9600 (default)\u003c/td\u003e\u003ctd\u003eUART_BPS_9600\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e19200\u003c/td\u003e\u003ctd\u003eUART_BPS_19200\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e38400\u003c/td\u003e\u003ctd\u003eUART_BPS_38400\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e57600\u003c/td\u003e\u003ctd\u003eUART_BPS_57600\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e115200\u003c/td\u003e\u003ctd\u003eUART_BPS_115200\u003c/td\u003e\u003c/tr\u003e\u003c/tbody\u003e\u003c/table\u003e\u003c/figure\u003e\n\n\n\n\u003cp\u003eAir data rate: The lower the air data rate, the longer the transmitting distance,      better anti-interference performance, and longer transmitting time; the air data rate must be constant for both communication parties.\u003c/p\u003e\n\n\n\n\u003cfigure class=\"wp-block-table mischianti-table-left\"\u003e\u003ctable class=\"has-electric-grass-gradient-background has-background\"\u003e\u003cthead\u003e\u003ctr\u003e\u003cth\u003e Air data rate（bps） \u003c/th\u003e\u003cth\u003e Constant value \u003c/th\u003e\u003c/tr\u003e\u003c/thead\u003e\u003ctbody\u003e\u003ctr\u003e\u003ctd\u003e2.4k \u003c/td\u003e\u003ctd\u003eAIR_DATA_RATE_000_24 \u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e2.4k \u003c/td\u003e\u003ctd\u003eAIR_DATA_RATE_001_24 \u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e2.4k (default)\u003c/td\u003e\u003ctd\u003eAIR_DATA_RATE_010_24\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e4.8k\u003c/td\u003e\u003ctd\u003eAIR_DATA_RATE_011_48\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e9.6k\u003c/td\u003e\u003ctd\u003eAIR_DATA_RATE_100_96\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e19.2k\u003c/td\u003e\u003ctd\u003eAIR_DATA_RATE_101_192\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e38.4k\u003c/td\u003e\u003ctd\u003eAIR_DATA_RATE_110_384\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e62.5k\u003c/td\u003e\u003ctd\u003eAIR_DATA_RATE_111_625\u003c/td\u003e\u003c/tr\u003e\u003c/tbody\u003e\u003c/table\u003e\u003c/figure\u003e\n\n\n\n\u003ch3\u003eOPTION detail\u003c/h3\u003e\n\n\n\n\u003ch4\u003eSub packet setting\u003c/h4\u003e\n\n\n\n\u003cp\u003eThis is the max length of the packet.\u003c/p\u003e\n\n\n\n\u003cp\u003eWhen the data is smaller than the subpacket length, the serial output of the receiving end is an uninterrupted continuous output. The receiving end serial port will output the subpacket when the data is larger than the subpacket length.\u003c/p\u003e\n\n\n\n\u003cfigure class=\"wp-block-table mischianti-table-left\"\u003e\u003ctable class=\"has-pale-ocean-gradient-background has-background\"\u003e\u003cthead\u003e\u003ctr\u003e\u003cth\u003ePacket size\u003c/th\u003e\u003cth\u003e Constant value \u003c/th\u003e\u003c/tr\u003e\u003c/thead\u003e\u003ctbody\u003e\u003ctr\u003e\u003ctd\u003e200bytes (default)\u003c/td\u003e\u003ctd\u003eSPS_200_00\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e128bytes\u003c/td\u003e\u003ctd\u003eSPS_128_01\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e64bytes\u003c/td\u003e\u003ctd\u003eSPS_064_10\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e32bytes\u003c/td\u003e\u003ctd\u003eSPS_032_11\u003c/td\u003e\u003c/tr\u003e\u003c/tbody\u003e\u003c/table\u003e\u003c/figure\u003e\n\n\n\n\u003ch4\u003eRSSI Ambient noise enable\u003c/h4\u003e\n\n\n\n\u003cp\u003eThis command can enable/disable the management type of RSSI, and It’s essential to manage the remote configuration. Pay attention isn’t the RSSI parameter in the message.\u003c/p\u003e\n\n\n\n\u003cp\u003eWhen enabled, the C0, C1, C2, C3 commands can be sent in the transmitting mode or WOR transmitting mode to read the register. Register 0x00: Current ambient noise RSSI Register 0X01: RSSI when the data was received last time.\u003c/p\u003e\n\n\n\n\u003cfigure class=\"wp-block-table mischianti-table-left\"\u003e\u003ctable class=\"has-pale-ocean-gradient-background has-background\"\u003e\u003cthead\u003e\u003ctr\u003e\u003cth\u003eRSSI Ambient noise enable\u003c/th\u003e\u003cth\u003e Constant value \u003c/th\u003e\u003c/tr\u003e\u003c/thead\u003e\u003ctbody\u003e\u003ctr\u003e\u003ctd\u003eEnable\u003c/td\u003e\u003ctd\u003eRSSI_AMBIENT_NOISE_ENABLED\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003eDisable (default)\u003c/td\u003e\u003ctd\u003eRSSI_AMBIENT_NOISE_DISABLED\u003c/td\u003e\u003c/tr\u003e\u003c/tbody\u003e\u003c/table\u003e\u003c/figure\u003e\n\n\n\n\u003ch4\u003eTransmission power\u003c/h4\u003e\n\n\n\n\u003cp\u003eYou can change this set of constants by applying a define like so:\u003c/p\u003e\n\n\n\u003cdiv class=\"wp-block-syntaxhighlighter-code \"\u003e\u003cpre class=\"brush: cpp; title: ; notranslate\" title=\"\"\u003e#define E220_22 // default value without set \n\u003c/pre\u003e\u003c/div\u003e\n\n\n\u003cp\u003eApplicable for \u003cstrong\u003eE220 with 22dBm as max power.\u003c/strong\u003e\u003cbr\u003eLow power transmission is not recommended due to its low power supply efficiency.\u003c/p\u003e\n\n\n\n\u003cfigure class=\"wp-block-table mischianti-table-left\"\u003e\u003ctable class=\"has-pale-ocean-gradient-background has-background\"\u003e\u003cthead\u003e\u003ctr\u003e\u003cth\u003e Transmission power (approximation) \u003c/th\u003e\u003cth\u003e Constant value \u003c/th\u003e\u003c/tr\u003e\u003c/thead\u003e\u003ctbody\u003e\u003ctr\u003e\u003ctd\u003e22dBm (default)\u003c/td\u003e\u003ctd\u003ePOWER_22\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e17dBm\u003c/td\u003e\u003ctd\u003ePOWER_17\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e13dBm\u003c/td\u003e\u003ctd\u003ePOWER_13\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e10dBm\u003c/td\u003e\u003ctd\u003ePOWER_10\u003c/td\u003e\u003c/tr\u003e\u003c/tbody\u003e\u003c/table\u003e\u003c/figure\u003e\n\n\n\n\u003cp\u003eApplicable for \u003cstrong\u003eE220 with 30dBm as max power.\u003c/strong\u003e\u003cbr\u003eLow power transmission is not recommended due to its low power supply efficiency.\u003c/p\u003e\n\n\n\u003cdiv class=\"wp-block-syntaxhighlighter-code \"\u003e\u003cpre class=\"brush: cpp; title: ; notranslate\" title=\"\"\u003e#define E220_30\n\u003c/pre\u003e\u003c/div\u003e\n\n\n\u003cfigure class=\"wp-block-table mischianti-table-left\"\u003e\u003ctable class=\"has-pale-ocean-gradient-background has-background\"\u003e\u003cthead\u003e\u003ctr\u003e\u003cth\u003e Transmission power (approximation) \u003c/th\u003e\u003cth\u003e Constant value \u003c/th\u003e\u003c/tr\u003e\u003c/thead\u003e\u003ctbody\u003e\u003ctr\u003e\u003ctd\u003e30dBm (default)\u003c/td\u003e\u003ctd\u003ePOWER_30\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e27dBm\u003c/td\u003e\u003ctd\u003ePOWER_27\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e24dBm\u003c/td\u003e\u003ctd\u003ePOWER_24\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e21dBm\u003c/td\u003e\u003ctd\u003ePOWER_21\u003c/td\u003e\u003c/tr\u003e\u003c/tbody\u003e\u003c/table\u003e\u003c/figure\u003e\n\n\n\n\u003cp\u003eYou can configure Channel frequency also with this define:\u003c/p\u003e\n\n\n\u003cdiv class=\"wp-block-syntaxhighlighter-code \"\u003e\u003cpre class=\"brush: cpp; title: ; notranslate\" title=\"\"\u003e// One of \n#define FREQUENCY_433 \n#define FREQUENCY_170\n#define FREQUENCY_470\n#define FREQUENCY_868\n#define FREQUENCY_915\n\u003c/pre\u003e\u003c/div\u003e\n\n\n\u003ch3\u003eTRANSMISSION_MODE Detail\u003c/h3\u003e\n\n\n\n\u003ch4\u003eEnable RSSI\u003c/h4\u003e\n\n\n\n\u003cp\u003eWhen enabled, the module receives wireless data, and it will follow an RSSI strength byte after output via the serial port TXD\u003c/p\u003e\n\n\n\n\u003cfigure class=\"wp-block-table mischianti-table-left\"\u003e\u003ctable class=\"has-blush-light-purple-gradient-background has-background\"\u003e\u003cthead\u003e\u003ctr\u003e\u003cth\u003e Enable RSSI \u003c/th\u003e\u003cth\u003e Constant value \u003c/th\u003e\u003c/tr\u003e\u003c/thead\u003e\u003ctbody\u003e\u003ctr\u003e\u003ctd\u003eEnable\u003c/td\u003e\u003ctd\u003eRSSI_ENABLED\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003eDisable (default)\u003c/td\u003e\u003ctd\u003eRSSI_DISABLED\u003c/td\u003e\u003c/tr\u003e\u003c/tbody\u003e\u003c/table\u003e\u003c/figure\u003e\n\n\n\n\u003ch4\u003eTransmission type\u003c/h4\u003e\n\n\n\n\u003cp\u003eTransmission mode: The first three bytes of each user’s data frame can be used as high/low address and channel in fixed transmission mode.   The module changes its address and channel when transmitted. And it will revert to the original setting after completing the process.\u003c/p\u003e\n\n\n\n\u003cfigure class=\"wp-block-table mischianti-table-left\"\u003e\u003ctable class=\"has-blush-light-purple-gradient-background has-background\"\u003e\u003cthead\u003e\u003ctr\u003e\u003cth\u003eFixed transmission enabling bit\u003c/th\u003e\u003cth\u003e Constant value \u003c/th\u003e\u003c/tr\u003e\u003c/thead\u003e\u003ctbody\u003e\u003ctr\u003e\u003ctd\u003eFixed transmission mode\u003c/td\u003e\u003ctd\u003eFT_FIXED_TRANSMISSION\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003eTransparent transmission mode (default)\u003c/td\u003e\u003ctd\u003eFT_TRANSPARENT_TRANSMISSION\u003c/td\u003e\u003c/tr\u003e\u003c/tbody\u003e\u003c/table\u003e\u003c/figure\u003e\n\n\n\n\u003ch4\u003eMonitor data before transmission\u003c/h4\u003e\n\n\n\n\u003cp\u003eWhen enabled, wireless data will be monitored before it is transmitted, avoiding interference to a certain extent, but may cause data delay.\u003c/p\u003e\n\n\n\n\u003cfigure class=\"wp-block-table mischianti-table-left\"\u003e\u003ctable class=\"has-blush-light-purple-gradient-background has-background\"\u003e\u003cthead\u003e\u003ctr\u003e\u003cth\u003e LBT enable byte \u003c/th\u003e\u003cth\u003e Constant value \u003c/th\u003e\u003c/tr\u003e\u003c/thead\u003e\u003ctbody\u003e\u003ctr\u003e\u003ctd\u003eEnable\u003c/td\u003e\u003ctd\u003eLBT_ENABLED\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003eDisable (default)\u003c/td\u003e\u003ctd\u003eLBT_DISABLED\u003c/td\u003e\u003c/tr\u003e\u003c/tbody\u003e\u003c/table\u003e\u003c/figure\u003e\n\n\n\n\u003cdiv class=\"wp-block-image\"\u003e\u003cimg src=\"https://www.mischianti.org/wp-content/uploads/2020/07/Ebyte-LoRa-E22-device-for-Arduino-esp32-or-esp8266-carrier-sense.jpg\"/\u003e\u003c/div\u003e\n\n\n\n\u003ch4\u003eWOR cycle\u003c/h4\u003e\n\n\n\n\u003cp\u003eIf WOR is transmitting: after the WOR receiver receives the wireless data and outputs it through the serial port, it will wait for 1000ms before entering the WOR again. Users can input the serial port data and return it via wireless during this period. Each serial byte will be refreshed for 1000ms. Users must transmit the first byte within 1000ms.\u003c/p\u003e\n\n\n\n\u003cul\u003e\u003cli\u003ePeriod T = (1 + WOR) * 500ms, maximum 4000ms, minimum 500ms\u003c/li\u003e\u003cli\u003eThe longer the WOR monitoring interval period, the lower the average power consumption, but the greater the data delay\u003c/li\u003e\u003cli\u003e\u003cstrong\u003eBoth the transmitter and the receiver must be the same (very important).\u003c/strong\u003e\u003c/li\u003e\u003c/ul\u003e\n\n\n\n\u003cfigure class=\"wp-block-table mischianti-table-left\"\u003e\u003ctable class=\"has-blush-light-purple-gradient-background has-background\"\u003e\u003cthead\u003e\u003ctr\u003e\u003cth\u003eWireless wake-up time\u003c/th\u003e\u003cth\u003e Constant value \u003c/th\u003e\u003c/tr\u003e\u003c/thead\u003e\u003ctbody\u003e\u003ctr\u003e\u003ctd\u003e500ms\u003c/td\u003e\u003ctd\u003eWAKE_UP_500\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e1000ms\u003c/td\u003e\u003ctd\u003eWAKE_UP_1000\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e1500ms\u003c/td\u003e\u003ctd\u003eWAKE_UP_1500\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e2000ms (default)\u003c/td\u003e\u003ctd\u003eWAKE_UP_2000\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e2500ms\u003c/td\u003e\u003ctd\u003eWAKE_UP_2500\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e3000ms\u003c/td\u003e\u003ctd\u003eWAKE_UP_3000\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e3500ms\u003c/td\u003e\u003ctd\u003eWAKE_UP_3500\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd\u003e4000ms\u003c/td\u003e\u003ctd\u003eWAKE_UP_4000\u003c/td\u003e\u003c/tr\u003e\u003c/tbody\u003e\u003c/table\u003e\u003c/figure\u003e\n\n\n\n\u003ch1\u003eCheck buffer\u003c/h1\u003e\n\n\n\n\u003cp\u003eFirst, we must introduce a simple but practical method to check if something is in the receiving buffer.\u003c/p\u003e\n\n\n\u003cdiv class=\"wp-block-syntaxhighlighter-code \"\u003e\u003cpre class=\"brush: arduino; title: ; notranslate\" title=\"\"\u003eint available();\n\u003c/pre\u003e\u003c/div\u003e\n\n\n\u003cp\u003eIt’s simple to return how many bytes you have in the current stream.\u003c/p\u003e\u003cdiv class=\"code-block code-block-2 amp-wp-d1954fa\" data-amp-original-style=\"margin: 8px 0; clear: both;\"\u003e\n\u003c/div\u003e\n\n\n\n\n\u003ch1\u003eSend receive messages\u003c/h1\u003e\n\n\n\n\u003ch2\u003eNormal transmission mode\u003c/h2\u003e\n\n\n\n\u003cp\u003eNormal/Transparent transmission mode sends messages to all devices with the same address and channel.\u003c/p\u003e\n\n\n\n\u003cdiv class=\"wp-block-image\"\u003e\u003cimg src=\"https://www.mischianti.org/wp-content/uploads/2019/10/LoRa_E32_transmittingScenarios.jpg\"/\u003e\u003c/div\u003e\n\n\n\n\n\n\u003ch3\u003eFixed transmission\u003c/h3\u003e\n\n\n\u003cp\u003eFixed transmission have more scenarios\u003c/p\u003e\n\n\n\n\u003cdiv class=\"wp-block-image\"\u003e\u003cimg src=\"https://www.mischianti.org/wp-content/uploads/2019/10/LoRa_E32_transmittingScenarios.jpg\"/\u003e\u003c/div\u003e\n\n\n\n\n\n\n\u003ch1\u003eThanks\u003c/h1\u003e\n\n\n\n\u003cp\u003eNow you have all information to do your work, but I think It’s important to show some real examples to understand better all the possibilities.\u003c/p\u003e\n\n\n\n\u003col\u003e\u003cli\u003eEbyte LoRa E220 device for Arduino, esp32 or esp8266: settings and basic usage\u003c/li\u003e\u003cli\u003eEbyte LoRa E220 device for Arduino, esp32 or esp8266: library\u003c/li\u003e\u003cli\u003eEbyte LoRa E220 device for Arduino, esp32 or esp8266: configuration\u003c/li\u003e\u003cli\u003eEbyte LoRa E220 device for Arduino, esp32 or esp8266: fixed transmission, broadcast, monitor, and RSSI\u003c/li\u003e\u003cli\u003eEbyte LoRa E220 device for Arduino, esp32 or esp8266: power saving and sending structured data\u003c/li\u003e\u003cli\u003e\u003cspan data-amp-original-style=\"color: initial;\" class=\"amp-wp-2ca27fe\"\u003eEbyte LoRa E220 device for Arduino, esp32 or esp8266: WOR microcontroller and Arduino shield\u003c/span\u003e\u003c/li\u003e\u003cli\u003eEbyte LoRa E220 device for Arduino, esp32 or esp8266: WOR microcontroller and WeMos D1 shield\u003c/li\u003e\u003cli\u003eEbyte LoRa E220 device for Arduino, esp32 or esp8266: WOR microcontroller and esp32 dev v1 shield\u003c/li\u003e\u003c/ol\u003e\n\n\n\n\u003cp\u003e\u003ca href=\"https://github.com/xreef/EByte_LoRa_E220_Series_Library\" data-type=\"URL\" data-id=\"https://github.com/xreef/EByte_LoRa_E220_Series_Library\" target=\"_blank\" rel=\"noreferrer noopener\"\u003eGithub library\u003c/a\u003e\u003c/p\u003e\n\n\n\n\u003cul\u003e\u003cli\u003e\u003ca href=\"https://www.pcbway.com/project/shareproject/LoRa_E32_Series_device_Arduino_shield.html\"\u003eMischianti Arduino LoRa shield (Open source)\u003c/a\u003e\u003c/li\u003e\u003cli\u003e\u003ca href=\"https://www.pcbway.com/project/shareproject/LoRa_E32_Series_device_WeMos_D1_mini_shield_RF_8km_range.html\"\u003eMischianti WeMos LoRa shield (Open source)\u003c/a\u003e\u003c/li\u003e\u003cli\u003e\u003ca rel=\"noreferrer noopener\" href=\"https://www.pcbway.com/project/shareproject/LoRa_ESP32_DEV_KIT_v1_shield_for_EByte_E32_E22__RF_8km_12km_range.html?from=mischianti05\" target=\"_blank\"\u003eMischianti ESP32 DOIT DEV KIT v1 shield (Open source)\u003c/a\u003e\u003c/li\u003e\u003c/ul\u003e\n\n\n      \n\n\u003cdiv class=\"mischianti-forum-button-container\"\u003e\n  \t\u003ca class=\"mischianti-forum-button\" href=\"https://www.mischianti.org/forums/forum/mischiantis-libraries/ebyte-lora-e220-uart-devices-llcc68/\" target=\"_blank\"\u003eSupport Forum\u003c/a\u003e\n\u003c/div\u003e\n\t\u003c/div\u003e","funding_links":[],"categories":["Libraries"],"sub_categories":["Communications"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fxreef%2FEByte_LoRa_E220_micropython_library","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fxreef%2FEByte_LoRa_E220_micropython_library","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fxreef%2FEByte_LoRa_E220_micropython_library/lists"}