Important changes to forums and questions
All forums and questions are now archived. To start a new conversation or read the latest updates go to forums.mbed.com.
7 years, 9 months ago.
Workflow with Online compiler
Hi,
long time ago I started with a mbed LPC1768 to make some rapid prototyping. My workflow was 1. Write program in online IDE 2. compile/download program 3 copy to mbed 4. reset/run program 5. take mbed to external power supply and run program to get/transfer sensor values
Now I didn't used it for a while and wanted to start a new try with a Nucleo F401RE and a BT Smart module.
I tried same workflow and everything worked find until reaching point 5.
If i switch off power supply by removing usb cable and take a usb power supply my mbed will not start. The only way is to "reprogram" by copying bin file again. Sometimes it doesn't work and I need to copy a bin file with an other name first.
What changed? Where is my mistake?
Regards Frank
2 Answers
7 years, 9 months ago.
You need to add a jumper on JP1 on the top of the board, close to the USB connector.
The STLink tries to negotiate the supply current from the USB host before to turn on the power for the board. If you use a power supply, there is no host and the negotiation fails, so no power for the nucleo board...
With JP1 on, there is no negotiation so you can run from an USB power block.
BR, Maxime
Thanks.. using JP1 works with external power supply. But I still have the problem that the devices deletes firmware if the STLink initialises.
Scenario: 1. Program the device 2. Connect to external power supply with JP1 3. Reconnect to pc with or wihout JP1 4. Need to reprogram
posted by 07 Feb 20177 years, 9 months ago.
The Problem you have is that the ST-Link will only power youre application processor if it has a valid usb communication. This is what the manual says about it: "Note: In case the board is powered by an USB charger, there is no USB enumeration, so the led LD3 remains set to OFF permanently and the target STM32 is not powered. In this specific case the jumper JP1 needs to be set to ON, to allow target STM32 to be powered anyway."
So you wanna set JP1 then powering from a charger