Nano RP2040 Connect

There is an example in the embed core for Arduino Nano RP2040 Connect, named 'AccessFlashAsUSBDisk'. I loaded the program, like below...

/*
   QSPI as USB Mass Storage
   This example shows how to expose a QSPIF BlockDevice (16MB external flash on the Portenta H7)
   as an USB stick. It can be adapted to any kind of BlockDevice (FlashIAP or either RAM via HeapBlockDevice)
   Before loading this example, make sure you execute WiFiFirmwareUpdater sketch
   to create and format the proper partitions.
*/

#include "PluggableUSBMSD.h"
#include "QSPIFBlockDevice.h"
#include "MBRBlockDevice.h"
#include "FATFileSystem.h"

static QSPIFBlockDevice root;
mbed::MBRBlockDevice wifi_data(&root, 1);
mbed::MBRBlockDevice ota_data(&root, 2);
static mbed::FATFileSystem wifi("wifi");
static mbed::FATFileSystem ota("ota");

void USBMSD::begin()
{
  int err = wifi.mount(&wifi_data);
  if (err) {
    while (!Serial);
    Serial.println("Please run WiFiFirmwareUpdater before");
    return;
  }
  ota.mount(&ota_data);
}


USBMSD MassStorage(&root);

void setup() {
  Serial.begin(115200);
  MassStorage.begin();
}

void printDirectory(char* name) {
  DIR *d;
  struct dirent *p;

  d = opendir(name);
  if (d != NULL) {
    while ((p = readdir(d)) != NULL) {
      Serial.println(p->d_name);
    }
  }
  closedir(d);
}

void loop() {
  if (MassStorage.media_removed()) {
    // list the content of the partitions
    // you may need to restart the board for the list to update if you copied new files
    Serial.println("Content of WiFi partition:");
    printDirectory("/wifi");
    Serial.println("Content of OTA partition:");
    printDirectory("/ota");
  }
  delay(1000);
}

First it gave an error saying QSPIFBlockDevice.h was missing. So, I went to github to retrieve the relevant library, to find that the library is now deprecated and no longer supported by ARM. Anyway, I downloaded and installed the library. On compiling, below is what Arduino embed spits out...

Arduino: 1.8.19 (Linux), Board: "Arduino Nano RP2040 Connect"











In file included from /home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:17:0:
QSPIFBlockDevice.h:28:44: error: 'BD_ERROR_DEVICE_ERROR' was not declared in this scope
     QSPIF_BD_ERROR_DEVICE_ERROR          = BD_ERROR_DEVICE_ERROR, /*!< device specific error -4001 */
                                            ^~~~~~~~~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.h:28:44: note: suggested alternative:
In file included from /home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.h:20:0,
                 from /home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:17:
/home/rajiv/.arduino15/packages/arduino/hardware/mbed_nano/3.5.1/cores/arduino/mbed/storage/blockdevice/include/blockdevice/BlockDevice.h:34:5: note:   'BD_ERROR_DEVICE_ERROR'
     BD_ERROR_DEVICE_ERROR       = -4001, /*!< device specific error */
     ^~~~~~~~~~~~~~~~~~~~~
In file included from /home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:17:0:
QSPIFBlockDevice.h:88:45: error: expected class-name before '{' token
 class QSPIFBlockDevice : public BlockDevice {
                                             ^
QSPIFBlockDevice.h:134:36: error: 'bd_addr_t' has not been declared
     virtual int read(void *buffer, bd_addr_t addr, bd_size_t size);
                                    ^~~~~~~~~
QSPIFBlockDevice.h:134:52: error: 'bd_size_t' has not been declared
     virtual int read(void *buffer, bd_addr_t addr, bd_size_t size);
                                                    ^~~~~~~~~
QSPIFBlockDevice.h:149:45: error: 'bd_addr_t' has not been declared
     virtual int program(const void *buffer, bd_addr_t addr, bd_size_t size);
                                             ^~~~~~~~~
QSPIFBlockDevice.h:149:61: error: 'bd_size_t' has not been declared
     virtual int program(const void *buffer, bd_addr_t addr, bd_size_t size);
                                                             ^~~~~~~~~
QSPIFBlockDevice.h:164:23: error: 'bd_addr_t' has not been declared
     virtual int erase(bd_addr_t addr, bd_size_t size);
                       ^~~~~~~~~
QSPIFBlockDevice.h:164:39: error: 'bd_size_t' has not been declared
     virtual int erase(bd_addr_t addr, bd_size_t size);
                                       ^~~~~~~~~
QSPIFBlockDevice.h:170:13: error: 'bd_size_t' does not name a type; did you mean 'blksize_t'?
     virtual bd_size_t get_read_size() const;
             ^~~~~~~~~
             blksize_t
QSPIFBlockDevice.h:177:13: error: 'bd_size_t' does not name a type; did you mean 'blksize_t'?
     virtual bd_size_t get_program_size() const;
             ^~~~~~~~~
             blksize_t
QSPIFBlockDevice.h:184:13: error: 'bd_size_t' does not name a type; did you mean 'blksize_t'?
     virtual bd_size_t get_erase_size() const;
             ^~~~~~~~~
             blksize_t
QSPIFBlockDevice.h:192:13: error: 'bd_size_t' does not name a type; did you mean 'blksize_t'?
     virtual bd_size_t get_erase_size(bd_addr_t addr);
             ^~~~~~~~~
             blksize_t
QSPIFBlockDevice.h:209:13: error: 'bd_size_t' does not name a type; did you mean 'blksize_t'?
     virtual bd_size_t size() const;
             ^~~~~~~~~
             blksize_t
QSPIFBlockDevice.h:229:5: error: 'qspi_status_t' does not name a type; did you mean 'spi_inst_t'?
     qspi_status_t _qspi_send_program_command(unsigned int prog_instruction, const void *buffer, bd_addr_t addr,
     ^~~~~~~~~~~~~
     spi_inst_t
QSPIFBlockDevice.h:233:5: error: 'qspi_status_t' does not name a type; did you mean 'spi_inst_t'?
     qspi_status_t _qspi_send_read_command(unsigned int read_instruction, void *buffer, bd_addr_t addr, bd_size_t size);
     ^~~~~~~~~~~~~
     spi_inst_t
QSPIFBlockDevice.h:236:5: error: 'qspi_status_t' does not name a type; did you mean 'spi_inst_t'?
     qspi_status_t _qspi_send_erase_command(unsigned int erase_instruction, bd_addr_t addr, bd_size_t size);
     ^~~~~~~~~~~~~
     spi_inst_t
QSPIFBlockDevice.h:239:5: error: 'qspi_status_t' does not name a type; did you mean 'spi_inst_t'?
     qspi_status_t _qspi_send_general_command(unsigned int instruction_int, bd_addr_t addr, const char *tx_buffer,
     ^~~~~~~~~~~~~
     spi_inst_t
QSPIFBlockDevice.h:243:5: error: 'qspi_status_t' does not name a type; did you mean 'spi_inst_t'?
     qspi_status_t _qspi_configure_format(qspi_bus_width_t inst_width, qspi_bus_width_t address_width,
     ^~~~~~~~~~~~~
     spi_inst_t
In file included from /home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:17:0:
QSPIFBlockDevice.h:248:5: error: 'qspi_status_t' does not name a type; did you mean 'spi_inst_t'?
     qspi_status_t _qspi_set_frequency(int freq);
     ^~~~~~~~~~~~~
     spi_inst_t
QSPIFBlockDevice.h:300:33: error: 'bd_size_t' has not been declared
     int _utils_find_addr_region(bd_size_t offset);
                                 ^~~~~~~~~
QSPIFBlockDevice.h:310:11: error: 'QSPI' in namespace 'mbed' does not name a type
     mbed::QSPI _qspi;
           ^~~~
QSPIFBlockDevice.h:315:12: error: 'SingletonPtr' does not name a type
     static SingletonPtr<PlatformMutex> _devices_mutex;
            ^~~~~~~~~~~~
QSPIFBlockDevice.h:324:5: error: 'PlatformMutex' does not name a type
     PlatformMutex _mutex;
     ^~~~~~~~~~~~~
QSPIFBlockDevice.h:341:5: error: 'bd_size_t' does not name a type; did you mean 'blksize_t'?
     bd_size_t _region_high_boundary[QSPIF_MAX_REGIONS]; //region high address offset boundary
     ^~~~~~~~~
     blksize_t
QSPIFBlockDevice.h:348:5: error: 'bd_size_t' does not name a type; did you mean 'blksize_t'?
     bd_size_t _device_size_bytes;
     ^~~~~~~~~
     blksize_t
QSPIFBlockDevice.h:351:5: error: 'qspi_bus_width_t' does not name a type; did you mean 'spi_inst_t'?
     qspi_bus_width_t _inst_width; //Bus width for Instruction phase
     ^~~~~~~~~~~~~~~~
     spi_inst_t
QSPIFBlockDevice.h:352:5: error: 'qspi_bus_width_t' does not name a type; did you mean 'spi_inst_t'?
     qspi_bus_width_t _address_width; //Bus width for Address phase
     ^~~~~~~~~~~~~~~~
     spi_inst_t
QSPIFBlockDevice.h:353:5: error: 'qspi_address_size_t' does not name a type
     qspi_address_size_t _address_size; // number of bytes for address
     ^~~~~~~~~~~~~~~~~~~
QSPIFBlockDevice.h:354:5: error: 'qspi_bus_width_t' does not name a type; did you mean 'spi_inst_t'?
     qspi_bus_width_t _data_width; //Bus width for Data phase
     ^~~~~~~~~~~~~~~~
     spi_inst_t
In file included from /home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:17:0:
QSPIFBlockDevice.h:104:49: error: 'MBED_CONF_QSPIF_QSPI_FREQ' was not declared in this scope
                      int clock_mode, int freq = MBED_CONF_QSPIF_QSPI_FREQ);
                                                 ^~~~~~~~~~~~~~~~~~~~~~~~~
QSPIFBlockDevice.cpp:107:1: error: 'SingletonPtr' does not name a type
 SingletonPtr<PlatformMutex> QSPIFBlockDevice::_devices_mutex;
 ^~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp: In constructor 'QSPIFBlockDevice::QSPIFBlockDevice(PinName, PinName, PinName, PinName, PinName, PinName, int, int)':
QSPIFBlockDevice.cpp:115:7: error: class 'QSPIFBlockDevice' does not have any field named '_qspi'
     : _qspi(io0, io1, io2, io3, sclk, csel, clock_mode), _csel(csel), _freq(freq), _device_size_bytes(0),
       ^~~~~
QSPIFBlockDevice.cpp:115:84: error: class 'QSPIFBlockDevice' does not have any field named '_device_size_bytes'
     : _qspi(io0, io1, io2, io3, sclk, csel, clock_mode), _csel(csel), _freq(freq), _device_size_bytes(0),
                                                                                    ^~~~~~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp: In member function 'virtual int QSPIFBlockDevice::init()':
QSPIFBlockDevice.cpp:149:23: error: 'QSPI_STATUS_OK' was not declared in this scope
     int qspi_status = QSPI_STATUS_OK;
                       ^~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:149:23: note: suggested alternative: '_SYS_STAT_H'
     int qspi_status = QSPI_STATUS_OK;
                       ^~~~~~~~~~~~~~
                       _SYS_STAT_H
QSPIFBlockDevice.cpp:151:5: error: '_mutex' was not declared in this scope
     _mutex.lock();
     ^~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:151:5: note: suggested alternative: '__utoa'
     _mutex.lock();
     ^~~~~~
     __utoa
QSPIFBlockDevice.cpp:169:5: error: '_inst_width' was not declared in this scope
     _inst_width = QSPI_CFG_BUS_SINGLE;
     ^~~~~~~~~~~
QSPIFBlockDevice.cpp:169:19: error: 'QSPI_CFG_BUS_SINGLE' was not declared in this scope
     _inst_width = QSPI_CFG_BUS_SINGLE;
                   ^~~~~~~~~~~~~~~~~~~
QSPIFBlockDevice.cpp:170:5: error: '_address_width' was not declared in this scope
     _address_width = QSPI_CFG_BUS_SINGLE;
     ^~~~~~~~~~~~~~
QSPIFBlockDevice.cpp:171:5: error: '_address_size' was not declared in this scope
     _address_size = QSPI_CFG_ADDR_SIZE_24;
     ^~~~~~~~~~~~~
QSPIFBlockDevice.cpp:171:21: error: 'QSPI_CFG_ADDR_SIZE_24' was not declared in this scope
     _address_size = QSPI_CFG_ADDR_SIZE_24;
                     ^~~~~~~~~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:171:21: note: suggested alternative: 'QSPIF_SFDP_HEADER_SIZE'
     _address_size = QSPI_CFG_ADDR_SIZE_24;
                     ^~~~~~~~~~~~~~~~~~~~~
                     QSPIF_SFDP_HEADER_SIZE
QSPIFBlockDevice.cpp:172:5: error: '_data_width' was not declared in this scope
     _data_width = QSPI_CFG_BUS_SINGLE;
     ^~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:172:5: note: suggested alternative: 'data_length'
     _data_width = QSPI_CFG_BUS_SINGLE;
     ^~~~~~~~~~~
     data_length
QSPIFBlockDevice.cpp:178:27: error: '_qspi_set_frequency' was not declared in this scope
     if (QSPI_STATUS_OK != _qspi_set_frequency(_freq)) {
                           ^~~~~~~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:178:27: note: suggested alternative: 'spi_get_dreq'
     if (QSPI_STATUS_OK != _qspi_set_frequency(_freq)) {
                           ^~~~~~~~~~~~~~~~~~~
                           spi_get_dreq
QSPIFBlockDevice.cpp:194:19: error: '_qspi_send_general_command' was not declared in this scope
     qspi_status = _qspi_send_general_command(QSPIF_RDID, QSPI_NO_ADDRESS_COMMAND, NULL, 0, (char *)vendor_device_ids,
                   ^~~~~~~~~~~~~~~~~~~~~~~~~~
QSPIFBlockDevice.cpp:236:9: error: '_device_size_bytes' was not declared in this scope
         _device_size_bytes; // If there's no region map, we have a single region sized the entire device size
         ^~~~~~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:236:9: note: suggested alternative: '_region_size_bytes'
         _device_size_bytes; // If there's no region map, we have a single region sized the entire device size
         ^~~~~~~~~~~~~~~~~~
         _region_size_bytes
QSPIFBlockDevice.cpp:237:5: error: '_region_high_boundary' was not declared in this scope
     _region_high_boundary[0] = _device_size_bytes - 1;
     ^~~~~~~~~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:237:5: note: suggested alternative: '_regions_count'
     _region_high_boundary[0] = _device_size_bytes - 1;
     ^~~~~~~~~~~~~~~~~~~~~
     _regions_count
QSPIFBlockDevice.cpp:251:28: error: 'QSPI_CFG_ALT_SIZE_8' was not declared in this scope
                            QSPI_CFG_ALT_SIZE_8, QSPI_CFG_BUS_SINGLE, 0);
                            ^~~~~~~~~~~~~~~~~~~
QSPIFBlockDevice.cpp:250:5: error: '_qspi_configure_format' was not declared in this scope
     _qspi_configure_format(QSPI_CFG_BUS_SINGLE, QSPI_CFG_BUS_SINGLE, QSPI_CFG_ADDR_SIZE_24, QSPI_CFG_BUS_SINGLE,
     ^~~~~~~~~~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:250:5: note: suggested alternative: 'spi_set_format'
     _qspi_configure_format(QSPI_CFG_BUS_SINGLE, QSPI_CFG_BUS_SINGLE, QSPI_CFG_ADDR_SIZE_24, QSPI_CFG_BUS_SINGLE,
     ^~~~~~~~~~~~~~~~~~~~~~
     spi_set_format
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp: In member function 'virtual int QSPIFBlockDevice::deinit()':
QSPIFBlockDevice.cpp:265:5: error: '_mutex' was not declared in this scope
     _mutex.lock();
     ^~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:265:5: note: suggested alternative: '__utoa'
     _mutex.lock();
     ^~~~~~
     __utoa
QSPIFBlockDevice.cpp:281:5: error: 'qspi_status_t' was not declared in this scope
     qspi_status_t status = _qspi_send_general_command(QSPIF_WRDI, QSPI_NO_ADDRESS_COMMAND, NULL, 0, NULL, 0);
     ^~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:281:5: note: suggested alternative: 'spi_inst_t'
     qspi_status_t status = _qspi_send_general_command(QSPIF_WRDI, QSPI_NO_ADDRESS_COMMAND, NULL, 0, NULL, 0);
     ^~~~~~~~~~~~~
     spi_inst_t
QSPIFBlockDevice.cpp:282:9: error: 'status' was not declared in this scope
     if (status != QSPI_STATUS_OK)  {
         ^~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:282:9: note: suggested alternative: 'statvfs'
     if (status != QSPI_STATUS_OK)  {
         ^~~~~~
         statvfs
QSPIFBlockDevice.cpp:282:19: error: 'QSPI_STATUS_OK' was not declared in this scope
     if (status != QSPI_STATUS_OK)  {
                   ^~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:282:19: note: suggested alternative: '_SYS_STAT_H'
     if (status != QSPI_STATUS_OK)  {
                   ^~~~~~~~~~~~~~
                   _SYS_STAT_H
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp: At global scope:
QSPIFBlockDevice.cpp:298:5: error: prototype for 'int QSPIFBlockDevice::read(void*, mbed::bd_addr_t, mbed::bd_size_t)' does not match any in class 'QSPIFBlockDevice'
 int QSPIFBlockDevice::read(void *buffer, bd_addr_t addr, bd_size_t size)
     ^~~~~~~~~~~~~~~~
In file included from /home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:17:0:
QSPIFBlockDevice.h:134:17: error: candidate is: virtual int QSPIFBlockDevice::read(void*, int, int)
     virtual int read(void *buffer, bd_addr_t addr, bd_size_t size);
                 ^~~~
QSPIFBlockDevice.cpp:323:5: error: prototype for 'int QSPIFBlockDevice::program(const void*, mbed::bd_addr_t, mbed::bd_size_t)' does not match any in class 'QSPIFBlockDevice'
 int QSPIFBlockDevice::program(const void *buffer, bd_addr_t addr, bd_size_t size)
     ^~~~~~~~~~~~~~~~
In file included from /home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:17:0:
QSPIFBlockDevice.h:149:17: error: candidate is: virtual int QSPIFBlockDevice::program(const void*, int, int)
     virtual int program(const void *buffer, bd_addr_t addr, bd_size_t size);
                 ^~~~~~~
QSPIFBlockDevice.cpp:379:5: error: prototype for 'int QSPIFBlockDevice::erase(mbed::bd_addr_t, mbed::bd_size_t)' does not match any in class 'QSPIFBlockDevice'
 int QSPIFBlockDevice::erase(bd_addr_t addr, bd_size_t in_size)
     ^~~~~~~~~~~~~~~~
In file included from /home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:17:0:
QSPIFBlockDevice.h:164:17: error: candidate is: virtual int QSPIFBlockDevice::erase(int, int)
     virtual int erase(bd_addr_t addr, bd_size_t size);
                 ^~~~~
QSPIFBlockDevice.cpp:462:45: error: no 'mbed::bd_size_t QSPIFBlockDevice::get_read_size() const' member function declared in class 'QSPIFBlockDevice'
 bd_size_t QSPIFBlockDevice::get_read_size() const
                                             ^~~~~
QSPIFBlockDevice.cpp:468:48: error: no 'mbed::bd_size_t QSPIFBlockDevice::get_program_size() const' member function declared in class 'QSPIFBlockDevice'
 bd_size_t QSPIFBlockDevice::get_program_size() const
                                                ^~~~~
QSPIFBlockDevice.cpp:474:46: error: no 'mbed::bd_size_t QSPIFBlockDevice::get_erase_size() const' member function declared in class 'QSPIFBlockDevice'
 bd_size_t QSPIFBlockDevice::get_erase_size() const
                                              ^~~~~
QSPIFBlockDevice.cpp:481:58: error: no 'mbed::bd_size_t QSPIFBlockDevice::get_erase_size(mbed::bd_addr_t)' member function declared in class 'QSPIFBlockDevice'
 bd_size_t QSPIFBlockDevice::get_erase_size(bd_addr_t addr)
                                                          ^
QSPIFBlockDevice.cpp:512:36: error: no 'mbed::bd_size_t QSPIFBlockDevice::size() const' member function declared in class 'QSPIFBlockDevice'
 bd_size_t QSPIFBlockDevice::size() const
                                    ^~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp: In member function 'int QSPIFBlockDevice::add_new_csel_instance(PinName)':
QSPIFBlockDevice.cpp:537:5: error: '_devices_mutex' was not declared in this scope
     _devices_mutex->lock();
     ^~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp: In member function 'int QSPIFBlockDevice::remove_csel_instance(PinName)':
QSPIFBlockDevice.cpp:568:5: error: '_devices_mutex' was not declared in this scope
     _devices_mutex->lock();
     ^~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp: In member function 'int QSPIFBlockDevice::_sfdp_parse_sector_map_table(uint32_t, size_t)':
QSPIFBlockDevice.cpp:597:5: error: 'qspi_status_t' was not declared in this scope
     qspi_status_t status = _qspi_send_read_command(QSPIF_SFDP, (char *)sector_map_table, sector_map_table_addr /*address*/,
     ^~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:597:5: note: suggested alternative: 'spi_inst_t'
     qspi_status_t status = _qspi_send_read_command(QSPIF_SFDP, (char *)sector_map_table, sector_map_table_addr /*address*/,
     ^~~~~~~~~~~~~
     spi_inst_t
QSPIFBlockDevice.cpp:599:9: error: 'status' was not declared in this scope
     if (status != QSPI_STATUS_OK) {
         ^~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:599:9: note: suggested alternative: 'statvfs'
     if (status != QSPI_STATUS_OK) {
         ^~~~~~
         statvfs
QSPIFBlockDevice.cpp:599:19: error: 'QSPI_STATUS_OK' was not declared in this scope
     if (status != QSPI_STATUS_OK) {
                   ^~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:599:19: note: suggested alternative: '_SYS_STAT_H'
     if (status != QSPI_STATUS_OK) {
                   ^~~~~~~~~~~~~~
                   _SYS_STAT_H
QSPIFBlockDevice.cpp:624:9: error: '_region_high_boundary' was not declared in this scope
         _region_high_boundary[i_ind] = (_region_size_bytes[i_ind] - 1) + prev_boundary;
         ^~~~~~~~~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:624:9: note: suggested alternative: '_regions_count'
         _region_high_boundary[i_ind] = (_region_size_bytes[i_ind] - 1) + prev_boundary;
         ^~~~~~~~~~~~~~~~~~~~~
         _regions_count
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp: In member function 'int QSPIFBlockDevice::_sfdp_parse_basic_param_table(uint32_t, size_t)':
QSPIFBlockDevice.cpp:650:5: error: 'qspi_status_t' was not declared in this scope
     qspi_status_t status = _qspi_send_read_command(QSPIF_SFDP, (char *)param_table, basic_table_addr /*address*/,
     ^~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:650:5: note: suggested alternative: 'spi_inst_t'
     qspi_status_t status = _qspi_send_read_command(QSPIF_SFDP, (char *)param_table, basic_table_addr /*address*/,
     ^~~~~~~~~~~~~
     spi_inst_t
QSPIFBlockDevice.cpp:652:9: error: 'status' was not declared in this scope
     if (status != QSPI_STATUS_OK) {
         ^~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:652:9: note: suggested alternative: 'statvfs'
     if (status != QSPI_STATUS_OK) {
         ^~~~~~
         statvfs
QSPIFBlockDevice.cpp:652:19: error: 'QSPI_STATUS_OK' was not declared in this scope
     if (status != QSPI_STATUS_OK) {
                   ^~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:652:19: note: suggested alternative: '_SYS_STAT_H'
     if (status != QSPI_STATUS_OK) {
                   ^~~~~~~~~~~~~~
                   _SYS_STAT_H
QSPIFBlockDevice.cpp:669:5: error: '_device_size_bytes' was not declared in this scope
     _device_size_bytes = (density_bits + 1) / 8;
     ^~~~~~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:669:5: note: suggested alternative: '_region_size_bytes'
     _device_size_bytes = (density_bits + 1) / 8;
     ^~~~~~~~~~~~~~~~~~
     _region_size_bytes
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp: In member function 'int QSPIFBlockDevice::_sfdp_parse_sfdp_headers(uint32_t&, size_t&, uint32_t&, size_t&)':
QSPIFBlockDevice.cpp:716:28: error: 'QSPI_CFG_BUS_SINGLE' was not declared in this scope
     _qspi_configure_format(QSPI_CFG_BUS_SINGLE, QSPI_CFG_BUS_SINGLE, QSPI_CFG_ADDR_SIZE_24, QSPI_CFG_BUS_SINGLE,
                            ^~~~~~~~~~~~~~~~~~~
QSPIFBlockDevice.cpp:716:70: error: 'QSPI_CFG_ADDR_SIZE_24' was not declared in this scope
     _qspi_configure_format(QSPI_CFG_BUS_SINGLE, QSPI_CFG_BUS_SINGLE, QSPI_CFG_ADDR_SIZE_24, QSPI_CFG_BUS_SINGLE,
                                                                      ^~~~~~~~~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:716:70: note: suggested alternative: 'QSPIF_SFDP_HEADER_SIZE'
     _qspi_configure_format(QSPI_CFG_BUS_SINGLE, QSPI_CFG_BUS_SINGLE, QSPI_CFG_ADDR_SIZE_24, QSPI_CFG_BUS_SINGLE,
                                                                      ^~~~~~~~~~~~~~~~~~~~~
                                                                      QSPIF_SFDP_HEADER_SIZE
QSPIFBlockDevice.cpp:717:28: error: 'QSPI_CFG_ALT_SIZE_8' was not declared in this scope
                            QSPI_CFG_ALT_SIZE_8, QSPI_CFG_BUS_SINGLE, 8);
                            ^~~~~~~~~~~~~~~~~~~
In file included from /home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/AccessFlashAsUSBDisk_NanoRP2040ConnectExample.ino:10:0:
QSPIFBlockDevice.h:28:44: error: 'BD_ERROR_DEVICE_ERROR' was not declared in this scope
     QSPIF_BD_ERROR_DEVICE_ERROR          = BD_ERROR_DEVICE_ERROR, /*!< device specific error -4001 */
                                            ^~~~~~~~~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.h:28:44: note: suggested alternative:
In file included from /home/rajiv/.arduino15/packages/arduino/hardware/mbed_nano/3.5.1/libraries/USBMSD/src/PluggableUSBMSD.h:28:0,
                 from /home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/AccessFlashAsUSBDisk_NanoRP2040ConnectExample.ino:9:
/home/rajiv/.arduino15/packages/arduino/hardware/mbed_nano/3.5.1/cores/arduino/mbed/storage/blockdevice/include/blockdevice/BlockDevice.h:34:5: note:   'BD_ERROR_DEVICE_ERROR'
     BD_ERROR_DEVICE_ERROR       = -4001, /*!< device specific error */
     ^~~~~~~~~~~~~~~~~~~~~
In file included from /home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/AccessFlashAsUSBDisk_NanoRP2040ConnectExample.ino:10:0:
QSPIFBlockDevice.h:88:45: error: expected class-name before '{' token
 class QSPIFBlockDevice : public BlockDevice {
                                             ^
QSPIFBlockDevice.h:134:36: error: 'bd_addr_t' has not been declared
     virtual int read(void *buffer, bd_addr_t addr, bd_size_t size);
                                    ^~~~~~~~~
QSPIFBlockDevice.h:134:52: error: 'bd_size_t' has not been declared
     virtual int read(void *buffer, bd_addr_t addr, bd_size_t size);
                                                    ^~~~~~~~~
QSPIFBlockDevice.h:149:45: error: 'bd_addr_t' has not been declared
     virtual int program(const void *buffer, bd_addr_t addr, bd_size_t size);
                                             ^~~~~~~~~
QSPIFBlockDevice.h:149:61: error: 'bd_size_t' has not been declared
     virtual int program(const void *buffer, bd_addr_t addr, bd_size_t size);
                                                             ^~~~~~~~~
QSPIFBlockDevice.h:164:23: error: 'bd_addr_t' has not been declared
     virtual int erase(bd_addr_t addr, bd_size_t size);
                       ^~~~~~~~~
QSPIFBlockDevice.h:164:39: error: 'bd_size_t' has not been declared
     virtual int erase(bd_addr_t addr, bd_size_t size);
                                       ^~~~~~~~~
QSPIFBlockDevice.h:170:13: error: 'bd_size_t' does not name a type; did you mean 'blksize_t'?
     virtual bd_size_t get_read_size() const;
             ^~~~~~~~~
             blksize_t
QSPIFBlockDevice.h:177:13: error: 'bd_size_t' does not name a type; did you mean 'blksize_t'?
     virtual bd_size_t get_program_size() const;
             ^~~~~~~~~
             blksize_t
QSPIFBlockDevice.cpp:716:5: error: '_qspi_configure_format' was not declared in this scope
     _qspi_configure_format(QSPI_CFG_BUS_SINGLE, QSPI_CFG_BUS_SINGLE, QSPI_CFG_ADDR_SIZE_24, QSPI_CFG_BUS_SINGLE,
     ^~~~~~~~~~~~~~~~~~~~~~
QSPIFBlockDevice.h:184:13: error: 'bd_size_t' does not name a type; did you mean 'blksize_t'?
     virtual bd_size_t get_erase_size() const;
             ^~~~~~~~~
             blksize_t
QSPIFBlockDevice.h:192:13: error: 'bd_size_t' does not name a type; did you mean 'blksize_t'?
     virtual bd_size_t get_erase_size(bd_addr_t addr);
             ^~~~~~~~~
             blksize_t
QSPIFBlockDevice.h:209:13: error: 'bd_size_t' does not name a type; did you mean 'blksize_t'?
     virtual bd_size_t size() const;
             ^~~~~~~~~
             blksize_t
QSPIFBlockDevice.h:229:5: error: 'qspi_status_t' does not name a type; did you mean 'osStatus_t'?
     qspi_status_t _qspi_send_program_command(unsigned int prog_instruction, const void *buffer, bd_addr_t addr,
     ^~~~~~~~~~~~~
     osStatus_t
QSPIFBlockDevice.h:233:5: error: 'qspi_status_t' does not name a type; did you mean 'osStatus_t'?
     qspi_status_t _qspi_send_read_command(unsigned int read_instruction, void *buffer, bd_addr_t addr, bd_size_t size);
     ^~~~~~~~~~~~~
     osStatus_t
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:716:5: note: suggested alternative: 'spi_set_format'
     _qspi_configure_format(QSPI_CFG_BUS_SINGLE, QSPI_CFG_BUS_SINGLE, QSPI_CFG_ADDR_SIZE_24, QSPI_CFG_BUS_SINGLE,
     ^~~~~~~~~~~~~~~~~~~~~~
     spi_set_format
QSPIFBlockDevice.cpp:719:5: error: 'qspi_status_t' was not declared in this scope
     qspi_status_t status = _qspi_send_read_command(QSPIF_SFDP, (char *)sfdp_header, addr /*address*/, data_length);
     ^~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:719:5: note: suggested alternative: 'spi_inst_t'
     qspi_status_t status = _qspi_send_read_command(QSPIF_SFDP, (char *)sfdp_header, addr /*address*/, data_length);
     ^~~~~~~~~~~~~
     spi_inst_t
QSPIFBlockDevice.cpp:720:9: error: 'status' was not declared in this scope
     if (status != QSPI_STATUS_OK) {
         ^~~~~~
QSPIFBlockDevice.h:236:5: error: 'qspi_status_t' does not name a type; did you mean 'osStatus_t'?
     qspi_status_t _qspi_send_erase_command(unsigned int erase_instruction, bd_addr_t addr, bd_size_t size);
     ^~~~~~~~~~~~~
     osStatus_t
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:720:9: note: suggested alternative: 'statvfs'
     if (status != QSPI_STATUS_OK) {
         ^~~~~~
         statvfs
QSPIFBlockDevice.cpp:720:19: error: 'QSPI_STATUS_OK' was not declared in this scope
     if (status != QSPI_STATUS_OK) {
                   ^~~~~~~~~~~~~~
QSPIFBlockDevice.h:239:5: error: 'qspi_status_t' does not name a type; did you mean 'osStatus_t'?
     qspi_status_t _qspi_send_general_command(unsigned int instruction_int, bd_addr_t addr, const char *tx_buffer,
     ^~~~~~~~~~~~~
     osStatus_t
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:720:19: note: suggested alternative: '_SYS_STAT_H'
     if (status != QSPI_STATUS_OK) {
                   ^~~~~~~~~~~~~~
                   _SYS_STAT_H
QSPIFBlockDevice.cpp:745:9: error: 'status' was not declared in this scope
         status = _qspi_send_read_command(QSPIF_SFDP, (char *)param_header, addr, data_length);
         ^~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:745:9: note: suggested alternative: 'statvfs'
         status = _qspi_send_read_command(QSPIF_SFDP, (char *)param_header, addr, data_length);
         ^~~~~~
         statvfs
QSPIFBlockDevice.cpp:745:18: error: '_qspi_send_read_command' was not declared in this scope
         status = _qspi_send_read_command(QSPIF_SFDP, (char *)param_header, addr, data_length);
                  ^~~~~~~~~~~~~~~~~~~~~~~
QSPIFBlockDevice.h:243:5: error: 'qspi_status_t' does not name a type; did you mean 'osStatus_t'?
     qspi_status_t _qspi_configure_format(qspi_bus_width_t inst_width, qspi_bus_width_t address_width,
     ^~~~~~~~~~~~~
     osStatus_t
In file included from /home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/AccessFlashAsUSBDisk_NanoRP2040ConnectExample.ino:10:0:
QSPIFBlockDevice.h:248:5: error: 'qspi_status_t' does not name a type; did you mean 'osStatus_t'?
     qspi_status_t _qspi_set_frequency(int freq);
     ^~~~~~~~~~~~~
     osStatus_t
QSPIFBlockDevice.h:300:33: error: 'bd_size_t' has not been declared
     int _utils_find_addr_region(bd_size_t offset);
                                 ^~~~~~~~~
QSPIFBlockDevice.h:310:11: error: 'QSPI' in namespace 'mbed' does not name a type
     mbed::QSPI _qspi;
           ^~~~
QSPIFBlockDevice.h:341:5: error: 'bd_size_t' does not name a type; did you mean 'blksize_t'?
     bd_size_t _region_high_boundary[QSPIF_MAX_REGIONS]; //region high address offset boundary
     ^~~~~~~~~
     blksize_t
QSPIFBlockDevice.h:348:5: error: 'bd_size_t' does not name a type; did you mean 'blksize_t'?
     bd_size_t _device_size_bytes;
     ^~~~~~~~~
     blksize_t
QSPIFBlockDevice.cpp:746:23: error: 'QSPI_STATUS_OK' was not declared in this scope
         if (status != QSPI_STATUS_OK) {
                       ^~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:746:23: note: suggested alternative: '_SYS_STAT_H'
         if (status != QSPI_STATUS_OK) {
                       ^~~~~~~~~~~~~~
                       _SYS_STAT_H
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp: In member function 'int QSPIFBlockDevice::_sfdp_set_qpi_enabled(uint8_t*)':
QSPIFBlockDevice.cpp:790:18: error: 'QSPI_STATUS_OK' was not declared in this scope
             if  (QSPI_STATUS_OK != _qspi_send_general_command(0x38, QSPI_NO_ADDRESS_COMMAND, NULL, 0, NULL, 0)) {
                  ^~~~~~~~~~~~~~
QSPIFBlockDevice.h:351:5: error: 'qspi_bus_width_t' does not name a type; did you mean 'spi_inst_t'?
     qspi_bus_width_t _inst_width; //Bus width for Instruction phase
     ^~~~~~~~~~~~~~~~
     spi_inst_t
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:790:18: note: suggested alternative: '_SYS_STAT_H'
             if  (QSPI_STATUS_OK != _qspi_send_general_command(0x38, QSPI_NO_ADDRESS_COMMAND, NULL, 0, NULL, 0)) {
                  ^~~~~~~~~~~~~~
                  _SYS_STAT_H
QSPIFBlockDevice.cpp:790:36: error: '_qspi_send_general_command' was not declared in this scope
             if  (QSPI_STATUS_OK != _qspi_send_general_command(0x38, QSPI_NO_ADDRESS_COMMAND, NULL, 0, NULL, 0)) {
                                    ^~~~~~~~~~~~~~~~~~~~~~~~~~
QSPIFBlockDevice.h:352:5: error: 'qspi_bus_width_t' does not name a type; did you mean 'spi_inst_t'?
     qspi_bus_width_t _address_width; //Bus width for Address phase
     ^~~~~~~~~~~~~~~~
     spi_inst_t
QSPIFBlockDevice.h:353:5: error: 'qspi_address_size_t' does not name a type
     qspi_address_size_t _address_size; // number of bytes for address
     ^~~~~~~~~~~~~~~~~~~
QSPIFBlockDevice.cpp:797:18: error: 'QSPI_STATUS_OK' was not declared in this scope
             if  (QSPI_STATUS_OK != _qspi_send_general_command(0x35, QSPI_NO_ADDRESS_COMMAND, NULL, 0, NULL, 0)) {
                  ^~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:797:18: note: suggested alternative: '_SYS_STAT_H'
             if  (QSPI_STATUS_OK != _qspi_send_general_command(0x35, QSPI_NO_ADDRESS_COMMAND, NULL, 0, NULL, 0)) {
                  ^~~~~~~~~~~~~~
                  _SYS_STAT_H
QSPIFBlockDevice.cpp:797:36: error: '_qspi_send_general_command' was not declared in this scope
             if  (QSPI_STATUS_OK != _qspi_send_general_command(0x35, QSPI_NO_ADDRESS_COMMAND, NULL, 0, NULL, 0)) {
                                    ^~~~~~~~~~~~~~~~~~~~~~~~~~
QSPIFBlockDevice.h:354:5: error: 'qspi_bus_width_t' does not name a type; did you mean 'spi_inst_t'?
     qspi_bus_width_t _data_width; //Bus width for Data phase
     ^~~~~~~~~~~~~~~~
     spi_inst_t
In file included from /home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/AccessFlashAsUSBDisk_NanoRP2040ConnectExample.ino:10:0:
QSPIFBlockDevice.h:104:49: error: 'MBED_CONF_QSPIF_QSPI_FREQ' was not declared in this scope
                      int clock_mode, int freq = MBED_CONF_QSPIF_QSPI_FREQ);
                                                 ^~~~~~~~~~~~~~~~~~~~~~~~~
QSPIFBlockDevice.cpp:804:18: error: 'QSPI_STATUS_OK' was not declared in this scope
             if  (QSPI_STATUS_OK != _qspi_send_general_command(0x65, 0x800003, NULL, 0, (char *)config_reg, 1)) {
                  ^~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:804:18: note: suggested alternative: '_SYS_STAT_H'
             if  (QSPI_STATUS_OK != _qspi_send_general_command(0x65, 0x800003, NULL, 0, (char *)config_reg, 1)) {
                  ^~~~~~~~~~~~~~
                  _SYS_STAT_H
QSPIFBlockDevice.cpp:804:36: error: '_qspi_send_general_command' was not declared in this scope
             if  (QSPI_STATUS_OK != _qspi_send_general_command(0x65, 0x800003, NULL, 0, (char *)config_reg, 1)) {
                                    ^~~~~~~~~~~~~~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.h:104:49: note: suggested alternative: 'MBED_CONF_DRIVERS_QSPI_IO0'
                      int clock_mode, int freq = MBED_CONF_QSPIF_QSPI_FREQ);
                                                 ^~~~~~~~~~~~~~~~~~~~~~~~~
                                                 MBED_CONF_DRIVERS_QSPI_IO0
AccessFlashAsUSBDisk_NanoRP2040ConnectExample:14:25: error: no matching function for call to 'QSPIFBlockDevice::QSPIFBlockDevice()'
 static QSPIFBlockDevice root;
                         ^~~~
In file included from /home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/AccessFlashAsUSBDisk_NanoRP2040ConnectExample.ino:10:0:
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.h:103:5: note: candidate: QSPIFBlockDevice::QSPIFBlockDevice(PinName, PinName, PinName, PinName, PinName, PinName, int, int)
     QSPIFBlockDevice(PinName io0, PinName io1, PinName io2, PinName io3, PinName sclk, PinName csel,
     ^~~~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.h:103:5: note:   candidate expects 8 arguments, 0 provided
AccessFlashAsUSBDisk_NanoRP2040ConnectExample:15:40: error: no matching function for call to 'mbed::MBRBlockDevice::MBRBlockDevice(QSPIFBlockDevice*, int)'
 mbed::MBRBlockDevice wifi_data(&root, 1);
                                        ^
In file included from /home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/AccessFlashAsUSBDisk_NanoRP2040ConnectExample.ino:11:0:
/home/rajiv/.arduino15/packages/arduino/hardware/mbed_nano/3.5.1/cores/arduino/mbed/storage/blockdevice/include/blockdevice/MBRBlockDevice.h:85:5: note: candidate: mbed::MBRBlockDevice::MBRBlockDevice(mbed::BlockDevice*, int)
     MBRBlockDevice(BlockDevice *bd, int part);
     ^~~~~~~~~~~~~~
/home/rajiv/.arduino15/packages/arduino/hardware/mbed_nano/3.5.1/cores/arduino/mbed/storage/blockdevice/include/blockdevice/MBRBlockDevice.h:85:5: note:   no known conversion for argument 1 from 'QSPIFBlockDevice*' to 'mbed::BlockDevice*'
/home/rajiv/.arduino15/packages/arduino/hardware/mbed_nano/3.5.1/cores/arduino/mbed/storage/blockdevice/include/blockdevice/MBRBlockDevice.h:44:7: note: candidate: constexpr mbed::MBRBlockDevice::MBRBlockDevice(const mbed::MBRBlockDevice&)
 class MBRBlockDevice : public BlockDevice {
       ^~~~~~~~~~~~~~
/home/rajiv/.arduino15/packages/arduino/hardware/mbed_nano/3.5.1/cores/arduino/mbed/storage/blockdevice/include/blockdevice/MBRBlockDevice.h:44:7: note:   candidate expects 1 argument, 2 provided
AccessFlashAsUSBDisk_NanoRP2040ConnectExample:16:39: error: no matching function for call to 'mbed::MBRBlockDevice::MBRBlockDevice(QSPIFBlockDevice*, int)'
 mbed::MBRBlockDevice ota_data(&root, 2);
                                       ^
In file included from /home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/AccessFlashAsUSBDisk_NanoRP2040ConnectExample.ino:11:0:
/home/rajiv/.arduino15/packages/arduino/hardware/mbed_nano/3.5.1/cores/arduino/mbed/storage/blockdevice/include/blockdevice/MBRBlockDevice.h:85:5: note: candidate: mbed::MBRBlockDevice::MBRBlockDevice(mbed::BlockDevice*, int)
     MBRBlockDevice(BlockDevice *bd, int part);
     ^~~~~~~~~~~~~~
/home/rajiv/.arduino15/packages/arduino/hardware/mbed_nano/3.5.1/cores/arduino/mbed/storage/blockdevice/include/blockdevice/MBRBlockDevice.h:85:5: note:   no known conversion for argument 1 from 'QSPIFBlockDevice*' to 'mbed::BlockDevice*'
/home/rajiv/.arduino15/packages/arduino/hardware/mbed_nano/3.5.1/cores/arduino/mbed/storage/blockdevice/include/blockdevice/MBRBlockDevice.h:44:7: note: candidate: constexpr mbed::MBRBlockDevice::MBRBlockDevice(const mbed::MBRBlockDevice&)
 class MBRBlockDevice : public BlockDevice {
       ^~~~~~~~~~~~~~
/home/rajiv/.arduino15/packages/arduino/hardware/mbed_nano/3.5.1/cores/arduino/mbed/storage/blockdevice/include/blockdevice/MBRBlockDevice.h:44:7: note:   candidate expects 1 argument, 2 provided
AccessFlashAsUSBDisk_NanoRP2040ConnectExample:32:25: error: no matching function for call to 'arduino::USBMSD::USBMSD(QSPIFBlockDevice*)'
 USBMSD MassStorage(&root);
                         ^
In file included from /home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/AccessFlashAsUSBDisk_NanoRP2040ConnectExample.ino:9:0:
/home/rajiv/.arduino15/packages/arduino/hardware/mbed_nano/3.5.1/libraries/USBMSD/src/PluggableUSBMSD.h:106:5: note: candidate: arduino::USBMSD::USBMSD(USBPhy*, mbed::BlockDevice*, uint16_t, uint16_t, uint16_t)
     USBMSD(USBPhy *phy, mbed::BlockDevice *bd, uint16_t vendor_id, uint16_t product_id, uint16_t product_release);
     ^~~~~~
/home/rajiv/.arduino15/packages/arduino/hardware/mbed_nano/3.5.1/libraries/USBMSD/src/PluggableUSBMSD.h:106:5: note:   candidate expects 5 arguments, 1 provided
In file included from /home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/AccessFlashAsUSBDisk_NanoRP2040ConnectExample.ino:9:0:
/home/rajiv/.arduino15/packages/arduino/hardware/mbed_nano/3.5.1/libraries/USBMSD/src/PluggableUSBMSD.h:87:5: note: candidate: arduino::USBMSD::USBMSD(mbed::BlockDevice*, bool, uint16_t, uint16_t, uint16_t)
     USBMSD(mbed::BlockDevice *bd, bool connect_blocking = true, uint16_t vendor_id = 0x0703, uint16_t product_id = 0x0104, uint16_t product_release = 0x0001);
     ^~~~~~
/home/rajiv/.arduino15/packages/arduino/hardware/mbed_nano/3.5.1/libraries/USBMSD/src/PluggableUSBMSD.h:87:5: note:   no known conversion for argument 1 from 'QSPIFBlockDevice*' to 'mbed::BlockDevice*'
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/AccessFlashAsUSBDisk_NanoRP2040ConnectExample.ino: In function 'void loop()':
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/AccessFlashAsUSBDisk_NanoRP2040ConnectExample.ino:57:27: warning: ISO C++ forbids converting a string constant to 'char*' [-Wwrite-strings]
     printDirectory("/wifi");
                           ^
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/AccessFlashAsUSBDisk_NanoRP2040ConnectExample.ino:59:26: warning: ISO C++ forbids converting a string constant to 'char*' [-Wwrite-strings]
     printDirectory("/ota");
                          ^
QSPIFBlockDevice.cpp:808:18: error: 'QSPI_STATUS_OK' was not declared in this scope
             if  (QSPI_STATUS_OK != _qspi_send_general_command(0x71, 0x800003, NULL, 0, (char *)config_reg, 1)) {
                  ^~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:808:18: note: suggested alternative: '_SYS_STAT_H'
             if  (QSPI_STATUS_OK != _qspi_send_general_command(0x71, 0x800003, NULL, 0, (char *)config_reg, 1)) {
                  ^~~~~~~~~~~~~~
                  _SYS_STAT_H
QSPIFBlockDevice.cpp:808:36: error: '_qspi_send_general_command' was not declared in this scope
             if  (QSPI_STATUS_OK != _qspi_send_general_command(0x71, 0x800003, NULL, 0, (char *)config_reg, 1)) {
                                    ^~~~~~~~~~~~~~~~~~~~~~~~~~
QSPIFBlockDevice.cpp:815:18: error: 'QSPI_STATUS_OK' was not declared in this scope
             if  (QSPI_STATUS_OK != _qspi_send_general_command(0x65, QSPI_NO_ADDRESS_COMMAND, NULL, 0, (char *)config_reg, 1)) {
                  ^~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:815:18: note: suggested alternative: '_SYS_STAT_H'
             if  (QSPI_STATUS_OK != _qspi_send_general_command(0x65, QSPI_NO_ADDRESS_COMMAND, NULL, 0, (char *)config_reg, 1)) {
                  ^~~~~~~~~~~~~~
                  _SYS_STAT_H
QSPIFBlockDevice.cpp:815:36: error: '_qspi_send_general_command' was not declared in this scope
             if  (QSPI_STATUS_OK != _qspi_send_general_command(0x65, QSPI_NO_ADDRESS_COMMAND, NULL, 0, (char *)config_reg, 1)) {
                                    ^~~~~~~~~~~~~~~~~~~~~~~~~~
QSPIFBlockDevice.cpp:819:18: error: 'QSPI_STATUS_OK' was not declared in this scope
             if  (QSPI_STATUS_OK != _qspi_send_general_command(0x61, QSPI_NO_ADDRESS_COMMAND, NULL, 0, (char *)config_reg, 1)) {
                  ^~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:819:18: note: suggested alternative: '_SYS_STAT_H'
             if  (QSPI_STATUS_OK != _qspi_send_general_command(0x61, QSPI_NO_ADDRESS_COMMAND, NULL, 0, (char *)config_reg, 1)) {
                  ^~~~~~~~~~~~~~
                  _SYS_STAT_H
QSPIFBlockDevice.cpp:819:36: error: '_qspi_send_general_command' was not declared in this scope
             if  (QSPI_STATUS_OK != _qspi_send_general_command(0x61, QSPI_NO_ADDRESS_COMMAND, NULL, 0, (char *)config_reg, 1)) {
                                    ^~~~~~~~~~~~~~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp: In member function 'int QSPIFBlockDevice::_sfdp_set_quad_enabled(uint8_t*)':
QSPIFBlockDevice.cpp:881:28: error: 'QSPI_CFG_BUS_SINGLE' was not declared in this scope
     _qspi_configure_format(QSPI_CFG_BUS_SINGLE, QSPI_CFG_BUS_SINGLE, QSPI_CFG_ADDR_SIZE_24, QSPI_CFG_BUS_SINGLE,
                            ^~~~~~~~~~~~~~~~~~~
QSPIFBlockDevice.cpp:881:70: error: 'QSPI_CFG_ADDR_SIZE_24' was not declared in this scope
     _qspi_configure_format(QSPI_CFG_BUS_SINGLE, QSPI_CFG_BUS_SINGLE, QSPI_CFG_ADDR_SIZE_24, QSPI_CFG_BUS_SINGLE,
                                                                      ^~~~~~~~~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:881:70: note: suggested alternative: 'QSPIF_SFDP_HEADER_SIZE'
     _qspi_configure_format(QSPI_CFG_BUS_SINGLE, QSPI_CFG_BUS_SINGLE, QSPI_CFG_ADDR_SIZE_24, QSPI_CFG_BUS_SINGLE,
                                                                      ^~~~~~~~~~~~~~~~~~~~~
                                                                      QSPIF_SFDP_HEADER_SIZE
QSPIFBlockDevice.cpp:882:28: error: 'QSPI_CFG_ALT_SIZE_8' was not declared in this scope
                            QSPI_CFG_ALT_SIZE_8, QSPI_CFG_BUS_SINGLE, 0);
                            ^~~~~~~~~~~~~~~~~~~
QSPIFBlockDevice.cpp:881:5: error: '_qspi_configure_format' was not declared in this scope
     _qspi_configure_format(QSPI_CFG_BUS_SINGLE, QSPI_CFG_BUS_SINGLE, QSPI_CFG_ADDR_SIZE_24, QSPI_CFG_BUS_SINGLE,
     ^~~~~~~~~~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:881:5: note: suggested alternative: 'spi_set_format'
     _qspi_configure_format(QSPI_CFG_BUS_SINGLE, QSPI_CFG_BUS_SINGLE, QSPI_CFG_ADDR_SIZE_24, QSPI_CFG_BUS_SINGLE,
     ^~~~~~~~~~~~~~~~~~~~~~
     spi_set_format
QSPIFBlockDevice.cpp:885:9: error: 'QSPI_STATUS_OK' was not declared in this scope
     if (QSPI_STATUS_OK == _qspi_send_general_command(_read_register_inst, QSPI_NO_ADDRESS_COMMAND, NULL, 0,
         ^~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:885:9: note: suggested alternative: '_SYS_STAT_H'
     if (QSPI_STATUS_OK == _qspi_send_general_command(_read_register_inst, QSPI_NO_ADDRESS_COMMAND, NULL, 0,
         ^~~~~~~~~~~~~~
         _SYS_STAT_H
QSPIFBlockDevice.cpp:885:27: error: '_qspi_send_general_command' was not declared in this scope
     if (QSPI_STATUS_OK == _qspi_send_general_command(_read_register_inst, QSPI_NO_ADDRESS_COMMAND, NULL, 0,
                           ^~~~~~~~~~~~~~~~~~~~~~~~~~
QSPIFBlockDevice.cpp:905:9: error: 'QSPI_STATUS_OK' was not declared in this scope
     if (QSPI_STATUS_OK == _qspi_send_general_command(_write_register_inst, QSPI_NO_ADDRESS_COMMAND, (char *)status_reg,
         ^~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:905:9: note: suggested alternative: '_SYS_STAT_H'
     if (QSPI_STATUS_OK == _qspi_send_general_command(_write_register_inst, QSPI_NO_ADDRESS_COMMAND, (char *)status_reg,
         ^~~~~~~~~~~~~~
         _SYS_STAT_H
QSPIFBlockDevice.cpp:905:27: error: '_qspi_send_general_command' was not declared in this scope
     if (QSPI_STATUS_OK == _qspi_send_general_command(_write_register_inst, QSPI_NO_ADDRESS_COMMAND, (char *)status_reg,
                           ^~~~~~~~~~~~~~~~~~~~~~~~~~
QSPIFBlockDevice.cpp:923:9: error: 'QSPI_STATUS_OK' was not declared in this scope
     if (QSPI_STATUS_OK == _qspi_send_general_command(_read_register_inst, QSPI_NO_ADDRESS_COMMAND, NULL, 0,
         ^~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:923:9: note: suggested alternative: '_SYS_STAT_H'
     if (QSPI_STATUS_OK == _qspi_send_general_command(_read_register_inst, QSPI_NO_ADDRESS_COMMAND, NULL, 0,
         ^~~~~~~~~~~~~~
         _SYS_STAT_H
QSPIFBlockDevice.cpp:923:27: error: '_qspi_send_general_command' was not declared in this scope
     if (QSPI_STATUS_OK == _qspi_send_general_command(_read_register_inst, QSPI_NO_ADDRESS_COMMAND, NULL, 0,
                           ^~~~~~~~~~~~~~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp: In member function 'int QSPIFBlockDevice::_sfdp_detect_best_bus_read_mode(uint8_t*, int, bool&, bool&, unsigned int&)':
QSPIFBlockDevice.cpp:1025:17: error: '_address_width' was not declared in this scope
                 _address_width = QSPI_CFG_BUS_QUAD;
                 ^~~~~~~~~~~~~~
QSPIFBlockDevice.cpp:1025:34: error: 'QSPI_CFG_BUS_QUAD' was not declared in this scope
                 _address_width = QSPI_CFG_BUS_QUAD;
                                  ^~~~~~~~~~~~~~~~~
QSPIFBlockDevice.cpp:1026:17: error: '_data_width' was not declared in this scope
                 _data_width = QSPI_CFG_BUS_QUAD;
                 ^~~~~~~~~~~
QSPIFBlockDevice.cpp:1041:13: error: '_address_width' was not declared in this scope
             _address_width = QSPI_CFG_BUS_QUAD;
             ^~~~~~~~~~~~~~
QSPIFBlockDevice.cpp:1041:30: error: 'QSPI_CFG_BUS_QUAD' was not declared in this scope
             _address_width = QSPI_CFG_BUS_QUAD;
                              ^~~~~~~~~~~~~~~~~
QSPIFBlockDevice.cpp:1042:13: error: '_data_width' was not declared in this scope
             _data_width = QSPI_CFG_BUS_QUAD;
             ^~~~~~~~~~~
QSPIFBlockDevice.cpp:1053:13: error: '_data_width' was not declared in this scope
             _data_width = QSPI_CFG_BUS_QUAD;
             ^~~~~~~~~~~
QSPIFBlockDevice.cpp:1053:27: error: 'QSPI_CFG_BUS_QUAD' was not declared in this scope
             _data_width = QSPI_CFG_BUS_QUAD;
                           ^~~~~~~~~~~~~~~~~
QSPIFBlockDevice.cpp:1063:13: error: '_address_width' was not declared in this scope
             _address_width = QSPI_CFG_BUS_DUAL;
             ^~~~~~~~~~~~~~
QSPIFBlockDevice.cpp:1063:30: error: 'QSPI_CFG_BUS_DUAL' was not declared in this scope
             _address_width = QSPI_CFG_BUS_DUAL;
                              ^~~~~~~~~~~~~~~~~
QSPIFBlockDevice.cpp:1064:13: error: '_data_width' was not declared in this scope
             _data_width = QSPI_CFG_BUS_DUAL;
             ^~~~~~~~~~~
QSPIFBlockDevice.cpp:1075:13: error: '_address_width' was not declared in this scope
             _address_width = QSPI_CFG_BUS_DUAL;
             ^~~~~~~~~~~~~~
QSPIFBlockDevice.cpp:1075:30: error: 'QSPI_CFG_BUS_DUAL' was not declared in this scope
             _address_width = QSPI_CFG_BUS_DUAL;
                              ^~~~~~~~~~~~~~~~~
QSPIFBlockDevice.cpp:1076:13: error: '_data_width' was not declared in this scope
             _data_width = QSPI_CFG_BUS_DUAL;
             ^~~~~~~~~~~
QSPIFBlockDevice.cpp:1085:13: error: '_data_width' was not declared in this scope
             _data_width = QSPI_CFG_BUS_DUAL;
             ^~~~~~~~~~~
QSPIFBlockDevice.cpp:1085:27: error: 'QSPI_CFG_BUS_DUAL' was not declared in this scope
             _data_width = QSPI_CFG_BUS_DUAL;
                           ^~~~~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp: In member function 'int QSPIFBlockDevice::_reset_flash_mem()':
QSPIFBlockDevice.cpp:1102:9: error: 'QSPI_STATUS_OK' was not declared in this scope
     if (QSPI_STATUS_OK == _qspi_send_general_command(QSPIF_RDSR, QSPI_NO_ADDRESS_COMMAND, NULL, 0, status_value,
         ^~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:1102:9: note: suggested alternative: '_SYS_STAT_H'
     if (QSPI_STATUS_OK == _qspi_send_general_command(QSPIF_RDSR, QSPI_NO_ADDRESS_COMMAND, NULL, 0, status_value,
         ^~~~~~~~~~~~~~
         _SYS_STAT_H
QSPIFBlockDevice.cpp:1102:27: error: '_qspi_send_general_command' was not declared in this scope
     if (QSPI_STATUS_OK == _qspi_send_general_command(QSPIF_RDSR, QSPI_NO_ADDRESS_COMMAND, NULL, 0, status_value,
                           ^~~~~~~~~~~~~~~~~~~~~~~~~~
QSPIFBlockDevice.cpp:1112:13: error: 'QSPI_STATUS_OK' was not declared in this scope
         if (QSPI_STATUS_OK == _qspi_send_general_command(QSPIF_RSTEN, QSPI_NO_ADDRESS_COMMAND, NULL, 0, NULL,
             ^~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:1112:13: note: suggested alternative: '_SYS_STAT_H'
         if (QSPI_STATUS_OK == _qspi_send_general_command(QSPIF_RSTEN, QSPI_NO_ADDRESS_COMMAND, NULL, 0, NULL,
             ^~~~~~~~~~~~~~
             _SYS_STAT_H
QSPIFBlockDevice.cpp:1112:31: error: '_qspi_send_general_command' was not declared in this scope
         if (QSPI_STATUS_OK == _qspi_send_general_command(QSPIF_RSTEN, QSPI_NO_ADDRESS_COMMAND, NULL, 0, NULL,
                               ^~~~~~~~~~~~~~~~~~~~~~~~~~
QSPIFBlockDevice.cpp:1123:17: error: 'QSPI_STATUS_OK' was not declared in this scope
             if (QSPI_STATUS_OK == _qspi_send_general_command(QSPIF_RST, QSPI_NO_ADDRESS_COMMAND, NULL, 0, NULL,
                 ^~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:1123:17: note: suggested alternative: '_SYS_STAT_H'
             if (QSPI_STATUS_OK == _qspi_send_general_command(QSPIF_RST, QSPI_NO_ADDRESS_COMMAND, NULL, 0, NULL,
                 ^~~~~~~~~~~~~~
                 _SYS_STAT_H
QSPIFBlockDevice.cpp:1123:35: error: '_qspi_send_general_command' was not declared in this scope
             if (QSPI_STATUS_OK == _qspi_send_general_command(QSPIF_RST, QSPI_NO_ADDRESS_COMMAND, NULL, 0, NULL,
                                   ^~~~~~~~~~~~~~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp: In member function 'bool QSPIFBlockDevice::_is_mem_ready()':
QSPIFBlockDevice.cpp:1146:9: error: 'wait_ms' was not declared in this scope
         wait_ms(1);
         ^~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:1146:9: note: suggested alternative: 'wait_ns'
         wait_ms(1);
         ^~~~~~~
         wait_ns
QSPIFBlockDevice.cpp:1150:13: error: 'QSPI_STATUS_OK' was not declared in this scope
         if (QSPI_STATUS_OK != _qspi_send_general_command(QSPIF_RDSR, QSPI_NO_ADDRESS_COMMAND, NULL, 0, status_value,
             ^~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:1150:13: note: suggested alternative: '_SYS_STAT_H'
         if (QSPI_STATUS_OK != _qspi_send_general_command(QSPIF_RDSR, QSPI_NO_ADDRESS_COMMAND, NULL, 0, status_value,
             ^~~~~~~~~~~~~~
             _SYS_STAT_H
QSPIFBlockDevice.cpp:1150:31: error: '_qspi_send_general_command' was not declared in this scope
         if (QSPI_STATUS_OK != _qspi_send_general_command(QSPIF_RDSR, QSPI_NO_ADDRESS_COMMAND, NULL, 0, status_value,
                               ^~~~~~~~~~~~~~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp: In member function 'int QSPIFBlockDevice::_set_write_enable()':
QSPIFBlockDevice.cpp:1170:13: error: 'QSPI_STATUS_OK' was not declared in this scope
         if (QSPI_STATUS_OK !=  _qspi_send_general_command(QSPIF_WREN, QSPI_NO_ADDRESS_COMMAND, NULL, 0, NULL, 0)) {
             ^~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:1170:13: note: suggested alternative: '_SYS_STAT_H'
         if (QSPI_STATUS_OK !=  _qspi_send_general_command(QSPIF_WREN, QSPI_NO_ADDRESS_COMMAND, NULL, 0, NULL, 0)) {
             ^~~~~~~~~~~~~~
             _SYS_STAT_H
QSPIFBlockDevice.cpp:1170:32: error: '_qspi_send_general_command' was not declared in this scope
         if (QSPI_STATUS_OK !=  _qspi_send_general_command(QSPIF_WREN, QSPI_NO_ADDRESS_COMMAND, NULL, 0, NULL, 0)) {
                                ^~~~~~~~~~~~~~~~~~~~~~~~~~
QSPIFBlockDevice.cpp:1181:13: error: 'QSPI_STATUS_OK' was not declared in this scope
         if (QSPI_STATUS_OK != _qspi_send_general_command(QSPIF_RDSR, QSPI_NO_ADDRESS_COMMAND, NULL, 0, status_value,
             ^~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:1181:13: note: suggested alternative: '_SYS_STAT_H'
         if (QSPI_STATUS_OK != _qspi_send_general_command(QSPIF_RDSR, QSPI_NO_ADDRESS_COMMAND, NULL, 0, status_value,
             ^~~~~~~~~~~~~~
             _SYS_STAT_H
QSPIFBlockDevice.cpp:1181:31: error: '_qspi_send_general_command' was not declared in this scope
         if (QSPI_STATUS_OK != _qspi_send_general_command(QSPIF_RDSR, QSPI_NO_ADDRESS_COMMAND, NULL, 0, status_value,
                               ^~~~~~~~~~~~~~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp: In member function 'int QSPIFBlockDevice::_enable_fast_mdoe()':
QSPIFBlockDevice.cpp:1205:28: error: 'QSPI_CFG_BUS_SINGLE' was not declared in this scope
     _qspi_configure_format(QSPI_CFG_BUS_SINGLE, QSPI_CFG_BUS_SINGLE, QSPI_CFG_ADDR_SIZE_24, QSPI_CFG_BUS_SINGLE,
                            ^~~~~~~~~~~~~~~~~~~
QSPIFBlockDevice.cpp:1205:70: error: 'QSPI_CFG_ADDR_SIZE_24' was not declared in this scope
     _qspi_configure_format(QSPI_CFG_BUS_SINGLE, QSPI_CFG_BUS_SINGLE, QSPI_CFG_ADDR_SIZE_24, QSPI_CFG_BUS_SINGLE,
                                                                      ^~~~~~~~~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:1205:70: note: suggested alternative: 'QSPIF_SFDP_HEADER_SIZE'
     _qspi_configure_format(QSPI_CFG_BUS_SINGLE, QSPI_CFG_BUS_SINGLE, QSPI_CFG_ADDR_SIZE_24, QSPI_CFG_BUS_SINGLE,
                                                                      ^~~~~~~~~~~~~~~~~~~~~
                                                                      QSPIF_SFDP_HEADER_SIZE
QSPIFBlockDevice.cpp:1206:28: error: 'QSPI_CFG_ALT_SIZE_8' was not declared in this scope
                            QSPI_CFG_ALT_SIZE_8, QSPI_CFG_BUS_SINGLE, 0);
                            ^~~~~~~~~~~~~~~~~~~
QSPIFBlockDevice.cpp:1205:5: error: '_qspi_configure_format' was not declared in this scope
     _qspi_configure_format(QSPI_CFG_BUS_SINGLE, QSPI_CFG_BUS_SINGLE, QSPI_CFG_ADDR_SIZE_24, QSPI_CFG_BUS_SINGLE,
     ^~~~~~~~~~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:1205:5: note: suggested alternative: 'spi_set_format'
     _qspi_configure_format(QSPI_CFG_BUS_SINGLE, QSPI_CFG_BUS_SINGLE, QSPI_CFG_ADDR_SIZE_24, QSPI_CFG_BUS_SINGLE,
     ^~~~~~~~~~~~~~~~~~~~~~
     spi_set_format
QSPIFBlockDevice.cpp:1209:9: error: 'QSPI_STATUS_OK' was not declared in this scope
     if (QSPI_STATUS_OK == _qspi_send_general_command(read_conf_register_inst, QSPI_NO_ADDRESS_COMMAND, NULL, 0,
         ^~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:1209:9: note: suggested alternative: '_SYS_STAT_H'
     if (QSPI_STATUS_OK == _qspi_send_general_command(read_conf_register_inst, QSPI_NO_ADDRESS_COMMAND, NULL, 0,
         ^~~~~~~~~~~~~~
         _SYS_STAT_H
QSPIFBlockDevice.cpp:1209:27: error: '_qspi_send_general_command' was not declared in this scope
     if (QSPI_STATUS_OK == _qspi_send_general_command(read_conf_register_inst, QSPI_NO_ADDRESS_COMMAND, NULL, 0,
                           ^~~~~~~~~~~~~~~~~~~~~~~~~~
QSPIFBlockDevice.cpp:1229:9: error: 'QSPI_STATUS_OK' was not declared in this scope
     if (QSPI_STATUS_OK == _qspi_send_general_command(_write_register_inst, QSPI_NO_ADDRESS_COMMAND, status_reg,
         ^~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:1229:9: note: suggested alternative: '_SYS_STAT_H'
     if (QSPI_STATUS_OK == _qspi_send_general_command(_write_register_inst, QSPI_NO_ADDRESS_COMMAND, status_reg,
         ^~~~~~~~~~~~~~
         _SYS_STAT_H
QSPIFBlockDevice.cpp:1229:27: error: '_qspi_send_general_command' was not declared in this scope
     if (QSPI_STATUS_OK == _qspi_send_general_command(_write_register_inst, QSPI_NO_ADDRESS_COMMAND, status_reg,
                           ^~~~~~~~~~~~~~~~~~~~~~~~~~
QSPIFBlockDevice.cpp:1246:9: error: 'QSPI_STATUS_OK' was not declared in this scope
     if (QSPI_STATUS_OK == _qspi_send_general_command(read_conf_register_inst, QSPI_NO_ADDRESS_COMMAND, NULL, 0,
         ^~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:1246:9: note: suggested alternative: '_SYS_STAT_H'
     if (QSPI_STATUS_OK == _qspi_send_general_command(read_conf_register_inst, QSPI_NO_ADDRESS_COMMAND, NULL, 0,
         ^~~~~~~~~~~~~~
         _SYS_STAT_H
QSPIFBlockDevice.cpp:1246:27: error: '_qspi_send_general_command' was not declared in this scope
     if (QSPI_STATUS_OK == _qspi_send_general_command(read_conf_register_inst, QSPI_NO_ADDRESS_COMMAND, NULL, 0,
                           ^~~~~~~~~~~~~~~~~~~~~~~~~~
/home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp: At global scope:
QSPIFBlockDevice.cpp:1261:5: error: prototype for 'int QSPIFBlockDevice::_utils_find_addr_region(mbed::bd_size_t)' does not match any in class 'QSPIFBlockDevice'
 int QSPIFBlockDevice::_utils_find_addr_region(bd_size_t offset)
     ^~~~~~~~~~~~~~~~
In file included from /home/rajiv/Documents/Arduino/sketches/AccessFlashAsUSBDisk_NanoRP2040ConnectExample/QSPIFBlockDevice.cpp:17:0:
QSPIFBlockDevice.h:300:9: error: candidate is: int QSPIFBlockDevice::_utils_find_addr_region(int)
     int _utils_find_addr_region(bd_size_t offset);
         ^~~~~~~~~~~~~~~~~~~~~~~
QSPIFBlockDevice.cpp:1312:1: error: 'qspi_status_t' does not name a type; did you mean 'spi_inst_t'?
 qspi_status_t QSPIFBlockDevice::_qspi_set_frequency(int freq)
 ^~~~~~~~~~~~~
 spi_inst_t
QSPIFBlockDevice.cpp:1317:1: error: 'qspi_status_t' does not name a type; did you mean 'spi_inst_t'?
 qspi_status_t QSPIFBlockDevice::_qspi_send_read_command(unsigned int read_inst, void *buffer, bd_addr_t addr,
 ^~~~~~~~~~~~~
 spi_inst_t
QSPIFBlockDevice.cpp:1332:1: error: 'qspi_status_t' does not name a type; did you mean 'spi_inst_t'?
 qspi_status_t QSPIFBlockDevice::_qspi_send_program_command(unsigned int progInst, const void *buffer, bd_addr_t addr,
 ^~~~~~~~~~~~~
 spi_inst_t
QSPIFBlockDevice.cpp:1346:1: error: 'qspi_status_t' does not name a type; did you mean 'spi_inst_t'?
 qspi_status_t QSPIFBlockDevice::_qspi_send_erase_command(unsigned int erase_inst, bd_addr_t addr, bd_size_t size)
 ^~~~~~~~~~~~~
 spi_inst_t
QSPIFBlockDevice.cpp:1368:1: error: 'qspi_status_t' does not name a type; did you mean 'spi_inst_t'?
 qspi_status_t QSPIFBlockDevice::_qspi_send_general_command(unsigned int instruction, bd_addr_t addr,
 ^~~~~~~~~~~~~
 spi_inst_t
QSPIFBlockDevice.cpp:1382:1: error: 'qspi_status_t' does not name a type; did you mean 'spi_inst_t'?
 qspi_status_t QSPIFBlockDevice::_qspi_configure_format(qspi_bus_width_t inst_width, qspi_bus_width_t address_width,
 ^~~~~~~~~~~~~
 spi_inst_t
exit status 1
'BD_ERROR_DEVICE_ERROR' was not declared in this scope


This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.

How do I get this example program to work? Or is there another solution?

I aim to build a mobile data logger that logs data to the 16MB of QSPI flash on the Nano RP2040 Connect. After the logging is over, I want to connect my device to a PC and download the CSV file created by the logger, for further processing...

Help...!

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.