Hi all, So I've been using a Portenta H7 in the lab at university and after trying to upload a sketch I get an error saying that the upload failed. After disconnecting and re-connecting the Arduino, the PC no longer shows up on the COM ports! Now, whenever I connect the device I get this orange pulsing (experience tells me that it's probably an error indicator, but I just don't know what it means)
does anyone know if something has blown or if there was a short circuit that has caused this or better yet how to fix it?
quick update! After pressing and holding the reset button for a long time it seems to have come back to life! Now the PC recognises it on the COM port and the Arduino IDE says that the Portenta is connected
does anyone know what caused the issue to begin with? I just want to make sure I'm not breaking my Portenta as they aren't cheap!
In this case try dis-connecting and again connecting
Secondly Try Pressing Restart button of your device
Check your cable that it mustn't have any cut or break between them
Try restarting your computer
Try out these step and then reply
In this case try dis-connecting and again connecting
Secondly Try Pressing Restart button of your device
Check your cable that it mustn't have any cut or break between them
Try restarting your Device
In this case try dis-connecting and again connecting
Secondly Try Pressing Restart button of your device
Check your cable that it mustn't have any cut or break between them
Try restarting your computer
Have u done these step?
What are u trying to build up with device Likewise this device is used to connect devices, visualize data, control and share your projects from anywhere in the world.
So what r u tying to do so
This is really a little bit expensive device and I can understand how u r felling right now So pls try these step and Revert back
The portenta works now, I just don't know what caused it to stop working in the first place.
I have a waveform generator that was producing a 0 - 3.3 V sin wave which is connected to the A0 pin. I was then using the Serial plotter to print the waveform. I did leave the signal attached whilst uploading a new sketch, so I'm not sure if this is what caused the problem
A 4X long, 4X short blink pattern indicates Mbed OS has crashed. This causes the USB code that creates the CDC serial port to stop running, thus no port.
As you discovered already, you can recover from this by putting the board in bootloader mode via the double reset technique. Since there was some confusion about single vs double reset, etc. in this discussion, I'll describe the precise technique:
Press and release the reset button on the Portenta H7.
Wait for the green light to come on.
It does this almost immediately, but you do need to wait for it.
While the green LED is still on (it only stays on for one second so you need to be quick), press and release the reset button again.
You should now see the green LED pulsing, which indicates the bootloader is running.
If not, repeat the process in case you didn't get the timing quite right.
The board will now stay in bootloader mode until one of the following occurs:
A sketch is uploaded to the board.
The reset button is pressed.
The board is power cycled.
After doing this, you will be able to select the port of your Portenta H7 board from the Arduino IDE's Tools > Port menu. The port may be different when the bootloader is running so don't assume you already have the correct port selected.
There are a lot of different things that can crash Mbed OS. I suppose it is possible that a corrupted program resulting from an interrupted upload might cause it, though it seems unlikely to occur IRL.
More often it is caused by a problem in the sketch. For example, simply attempting to use analogWrite() on one of the pins without PWM support will cause a crash:
I don't think it is likely to be caused by physical conditions though. So I wouldn't get too paranoid that this is an indication that there is physical damage to your board. These crashes are simply a normal part of development for the Arduino boards that use the Mbed OS core. You're sure to see plenty more of them as you continue in your work with the Portenta H7. The important thing is to know how to recover the board and then work to find the problem in the code that caused the crash.
Debug information is printed on Serial1 when Mbed OS crashes. You can view the debug output by following these instructions (no guarantee it will be helpful though):
Unplug your Nano 33 BLE board from the computer or power supply.
Make the following connections between a USB to TTL serial adapter (AKA "FTDI") and your Nano 33 BLE:
Adapter
Nano 33 BLE
RX
TX1
GND
GND
You will also need to power the Nano 33 BLE. You can do this via the USB socket, or power it from the USB to TTL serial adapter's VCC pin. If the serial adapter's VCC pin is outputting 5 V, connect it to the Nano 33 BLE's VIN pin. If the serial adapter's VCC pin is outputting 3.3 V, connect it to the Nano 33 BLE's 3.3 V pin.
Connect the serial adapter to your computer with a USB cable.
Select the port of the serial adapter from the Arduino IDE's Tools > Port menu.
Select Tools > Serial Monitor from the Arduino IDE menus.
Set the baud rate menu at the bottom right corner of Serial Monitor to 115200.
Press and release the reset button on the Nano 33 BLE. You should now see the "MbedOS Error Info" output in the Serial Monitor output field.
Hi @in0, thank you for the detailed answer! that makes a lot more sense now.
The crash occurred after trying to upload a sketch to the Portenta. In the loop of my code, I have this:
void loop() {
// as loop() is inside an endless for(;;), return will simply restart loop()
if (isCommandReady() == false)
return;
// ========= Code to read the ADC =========
}
where the isCommandReady() function just checks the Serial Port to see if a predefined terminator has been read.
so is there a problem caused by me using this setup? or could it have just been a quirky upload?