Hi there for whatever reason I can't seem to get my code to upload to the nano rp2040
I have the board and com selected but i get the error
Sketch uses 97134 bytes (0%) of program storage space. Maximum is 16777216 bytes.
Global variables use 44480 bytes (16%) of dynamic memory, leaving 225856 bytes for local variables. Maximum is 270336 bytes.
Performing 1200-bps touch reset on serial port COM1
"C:\Users\markl\AppData\Local\Arduino15\packages\arduino\tools\rp2040tools\1.0.6/rp2040load" -v -D "C:\Users\markl\AppData\Local\Temp\arduino-sketch-CEF29DEE4D5E0076A00DB65CCBE2B194/ble_imu.ino.elf"
rp2040load 1.0.6 - compiled with go1.16.2
.....................
Failed uploading: uploading error: exit status 1
I tried some various trouble shooting methods like uploading while the board is in reset mode, but still no avail
Make sure the USB cable is completely plugged into both the Arduino board and the PC and then try again.
If that doesn't help, you may have a damaged/defective or charge-only USB cable. Try again with a different cable.
Either of the above can result in the power connections being made (and thus LED lights on the board), but no data connections (and thus no port/drive for the board).
So with a new cable in use, following the steps provided I am able to establish a connection. However, after I flash my code to the nano2040 it says
Sketch uses 97867 bytes (0%) of program storage space. Maximum is 16777216 bytes.
Global variables use 44468 bytes (16%) of dynamic memory, leaving 225868 bytes for local variables. Maximum is 270336 bytes.
Performing 1200-bps touch reset on serial port COM3
"C:\Users\markl\AppData\Local\Arduino15\packages\arduino\tools\rp2040tools\1.0.6/rp2040load" -v -D "C:\Users\markl\AppData\Local\Temp\arduino-sketch-CEF29DEE4D5E0076A00DB65CCBE2B194/ble_imu.ino.elf"
rp2040load 1.0.6 - compiled with go1.16.2
.Loading into Flash: [ ] 0%
Loading into Flash: [= ] 4%
Loading into Flash: [== ] 8%
Loading into Flash: [=== ] 12%
Loading into Flash: [==== ] 16%
Loading into Flash: [====== ] 20%
Loading into Flash: [======= ] 24%
Loading into Flash: [======== ] 29%
Loading into Flash: [========= ] 33%
Loading into Flash: [=========== ] 37%
Loading into Flash: [============ ] 41%
Loading into Flash: [============= ] 45%
Loading into Flash: [============== ] 49%
Loading into Flash: [================ ] 54%
Loading into Flash: [================= ] 58%
Loading into Flash: [================== ] 62%
Loading into Flash: [=================== ] 66%
Loading into Flash: [===================== ] 70%
Loading into Flash: [====================== ] 74%
Loading into Flash: [======================= ] 78%
Loading into Flash: [======================== ] 83%
Loading into Flash: [========================== ] 87%
Loading into Flash: [=========================== ] 91%
Loading into Flash: [============================ ] 95%
Loading into Flash: [============================= ] 99%
Loading into Flash: [==============================] 100%
After it flashes the com connection disappears again.
I'm using a basic example sketch:
#include <Arduino_LSM6DSOX.h>
void setup() {
}
void loop() {
float x, y, z;
if (IMU.accelerationAvailable()) {
IMU.readAcceleration(x, y, z);
Serial.print(x);
Serial.print('\t');
Serial.print(y);
Serial.print('\t');
Serial.println(z);
}
}
I want to be reading data from the serial port so the fact that the connection disappears makes it impossible to use
Hi @mmiller305033. The problem is you forgot to add a call to IMU.begin() in your setup function.
You can see how that is done in the library's documentation here:
You can also check the examples that demonstrate the usage of the library. They are listed under the File > Examples > Arduino_LSM6DSOX menu in Arduino IDE.
I'm having the same issue here. I have nothing connected to any of the pins on the board. I was able to upload in bootloader mode, complete a hard reset, and complete a factory reset all successfully.
But when I try to upload a sketch (even a sketch with no additional code aside from setup and loop methods defined), I get Failed uploading: uploading error: exit status 1
I tried a different computer with the exact same cable and I can upload to both my Arduino Leonardo and Nano successfully. I checked the driver versions and they appear exactly the same in Device Manager on both computers. Both PCs are on the same version of Windows (21H2). Both are running the newest Arduino IDE (2.1.0).
The only big difference I can think of is one has an AMD CPU and the other has Intel.