Dear Alan,

I confirm the following settings from the NuttX make menuconfig. RX: PA24,
alternate function 0. TX: PA23, alternate function 0. So, this is correct.
Greg's user manual helped. I just grepped for the definitions.

I see that the MCUZone's AT32UC3B isn't very different from the AVR32DEV1.
Also,
Alan's link helped. Thank you Alan. I didn't know the document existed
online.

I just made the jumper connections:

1) FTDI's ground -> Board's ground (J2, pin 32 - from the schematic).
2) FTDI's RX -> Board's TX (J1, pin 15: CPU pin 47, PA_23)
3) FTDI's TX -> Board's RX (J1, pin 28: CPU pin 59, PA_24)

I configured `minicom' with 57600, 8, 0, 1. I see both user LEDs on. Yet,
nothing on the minicom except for one strange character. I did
notice/thought of
two things/possibilities:

a) menuconfig -> Device Driver -> Serial Driver Support -> USART1
Configuration -> Uses 2 stop bits. The default numeric value assigned for
this
is 0. Is that right? Does 0 indicate "no stop bits"?

b) And I quote from Alan's observation:

> AVR32DEV1, but it has the 32KHz crystal soldered in the board:

Alan, I see two crystal oscillators on the board. They have called
(reference
designators) them Y1 and Y3. They are 12 MHz and 32.768 KHz respectively. I
would assume that the latter has something to do with the CPU's RTC. By any
chance, is our external crystal on our dev kit different from the value on
Greg's dev kit? Perhaps the clock configuration is incorrect?

Alan and Greg: thank you so much for the links to the dev kit reference
manual.
They are very helpful. Finally, I just wanted to see how the clocks are
configured with RT-Thread to compare. I now remember that I used the
Microchip's
ASF (at32uc3b0256) device abstractions for it. It wasn't very
straightforward
for me to compare the settings with arch/avr32/at32uc3_clkinit.c.

Best regards,

R

P.S. Alan, just one last thing: From the code (board.h), I see this:

#define PINMUX_USART1_RXD PINMUX_USART1_RXD_2
#define PINMUX_USART1_TXD PINMUX_USART1_TXD_1

They seem to reflect PA_24 and PA_23. OR am I getting something wrong here?

arch/avr/src/at32uc3/at32uc3b_pinmux.h:#define PINMUX_USART1_RXD_2
(GPIO_PERIPH | GPIO_FUNCA | GPIO_PORTA | 24)
arch/avr/src/at32uc3/at32uc3b_pinmux.h:#define PINMUX_USART1_TXD_1
(GPIO_PERIPH | GPIO_FUNCA | GPIO_PORTA | 23)



On Sun, 19 Nov 2023 at 21:02, Raman Gopalan <ramangopa...@gmail.com> wrote:

>
> Dear Alan,
>
> > Did you setup your serial console terminal to 57600 ? Normally NuttX
> uses
> > 115200, but for avr32dev1 the default is this value.
>
> Yes, for sure. I checked .config. It was exactly 57600. Also on `minicom'.
>
> > Do you have the AVR32DEV1 schematic? I didn't find it.
>
> This has been a problem for a while Alan. I didn't find the
> schematic/gerber
> either. But I am happy the chip has fewer pins :) The headers are easy to
> probe.
>
> > Looking the NuttX source code, the console is using USART1 PA24 as RXD
> and
> > PA17 as TXD.
>
> Understand. I will double-check this tomorrow.
>
> R
>
> On Sun, 19 Nov 2023 at 20:25, Raman Gopalan <ramangopa...@gmail.com>
> wrote:
>
>>
>> > Question: did you cloned nuttx-apps as apps/ in the same directory you
>> have
>> > cloned nuttx ?
>>
>> For sure Alan. This is exactly how it is on both my machines.
>>
>> > NuttX "depends on" apps/ to compile (it doesn't depend, but the build
>> system
>> > depends/expects to find it there).
>>
>> Fully understand. Yes, this is the case.
>>
>> R
>>
>> On Sun, 19 Nov 2023 at 20:11, Alan C. Assis <acas...@gmail.com> wrote:
>>
>>> Hi Raman,
>>>
>>> On 11/19/23, Raman Gopalan <ramangopa...@gmail.com> wrote:
>>> > Dear Alan, Dear Gregory, Greetings!
>>> >
>>> > Hello Kevin and Zou Boan!
>>> >
>>> > Many thanks for your suggestions. I will write in detail in a bit but
>>> > before, I was too excited about Alan's suggestion.
>>> >
>>> >> Other option could be extend the CMake support to AVR32 boards.
>>> >
>>> > I quickly glanced through boards/arm/stm32 to see how the CMake files
>>> > work. I put in place the CMakeLists files (similar to stm32f103, Blue
>>> > Pill) for avr32dev1.
>>> >
>>> > I then ran cmake seeking help from the instructions here [1]. It
>>> > initially asked me to pip install kconfiglib. Here's the volley I had
>>> > with the Cygwin terminal.
>>> >
>>> > raman@foobar ~/nuttxspace/nuttx
>>> > $ cmake -B build -DBOARD_CONFIG=avr32dev1:nsh -GNinja
>>> > CMake Error at CMakeLists.txt:82 (message):
>>> >   Kconfig environment depends on kconfiglib, Please install:
>>> >
>>> >     $ pip install kconfiglib
>>> >
>>> >
>>> > -- Configuring incomplete, errors occurred!
>>> >
>>> > raman@foobar ~/nuttxspace/nuttx
>>> > $ pip install kconfiglib
>>> > Collecting kconfiglib
>>> >   Using cached kconfiglib-14.1.0-py2.py3-none-any.whl (145 kB)
>>> > Installing collected packages: kconfiglib
>>> > Successfully installed kconfiglib-14.1.0
>>> >
>>> > Post this, I ran into another CMake error:
>>> >
>>> > raman@foobar ~/nuttxspace/nuttx
>>> > $ cmake -B build -DBOARD_CONFIG=avr32dev1:nsh -GNinja
>>> > -- Initializing NuttX
>>> > CMake Warning at CMakeLists.txt:348 (message):
>>> >   Kconfig Configuration Error:
>>> > C:\Users\raman\anaconda3\Scripts\olddefconfig:
>>> >   arch/Kconfig:252:
>>> '/home/raman/nuttxspace/nuttx/build/arch/dummy/Kconfig'
>>> >   not found (in 'source "$BINDIR/arch/dummy/Kconfig"').  Check that
>>> >   environment variables are set correctly (e.g.  $srctree, which is
>>> unset
>>> > or
>>> >   blank).  Also note that unset environment variables expand to the
>>> empty
>>> >   string.
>>> >
>>> >
>>> > CMake Error at CMakeLists.txt:353 (message):
>>> >   Failed to initialize Kconfig configuration:
>>> >
>>> >
>>> > -- Configuring incomplete, errors occurred!
>>> >
>>> > I initially wanted to check if the case is the same for other
>>> > targets. CMake throws the same response for stm32f103-minimum too. I
>>> > checked what the programs olddefconfig and defconfig did. Simply
>>> > invoking the programs olddefconfig.exe (OR defconfig) echo this for a
>>> > response:
>>> >
>>> > raman@foobar ~/nuttxspace/nuttx
>>> > $ oldconfig
>>> > Kconfig:10: warning: APPSDIR has 'option env="APPSDIR"', but the
>>> > environment variable APPSDIR is not set
>>> > Kconfig:14: warning: APPSBINDIR has 'option env="APPSBINDIR"', but the
>>> > environment variable APPSBINDIR is not set
>>> > Kconfig:22: warning: BINDIR has 'option env="BINDIR"', but the
>>> environment
>>> > variable BINDIR is not set
>>> > Kconfig:278: warning: the 'modules' option is not supported. Let me
>>> know if
>>> > this is a problem for you, as it wouldn't be that hard to implement.
>>> Note
>>> > that modules are supported -- Kconfiglib just assumes the sy
>>> > mbol name MODULES, like older versions of the C implementation did when
>>> > 'option modules' wasn't used.
>>> > C:\Users\raman\anaconda3\Scripts\oldconfig: arch/Kconfig:252:
>>> > '$BINDIR/arch/dummy/Kconfig' not found (in 'source
>>> > "$BINDIR/arch/dummy/Kconfig"'). Check that environment variables are
>>> set
>>> > correctly (e.g. $srctree
>>> > , which is unset or blank). Also note that unset environment variables
>>> > expand to the empty string.
>>> >
>>> > Perhaps I am missing yet another terminal configuration? I will write
>>> > back in a couple of hours with the results of the minicom session with
>>> > AVR32DEV1.
>>> >
>>> > Many thanks.
>>>
>>> Question: did you cloned nuttx-apps as apps/ in the same directory you
>>> have cloned nuttx ?
>>>
>>> NuttX "depends on" apps/ to compile (it doesn't depend, but the build
>>> system depends/expects to find it there).
>>>
>>> So:
>>>
>>> nuttxspace:
>>> ./apps
>>> ./nuttx
>>>
>>> Best Regards,
>>>
>>> Alan
>>>
>>

Reply via email to