In this configuration I have no problems with communication, but for large packets, which I split in chunks of 200bytes each, the transmission of each chunk takes around 1s which is too slow.
I tried increasing the UART baud rate by setting: configuration.SPED.uartBaudRate=UART_BPS_19200;
and leaving all the rest unchanged (obviously I also used the same baud rate on my Serial ports on both the microcontrollers).
The modules correctly get the configuration, and the transmitter starts transmitting packets (or so it says as it returns E220_SUCCESS as ResponseStatus code), but the receiver doesn’t seem to get any packet.
I also tried increasing the uartBaudRate to 115000, and tried some combinations with airDataRate values (augmenting and diminishing it in various configurations), but it looks like I can only communicate with the default values of these options (9600 and 1024 resectively).
Am I missing something? Do I need to set some other values to get higher transmission speed on these modules?
If you need the methods I use for transmission and the sketch for reception I can attach it.
Hi aleemont,
I think to change speed, you must change the Air data rate. If you want to change the baud rate (I don’t remember very well), you must also set the baud rate on the initial constructor.
By default, It is set to 9600.
Using any of the following constructors causes both boards to go in kernel panic as the getConfiguration() returns a null pointer.
Here’s the receiver code:
#define E220_22 #define FREQUENCY_868 #define ENABLE_RSSI
<div>
<div>#include <Arduino.h></div>
<div>#include <LoRa_E220.h></div>
</div> byte RX_PIN = 16; byte TX_PIN = 17; byte AUX_PIN = 18; // not used byte M0_PIN = 19; // not used byte M1_PIN = 21; // not used
digitalWrite(M0_PIN, LOW); digitalWrite(M1_PIN, LOW); // Startup all pins and UART bool res = e220ttl.begin(); //Serial.println("Begin: " + String(res)); ResponseStructContainer c; c = e220ttl.getConfiguration(); //Error is happening here Serial.println("Error happens here"); // It's important get configuration pointer before all other operation Configuration configuration = *(Configuration *)c.data; Serial.println("And I can't get here");
// Set configuration changed and set to not hold the configuration ResponseStatus rs = e220ttl.setConfiguration(configuration, WRITE_CFG_PWR_DWN_SAVE); Serial.println(rs.getResponseDescription()); Serial.println(rs.code); c.close(); c = e220ttl.getConfiguration(); // It's important get configuration pointer before all other operation configuration = *(Configuration *)c.data; Serial.println(c.status.getResponseDescription()); Serial.println(c.status.code);
And here’s the output on the Serial Monitor (with DEBUG_PRINT enabled):
ets Jul 29 2019 12:21:46
rst:0xc (SW_CPU_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT) configsip: 0, SPIWP:0xee clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00 mode:DIO, clock div:2 load:0x3fff0030,len:1184 load:0x40078000,len:13232 load:0x40080400,len:3028 entry 0x400805e4 RX MIC ---> -1 TX MIC ---> -1 AUX ---> 18 M0 ---> 19 M1 ---> 21 Init AUX pin! Init M0 pin! Init M1 pin! Begin ex Begin Hardware Serial Begin MODE NORMAL! AUX HIGH! Complete! Error happens here Guru Meditation Error: Core 1 panic'ed (LoadProhibited). Exception was unhandled.
Maintaining a repository (or site or forum) is a lot like tending to a garden - it requires constant care and attention to keep it thriving. If you're a skilled gardener (or coder!) and want to help keep our repository blooming, we'd love to have you on board! We're also looking for talented writers and forum moderators to help us grow our community. Interested in joining our team? Don't hesitate to reach out and let us know how you can contribute!
Are you a fan of electronics or programming? Share your knowledge with others, write a simple tutorial or how to make a great project Contact me: share_your_ideas@mischianti.org
The content displayed on this website is protected under a CC BY-NC-ND license. Visitors are prohibited from using, redistributing, or altering any content from this website for commercial purposes, including generating revenue through advertising. Any unauthorized use is a violation of the license terms and legal action may be taken against individuals or entities found to be in violation.
You must also provide the link to the source.
Welcome to Our Family!
To provide the best experiences, we use technologies like cookies to store and/or access device information. Consenting to these technologies will allow us to process data such as browsing behavior or unique IDs on this site. Not consenting or withdrawing consent, may adversely affect certain features and functions.
Functional
Always active
The technical storage or access is strictly necessary for the legitimate purpose of enabling the use of a specific service explicitly requested by the subscriber or user, or for the sole purpose of carrying out the transmission of a communication over an electronic communications network.
Preferences
The technical storage or access is necessary for the legitimate purpose of storing preferences that are not requested by the subscriber or user.
Statistics
The technical storage or access that is used exclusively for statistical purposes.The technical storage or access that is used exclusively for anonymous statistical purposes. Without a subpoena, voluntary compliance on the part of your Internet Service Provider, or additional records from a third party, information stored or retrieved for this purpose alone cannot usually be used to identify you.
Marketing
The technical storage or access is required to create user profiles to send advertising, or to track the user on a website or across several websites for similar marketing purposes.
To provide the best experiences, we use technologies like cookies to store and/or access device information. Consenting to these technologies will allow us to process data such as browsing behavior or unique IDs on this site. Not consenting or withdrawing consent, may adversely affect certain features and functions.
Functional
Always active
The technical storage or access is strictly necessary for the legitimate purpose of enabling the use of a specific service explicitly requested by the subscriber or user, or for the sole purpose of carrying out the transmission of a communication over an electronic communications network.
Preferences
The technical storage or access is necessary for the legitimate purpose of storing preferences that are not requested by the subscriber or user.
Statistics
The technical storage or access that is used exclusively for statistical purposes.The technical storage or access that is used exclusively for anonymous statistical purposes. Without a subpoena, voluntary compliance on the part of your Internet Service Provider, or additional records from a third party, information stored or retrieved for this purpose alone cannot usually be used to identify you.
Marketing
The technical storage or access is required to create user profiles to send advertising, or to track the user on a website or across several websites for similar marketing purposes.