ROBOTIS-GIT / OpenCR

Software for ROS Embedded board (a.k.a. OpenCR). OpenCR means Open-source Control Module for ROS.
Apache License 2.0
384 stars 238 forks source link

LED pins are not as per e-manual #214

Closed mkhuthir closed 4 years ago

mkhuthir commented 4 years ago

e-Manual stating that LED pins are:

image

Current firmware 1.2.3 is using:

Front_left = BDPIN_GPIO_6 Front_right = BDPIN_GPIO_8 Back_left = BDPIN_GPIO_10 Back_right =BDPIN_GPIO_12

please check. Also I noticed in your video on how to connect LEDs to OpenCR, there are no resistors added

image

I think we need to add a resistor for each LED. See below link for info. http://www.resistorguide.com/resistor-for-led/

KyoungHwan2046 commented 4 years ago

Hi, @mkhuthir .

We just found out that the circuit of the video is wrong.

Your opinion is right. The resistor should be in the circuit.

We'll make correct the e-manual with uploading of correct circuit.

Thank you.

mkhuthir commented 4 years ago

hi @KyoungHwan2046

thank you very much; what about pin numbers ?

KyoungHwan2046 commented 4 years ago

Hi @mkhuthir

Also we will update the pin numbers too.

Thank you for your contribution.

mkhuthir commented 4 years ago

Thank you very much.

KyoungHwan2046 commented 4 years ago

@mkhuthir

I have a question.

You said that

current firmware 1.2.3 is using: Front_left = BDPIN_GPIO_6 Front_right = BDPIN_GPIO_8 Back_left = BDPIN_GPIO_10 Back_right =BDPIN_GPIO_12

but I cannot found where this code is. Would you tell me where did you find this code?

And the last edit of led pin configuring is can find here.

https://github.com/ROBOTIS-GIT/OpenCR/commit/190d9501aaba443e0e2380734daa07b2cc6a1081#diff-fe87ed179ef2b783508b98b1fb99ecdbR388

mkhuthir commented 4 years ago

@KyoungHwan2046

The pin numbers I mentioned are the actual active pins when I tested firmware 1.2.3 on my TurtleBot3 hardware. its not taken from code.

KyoungHwan2046 commented 4 years ago

@mkhuthir

Could you please upload a picture that you connect pins?

Well, The openCR-binary code is based on the "openCR" code and you can see the configuration of led pins on

https://github.com/ROBOTIS-GIT/OpenCR/blob/master/arduino/opencr_arduino/opencr/libraries/turtlebot3/src/turtlebot3/turtlebot3_sensor.cpp#L386 .

So, if the openCR with 'openCR-binary' code works different, than we will update on next release.

mkhuthir commented 4 years ago

Im using the firmware binary from the following link:

https://github.com/ROBOTIS-GIT/OpenCR-Binaries/tree/master/turtlebot3/ROS1/latest

I will upload the photos soon.

mkhuthir commented 4 years ago

Hello @KyoungHwan2046

Sorry I could not share photos today because my TurtleBot3 not with me now. However I searched the code and I think I found the issue is that section 3.4 GPIO in e-manual is showing that BDPIN_GPIO_4=D53=PIN6 but conflicting with your video where you are showing BDPIN_GPIO_4 connected to PIN 4 not PIN 6.

image

I think confusion was because of below image. It should be made clear that numbers 1-20 in this image are pin numbers not GPIO numbers.

image

correct LED connections should be to pins (2,6,8,10,12) instead of pins (2,4,6,8,10) as shown below. No code correction is required.

image

mkhuthir commented 4 years ago

@KyoungHwan2046

Below are connection photos for your info. this is the correct connection after clearing confusion. image image image

KyoungHwan2046 commented 4 years ago

Hi, @mkhuthir .

Thank you for your update.

The pin map of the video is wrong and the modified video will be updated soon.

Once again, thank you for your help and supports.

mkhuthir commented 4 years ago

Thank you very much @KyoungHwan2046

KyoungHwan2046 commented 4 years ago

This issue will be closed since there were no actions for a while. You can reopen this issue to show this issue to the users whenever. Thanks.