cancel
Showing results for 
Search instead for 
Did you mean: 

Communication between B-L072Z-LRWAN1 and NUCLEO-L053R8 + I-NUCLEO-LRWAN1

pbdiazam
Associate II

I am fairly new to STM32 programming and I want to stablish a communication between both boards (B-L072Z-LRWAN1 and NUCLEO-L053R8 + I-NUCLEO-LRWAN1). I was wondering if I can achieve this goal using the PingPong example located in the Cube expansion folder.

This example is avaliable for the B-L072Z-LRWAN1 board but not for the NUCLEO-L053R8 + I-NUCLEO-LRWAN1 combination. However, the PingPong example is avaliable for NUCLEO-L053R8 + some other boards like sx1272mb2das.

What do I need to modify if I want to make the example avaliable for the NUCLEO-L053R8 + I-NUCLEO-LRWAN1 combination?

Thank you in advance.

10 REPLIES 10

All the firmware is contained on the USI module, so you'd need to build the PingPong example for that directly. That requires some work on the SX1272 code to manage direction control, and defining the pins used. USI had some directions/details on their GitHub page, but I ported code in from my MultiTech/CDEBYTE forks.

Programming the module requires the attachment of an SWD header and connection to an ST-LINK.

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..

Here is the thread I had from before, a bit bastardized by the forum transition I'm afraid

https://community.st.com/s/question/0D50X00009XkgY5SAJ/inucleolrwan1

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
pbdiazam
Associate II

Thank you for your time. So if I understood it correctly:

  1. I can modify the SX1272 code directly from the already created project (sx1272mb2das PingPong) managing direction control and defining the corresponding pin assignments to make it work.
  2. I need a ST-LINK devide like for example:0690X0000060PK9QAM.jpgI have already connected the expansion board on top of the NUCLEO board and this board through USB . Are not both boards ready to be used? I am a bit lost in this. Where can I find information about how is the expansion board connected to the ST-LINK?. All additional basic information you can provide to me is really appreciated (I need to learn from scratch).

Thank you again.

I forked sx1272mb2das.c into a STM32CubeExpansion_LRWAN_V1.x.x\Drivers\BSP\sx1272usi\sx1272usi.c file

And created a USE_I_NUCLEO_LRWAN1 section in stm32l0xx_hw_conf.h

That's a clone ST-LINK, but should work, you'd need to solder a header on to JP6 of the USI shield if it doesn't have one. You'll need to mass-erase the part as USI uses read-out protection.

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
pbdiazam
Associate II

Wait, I think I misunderstood what you meant. I want to have the NUCLEO-L053R8 + I-NUCLEO-LRWAN1 boards combination as a node, not just the I-NUCLEO-LRWAN1 alone. What you said is for the I-NUCLEO-LRWAN1 alone, right?

I am flashing the PingPong program avaliable, which should work for this board + expansion (the readme.txt file says so), but for some reason the transmision is not done. (I can see the command OnTxTimeout). Why is this happening?

Ok, but your proposed model has no direct access to the radio, the USI module presents a serial AT command interface, the SX1272 is not visible to you.

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
pbdiazam
Associate II

So if I want to use the combination of both boards, do I need to stablish a ST-Link communication between them using the ST-Link pings (CN2)? If so, how should I connect them to the I-NUCLEO-LRWAN1?

0690X0000060Q7QQAU.jpg

Thanks again!

You'd want to remove those jumpers, and then wire up the CN4 SWD connector to the USI JP6 connector

JP6 Header

1 3V3

2 SWCLK

3 GND

4 SWDIO

5 NRST

CN4

1 VTARGET

2 SWCLK

3 GND

4 SWDIO

5 NRST

6 SWO

You shouldn't need to connect for power.

I'd opt for the stand-alone ST-LINK, it would make debugging both targets easier.

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
pbdiazam
Associate II

Thank you for your help. By the way, I have seen an example in the Cube software called AT_Master which sends the AT commands to the USI module, which is connected to the radio module. Do you think I can implement the PingPong starting with that example? I would prefer to do that instead if it is possible.

Anyways, I though that the PingPong example was working fine on the B-L072Z-LRWAN1 but it is not. I am getting this in the UART terminal:

0690X0000060RnHQAU.png

I did not modify any code of the example (just added some #includes) and the 'Ping' message is not done. I am just compiling and flashing the example into the board. When I try to debug to see what happens I get this error:

0690X0000060RnvQAE.png

I added some batteries to the board in case it was due to power issues, but does not work either. What can cause this error?

PS: I am working on a Virtual Machine (Windows 10 as guest)