Getting Started with Milk-V Duo – RISC-V Linux Development Board

Learn how to use the Milk-V Duo Linux development board with dual-core 1 GHz CVITEK CV1800B CPU, 64 MB RAM and a MicroSD card slot. Run Linux and Arduino sketches at the same time.

Getting Started with Milk-V Duo RISC-V Linux Development Board CIRCUITSTATE Electronics Featured Image

RISC-V has been making waves for the past five years, mainly in the embedded systems. We have been seeing more and RISC-V CPU releases by major manufacturers in the last few years. The latest of that is from Raspberry Pi Ltd when they integrated a Hazard3 RISC-V core inside their latest RP2350 general-purpose microcontroller. In case you didn’t know, RISC-V is a free and open-source Instruction Set Architecture (ISA) based on the RISC CPU architecture philosophy. Since it is free, you don’t need to pay any royalties when you make chips with their designs and there are no restrictions in how many you can make or where you can use it. This is unlike the proprietary architectures like x86 and ARM where the sources are not available and you need to pay for using. Because of these advantages, more and more companies are incorporating RISC-V cores or making complete RISC-V solutions in an effort to drive adoption and develop the ecosystem. We can call this as a early adoption and transitioning phase for RISC-V. In that situation we might see short-lived products and designs. Today, we are introducing you to the Milk-V Duo, a compact Linux development board based on the CV1800B from Cvitek. As you may have guessed, is a dual-core RISC-V CPU with two C906 cores.

Milk-V Duo

Milk-V Duo 64M RISC-V Linux Development Board Top Iso View by CIRCUITSTATE Electronics
Milk-V Duo 64M top view

Duo is a CV1800B-based compact Linux development board from Milk-V. Yes, Milk-V is a company/brand from China. Duo is not the only board in this series or the boards they make. There is Due-256M, Duo-S and DuoModule 01 Evaluation Board. Confusing naming indeed. The plain Duo is powered by a dual-core CV1800B RISC-V CPU from Cvitek. If you search for the CPU name on the internet, you will find that Milk-V website is the major resource for all your information about that CPU. May be Milk-V and Cvitek are partners or the same company, we are not sure. Regardless, the Duo comes with an integrated 64 MB RAM where the Duo-256M comes with a 256 MB capacity. The following table shows all board in this series. The Duo is now in the End of Life (EoL) state where it may no longer be manufactured or supported. So if you are planning to buy one, get the 256 MB version.

SpecificationDuoDuo 256MDuo SDuoModule 01 Evaluation Board
Image (Top)Document PicturesDocument PicturesDocument PicturesDocument Pictures
SoCCVITEK CV1800BSG2002SG2000SG2000
RISC-V CPUC906 @ 1GHz +
C906 @ 700MHz
C906 @ 1GHz +
C906 @ 700MHz
C906 @ 1GHz +
C906 @ 700MHz
C906 @ 1GHz +
C906 @ 700MHz
ARM CPUN/A1 x Cortex-A53 @ 1GHz1 x Cortex-A53 @ 1GHz1 x Cortex-A53 @ 1GHz
MCU8051 @ 8KB SRAM8051 @ 6KB SRAM8051 @ 6KB SRAM8051 @ 6KB SRAM
TPU0.5 TOPS @ INT81 TOPS @ INT80.5 TOPS @ INT80.5 TOPS @ INT8
Storage1 x microSD connector or
1 x SD NAND on board
1 x microSD connector or
1 x SD NAND on board
1 x microSD connector
1 x eMMC Pad on board
1 x microSD connector
1 x 8GB eMMC onboard
MemorySIP DRAM 64MBSIP DRAM 256MBSIP DRAM 512MBSIP DRAM 512MB
USB1 x Type-C for power and data, USB Pads available1 x Type-C for power and data, USB Pads available1 x Type-C for power and data or
1 x USB 2.0 A Port HOST
1 x Type-C for power and data or
4 x USB 2.0 A Port HOST
CSI1 x 16P FPC connector (MIPI CSI 2-lane)1 x 16P FPC connector (MIPI CSI 2-lane)1 x 16P FPC connector (MIPI CSI 2-lane)
1 x 15P FPC connector (MIPI CSI 2-lane)
1 x 16P FPC connector (MIPI CSI 2-lane)
1 x 15P FPC connector (MIPI CSI 2-lane)
Sensor Support4M @ 25fps5M @ 30fps5M @ 30fps5M @ 30fps
Ethernet100 Mbps Ethernet with PHY100 Mbps Ethernet with PHY100 Mbps Ethernet port (RJ45) onboard2 x 100Mbps Ethernet Ports (RJ45)
WirelessN/AN/AOptional Wi-Fi 6 / BT5.4 onboardWi-Fi 6 / BT5.4 onboard
AudioN/AVia GPIO PadsVia GPIO Header1 x 3.5mm jack for audio out
2 x 2p for mic in
DisplayN/AN/AVia GPIO Header (MIPI DSI 4-lane)1 x 39P FPC Connector (MIPI DSI 4-lane)
GPIOUp to 26 GPIOsUp to 26 GPIOsUp to 39 GPIO pin (2 x 26 pin header)Up to 19 GPIOs
Power5V/1A5V/1A5V/1A5V/1A
OS SupportBuildroot, RTOSBuildroot, RTOSBuildroot, RTOSBuildroot, RTOS
Size21 x 51 mm21 x 51 mm43 x 43 mm100 x 75 mm
OthersN/AN/A1 x BOOT button
1 x Recovery button
1 x RST button
1 x BOOT button
1 x Recovery button
1 x RST button

Features

  • 1 GHz and 700 MHz RISC-V C906 processors
  • Integrated CVITEK TPU for smart detection.
  • SIP DRAM 64MB
  • Supports H.264/H.265 video encoding, up to 2880×1620 @ 20fps.
  • Compatible with high-definition CMOS sensors.
  • Programmable frequency output for sensor clock.
  • Comprehensive ISP features for image optimization.
  • Partial OpenCV library support with CV hardware acceleration.
  • 16-bit audio codec with built-in mic input and output functions.
  • Flexible network configurations with 1 Ethernet PHY.
Milk-V Duo 64M RISC-V Linux Development Board Back Iso View by CIRCUITSTATE Electronics
Milk-V Duo 64M bottom view

Pinout Diagram

Milk-V Duo Pinout Diagram R0.1 by CIRCUITSTATE Electronics
Milk-V Duo pinout diagram

Schematic

Milk-V-Duo-Schematic-v1.2_1
Milk-V-Duo-Schematic-v1.2_2
Milk-V-Duo-Schematic-v1.2_3
Milk-V-Duo-Schematic-v1.2_4
Milk-V-Duo-Schematic-v1.2_5

The Duo can be powered from both the USB-C connector or an external power input. Both these inputs are converted to 3.3V at a maximum current of 2A by the MP1657 buck converter. The MP1657 can takes in a maximum of 16V input and provide an output current as high as 3A. In addition to the 3.3V supply, the system also needs a 0.9V and a 1.8V rails. These are provided by two MP1605 step-down converters, each providing a maximum of 2A. You can see three inductors on the PCB that form these power conversion circuits. There is also a red LED connected to the 3.3V line to indicate power status.

A blue LED is connected to the GPIO24-C pin of the SoC though a Mosfet. This can be used for debugging purposes. The Flash memory can be a MicroSD card or an NAND/NOR chip. The Flash memory footprint is left empty while the MicroSD card slot is soldered. Only one can be used at a time since both of them share the same SDIO interface. There is a 16-pin vertical FPC connector for the camera interfacing. Even though the CV1800B has a four-lane MIPI interface, only two lanes are used in the connector. The connector also breaks out an I2C bus which helps to control the camera. A decent number of popular camera sensors from different vendors are compatible with the CV1800B, including IMX385, IMX335 and IMX334 from Sony, OV4689 and OS04C10 from OmniVision.

In terms of audio capabilities, there is an empty footprint for a microphone for audio input. You can see this footprint as a smiley face on the board. There are no pins for audio output nor an I2S interface. There are no components on the back side of the PCB. Since the board has castellation, it can be easily soldered on a carrier PCB.

CV1800B

Milk-V Duo 64M RISC-V Linux Development Board Top View by CIRCUITSTATE Electronics
Milk-V Duo 64M top view

Let’s talk more about the CVITEK CV1800B. Following is the block diagram of the chip. As you can see, the CPU core used by this chip is the XuanTie C906 with a 64-bit RV64IMA[F]C[V] RISC-V specification. The letters in the specification denotes the following.

  • RV64 – Specifies a 64-bit architecture, meaning it uses 64-bit registers and addresses. 
  • I – The base integer instruction set, providing fundamental arithmetic and logical operations. 
  • M – The multiplication and division extension, adding instructions for these operations. 
  • A – The atomic memory operations extension, enabling atomic read-modify-write operations on memory. 
  • F – The floating-point extension, adding instructions for single-precision floating-point calculations. 
  • C – The compressed instruction extension, providing 16-bit versions of commonly used instructions to reduce code size. 
  • V – The vector extension, adding instructions for performing parallel operations on vectors of data.

In the CV1800B, one of these cores run at 1 GHz and the other one at 700 MHz. In addition to these cores, there is also an 8051 microcontroller core integrated into the chip with 8 KB SRAM. So there are three CPU cores inside the chip in total. For AI applications, the chip has an NPU (Neural Processing Unit) that can do 0.5 TOPS (Trillion Operations per Second) at 8-bit integer operations. In terms of memory, the package includes a 64 MB DDR2 RAM connected to the AMBA bus. Hardware accelerations include an ISP (Image Signal Processor), H.265, H264 and JPEG encoders. These accelerators can be used for the MIPI CSI/DVP four-lane interface by adding a camera input. High-speed peripherals include USB 2.0, Ethernet PHY, SPI NOR, SPI NAND and SDIO 3.0 interfaces, while the low-speed peripherals include the typical I2C, SPI, ADC, PWM, and UART. I2S is missing though. The security subsystem includes AES, SHA, eFuse and Secure Boot capabilities.

Specifications

  • RISC-V CPU:
    • 1 x C906 @ 1 GHz
    • 1 x C906 @ 700 MHz
  • NPU: 0.5 TOPS @ INT8
  • Memory: SIP DRAM 64M
  • Video Module
    • ISP 4M@25fps
    • MIPI 4L CSI
    • H.265/H.264 Decoding and Encoding
  • Audio Module
    • 16-bit Audio Codec
  • Storage
    • 1 x SPI-NOR
    • 1 x SPI-NAND
    • 2 x SDIO3.0
  • Network: 10M/100M MAC PHY
  • Security Module: Secure boot/AES/SHA/Efuse
  • Peripherals
    • 3 x ADC
    • 4 x I2C
    • 3 x SPI
    • 5 x UART
    • 4 x PWM
    • 2 x SDIO 3.0
    • 51 GPIOs
  • Temperature Range: -30~70 °C
  • Package Type: QFN
  • Package Dimensions: 7 x 7 x 0.9 mm
  • Pin Pitch: 0.35 mm
  • Total Pins: 68

Flashing OS Image

Milk-V Duo 64M RISC-V Linux Development Board Top View and Package Box by CIRCUITSTATE Electronics
Milk-V Duo 64M board with a MicroSD card in the slot along with the original package box near it

Milk-V maintains an open-source repository at GitHub to host the systems images for the Duo series board. At the time of this writing, the latest version is v1.1.4. We can go to the releases page and download the latest binary images. If you feel adventurous, you can also build everything on your own. We will keep things simple here. Since we have the 64 MB version, we are going to download the milkv-duo-sd-v1.1.4.img.zip from the list. Before flashing, you need supported Micro SD card to flash the OS. We are using a generic Sandisk Ultra 16 GB card here. Format the card before flashing anything. To flash the system image, we can use the Balena Etcher tool. Download and install it if you haven’t already. From here, everything should be simple and straightforward.

We followed the process explained in the official documentation here. First, select the image file you want to flash by clicking the Flash from file button.

Balena Etcher Flashing Milk V Duo OS Image to SD Card Select Image File CIRCUITSTATE Electronics 1
Select image file

Then click on the Select target button and choose the right target. In this case, the target is a 16 GB Micro SD card.

Balena Etcher Flashing Milk V Duo OS Image to SD Card Select Drive CIRCUITSTATE Electronics 2
Select target drive

Next, click on the Flash! button to start the flashing process.

Balena Etcher Flashing Milk V Duo OS Image to SD Card Select Drive CIRCUITSTATE Electronics 1
Ready to flash

It can take up to a minute for the flashing to complete. Wait until it finishes.

Balena Etcher Flashing Milk V Duo OS Image to SD Card Flashing in Progress CIRCUITSTATE Electronics 1
Flashing in progress

Once the flashing is completed, you can close the Balena Etcher and eject the SD card.

Balena Etcher Flashing Milk V Duo OS Image to SD Card Flashing Completed CIRCUITSTATE Electronics 1
Flashing completed

Your Micro SD card should now have the OS image in ready-to-boot state. Now insert the SD card to the slot on the board and connect the power. It is recommended to disconnect the power before inserting or removing the SD card.

Booting & Configuration

As soon as you connect the board though a USB-C cable, the red power LED will light up. Make sure that the power source is capable of delivering more than 1A. It will take another 10 seconds or so for the OS to boot and enumerate. The blue LED will also start blinking indicating that the system is running. You can disable this if you want and we will show this later.

We are using a Windows 11 64-bit PC for this tutorial and will show screenshots from there. When the device is enumerated, it will show up in the Device Manger list. But since Windows won’t be able to automatically assign drivers for the board, we have to manually do that. The Duo board comes with the USB-NCM interface enabled by default. This interface allows you to use the board as a networking device and will appear as one. You can follow this tutorial to setup the drivers for the USB-NCM interface.

Windows Device Manager showing Milk-V Duo USB NCM interface
UsbNcm Host Device #2

After that is done, the device will appear as a UsbNcm Host Device #2 in this case. If you now run the ipconfig command from terminal you will see the device listed there as well.

ipconfig /all
PowerShell
Ethernet adapter Ethernet 4:

   Connection-specific DNS Suffix  . :
   Description . . . . . . . . . . . : UsbNcm Host Device #2
   Physical Address. . . . . . . . . : 62-96-99-5D-30-5B
   DHCP Enabled. . . . . . . . . . . : Yes
   Autoconfiguration Enabled . . . . : Yes
   Link-local IPv6 Address . . . . . : fe80::7af3:3a6b:bb60:7aeb%15(Preferred)
   IPv4 Address. . . . . . . . . . . : 192.168.42.178(Preferred)
   Subnet Mask . . . . . . . . . . . : 255.255.255.0
   Lease Obtained. . . . . . . . . . : 27 July 2025 04:20:59 PM
   Lease Expires . . . . . . . . . . : 27 July 2025 05:20:59 PM
   Default Gateway . . . . . . . . . :
   DHCP Server . . . . . . . . . . . : 192.168.42.1
   DHCPv6 IAID . . . . . . . . . . . : 975884488
   DHCPv6 Client DUID. . . . . . . . : 00-01-00-01-2D-36-0E-15-D8-43-AE-21-47-8B
   NetBIOS over Tcpip. . . . . . . . : Enabled
Terminal
Windows Terminal showing the network interfaces as a result of ipconfig command
Result of ipconfig command

You need to take a note of the DHCP Server address in order to access the board. After copying the IP address, you can ping the board to see if the communication is working or not. If it is working, all of your pings will be successful.

ping 192.168.42.1
PowerShell
Pinging the Milk-V Duo board from Windows Terminal with SSH access
Pinging the board

Next is accessing the board via SSH (Secure Shell). Run the following command for doing this. If you are prompted for a fingerprint, then type in “yes”. If there is a fingerprint conflict, you can delete the old entries and start fresh.

Windows Terminal showing SSH access window from Milk-V Duo Linux board
Accessing SSH
ssh root@192.168.42.1
PowerShell

The default password is “milkv”. After entering, you can type in any Linux command and run it. For example, you can get the system details using the lscpu or neofetch command.

Windows Terminal showing lscpu command from Milk-V Duo Linux board in SSH mode
lscpu command
Windows Terminal showing neofetch command from Milk-V Duo Linux board in SSH mode
neofetch command

Type top or htop for process monitoring.

Windows Terminal showing top command from Milk-V Duo Linux board in SSH mode
top command
Windows Terminal showing htop command from Milk-V Duo Linux board in SSH mode
htop command

Python 3.9.5 is also included in the system image.

Windows Terminal showing Python version from Milk-V Duo Linux board in SSH mode
Python version

Installing the Arduino Image

Since the Milk-V Duo has two cores, we can run Linux on the first core running at 1 GHz and an Arduino core on the second running at 700 MHz. That’s awesome. Installing the Arduino image is the same as the normal image. Just use Balena Etcher and flash the image to the Micro SD card. This time when you access the board using SSH, you will get a warning or error saying the device fingerprints are not matching. Simply delete the old fingerprint from the known_hosts file and try again. Add the new device to the list when prompted. The LED will still be blinking when the board is running. You can disable this by running the following command.

mv /mnt/system/blink.sh /mnt/system/blink.sh_backup && sync
SSH

And then rebooting the board with the following command.

reboot
SSH

After rebooting the LED will stop blinking. Now we need to program the board using the Arduino IDE. In order to add support for the board, you need to add the following line to the boards URLs.

https://github.com/milkv-duo/duo-arduino/releases/download/v0.2.4/package_sg200x_index.json
URL
Adding Milk-V-Duo Board URL to Arduino-IDE by CIRCUITSTATE Electronics
Add the board URL

After adding the new URL, Arduino IDE will automatically update the boards list. You need an internet connection for this.

Selecting Milk-V Duo in Arduino IDE by CIRCUITSTATE Electronics
Select the board and COM port

After the board list is updated, you can open the connected devices list and search for “duo” and the Duo Dev Device should appear there. The board will also create a COM port in your computer which you can find from the Device Manager. Once you select the device and the COM port correctly, you are ready to flash your first program. For example, you can open the default Blink sketch and upload it.

/*
  Blink

  Turns an LED on for one second, then off for one second, repeatedly.

  Most Arduinos have an on-board LED you can control. On the UNO, MEGA and ZERO
  it is attached to digital pin 13, on MKR1000 on pin 6. LED_BUILTIN is set to
  the correct LED pin independent of which board is used.
  If you want to know what pin the on-board LED is connected to on your Arduino
  model, check the Technical Specs of your board at:
  https://docs.arduino.cc/hardware/

  modified 8 May 2014
  by Scott Fitzgerald
  modified 2 Sep 2016
  by Arturo Guadalupi
  modified 8 Sep 2016
  by Colby Newman

  This example code is in the public domain.

  https://docs.arduino.cc/built-in-examples/basics/Blink/
*/

// the setup function runs once when you press reset or power the board
void setup() {
  // initialize digital pin LED_BUILTIN as an output.
  pinMode(LED_BUILTIN, OUTPUT);
}

// the loop function runs over and over again forever
void loop() {
  digitalWrite(LED_BUILTIN, HIGH);  // turn the LED on (HIGH is the voltage level)
  delay(1000);                      // wait for a second
  digitalWrite(LED_BUILTIN, LOW);   // turn the LED off by making the voltage LOW
  delay(1000);                      // wait for a second
}
Blink.ino

Following is our compilation and upload log.

C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\HardwareSerial.cpp:31:19: warning: '__dso_handle' initialized and declared 'extern'
   31 | extern "C" void * __dso_handle = 0 ;
      |                   ^~~~~~~~~~~~
In file included from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant.h:4,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:33,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\WMath.cpp:6:
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:243: warning: "PLIC_BASE" redefined
  243 | #define PLIC_BASE           (0x70000000UL)
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:166: note: this is the location of the previous definition
  166 | #define PLIC_BASE               0x70000000
      | 
In file included from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant.h:4,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:33,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/Arduino.h:23,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\Main.cpp:20:
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:243: warning: "PLIC_BASE" redefined
  243 | #define PLIC_BASE           (0x70000000UL)
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:166: note: this is the location of the previous definition
  166 | #define PLIC_BASE               0x70000000
      | 
In file included from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_digital.h:22,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/Arduino.h:25:
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:79: warning: "round" redefined
   79 | #define round(x)     ((x ) >= 0 ? (long)((x) + 0.5) : (long)((x) - 0.5))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:86: note: this is the location of the previous definition
   86 | #define round(x)     ((x) >= 0 ? (long)((x) + 0.5) : (long)((x) - 0.5))  // round() comes from STL
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:84: warning: "lowByte" redefined
   84 | #define lowByte(w) ((uint8_t) ((w) & 0xff))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:95: note: this is the location of the previous definition
   95 | #define lowByte(w) ((uint8_t)((w) & 0xff))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:85: warning: "highByte" redefined
   85 | #define highByte(w) ((uint8_t) ((w) >> 8))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:96: note: this is the location of the previous definition
   96 | #define highByte(w) ((uint8_t)((w) >> 8))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:90: warning: "bitWrite" redefined
   90 | #define bitWrite(value, bit, bitvalue) (bitvalue ? bitSet(value, bit) : bitClear(value, bit))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:102: note: this is the location of the previous definition
  102 | #define bitWrite(value, bit, bitvalue) ((bitvalue) ? bitSet(value, bit) : bitClear(value, bit))
      | 
In file included from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant.h:4,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:33,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/Arduino.h:23,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\Tone.cpp:5:
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:243: warning: "PLIC_BASE" redefined
  243 | #define PLIC_BASE           (0x70000000UL)
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:166: note: this is the location of the previous definition
  166 | #define PLIC_BASE               0x70000000
      | 
In file included from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_digital.h:22,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/Arduino.h:25:
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:79: warning: "round" redefined
   79 | #define round(x)     ((x ) >= 0 ? (long)((x) + 0.5) : (long)((x) - 0.5))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:86: note: this is the location of the previous definition
   86 | #define round(x)     ((x) >= 0 ? (long)((x) + 0.5) : (long)((x) - 0.5))  // round() comes from STL
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:84: warning: "lowByte" redefined
   84 | #define lowByte(w) ((uint8_t) ((w) & 0xff))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:95: note: this is the location of the previous definition
   95 | #define lowByte(w) ((uint8_t)((w) & 0xff))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:85: warning: "highByte" redefined
   85 | #define highByte(w) ((uint8_t) ((w) >> 8))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:96: note: this is the location of the previous definition
   96 | #define highByte(w) ((uint8_t)((w) >> 8))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:90: warning: "bitWrite" redefined
   90 | #define bitWrite(value, bit, bitvalue) (bitvalue ? bitSet(value, bit) : bitClear(value, bit))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:102: note: this is the location of the previous definition
  102 | #define bitWrite(value, bit, bitvalue) ((bitvalue) ? bitSet(value, bit) : bitClear(value, bit))
      | 
In file included from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant.h:4,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:33,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\wiring_analog.c:21:
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:243: warning: "PLIC_BASE" redefined
  243 | #define PLIC_BASE           (0x70000000UL)
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:166: note: this is the location of the previous definition
  166 | #define PLIC_BASE               0x70000000
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\wiring_analog.c: In function 'analogRead':
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\wiring_analog.c:101:9: warning: 'return' with no value, in function returning non-void
  101 |         return;
      |         ^~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\wiring_analog.c:95:10: note: declared here
   95 | uint32_t analogRead(uint32_t pinNumber)
      |          ^~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\wiring_analog.c:106:9: warning: 'return' with no value, in function returning non-void
  106 |         return;
      |         ^~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\wiring_analog.c:95:10: note: declared here
   95 | uint32_t analogRead(uint32_t pinNumber)
      |          ^~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\wiring_analog.c:109:5: warning: implicit declaration of function 'pinMode' [-Wimplicit-function-declaration]
  109 |     pinMode(pinNumber, INPUT);
      |     ^~~~~~~
In file included from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant.h:4,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:33,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\System.cpp:5:
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:243: warning: "PLIC_BASE" redefined
  243 | #define PLIC_BASE           (0x70000000UL)
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:166: note: this is the location of the previous definition
  166 | #define PLIC_BASE               0x70000000
      | 
In file included from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant.h:4,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:33,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/bsp/include/csi/csi_riscv_gcc.h:8,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\time.c:5:
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:243: warning: "PLIC_BASE" redefined
  243 | #define PLIC_BASE           (0x70000000UL)
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:166: note: this is the location of the previous definition
  166 | #define PLIC_BASE               0x70000000
      | 
In file included from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant.h:4,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:33,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\startup\interrupt.c:28:
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:243: warning: "PLIC_BASE" redefined
  243 | #define PLIC_BASE           (0x70000000UL)
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:166: note: this is the location of the previous definition
  166 | #define PLIC_BASE               0x70000000
      | 
In file included from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant.h:4,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:33,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/WInterrupts.h:22,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\interrupts.c:5:
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:243: warning: "PLIC_BASE" redefined
  243 | #define PLIC_BASE           (0x70000000UL)
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:166: note: this is the location of the previous definition
  166 | #define PLIC_BASE               0x70000000
      | 
In file included from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant.h:4,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:33,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:22,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\wiring_shift.c:20:
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:243: warning: "PLIC_BASE" redefined
  243 | #define PLIC_BASE           (0x70000000UL)
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:166: note: this is the location of the previous definition
  166 | #define PLIC_BASE               0x70000000
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:79: warning: "round" redefined
   79 | #define round(x)     ((x ) >= 0 ? (long)((x) + 0.5) : (long)((x) - 0.5))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:86: note: this is the location of the previous definition
   86 | #define round(x)     ((x) >= 0 ? (long)((x) + 0.5) : (long)((x) - 0.5))  // round() comes from STL
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:84: warning: "lowByte" redefined
   84 | #define lowByte(w) ((uint8_t) ((w) & 0xff))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:95: note: this is the location of the previous definition
   95 | #define lowByte(w) ((uint8_t)((w) & 0xff))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:85: warning: "highByte" redefined
   85 | #define highByte(w) ((uint8_t) ((w) >> 8))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:96: note: this is the location of the previous definition
   96 | #define highByte(w) ((uint8_t)((w) >> 8))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:90: warning: "bitWrite" redefined
   90 | #define bitWrite(value, bit, bitvalue) (bitvalue ? bitSet(value, bit) : bitClear(value, bit))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:102: note: this is the location of the previous definition
  102 | #define bitWrite(value, bit, bitvalue) ((bitvalue) ? bitSet(value, bit) : bitClear(value, bit))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\wiring_shift.c: In function 'shiftIn':
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\wiring_shift.c:32:9: warning: implicit declaration of function 'digitalWrite' [-Wimplicit-function-declaration]
   32 |         digitalWrite(ulClockPin, HIGH) ;
      |         ^~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\wiring_shift.c:35:22: warning: implicit declaration of function 'digitalRead' [-Wimplicit-function-declaration]
   35 |             value |= digitalRead(ulDataPin) << i ;
      |                      ^~~~~~~~~~~
In file included from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant.h:4,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:33,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/bsp/include/csi/csi_riscv_gcc.h:8,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\startup\tick.c:6:
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:243: warning: "PLIC_BASE" redefined
  243 | #define PLIC_BASE           (0x70000000UL)
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:166: note: this is the location of the previous definition
  166 | #define PLIC_BASE               0x70000000
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\startup\tick.c: In function 'tick_init':
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\startup\tick.c:105:29: warning: passing argument 2 of 'attach_irq' from incompatible pointer type [-Wincompatible-pointer-types]
  105 |     attach_irq(IRQ_M_TIMER, &tick_irq_handler, 0, "M TIMER int", clint);
      |                             ^~~~~~~~~~~~~~~~~
      |                             |
      |                             void (*)(int,  void *)
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:117:40: note: expected 'irq_handler_t' {aka 'int (*)(int,  void *)'} but argument is of type 'void (*)(int,  void *)'
  117 | int attach_irq(int irqn, irq_handler_t handler, unsigned long flags,
      |                          ~~~~~~~~~~~~~~^~~~~~~
In file included from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant.h:4,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/bsp/include/csi/csi_common.h:15,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/bsp/include/hal/dw/dw_cvi_dma_ll.h:9,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/bsp/include/hal/hal_dma.h:9,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/bsp/include/cvi/cvi_dma.h:8,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\cvi_dma.c:6:
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:243: warning: "PLIC_BASE" redefined
  243 | #define PLIC_BASE           (0x70000000UL)
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:166: note: this is the location of the previous definition
  166 | #define PLIC_BASE               0x70000000
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\cvi_dma.c: In function 'dwc_do_first_queue':
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\cvi_dma.c:235:31: warning: passing argument 1 of 'clean_dcache_range' makes integer from pointer without a cast [-Wint-conversion]
  235 |         clean_dcache_range(cfg->src_addr, cfg->length);
      |                            ~~~^~~~~~~~~~
      |                               |
      |                               void *
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/bsp/include/csi/csi_common.h:37:35: note: expected 'uintptr_t' {aka 'long unsigned int'} but argument is of type 'void *'
   37 | void clean_dcache_range(uintptr_t start, size_t size);
      |                         ~~~~~~~~~~^~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\cvi_dma.c:238:29: warning: passing argument 1 of 'inv_dcache_range' makes integer from pointer without a cast [-Wint-conversion]
  238 |         inv_dcache_range(cfg->dst_addr, cfg->length);
      |                          ~~~^~~~~~~~~~
      |                             |
      |                             void *
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/bsp/include/csi/csi_common.h:36:33: note: expected 'uintptr_t' {aka 'long unsigned int'} but argument is of type 'void *'
   36 | void inv_dcache_range(uintptr_t start, size_t size);
      |                       ~~~~~~~~~~^~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\cvi_dma.c:241:31: warning: passing argument 1 of 'clean_dcache_range' makes integer from pointer without a cast [-Wint-conversion]
  241 |         clean_dcache_range(cfg->src_addr, cfg->length);
      |                            ~~~^~~~~~~~~~
      |                               |
      |                               void *
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/bsp/include/csi/csi_common.h:37:35: note: expected 'uintptr_t' {aka 'long unsigned int'} but argument is of type 'void *'
   37 | void clean_dcache_range(uintptr_t start, size_t size);
      |                         ~~~~~~~~~~^~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\cvi_dma.c:242:31: warning: passing argument 1 of 'flush_dcache_range' makes integer from pointer without a cast [-Wint-conversion]
  242 |         flush_dcache_range(cfg->dst_addr, cfg->length);
      |                            ~~~^~~~~~~~~~
      |                               |
      |                               void *
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/bsp/include/csi/csi_common.h:38:35: note: expected 'uintptr_t' {aka 'long unsigned int'} but argument is of type 'void *'
   38 | void flush_dcache_range(uintptr_t start, size_t size);
      |                         ~~~~~~~~~~^~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\cvi_dma.c: In function 'prep_transfer':
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\cvi_dma.c:451:32: warning: passing argument 1 of 'clean_dcache_range' makes integer from pointer without a cast [-Wint-conversion]
  451 |             clean_dcache_range((uint64_t *)&prev->lli, sizeof(struct dw_lli));
      |                                ^~~~~~~~~~~~~~~~~~~~~~
      |                                |
      |                                uint64_t * {aka long unsigned int *}
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/bsp/include/csi/csi_common.h:37:35: note: expected 'uintptr_t' {aka 'long unsigned int'} but argument is of type 'uint64_t *' {aka 'long unsigned int *'}
   37 | void clean_dcache_range(uintptr_t start, size_t size);
      |                         ~~~~~~~~~~^~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\cvi_dma.c:459:24: warning: passing argument 1 of 'clean_dcache_range' makes integer from pointer without a cast [-Wint-conversion]
  459 |     clean_dcache_range((uint64_t *)&prev->lli, sizeof(struct dw_lli));
      |                        ^~~~~~~~~~~~~~~~~~~~~~
      |                        |
      |                        uint64_t * {aka long unsigned int *}
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/bsp/include/csi/csi_common.h:37:35: note: expected 'uintptr_t' {aka 'long unsigned int'} but argument is of type 'uint64_t *' {aka 'long unsigned int *'}
   37 | void clean_dcache_range(uintptr_t start, size_t size);
      |                         ~~~~~~~~~~^~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\cvi_dma.c: In function 'cvi_dma_init':
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\cvi_dma.c:542:5: warning: implicit declaration of function 'hal_sdma_dma_int_mux_set_c906l'; did you mean 'hal_sdma_dma_int_mux_set_c906b'? [-Wimplicit-function-declaration]
  542 |     hal_sdma_dma_int_mux_set_c906l();
      |     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      |     hal_sdma_dma_int_mux_set_c906b
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\cvi_dma.c:546:41: warning: passing argument 2 of 'request_irq' from incompatible pointer type [-Wincompatible-pointer-types]
  546 |     request_irq((uint32_t)dma->irq_num, &dw_dma_irq_handler, 0, "dma", dma);
      |                                         ^~~~~~~~~~~~~~~~~~~
      |                                         |
      |                                         void (*)(uint32_t,  void *) {aka void (*)(unsigned int,  void *)}
In file included from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/bsp/include/csi/csi_riscv_gcc.h:8,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\cvi_dma.c:8:
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:119:41: note: expected 'irq_handler_t' {aka 'int (*)(int,  void *)'} but argument is of type 'void (*)(uint32_t,  void *)' {aka 'void (*)(unsigned int,  void *)'}
  119 | int request_irq(int irqn, irq_handler_t handler, unsigned long flags,
      |                           ~~~~~~~~~~~~~~^~~~~~~
In file included from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant.h:4,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:33,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\Stream.cpp:25:
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:243: warning: "PLIC_BASE" redefined
  243 | #define PLIC_BASE           (0x70000000UL)
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:166: note: this is the location of the previous definition
  166 | #define PLIC_BASE               0x70000000
      | 
In file included from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/misc.h:13,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\Stream.cpp:27:
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:79: warning: "round" redefined
   79 | #define round(x)     ((x ) >= 0 ? (long)((x) + 0.5) : (long)((x) - 0.5))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:86: note: this is the location of the previous definition
   86 | #define round(x)     ((x) >= 0 ? (long)((x) + 0.5) : (long)((x) - 0.5))  // round() comes from STL
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:84: warning: "lowByte" redefined
   84 | #define lowByte(w) ((uint8_t) ((w) & 0xff))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:95: note: this is the location of the previous definition
   95 | #define lowByte(w) ((uint8_t)((w) & 0xff))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:85: warning: "highByte" redefined
   85 | #define highByte(w) ((uint8_t) ((w) >> 8))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:96: note: this is the location of the previous definition
   96 | #define highByte(w) ((uint8_t)((w) >> 8))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:90: warning: "bitWrite" redefined
   90 | #define bitWrite(value, bit, bitvalue) (bitvalue ? bitSet(value, bit) : bitClear(value, bit))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:102: note: this is the location of the previous definition
  102 | #define bitWrite(value, bit, bitvalue) ((bitvalue) ? bitSet(value, bit) : bitClear(value, bit))
      | 
In file included from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant.h:4,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/bsp/include/csi/csi_common.h:15,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/bsp/include/csi/csi_spi.h:9,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:5:
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:243: warning: "PLIC_BASE" redefined
  243 | #define PLIC_BASE           (0x70000000UL)
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:166: note: this is the location of the previous definition
  166 | #define PLIC_BASE               0x70000000
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c: In function 'wait_ready_until_timeout':
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:69:17: warning: implicit declaration of function 'millis' [-Wimplicit-function-declaration]
   69 |     timestart = millis();
      |                 ^~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c: In function 'csi_spi_init':
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:388:21: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
  388 |         spi->priv = (void *)dw_spi_get_data_frame_len(spi_base);
      |                     ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c: In function 'csi_spi_uninit':
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:404:5: warning: implicit declaration of function 'disable_irq' [-Wimplicit-function-declaration]
  404 |     disable_irq((uint32_t)spi->dev.irq_num);
      |     ^~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:405:5: warning: implicit declaration of function 'detach_irq' [-Wimplicit-function-declaration]
  405 |     detach_irq((uint32_t)spi->dev.irq_num);
      |     ^~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c: In function 'csi_spi_frame_len':
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:536:21: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
  536 |         spi->priv = (void *)dw_spi_get_data_frame_len(spi_base);
      |                     ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c: In function 'csi_spi_send':
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:36: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                    ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:564:13: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
  564 |         if (IS_16BIT_FRAME_LEN(spi)) {
      |             ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:66: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                                                  ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:564:13: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
  564 |         if (IS_16BIT_FRAME_LEN(spi)) {
      |             ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:36: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                    ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:576:13: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
  576 |         if (IS_16BIT_FRAME_LEN(spi)) {
      |             ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:66: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                                                  ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:576:13: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
  576 |         if (IS_16BIT_FRAME_LEN(spi)) {
      |             ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:15:35: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   15 | #define IS_8BIT_FRAME_LEN(spi)   ((uint32_t)spi->priv <= 8U)
      |                                   ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:587:13: note: in expansion of macro 'IS_8BIT_FRAME_LEN'
  587 |         if (IS_8BIT_FRAME_LEN(spi)) {
      |             ^~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:36: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                    ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:609:13: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
  609 |         if (IS_16BIT_FRAME_LEN(spi)) {
      |             ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:66: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                                                  ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:609:13: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
  609 |         if (IS_16BIT_FRAME_LEN(spi)) {
      |             ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c: In function 'csi_spi_send_async':
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:36: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                    ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:669:9: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
  669 |     if (IS_16BIT_FRAME_LEN(spi)) {
      |         ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:66: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                                                  ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:669:9: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
  669 |     if (IS_16BIT_FRAME_LEN(spi)) {
      |         ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:681:13: warning: implicit declaration of function 'attach_irq' [-Wimplicit-function-declaration]
  681 |             attach_irq((uint32_t)spi->dev.irq_num, &dw_spi_irqhandler, 0, "spi send async", &spi->dev);
      |             ^~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:682:13: warning: implicit declaration of function 'enable_irq' [-Wimplicit-function-declaration]
  682 |             enable_irq((uint32_t)spi->dev.irq_num);
      |             ^~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c: In function 'dw_spi_send_intr':
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:36: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                    ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:700:13: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
  700 |         if (IS_16BIT_FRAME_LEN(spi)) {
      |             ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:66: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                                                  ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:700:13: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
  700 |         if (IS_16BIT_FRAME_LEN(spi)) {
      |             ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:15:35: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   15 | #define IS_8BIT_FRAME_LEN(spi)   ((uint32_t)spi->priv <= 8U)
      |                                   ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:702:20: note: in expansion of macro 'IS_8BIT_FRAME_LEN'
  702 |         } else if (IS_8BIT_FRAME_LEN(spi)) {
      |                    ^~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c: In function 'dw_spi_send_dma':
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:36: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                    ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:738:13: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
  738 |         if (IS_16BIT_FRAME_LEN(spi)) {
      |             ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:66: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                                                  ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:738:13: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
  738 |         if (IS_16BIT_FRAME_LEN(spi)) {
      |             ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:15:35: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   15 | #define IS_8BIT_FRAME_LEN(spi)   ((uint32_t)spi->priv <= 8U)
      |                                   ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:743:20: note: in expansion of macro 'IS_8BIT_FRAME_LEN'
  743 |         } else if (IS_8BIT_FRAME_LEN(spi)) {
      |                    ^~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c: In function 'csi_spi_receive':
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:36: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                    ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:797:13: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
  797 |         if (IS_16BIT_FRAME_LEN(spi)) {
      |             ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:66: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                                                  ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:797:13: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
  797 |         if (IS_16BIT_FRAME_LEN(spi)) {
      |             ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:36: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                    ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:809:13: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
  809 |         if (IS_16BIT_FRAME_LEN(spi)) {
      |             ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:66: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                                                  ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:809:13: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
  809 |         if (IS_16BIT_FRAME_LEN(spi)) {
      |             ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:15:35: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   15 | #define IS_8BIT_FRAME_LEN(spi)   ((uint32_t)spi->priv <= 8U)
      |                                   ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:829:13: note: in expansion of macro 'IS_8BIT_FRAME_LEN'
  829 |         if (IS_8BIT_FRAME_LEN(spi)) {
      |             ^~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:36: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                    ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:851:13: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
  851 |         if (IS_16BIT_FRAME_LEN(spi)) {
      |             ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:66: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                                                  ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:851:13: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
  851 |         if (IS_16BIT_FRAME_LEN(spi)) {
      |             ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c: In function 'csi_spi_receive_async':
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:36: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                    ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:906:13: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
  906 |         if (IS_16BIT_FRAME_LEN(spi)) {
      |             ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:66: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                                                  ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:906:13: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
  906 |         if (IS_16BIT_FRAME_LEN(spi)) {
      |             ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c: In function 'dw_spi_receive_intr':
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:36: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                    ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:941:13: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
  941 |         if (IS_16BIT_FRAME_LEN(spi)) {
      |             ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:66: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                                                  ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:941:13: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
  941 |         if (IS_16BIT_FRAME_LEN(spi)) {
      |             ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:15:35: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   15 | #define IS_8BIT_FRAME_LEN(spi)   ((uint32_t)spi->priv <= 8U)
      |                                   ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:943:20: note: in expansion of macro 'IS_8BIT_FRAME_LEN'
  943 |         } else if (IS_8BIT_FRAME_LEN(spi)) {
      |                    ^~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c: In function 'dw_spi_receive_dma':
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:36: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                    ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:986:13: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
  986 |         if (IS_16BIT_FRAME_LEN(spi)) {
      |             ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:66: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                                                  ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:986:13: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
  986 |         if (IS_16BIT_FRAME_LEN(spi)) {
      |             ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:15:35: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   15 | #define IS_8BIT_FRAME_LEN(spi)   ((uint32_t)spi->priv <= 8U)
      |                                   ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:990:20: note: in expansion of macro 'IS_8BIT_FRAME_LEN'
  990 |         } else if (IS_8BIT_FRAME_LEN(spi)) {
      |                    ^~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c: In function 'csi_spi_send_receive':
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:36: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                    ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:1052:13: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
 1052 |         if (IS_16BIT_FRAME_LEN(spi)) {
      |             ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:66: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                                                  ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:1052:13: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
 1052 |         if (IS_16BIT_FRAME_LEN(spi)) {
      |             ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:36: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                    ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:1064:13: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
 1064 |         if (IS_16BIT_FRAME_LEN(spi)) {
      |             ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:66: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                                                  ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:1064:13: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
 1064 |         if (IS_16BIT_FRAME_LEN(spi)) {
      |             ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:36: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                    ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:1072:13: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
 1072 |         if (IS_16BIT_FRAME_LEN(spi)) {
      |             ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:66: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                                                  ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:1072:13: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
 1072 |         if (IS_16BIT_FRAME_LEN(spi)) {
      |             ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:15:35: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   15 | #define IS_8BIT_FRAME_LEN(spi)   ((uint32_t)spi->priv <= 8U)
      |                                   ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:1086:13: note: in expansion of macro 'IS_8BIT_FRAME_LEN'
 1086 |         if (IS_8BIT_FRAME_LEN(spi)) {
      |             ^~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:36: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                    ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:1126:13: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
 1126 |         if (IS_16BIT_FRAME_LEN(spi)) {
      |             ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:66: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                                                  ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:1126:13: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
 1126 |         if (IS_16BIT_FRAME_LEN(spi)) {
      |             ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c: In function 'csi_spi_send_receive_async':
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:36: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                    ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:1198:9: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
 1198 |     if (IS_16BIT_FRAME_LEN(spi)) {
      |         ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:66: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                                                  ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:1198:9: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
 1198 |     if (IS_16BIT_FRAME_LEN(spi)) {
      |         ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c: In function 'dw_spi_send_receive_intr':
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:36: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                    ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:1234:13: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
 1234 |         if (IS_16BIT_FRAME_LEN(spi)) {
      |             ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:66: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                                                  ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:1234:13: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
 1234 |         if (IS_16BIT_FRAME_LEN(spi)) {
      |             ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:15:35: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   15 | #define IS_8BIT_FRAME_LEN(spi)   ((uint32_t)spi->priv <= 8U)
      |                                   ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:1237:20: note: in expansion of macro 'IS_8BIT_FRAME_LEN'
 1237 |         } else if (IS_8BIT_FRAME_LEN(spi)) {
      |                    ^~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c: In function 'dw_spi_send_receive_dma':
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:36: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                    ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:1274:13: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
 1274 |         if (IS_16BIT_FRAME_LEN(spi)) {
      |             ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:16:66: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   16 | #define IS_16BIT_FRAME_LEN(spi)  (((uint32_t)spi->priv > 8U) && ((uint32_t)spi->priv <= 16U))
      |                                                                  ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:1274:13: note: in expansion of macro 'IS_16BIT_FRAME_LEN'
 1274 |         if (IS_16BIT_FRAME_LEN(spi)) {
      |             ^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:15:35: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   15 | #define IS_8BIT_FRAME_LEN(spi)   ((uint32_t)spi->priv <= 8U)
      |                                   ^
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_spi.c:1279:20: note: in expansion of macro 'IS_8BIT_FRAME_LEN'
 1279 |         } else if (IS_8BIT_FRAME_LEN(spi)) {
      |                    ^~~~~~~~~~~~~~~~~
In file included from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant.h:4,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:33,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/Arduino.h:23,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\Print.cpp:24:
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:243: warning: "PLIC_BASE" redefined
  243 | #define PLIC_BASE           (0x70000000UL)
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:166: note: this is the location of the previous definition
  166 | #define PLIC_BASE               0x70000000
      | 
In file included from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_digital.h:22,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/Arduino.h:25:
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:79: warning: "round" redefined
   79 | #define round(x)     ((x ) >= 0 ? (long)((x) + 0.5) : (long)((x) - 0.5))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:86: note: this is the location of the previous definition
   86 | #define round(x)     ((x) >= 0 ? (long)((x) + 0.5) : (long)((x) - 0.5))  // round() comes from STL
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:84: warning: "lowByte" redefined
   84 | #define lowByte(w) ((uint8_t) ((w) & 0xff))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:95: note: this is the location of the previous definition
   95 | #define lowByte(w) ((uint8_t)((w) & 0xff))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:85: warning: "highByte" redefined
   85 | #define highByte(w) ((uint8_t) ((w) >> 8))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:96: note: this is the location of the previous definition
   96 | #define highByte(w) ((uint8_t)((w) >> 8))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:90: warning: "bitWrite" redefined
   90 | #define bitWrite(value, bit, bitvalue) (bitvalue ? bitSet(value, bit) : bitClear(value, bit))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:102: note: this is the location of the previous definition
  102 | #define bitWrite(value, bit, bitvalue) ((bitvalue) ? bitSet(value, bit) : bitClear(value, bit))
      | 
In file included from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant.h:4,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:33,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/Arduino.h:23,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\Mailbox.cpp:5:
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:243: warning: "PLIC_BASE" redefined
  243 | #define PLIC_BASE           (0x70000000UL)
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:166: note: this is the location of the previous definition
  166 | #define PLIC_BASE               0x70000000
      | 
In file included from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_digital.h:22,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/Arduino.h:25:
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:79: warning: "round" redefined
   79 | #define round(x)     ((x ) >= 0 ? (long)((x) + 0.5) : (long)((x) - 0.5))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:86: note: this is the location of the previous definition
   86 | #define round(x)     ((x) >= 0 ? (long)((x) + 0.5) : (long)((x) - 0.5))  // round() comes from STL
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:84: warning: "lowByte" redefined
   84 | #define lowByte(w) ((uint8_t) ((w) & 0xff))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:95: note: this is the location of the previous definition
   95 | #define lowByte(w) ((uint8_t)((w) & 0xff))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:85: warning: "highByte" redefined
   85 | #define highByte(w) ((uint8_t) ((w) >> 8))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:96: note: this is the location of the previous definition
   96 | #define highByte(w) ((uint8_t)((w) >> 8))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:90: warning: "bitWrite" redefined
   90 | #define bitWrite(value, bit, bitvalue) (bitvalue ? bitSet(value, bit) : bitClear(value, bit))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:102: note: this is the location of the previous definition
  102 | #define bitWrite(value, bit, bitvalue) ((bitvalue) ? bitSet(value, bit) : bitClear(value, bit))
      | 
In file included from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant.h:4,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/bsp/include/csi/csi_common.h:15,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/bsp/include/csi/csi_iic.h:10,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_iic.c:6:
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:243: warning: "PLIC_BASE" redefined
  243 | #define PLIC_BASE           (0x70000000UL)
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:166: note: this is the location of the previous definition
  166 | #define PLIC_BASE               0x70000000
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_iic.c: In function 'wait_iic_transmit':
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_iic.c:28:40: warning: implicit declaration of function 'millis' [-Wimplicit-function-declaration]
   28 |         uint32_t timecount = timeout + millis();
      |                                        ^~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_iic.c: In function 'csi_iic_master_send_async':
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_iic.c:941:48: warning: passing argument 2 of 'attach_irq' from incompatible pointer type [-Wincompatible-pointer-types]
  941 |         attach_irq((uint32_t)iic->dev.irq_num, &dw_iic_tx_handler, 0, "i2c master send", &iic->dev);
      |                                                ^~~~~~~~~~~~~~~~~~
      |                                                |
      |                                                void (*)(void *)
In file included from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_iic.c:9:
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:117:40: note: expected 'irq_handler_t' {aka 'int (*)(int,  void *)'} but argument is of type 'void (*)(void *)'
  117 | int attach_irq(int irqn, irq_handler_t handler, unsigned long flags,
      |                          ~~~~~~~~~~~~~~^~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_iic.c: In function 'csi_iic_master_receive_async':
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_iic.c:1019:44: warning: passing argument 2 of 'attach_irq' from incompatible pointer type [-Wincompatible-pointer-types]
 1019 |     attach_irq((uint32_t)iic->dev.irq_num, &dw_iic_rx_handler, 0, "iic master rx", &iic->dev);
      |                                            ^~~~~~~~~~~~~~~~~~
      |                                            |
      |                                            void (*)(void *)
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:117:40: note: expected 'irq_handler_t' {aka 'int (*)(int,  void *)'} but argument is of type 'void (*)(void *)'
  117 | int attach_irq(int irqn, irq_handler_t handler, unsigned long flags,
      |                          ~~~~~~~~~~~~~~^~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_iic.c: In function 'iic_slave_send_dma':
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_iic.c:1302:44: warning: passing argument 2 of 'attach_irq' from incompatible pointer type [-Wincompatible-pointer-types]
 1302 |     attach_irq((uint32_t)iic->dev.irq_num, &iic_slave_send_data_with_dma_irq,  0, "iic slave dma tx",  &iic->dev); ///< if use slave send dma attach will change
      |                                            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      |                                            |
      |                                            void (*)(void *)
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:117:40: note: expected 'irq_handler_t' {aka 'int (*)(int,  void *)'} but argument is of type 'void (*)(void *)'
  117 | int attach_irq(int irqn, irq_handler_t handler, unsigned long flags,
      |                          ~~~~~~~~~~~~~~^~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_iic.c: In function 'csi_iic_slave_send_async':
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_iic.c:1370:48: warning: passing argument 2 of 'attach_irq' from incompatible pointer type [-Wincompatible-pointer-types]
 1370 |         attach_irq((uint32_t)iic->dev.irq_num, &iic_slave_send_data_with_dma_irq, 0, "iic slave dma tx", &iic->dev);
      |                                                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      |                                                |
      |                                                void (*)(void *)
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:117:40: note: expected 'irq_handler_t' {aka 'int (*)(int,  void *)'} but argument is of type 'void (*)(void *)'
  117 | int attach_irq(int irqn, irq_handler_t handler, unsigned long flags,
      |                          ~~~~~~~~~~~~~~^~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_iic.c:1374:48: warning: passing argument 2 of 'attach_irq' from incompatible pointer type [-Wincompatible-pointer-types]
 1374 |         attach_irq((uint32_t)iic->dev.irq_num, &dw_iic_slave_tx_handler, 0, "iic slave tx", &iic->dev);
      |                                                ^~~~~~~~~~~~~~~~~~~~~~~~
      |                                                |
      |                                                void (*)(void *)
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:117:40: note: expected 'irq_handler_t' {aka 'int (*)(int,  void *)'} but argument is of type 'void (*)(void *)'
  117 | int attach_irq(int irqn, irq_handler_t handler, unsigned long flags,
      |                          ~~~~~~~~~~~~~~^~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_iic.c: In function 'csi_iic_slave_receive_async':
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\bsp\drivers\csi_iic.c:1475:48: warning: passing argument 2 of 'attach_irq' from incompatible pointer type [-Wincompatible-pointer-types]
 1475 |         attach_irq((uint32_t)iic->dev.irq_num, &dw_iic_slave_rx_handler, 0, "iic slave rx", &iic->dev);
      |                                                ^~~~~~~~~~~~~~~~~~~~~~~~
      |                                                |
      |                                                void (*)(void *)
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:117:40: note: expected 'irq_handler_t' {aka 'int (*)(int,  void *)'} but argument is of type 'void (*)(void *)'
  117 | int attach_irq(int irqn, irq_handler_t handler, unsigned long flags,
      |                          ~~~~~~~~~~~~~~^~~~~~~
In file included from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant.h:4,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:33,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:22,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_digital.h:22,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\wiring_digital.c:5:
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:243: warning: "PLIC_BASE" redefined
  243 | #define PLIC_BASE           (0x70000000UL)
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:166: note: this is the location of the previous definition
  166 | #define PLIC_BASE               0x70000000
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:79: warning: "round" redefined
   79 | #define round(x)     ((x ) >= 0 ? (long)((x) + 0.5) : (long)((x) - 0.5))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:86: note: this is the location of the previous definition
   86 | #define round(x)     ((x) >= 0 ? (long)((x) + 0.5) : (long)((x) - 0.5))  // round() comes from STL
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:84: warning: "lowByte" redefined
   84 | #define lowByte(w) ((uint8_t) ((w) & 0xff))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:95: note: this is the location of the previous definition
   95 | #define lowByte(w) ((uint8_t)((w) & 0xff))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:85: warning: "highByte" redefined
   85 | #define highByte(w) ((uint8_t) ((w) >> 8))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:96: note: this is the location of the previous definition
   96 | #define highByte(w) ((uint8_t)((w) >> 8))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:90: warning: "bitWrite" redefined
   90 | #define bitWrite(value, bit, bitvalue) (bitvalue ? bitSet(value, bit) : bitClear(value, bit))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:102: note: this is the location of the previous definition
  102 | #define bitWrite(value, bit, bitvalue) ((bitvalue) ? bitSet(value, bit) : bitClear(value, bit))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\wiring_digital.c: In function 'digitalRead':
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\wiring_digital.c:96:9: warning: 'return' with no value, in function returning non-void
   96 |         return;
      |         ^~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\wiring_digital.c:93:5: note: declared here
   93 | int digitalRead(uint8_t pinNumber)
      |     ^~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\wiring_digital.c:103:9: warning: 'return' with no value, in function returning non-void
  103 |         return;
      |         ^~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\wiring_digital.c:93:5: note: declared here
   93 | int digitalRead(uint8_t pinNumber)
      |     ^~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\wiring_digital.c:107:9: warning: 'return' with no value, in function returning non-void
  107 |         return;
      |         ^~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\wiring_digital.c:93:5: note: declared here
   93 | int digitalRead(uint8_t pinNumber)
      |     ^~~~~~~~~~~
In file included from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant.h:4,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:33,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/Arduino.h:23,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\wiring_pulse.cpp:18:
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:243: warning: "PLIC_BASE" redefined
  243 | #define PLIC_BASE           (0x70000000UL)
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:166: note: this is the location of the previous definition
  166 | #define PLIC_BASE               0x70000000
      | 
In file included from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_digital.h:22,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/Arduino.h:25:
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:79: warning: "round" redefined
   79 | #define round(x)     ((x ) >= 0 ? (long)((x) + 0.5) : (long)((x) - 0.5))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:86: note: this is the location of the previous definition
   86 | #define round(x)     ((x) >= 0 ? (long)((x) + 0.5) : (long)((x) - 0.5))  // round() comes from STL
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:84: warning: "lowByte" redefined
   84 | #define lowByte(w) ((uint8_t) ((w) & 0xff))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:95: note: this is the location of the previous definition
   95 | #define lowByte(w) ((uint8_t)((w) & 0xff))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:85: warning: "highByte" redefined
   85 | #define highByte(w) ((uint8_t) ((w) >> 8))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:96: note: this is the location of the previous definition
   96 | #define highByte(w) ((uint8_t)((w) >> 8))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:90: warning: "bitWrite" redefined
   90 | #define bitWrite(value, bit, bitvalue) (bitvalue ? bitSet(value, bit) : bitClear(value, bit))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:102: note: this is the location of the previous definition
  102 | #define bitWrite(value, bit, bitvalue) ((bitvalue) ? bitSet(value, bit) : bitClear(value, bit))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\wiring_pulse.cpp: In function 'long unsigned int pulseIn(uint8_t, uint8_t, long unsigned int)':
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:92:53: warning: conversion from 'long unsigned int' to 'uint32_t' {aka 'unsigned int'} changes value from '737869762948382' to '2971430174' [-Woverflow]
   92 | #define clockCyclesToMicroseconds(a) (((a) * 1000L) / (F_CPU / 1000L))
      |                                      ~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\wiring_pulse.cpp:38:37: note: in expansion of macro 'clockCyclesToMicroseconds'
   38 |     const uint32_t max_timeout_us = clockCyclesToMicroseconds(ULONG_MAX);
      |                                     ^~~~~~~~~~~~~~~~~~~~~~~~~
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\HardwareSerial.cpp.o"
In file included from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant.h:4,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:33,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/Arduino.h:23,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\cores\sg200x\WString.cpp:27:
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:243: warning: "PLIC_BASE" redefined
  243 | #define PLIC_BASE           (0x70000000UL)
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3\variants\duo/variant_soc.h:166: note: this is the location of the previous definition
  166 | #define PLIC_BASE               0x70000000
      | 
In file included from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_digital.h:22,
                 from C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/Arduino.h:25:
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:79: warning: "round" redefined
   79 | #define round(x)     ((x ) >= 0 ? (long)((x) + 0.5) : (long)((x) - 0.5))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:86: note: this is the location of the previous definition
   86 | #define round(x)     ((x) >= 0 ? (long)((x) + 0.5) : (long)((x) - 0.5))  // round() comes from STL
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:84: warning: "lowByte" redefined
   84 | #define lowByte(w) ((uint8_t) ((w) & 0xff))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:95: note: this is the location of the previous definition
   95 | #define lowByte(w) ((uint8_t)((w) & 0xff))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:85: warning: "highByte" redefined
   85 | #define highByte(w) ((uint8_t) ((w) >> 8))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:96: note: this is the location of the previous definition
   96 | #define highByte(w) ((uint8_t)((w) >> 8))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/wiring_constants.h:90: warning: "bitWrite" redefined
   90 | #define bitWrite(value, bit, bitvalue) (bitvalue ? bitSet(value, bit) : bitClear(value, bit))
      | 
C:\Users\vishn\AppData\Local\Arduino15\packages\sophgo\hardware\SG200X\0.2.3/cores/sg200x/include/common.h:102: note: this is the location of the previous definition
  102 | #define bitWrite(value, bit, bitvalue) ((bitvalue) ? bitSet(value, bit) : bitClear(value, bit))
      | 
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\Mailbox.cpp.o"
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\Main.cpp.o"
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\Print.cpp.o"
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\Stream.cpp.o"
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\System.cpp.o"
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\Tone.cpp.o"
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\WMath.cpp.o"
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\WString.cpp.o"
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\bsp\\drivers\\csi_adc.c.o"
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\bsp\\drivers\\csi_common.c.o"
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\bsp\\drivers\\csi_dma.c.o"
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\bsp\\drivers\\csi_dma_consts.c.o"
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\bsp\\drivers\\csi_gpio.c.o"
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\bsp\\drivers\\csi_gpio_pin.c.o"
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\bsp\\drivers\\csi_iic.c.o"
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\bsp\\drivers\\csi_pin.c.o"
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\bsp\\drivers\\csi_pwm.c.o"
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\bsp\\drivers\\csi_spi.c.o"
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\bsp\\drivers\\csi_target_get.c.o"
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\bsp\\drivers\\csi_uart.c.o"
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\bsp\\drivers\\cvi_dma.c.o"
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\bsp\\drivers\\cvi_mailbox.c.o"
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\bsp\\drivers\\cvi_spinlock.c.o"
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\bsp\\hal\\dw\\dw_iic_ll.c.o"
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\bsp\\hal\\dw\\dw_spi_ll.c.o"
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\bsp\\hal\\dw\\dw_uart_ll.c.o"
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\bsp\\hal\\hal_dma.c.o"
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\bsp\\hal\\hal_sysdma.c.o"
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\bsp\\startup\\interrupt.c.o"
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\bsp\\startup\\start.S.o"
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\bsp\\startup\\tick.c.o"
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\interrupts.c.o"
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\stdlib_noniso.c.o"
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\time.c.o"
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\wiring_analog.c.o"
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\wiring_digital.c.o"
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\wiring_pulse.cpp.o"
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-gcc-ar" cr "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\core.a" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\wiring_shift.c.o"
Archiving built core (caching) in: C:\Users\vishn\AppData\Local\arduino\cores\sophgo_SG200X_duo_513e1e73072cbbf41ac7faf03c483c77\core.a
Linking everything together...
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-g++" "-LC:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64" -nostartfiles -Wl,--no-warn-rwx-segments -mcmodel=medany -mabi=lp64d -march=rv64imfd_zicsr "-Wl,--Map=C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64/Blink.ino.map" "-TC:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\hardware\\SG200X\\0.2.3\\variants\\duo/link.ld" "-Wl,-Map,C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64/Blink.ino.map" --specs=nano.specs --specs=nosys.specs -o "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64/Blink.ino.elf" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\sketch\\Blink.ino.cpp.o" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64\\core\\variant_pin_maps.c.o" -Wl,--start-group -lm "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64/core\\core.a" -Wl,--end-group
C:/Users/vishn/AppData/Local/Arduino15/packages/sophgo/tools/xpack-riscv-none-elf-gcc/13.2.0-2/bin/../lib/gcc/riscv-none-elf/13.2.0/../../../../riscv"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-objcopy" -O binary "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64/Blink.ino.elf" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64/Blink.ino.bin"
-none-elf/bin/ld.exe: C:/Users/vishn/AppData/Local/Arduino15/packages/sophgo/tools/xpack-riscv-none-elf-gcc/13.2.0-2/bin/../lib/gcc/riscv-none-elf/13.2.0/../../../../riscv-none-elf/lib/rv64imfd_zicsr/lp64d\libc_nano.a(libc_a-signalr.o): in function `_getpid_r':
signalr.c:(.text._getpid_r+0x0): warning: _getpid is not implemented and will always fail
C:/Users/vishn/AppData/Local/Arduino15/packages/sophgo/tools/xpack-riscv-none-elf-gcc/13.2.0-2/bin/../lib/gcc/riscv-none-elf/13.2.0/../../../../riscv-none-elf/bin/ld.exe: C:/Users/vishn/AppData/Local/Arduino15/packages/sophgo/tools/xpack-riscv-none-elf-gcc/13.2.0-2/bin/../lib/gcc/riscv-none-elf/13.2.0/../../../../riscv-none-elf/lib/rv64imfd_zicsr/lp64d\libc_nano.a(libc_a-signalr.o): in function `.L0 ':
signalr.c:(.text._kill_r+0x20): warning: _kill is not implemented and will always fail
"C:\\Users\\vishn\\AppData\\Local\\Arduino15\\packages\\sophgo\\tools\\xpack-riscv-none-elf-gcc\\13.2.0-2/bin/riscv-none-elf-objcopy" -O ihex -R .eeprom "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64/Blink.ino.elf" "C:\\Users\\vishn\\AppData\\Local\\arduino\\sketches\\32AB1E0545D1BD1765520C7169C58F64/Blink.ino.hex"

burntool.py v0.3

upload firmware C:\Users\vishn\AppData\Local\arduino\sketches\32AB1E0545D1BD1765520C7169C58F64/Blink.ino.elf

start upload...

communication and testing...

connecting...

connection successful...
stop firmware...

ready to update firmware...
start to update firmware...
send data... 10.00%
send data... 20.00%
send data... 30.00%
send data... 40.00%
send data... 50.00%
send data... 60.00%
send data... 70.00%
send data... 80.00%
send data... 90.00%
send data... 100.00%
update firmware done...

restart firmware...

upload and runing success...
Console

After uploading the code, the blue LED should start blinking. Next, we can try a Hello World program. We are going to print the message to the UART3 port of the Milk-V Duo. We can access UART3 using the Serial3 instance. You need to connect a UART-USB converter to the pin in order to see the message. The serial interface created by the USB connector is not accessible from the Arduino core.

void setup() {
  Serial3.begin (115200);
}

void loop() {
  Serial3.printf ("hello world\r\n");
  delay (1000);
}
Hello-World.ino

There are more examples and interfaces you can try out. All of them are neatly documented in the official documentation. We will cover more examples and applications in the future. If you ask us if this board or the CV1800B SoC for a new product, we would say not. This is mainly because of the lack of high-quality documentation, active development support and long-term guarantees. The CV1800B SoC is no longer recommended for new designs and it did not have a complete datasheet. The documentation is all over the places and you will find a hard time collecting all things in one place. We hope Milk-V improves their documentation and provide better support in the future.

  1. Milk-V Duo – Product Page
  2. Milk-V Duo – Datasheet [PDF]
  3. Milk-V Duo – Hardware Design Resources
  4. Milk-V Duo – Documentation
  5. Buy Milk-V Duo – Robu.in
  6. Duo SDK – GitHub
  7. Balena Etcher
Share to your friends
Vishnu Mohanan

Vishnu Mohanan

Founder and CEO at CIRCUITSTATE Electronics

Articles: 103

Leave a Reply

Your email address will not be published. Required fields are marked *

This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

The reCAPTCHA verification period has expired. Please reload the page.