RAK3172 Breakout Board cannot communicate with Arduino IDE

Hi All,

Bought RAK3172 Breakout Board from Ali express so not sure it is in a good state in the first place.
It is not communicating with Arduino IDE, while downloading, it says not in boot mode.
I try putting it in boot mode by connecting boot pin to 3.3V and power cycling the module. Get the same response.
The module does not respond to AT+ver serial command as well, through Arduino serial window.
Furthermore does not communicate with DFU firmware tool as well. It says nothing found on serial port.
I am using following converter:

Is there any way I can confirm if RAK module is all good ? and not bricked. Thanks.

Welcome to the forum @omerattiqahmed
How did you connect the FTDI to the RAk3172 Breakout Board?
It should be like this:

Make sure to connect to UART2
Make sure to cross RX/TX lines
Make sure that the adapter provides 3.3V
Make sure to setup your terminal to 115200 Baud 8 bits no parity 1 stop bit

Thanks @beegee for the response. Appreciate it.
I made sure all the points you shared remain valid as I connect to RAK3172.
Interestingly the module isn’t willing to communicate with any of the following platforms:
Arduino IDE
DFU Firmware Update Tool
STM Cube Software (for downloading firmware)
I am fairly sure the FTDI works fine, since tested it with other boards. I just want to rule out that I got a bad module from Ali Express. Next time, I’ll try ordering from rak website. I thought to first check if I am missing something in wiring.

Just saw one thing in your original post:

boot pin to 3.3V

Don’t do that. That works only with the STM32CubeProgrammer.
Our DFU tool and Arduino IDE WILL NOT WORK if you connect BOOT0 to 3.3V, it has to stay open.

Thanks @beegee for highlighting this point, I tried with this combination as well but in vain unfortunately. I think the module itself might be bricked.

I’ve had a few 3172s come to me that behaved this way, and it turned out (for whatever reason) that the RAK firmware on them was either missing or somehow corrrupted such that loading applications onto them through the Arduino IDE was a no-go. The solution was a complete re-flash that includes everything, including the RAK bootloader.

To do this, grab the STMCubeProgrammer from here: STM32CubeProg - STM32CubeProgrammer software for all STM32 - STMicroelectronics and also the latest 3172 firmware from here: https://downloads.rakwireless.com/#LoRa/RAK3172/Firmware/.

Within that zip file, you’ll fine a few things - the one of interest is this:

Using the STM tool to flash the chip is where the BOOT0 pin comes into play. Pull it hiigh, and reset the chip (or power it on with BOOT0 high).

Load the STM32CubeProgrammer Application and verify the COM port and speed, then try a “Connect”

If the connect succeeds, you should see a dump of chip memory after a few seconds…

“Open File” and find where you’ve saved the .hex file I highlighted earlier.

The “Read” option should change to “Download”… Hit that, and the update should proceed.

Remove the jumper to BOOT0 and reset the chip - you should now be able to program the device from the Arduino IDE. Note that the message “device not in BOOT mode” is normal, but if you wait a few seconds, the upload will proceed anyway. I’m given to understand that you can explicitly put the device into boot mode by issuing an “AT+BOOT” command before attempting an upload, but I’ve never bothered.

I hope this works for you - I’ve had to do this with several 3172s acquired through AliExpress.

1 Like

Hi @philf
Much appreciate the detailed reply.

While trying to communicate via cube software, I got following notifications:

Screenshot_1

Screenshot_2

Screenshot_3

That’s the snapshot of the log:

I made sure it was in boot mode, BOOT0 = 3.3V and I cycled power to the board while BOOT0 pin = 3.3V

I’m almost suspicious of that particular FTDI adapter. I’ve never had a bad product from SparkFun, but the fact that your log shows a few unsuccessful attempts to get an acknowledgement from the 3172, but then manages to establish a connection and get a chip ID on the third try (only to have the next operation fail)…

The adapters I use employ exactly the same FTDI chip that appears on the SparkFun board - but one of the things that I find irksome about the design is that the 3.3V supply is coming from the FTDI’s internal LDO rather than an external regulator. According to the spec sheet, this is only designed to supply 50mA. I’ve never had a problem programming with a board of this design, but I notice that once the code starts running, the LEDs dim during a join or uplink.

Wondering if your mileage would vary with a different USB to serial adapter?

Hi @omerattiqahmed,

I am using the STM32CubeProgrammer a lot. Sharing some thoughts based on my experience.

  1. Poor connection on Supply and UART lines. Make sure they are connected firmly. It seems you are already established connection but suddenly stopped along the way with various errors showing up.
  2. Not fully working USB-UART converter. My RAKDAP1 never ever worked on STM32CubeProgrammer. I have no idea why for others, it works fine. You can try a different one.
  3. If supply of 3.3v is coming from the USB-UART converter, make sure it sustains the 3.3v. I’ve seen built-in 3.3v regulator on some USB-UART chip that are damaged. You can check the 3.3v with voltmeter.
  4. Worst is that the chip is already damaged. It can still happen but I can’t recall I experienced one. If it can still be detected by STM32CubeProgrammer, then very likely it should still be ok. One thing I look on chips if damaged is its current consumption. Maybe you can have a look if it is not absurd.