# Heltec Wifi LoRa32 V2 + LMIC questions

**URL:** <https://www.thethingsnetwork.org/forum/t/heltec-wifi-lora32-v2-lmic-questions/55321>\
**Category:** LMIC\
**Created:** [February 18, 2022, 8:47pm UTC](https://www.thethingsnetwork.org/forum/t/heltec-wifi-lora32-v2-lmic-questions/55321 "2022-02-18T20:47:08Z")\
**Posts on this page:** 17\
**Page:** 1

<div class="post-metadata">

**Author:** ![G1DDO](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/g1ddo/32/35697_2.png) [@G1DDO](https://www.thethingsnetwork.org/forum/u/G1DDO)\
**Post date:** [February 18, 2022, 8:47pm UTC](https://www.thethingsnetwork.org/forum/t/heltec-wifi-lora32-v2-lmic-questions/55321/1 "2022-02-18T20:47:08Z")

</div>

I have setup the Heltec SX1276 to send a payload to an application, which seems to work but not fully.

The data is sent to the application and I can decode it fine but it looks like the transmission doesn’t finish properly as shown below

Starting  
Packet queued  
3363: EV\_JOINING  
412050: EV\_TXSTART  
733088: EV\_JOINED  
netid: 19  
devaddr: XXXXXX  
AppSKey: XXXXXXXXX  
NwkSKey: XXXXXXXXX  
735486: EV\_TXSTART

In this I would expect to see EV\_TXCOMPLETE, which should be the receive response.

Can anyone confirm my thoughts are right and if so why might I be getting this issue?

Another thing I would also like to be able to receive download messages by this device but not sure what I would need to do for this.

Let me know if you need more information on setup/software to help diagnose.

Neil

---

<div class="post-metadata">

**Author:** ![Jeff-UK](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/jeff-uk/32/35697_2.png) [@Jeff-UK](https://www.thethingsnetwork.org/forum/u/Jeff-UK)\
**Post date:** [February 18, 2022, 9:36pm UTC](https://www.thethingsnetwork.org/forum/t/heltec-wifi-lora32-v2-lmic-questions/55321/2 "2022-02-18T21:36:22Z")

</div>

Hi Neil, the guys who will know will be bound to ask 1) which library/environment are you using & 2) which specific Heltec board (inc. any revision… 😉

---

<div class="post-metadata">

**Author:** ![G1DDO](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/g1ddo/32/35697_2.png) [@G1DDO](https://www.thethingsnetwork.org/forum/u/G1DDO)\
**Post date:** [February 18, 2022, 9:42pm UTC](https://www.thethingsnetwork.org/forum/t/heltec-wifi-lora32-v2-lmic-questions/55321/3 "2022-02-18T21:42:53Z")

</div>

Good point, its heltec lora 32 v2 and running via arduino and using the lmic library using OTAA.

---

<div class="post-metadata">

**Author:** ![bluejedi](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/bluejedi/32/44639_2.png) [@bluejedi](https://www.thethingsnetwork.org/forum/u/bluejedi)\
**Post date:** [February 18, 2022, 10:07pm UTC](https://www.thethingsnetwork.org/forum/t/heltec-wifi-lora32-v2-lmic-questions/55321/4 "2022-02-18T22:07:21Z")

</div>

> [@G1DDO](#):
>
> In this I would expect to see EV\_TXCOMPLETE, which should be the receive response.
> 
> Can anyone confirm my thoughts are right and if so why might I be getting this issue?

Not sure what you mean with “which should be the receive response.”.

The join succeeded. TXCOMPLETE should occur after the last TXSTART in your log.

Your log ends with TXSTART and shows no further details. What happens next?

> [@G1DDO](#):
>
> using the lmic library using OTAA

Which LMIC library exactly and which sketch are you using?

> [@G1DDO](#):
>
> Another thing I would also like to be able to receive download messages by this device but not sure what I would need to do for this.

For more information have a look at [LMIC-node](https://github.com/lnlp/LMIC-node)

---

<div class="post-metadata">

**Author:** ![G1DDO](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/g1ddo/32/35697_2.png) [@G1DDO](https://www.thethingsnetwork.org/forum/u/G1DDO)\
**Post date:** [February 18, 2022, 10:21pm UTC](https://www.thethingsnetwork.org/forum/t/heltec-wifi-lora32-v2-lmic-questions/55321/5 "2022-02-18T22:21:18Z")

</div>

Hi,

What I mean is that I wold expect the EV\_TXComplete to get called which would then check for RX (Downlink messages) and setup for the next send

case EV\_TXCOMPLETE:  
Serial.println(F(“EV\_TXCOMPLETE (includes waiting for RX windows)”));  
if (LMIC.txrxFlags & TXRX\_ACK)  
Serial.println(F(“Received ack”));  
if (LMIC.dataLen) {  
Serial.print(F(“Received “));  
Serial.print(LMIC.dataLen);  
Serial.println(F(” bytes of payload”));  
}  
// Schedule next transmission  
os\_setTimedCallback(&sendjob, os\_getTime()+sec2osticks(TX\_INTERVAL), do\_send);  
break;

My code just hangs theres no EV\_TXComplete and therefore nothing else happens.

I’m looking over the LMIC docs to see if there’s a way to receive messages without doing an Uplink.

---

<div class="post-metadata">

**Author:** ![bluejedi](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/bluejedi/32/44639_2.png) [@bluejedi](https://www.thethingsnetwork.org/forum/u/bluejedi)\
**Post date:** [February 18, 2022, 10:23pm UTC](https://www.thethingsnetwork.org/forum/t/heltec-wifi-lora32-v2-lmic-questions/55321/6 "2022-02-18T22:23:36Z")

</div>

> [@G1DDO](#):
>
> I’m looking over the LMIC docs to see if there’s a way to receive messages without doing an Uplink

There is _none_ for class A devices.

The LoRaWAN specification will be a better source for such information.

---

<div class="post-metadata">

**Author:** ![G1DDO](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/g1ddo/32/35697_2.png) [@G1DDO](https://www.thethingsnetwork.org/forum/u/G1DDO)\
**Post date:** [February 18, 2022, 10:31pm UTC](https://www.thethingsnetwork.org/forum/t/heltec-wifi-lora32-v2-lmic-questions/55321/7 "2022-02-18T22:31:35Z")

</div>

dang thats a shame that i cant do that

---

<div class="post-metadata">

**Author:** ![G1DDO](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/g1ddo/32/35697_2.png) [@G1DDO](https://www.thethingsnetwork.org/forum/u/G1DDO)\
**Post date:** [February 19, 2022, 7:11am UTC](https://www.thethingsnetwork.org/forum/t/heltec-wifi-lora32-v2-lmic-questions/55321/8 "2022-02-19T07:11:23Z")

</div>

To add to this I manage to find out why the EV\_TXComplete wasn’t being processed.

Turns out the mapping for DIO pins I had was .dio = {26, 33, 32} but this seems to be incorrect and changing it as shown below worked.

const lmic\_pinmap lmic\_pins = {  
.nss = 18,  
.rxtx = LMIC\_UNUSED\_PIN,  
.rst = 14,  
.dio = {26, 34, 35},  
};

I now get the EV\_TXComplete, however no ack or payload is returned so might need to do some more investigating on those bits to fully understand them.

---

<div class="post-metadata">

**Author:** ![bluejedi](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/bluejedi/32/44639_2.png) [@bluejedi](https://www.thethingsnetwork.org/forum/u/bluejedi)\
**Post date:** [February 19, 2022, 7:20am UTC](https://www.thethingsnetwork.org/forum/t/heltec-wifi-lora32-v2-lmic-questions/55321/9 "2022-02-19T07:20:32Z")

</div>

**Do first:** check the Big ESP32 topic and LMIC-node.

This will save you time and prevent wasting other people’s time for questions already answered, information that is already available and lessons already learned.

---

<div class="post-metadata">

**Author:** ![G1DDO](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/g1ddo/32/35697_2.png) [@G1DDO](https://www.thethingsnetwork.org/forum/u/G1DDO)\
**Post date:** [February 19, 2022, 8:08am UTC](https://www.thethingsnetwork.org/forum/t/heltec-wifi-lora32-v2-lmic-questions/55321/10 "2022-02-19T08:08:58Z")

</div>

This is true but some threads can go back years so take a very long time to read through them all. Luckily for this one I have found what I need to finish the project the rest is just to get a better understanding of LMIC.

---

<div class="post-metadata">

**Author:** ![bluejedi](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/bluejedi/32/44639_2.png) [@bluejedi](https://www.thethingsnetwork.org/forum/u/bluejedi)\
**Post date:** [February 19, 2022, 8:36am UTC](https://www.thethingsnetwork.org/forum/t/heltec-wifi-lora32-v2-lmic-questions/55321/11 "2022-02-19T08:36:51Z")

</div>

> [@G1DDO](#):
>
> This is true but some threads can go back years so take a very long time to read through them all.

What does my previous post mention?: **Do first:** check the Big ESP32 topic and LMIC-node.  
That is exactly one thread (the latest version contains all relevant information, of which most in the topic start).

If someone is too lazy to search for and read any information already available on the forum then (s)he is never going to find out that for many subjects much care and time has already been spent to provide very useful information at a glance.  
Wasting other people’s time ‘because searching and reading information already available on the forum is too much work’ is not a good motivator for trying to get help from others on the forum.

---

<div class="post-metadata">

**Author:** ![G1DDO](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/g1ddo/32/35697_2.png) [@G1DDO](https://www.thethingsnetwork.org/forum/u/G1DDO)\
**Post date:** [February 19, 2022, 3:25pm UTC](https://www.thethingsnetwork.org/forum/t/heltec-wifi-lora32-v2-lmic-questions/55321/12 "2022-02-19T15:25:02Z")

</div>

no ones is asking you to waste your time just don’t reply

---

<div class="post-metadata">

**Author:** ![descartes](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/descartes/32/47220_2.png) [@descartes](https://www.thethingsnetwork.org/forum/u/descartes)\
**Post date:** [February 19, 2022, 3:46pm UTC](https://www.thethingsnetwork.org/forum/t/heltec-wifi-lora32-v2-lmic-questions/55321/13 "2022-02-19T15:46:08Z")

</div>

Which inevitably means that you won’t get any replies - the people who know stuff do tend to have to repeat themselves quite a lot.

---

<div class="post-metadata">

**Author:** ![descartes](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/descartes/32/47220_2.png) [@descartes](https://www.thethingsnetwork.org/forum/u/descartes)\
**Post date:** [February 19, 2022, 3:51pm UTC](https://www.thethingsnetwork.org/forum/t/heltec-wifi-lora32-v2-lmic-questions/55321/14 "2022-02-19T15:51:16Z")

</div>

> [@G1DDO](#):
>
> I now get the EV\_TXComplete, however no ack or payload is returned so might need to do some more investigating on those bits to fully understand them.

There is the potential to get an Ack but it doesn’t come as standard and you can only do 10 a day to stay inside the Fair Use Policy.

No payload will be returned unless you have requested a downlink by some mechanism - which is part of those 10 a day. Why a limit - well to save some agro about searching the forum etc etc, it’s because the gateway is stone deaf whilst transmitting so too many downlinks means uplinks get lost.

I would recommend reading this as it will fill in many of the ‘usual’ questions:

[https://www.thethingsnetwork.org/docs/lorawan/](https://www.thethingsnetwork.org/docs/lorawan/)

---

<div class="post-metadata">

**Author:** ![bluejedi](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/bluejedi/32/44639_2.png) [@bluejedi](https://www.thethingsnetwork.org/forum/u/bluejedi)\
**Post date:** [February 19, 2022, 4:18pm UTC](https://www.thethingsnetwork.org/forum/t/heltec-wifi-lora32-v2-lmic-questions/55321/15 "2022-02-19T16:18:28Z")

</div>

> [@G1DDO](#):
>
> no ones is asking you to waste your time just don’t reply

Wrong, that is not how this forum works.  
You are wasting other users’ time by not checking for and reading _any_ relevant information already available on the forum and then come up with questions that have been answered many, many, many times already for which a lot of information and solutions are already available on the forum.  
My opinion is that this is comparable to spam.

This is not a forum where the manufacturer offers free support for their product. The forum is neither for users that want instant answers to their problems while unwilling to [_search_](https://www.thethingsnetwork.org/forum/search) for any relevant information already available on the forum. If using the search option to find some information is already too much hassle then this is probably not the right forum for them.

This forum is _for_ users _by_ users. Users who are spending their spare time and assist others for free. It is wiser to follow advice from experienced users than to neglect valuable advice, existing information and lessons learned.

Do you want to be the 100(0)th person running into the same issues, asking the same questions and come up with ‘solutions’ that already exist and are already known? WE don’t.

So you are welcome here to ask questions but do some homework on the forum first.  
It will serve you better and helps you ask better questions and people will be more willing to provide help to your _targeted_ questions.

---

<div class="post-metadata">

**Author:** ![claudiojperez](https://www.thethingsnetwork.org/forum/letter_avatar_proxy/v4/letter/c/9de053/32.png) [@claudiojperez](https://www.thethingsnetwork.org/forum/u/claudiojperez)\
**Post date:** [January 4, 2024, 7:29pm UTC](https://www.thethingsnetwork.org/forum/t/heltec-wifi-lora32-v2-lmic-questions/55321/16 "2024-01-04T19:29:01Z")

</div>

Hi, I would like to correct your pin assigment. I think you need to swap pin01 for pin02. Like this

const lmic\_pinmap lmic\_pins = {  
.nss = 18,  
.rxtx = LMIC\_UNUSED\_PIN,  
.rst = 14,  
.dio = {26, 35, 34},  
};

---

<div class="post-metadata">

**Author:** ![G1DDO](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/g1ddo/32/35697_2.png) [@G1DDO](https://www.thethingsnetwork.org/forum/u/G1DDO)\
**Post date:** [January 6, 2024, 6:09pm UTC](https://www.thethingsnetwork.org/forum/t/heltec-wifi-lora32-v2-lmic-questions/55321/17 "2024-01-06T18:09:44Z")

</div>

Thank you I will give this ago and see if it works.
