You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@nuttx.apache.org by Alan Carvalho de Assis <ac...@gmail.com> on 2021/01/21 12:47:02 UTC

Raspberry Pi Pico a nice board for NuttX

Hi Everyone,

I think many of you already saw this news!

The Raspberry Foundation created their own microcontroller based on
ARM Cortex M0+ with 1MB Flash and 256KB RAM.

They also add support to OpenOCD (not in mainline yet) see:

https://datasheets.raspberrypi.org/pico/getting_started_with_pico.pdf

So yes, a good board to use with NuttX and a good alternative to
Arduino and BluePill.

BR,

Alan

Re: Raspberry Pi Pico a nice board for NuttX

Posted by Brennan Ashton <ba...@brennanashton.com>.
On Fri, Jan 22, 2021, 3:54 PM Matias N. <ma...@imap.cc> wrote:

>
> > Is there any easy way to get all of the register definition header files
> > in place (with Apache 2 headers)?
>
> If there's an SVD file somewhere, you can use this:
>
> https://gitlab.com/nuttx_projects/svdgen
>
> I've used it many times and requires minimal tweaking afterwards.
>

I also used this with some Apache SVDs and modified the script around the
naming scheme used in the file (and handle some bad entries) and found it
saved a lot of time.

Some SVDs like to duplicate the register name with the register field name
which makes super long defines if you don't clean them up. I also made some
changes like not including the chip name at the start of the field which I
think also aligned better with the style.

But it is so much nicer than manually typing out everything and I think
less error prone.

--Brennan

>

Re: Raspberry Pi Pico a nice board for NuttX

Posted by "Matias N." <ma...@imap.cc>.
> Is there any easy way to get all of the register definition header files 
> in place (with Apache 2 headers)?

If there's an SVD file somewhere, you can use this:

https://gitlab.com/nuttx_projects/svdgen

I've used it many times and requires minimal tweaking afterwards.

Best,
Matias

Re: Raspberry Pi Pico a nice board for NuttX

Posted by "Matias N." <ma...@imap.cc>.
There's an SVD file, so no need to use any other headers:

https://github.com/raspberrypi/pico-sdk/blob/master/src/rp2040/hardware_regs/rp2040.svd

We discussed in the past about the license that would apply to a header auto-generated from the SVD but I'm not sure if we arrived at any conclusion (the rationale was that in the end was data that would be obtained from the datasheet or from other public sources). Still, the SVD is BSD3 so we would be OK if we had to use that license to the output.

Best,
Matias

On Wed, Jan 27, 2021, at 21:37, Justin Mclean wrote:
> Hi,
> 
> > Copyright © 2020 Raspberry Pi (Trading) Ltd. The documentation of the RP2040 microcontroller is licensed under a Creative Commons Attribution-NoDerivatives 4.0 International (CC BY-ND). Portions Copyright © 2019 Synopsys, Inc. All rights reserved. Used with permission. Synopsys & DesignWare are registered trademarks of Synopsys, Inc. Portions Copyright © 2000-2001, 2005, 2007, 2009, 2011-2012, 2016 ARM Limited. All rights reserved. Used with permission.
> 
> Being BSD it abdul be OK. The other bits of code “used with permission” might be an issue as they are unlikely to be under an open source license and NuttX would need to get permission to use them. May need to clarify on the legal discuss list.
> 
> Thanks,
> Justin

Re: Raspberry Pi Pico a nice board for NuttX

Posted by Justin Mclean <ju...@classsoftware.com>.
Hi,

> Copyright © 2020 Raspberry Pi (Trading) Ltd. The documentation of the RP2040 microcontroller is licensed under a Creative Commons Attribution-NoDerivatives 4.0 International (CC BY-ND). Portions Copyright © 2019 Synopsys, Inc. All rights reserved. Used with permission. Synopsys & DesignWare are registered trademarks of Synopsys, Inc. Portions Copyright © 2000-2001, 2005, 2007, 2009, 2011-2012, 2016 ARM Limited. All rights reserved. Used with permission.

Being BSD it abdul be OK. The other bits of code “used with permission” might be an issue as they are unlikely to be under an open source license and NuttX would need to get permission to use them. May need to clarify on the legal discuss list.

Thanks,
Justin

Re: Raspberry Pi Pico a nice board for NuttX

Posted by Arie de Muijnck <nu...@ademu.com>.
On 2021-01-22 23:38, Gregory Nutt wrote:
>
>>>> The Raspberry Foundation created their own microcontroller based on
>>>> ARM Cortex M0+ with 1MB Flash and 256KB RAM.
>
> I wonder how the performance is with two cores running from QSPI with 
> no instruction cache?
> There is no data cache either.  This could be an issue for SMP, at 
> least if the same RAM banks are being used.
>
> Still I think this could be an interesting SMP platform if there are 
> no showstopper architectural issues. That could be an interesting 
> project.
>
> Is there any easy way to get all of the register definition header 
> files in place (with Apache 2 headers)?
>

 From the datasheet 
https://datasheets.raspberrypi.org/rp2040/rp2040_datasheet.pdf:
     RP2040 is a stateless device, with support for cached 
execute-in-place from external QSPI memory.
Figure 2 on page 10 also shows an XIP/Cache between the QSPI and cores.

The datasheet has all (?) register definitions, header files are in the 
free SDK in files:
pico-sdk-master\src\rp2040\hardware_regs\include\hardware\regs\*.h

Datasheet has copyright:
      Copyright © 2020 Raspberry Pi (Trading) Ltd. The documentation of 
the RP2040 microcontroller is licensed under a Creative Commons 
Attribution-NoDerivatives 4.0 International (CC BY-ND). Portions 
Copyright © 2019 Synopsys, Inc. All rights reserved. Used with 
permission. Synopsys & DesignWare are registered trademarks of Synopsys, 
Inc. Portions Copyright © 2000-2001, 2005, 2007, 2009, 2011-2012, 2016 
ARM Limited. All rights reserved. Used with permission.
build-date: 2021-01-21 build-version: fcd04ef-clean

The headers files have copyright message:
     * Copyright (c) 2021 Raspberry Pi (Trading) Ltd.
     * SPDX-License-Identifier: BSD-3-Clause

However, I think there is some hidden core info in *.a files without 
sources.
Still studying...

Regards,
Arie de Muijnck


Re: Raspberry Pi Pico a nice board for NuttX

Posted by Gregory Nutt <sp...@gmail.com>.
>>> The Raspberry Foundation created their own microcontroller based on
>>> ARM Cortex M0+ with 1MB Flash and 256KB RAM.

I wonder how the performance is with two cores running from QSPI with no 
instruction cache?

There is no data cache either.  This could be an issue for SMP, at least 
if the same RAM banks are being used.

Still I think this could be an interesting SMP platform if there are no 
showstopper architectural issues. That could be an interesting project.

Is there any easy way to get all of the register definition header files 
in place (with Apache 2 headers)?


Re: Raspberry Pi Pico a nice board for NuttX

Posted by Alan Carvalho de Assis <ac...@gmail.com>.
Thank you Arie,

There is also an example to implement a bitbanging DUAL display HDMI:

https://github.com/Wren6991/picodvi

The MCU datasheet is here:

https://datasheets.raspberrypi.org/rp2040/rp2040_datasheet.pdf

BR,

Alan

On 1/21/21, Arie de Muijnck <my...@ademu.com> wrote:
> Yes, I saw it and immediately ordered two at the Pi Hut.
>
> The chip is a dual M0+ core, with 256 kB RAM, no flash, but the board uses 2
> MB QPSI flash.
> The boot loader emulates a USB drive, you can drop a file into it for
> programming.
> It has a few FPGA like state machines programmable for I2S, VGA, NeoPixel
> etc output.
> An example board layout for KiCad with I2S audio DAC and a VGA connector is
> already supported.
> The '12 bit' ADC is unfortunately only 9.5 bits accurate (ENOB).
>
> For that price it compares to a blue pill like a car to a bike...!
>
> Still studying all the docs... The tool chains (multiple!), examples and
> docs are already very complete.
>
> Arie de Muijnck
>
>
> On 2021-01-21 13:47, Alan Carvalho de Assis wrote:
>>
>> Hi Everyone,
>>
>> I think many of you already saw this news!
>>
>> The Raspberry Foundation created their own microcontroller based on
>> ARM Cortex M0+ with 1MB Flash and 256KB RAM.
>>
>> They also add support to OpenOCD (not in mainline yet) see:
>>
>> https://datasheets.raspberrypi.org/pico/getting_started_with_pico.pdf
>>
>> So yes, a good board to use with NuttX and a good alternative to
>> Arduino and BluePill.
>>
>> BR,
>>
>> Alan
>
>
>