micro-ROS / nuttx_apps

Other
10 stars 13 forks source link

microros foxy - stm32f4discovery build #28

Open thihakyawjob opened 4 years ago

thihakyawjob commented 4 years ago

Hi,

I try to build nsh for stm32f4discovery board. Find the attached nsh defconfig file for your review.

defconfig_f4discovery.txt

The error is as follow.

Error

Please guide me how to make it for STM32F4Discovery Board.

Thank you.

Regards, Thiha Kyaw

pablogs9 commented 4 years ago

Hello @thihakyawjob we have not tested stm32f4discovery with micro-ROS and Nuttx.

Have you tried to start with the official tutorial: https://micro-ros.github.io/docs/tutorials/core/first_application_rtos/nuttx/ ?

iluetkeb commented 4 years ago

@pablogs9 it's the same configuration issue we had for the Olimex board recently.

thihakyawjob commented 4 years ago

@pablogs9 it's the same configuration issue we had for the Olimex board recently.

Dear iluetkeb,

How did you solve it since you already noticed it? Can you advise me?

Thanks.

Regards, Thiha Kyaw

iluetkeb commented 4 years ago

I didn't solve it, Pablo did. On top of that, I'm traveling, so I currently don't have good access to the code base.

pablogs9 commented 4 years ago

Are you using the configuration provided by ros2 run micro_ros_setup configure_firmware.sh drive_base ?

Can you share a step by step command list so I can reproduce your issue?

thihakyawjob commented 4 years ago

Dear Pablogs,

There is no drive_base in stm32f4discovery project file. Therefore I use nsh.

ros2 run micro_ros_setup configure_firmware.sh nsh

I attached nsh deconfig file for your review.

https://github.com/micro-ROS/micro-ROS.github.io/files/5091024/defconfig_f4discovery.txt

Thank you.

Regards, Thiha Kyaw

pablogs9 commented 4 years ago

Have you tried to use this file as reference configuration for your board?

thihakyawjob commented 4 years ago

Dear Pablog,

OK. I will try. But stm32f4discovery doesn't have ethernet port. So We need to remove net settings later.

Regards, Thiha

thihakyawjob commented 4 years ago

Dear pablogs9,

I can successfully build it using drive_base file for stm32F4Discovery Board. I have a question about Tutorial using Olimex Board.

1) which port do you use for nsh in Olimex-stm32-e407? USB-OTG Port OR Uart3? 2) is usb-NuttX device from USB-OTG port? I am a bit confused in Tutorial.

Regarding about stm32F4Discovery;

In stm32F4Discovery, USB-OTG is connected to PA11 and PA12 while Olimex USB-OTG 2 port is connected to PB14 and PB15.

Do I need to make any modification in stm32F4Discovery?

Please advise.

Thanks.

Regards, Thiha Kyaw

pablogs9 commented 4 years ago

Hello @thihakyawjob, in the tutorial we are:

This way we have each communication on a separate serial port.

Regarding the configuration of this specific board, I can't tell you much because I have not it available here... But I recommend you trying to have the NSH over the USB-OTG and configuring micro-ROS in a UART serial port I guess that Nuttx will manage this both ports somehow. Sorry for not being so useful in this part.

thihakyawjob commented 4 years ago

Dear Pablogs9,

Thank you for your reply. Now I understand your test setup and I will test it.

Regards, Thiha

pablogs9 commented 4 years ago

Nice! Give us feedback when you have results.

And remember that we will be happy to include support for your board if you make a PR when you achieve the port

Thanks!