5 years, 3 months ago.

Does anybody have any experience working with this specific board called STM32F407VE?

This is the board I am talking about https://os.mbed.com/users/hudakz/code/STM32F407VET6_Hello/shortlog/

If yes, could you tell me how you configured the NRF2401 with the built in socket in this board? I am stuck for days. Please help!!There is also no documentation on net about this board. The one I found was https://os.mbed.com/users/hudakz/code/STM32F407VET6_Hello/shortlog/ but that only tells about ethernet interfacing.

1 Answer

5 years, 3 months ago.

Hello, swarm robot

The example programs below might help:

https://os.mbed.com/users/hudakz/code/STM32F407VET6_nRF24L01_Master/
https://os.mbed.com/users/hudakz/code/STM32F407VET6_nRF24L01_Slave/

Thanks! I tried this. The server seems to be transmitting. But the receiver shows no response. I don't know what to do on the receiver side. I used both your codes but reception is not happening!!

posted by swarm robot 23 Jan 2019

Try it again. I have replaced the RF24 library with my port to mbed in both Master and Slave. A test run using the online compiler worked fine.

posted by Zoltan Hudak 23 Jan 2019

I tried the updated code. But it is also not working! And now the radio.write function in master is executing when there is no nrf plugged in!!! The radio.write condition becomes false when nrf is added!! Please help.. I am failing this project :-(

posted by swarm robot 24 Jan 2019

Even the radio.available() gets executed when I remove the nrf from receiver !! What has happened?!

posted by swarm robot 24 Jan 2019

Both, master and slave, work fine for me. Double check your hardware.

posted by Zoltan Hudak 24 Jan 2019

I don't understand where I am going wrong. I have been with this board and 3 nrf modules for a week now. I have double checked hardware also. Do I need to do anything other than plugging in the nrf in the nrf on the the master and slave on hardware side? After doing that I burned the code of master and slave then nothing happens. I changed the nrf but then also nothing changed. The lack of documentation for this board makes me feel bad that I chose it for my final semester project.. I was able to do something in this project thanks to your documentation. I thank you for that! I don't know what to do now

posted by swarm robot 24 Jan 2019

If you are sure that the hardware is OK then I'd suggest the following:

  • Delete your both projects in the online compiler (to get rid off all the old stuff) and import them again.
  • Plug in the nRF24L01 modules into the NRF24L01 connector on both of your STM32F407VET6 back board (as shown in the pictures).
  • Compile and download the STM32F407VET6_nRF24L01_Master program to the first board.
  • Compile and download the STM32F407VET6_nRF24L01_Slave program to the second board.
  • Reset both bords
  • LED D2 on both bords shall start to blink.

The RF24 library uses channel 72 by default for communication. It could happen that that channel is interferred for instance by a WiFi router. You can try to use other channel. But in that case make sure you select the same channel on both boards:

//...
    // Initialize nRF24L01
    radio.begin();
    radio.setChannel(90);  // select channel 90 for communication
    radio.setPALevel(RF24_PA_LOW);
    radio.setRetries(5, 15);
    radio.setPayloadSize(1);
    radio.setAutoAck(true);
//...

By the way, how did you burn the code to the boards? Did the https://os.mbed.com/users/hudakz/code/STM32F407VET6_Hello/ run correctly on your boards?

For documentation on the board check the links below:

posted by Zoltan Hudak 24 Jan 2019

I compile the program in the online compiler. Generate the bin file and burn it through my stlink programmer hardware. The software I use for burning the bin file is STM32Cube Programmer. Your Blinky RTOS program worked fine for me. It is with the help of that program that I was able to do 25% of my project. But I am stuck here. All other hardware has been interfaces but this NRF2401 is lagging me too bad.

I tried the above steps you mentioned. Here are my observations: I also tried changing channel to 90.

1. The if (radio.write(&payload, sizeof(payload))) returns true when I remove the NRF2401 from the board. Otherwise this condition becomes false. 2.Receiver doesn't blink at all. 3. In the first version of code you uploaded, my transmitter if condition seemed to be working fine. It is the new updated one giving me this strange error. But in the earlier version also there was no response in the receiver.

posted by swarm robot 25 Jan 2019

You are right, radio.write(&payload, sizeof(payload)) returns true when no nRF24L01 is plugged in. That's why I modified the the begin() function in the RF24 library. Now it returns false if no nRF24L01 is connected and can be used to check for such condition.

posted by Zoltan Hudak 25 Jan 2019