Change Debug Port From UART0 to USB0

63 views
Skip to first unread message

subb...@gmail.com

unread,
Oct 23, 2018, 8:08:27 AM10/23/18
to BeagleBoard
Dear Support Team:

I am glad to have beaglebone black board to start my Linux activities.

Currently I am working on Baremetal Programming on Beagle Bone Black Board. I gone through the BBB booting procedure and I found that the boot environment using UART0 as debug/console. Now, I want to change debug port from UART0 to USB0.

1. Is it fixed in Boot ROM code only.?
2. What are all the necessary information should I know.?
3. Is it required to modify in u-boot source code.? if yes, where can I change.?

Please respond as soon as possible.


Thanks and Regards,
Siva Prakash Reddy

Robert Nelson

unread,
Oct 23, 2018, 9:25:52 AM10/23/18
to Beagle Board, subb...@gmail.com
On Tue, Oct 23, 2018 at 7:08 AM <subb...@gmail.com> wrote:
>
> Dear Support Team:

Sorry, just a community of users. No Support Team here. ;)

>
> I am glad to have beaglebone black board to start my Linux activities.
>
> Currently I am working on Baremetal Programming on Beagle Bone Black Board. I gone through the BBB booting procedure and I found that the boot environment using UART0 as debug/console. Now, I want to change debug port from UART0 to USB0.
>
> 1. Is it fixed in Boot ROM code only.?
> 2. What are all the necessary information should I know.?
> 3. Is it required to modify in u-boot source code.? if yes, where can I change.?

The Boot ROM "defaults" to UART0, this is why you see "CCCCCC's.."
over the usart when the eMMC and microSD are blank..

However u-boot can be "easly" programed to change the UART0 to a different UARTx

However to change from UART0 to USB0, "you'll" have to do some work..

PS, once you jump from u-boot to app x, the "usb" handoff is complex...

Regards,

--
Robert Nelson
https://rcn-ee.com/

subb...@gmail.com

unread,
Oct 29, 2018, 8:00:20 AM10/29/18
to BeagleBoard
Thank You For Your Response.

>
>However to change from UART0 to USB0, "you'll" have to do some work..
>

Can you please guide me how to proceed.?
Where to change.?

Is it required to change to any configuration setting while building U-Boot source code.?

>
>However u-boot can be "easly" programed to change the UART0 to a different UARTx
>

If the Boot ROM is fixed, how can we change that.?

Robert Nelson

unread,
Oct 29, 2018, 10:12:48 AM10/29/18
to Beagle Board, Siva Prakash Reddy Nareddy
> >However to change from UART0 to USB0, "you'll" have to do some work..
> >
>
> Can you please guide me how to proceed.?
> Where to change.?

Like i said, "you'll" have some work todo..

https://github.com/u-boot/u-boot

> Is it required to change to any configuration setting while building U-Boot source code.?
>
> >
> >However u-boot can be "easly" programed to change the UART0 to a different UARTx
> >
>
> If the Boot ROM is fixed, how can we change that.?

No, the Boot ROM is still defaulted to UART0, but that doesn't stop
you from using a different UARTx when U-Boot runs..

subb...@gmail.com

unread,
Oct 30, 2018, 10:10:50 AM10/30/18
to BeagleBoard

Hello:

Thanks for the valuable response.

In my case I had created only BOOT partition on my SD Card and I copied the MLO, U-boot.img and uEnv.txt files.

the content in the uEnv.txt is as follows:


uenvcmd=setenv bootargs console=ttyUSB0,115200n8 console=${console}
echo *** Booting To Baremetal_1 ***


Before applying USB power to BBB, SD card is inserted and I pressed and hold the Switch-2 to boot from SD Card.

But there is no response from the board at USB0 port.


Is it problem with uEnv.txt file.?

Are there required for any changes.?


Thanks And Regards,

Siva Prakash Reddy

Robert Nelson

unread,
Oct 30, 2018, 10:49:42 AM10/30/18
to Beagle Board, Siva Prakash Reddy Nareddy
On Tue, Oct 30, 2018 at 9:10 AM <subb...@gmail.com> wrote:
>
> Hello:
>
> Thanks for the valuable response.
>
> In my case I had created only BOOT partition on my SD Card and I copied the MLO, U-boot.img and uEnv.txt files.
>
> the content in the uEnv.txt is as follows:
>
>
> uenvcmd=setenv bootargs console=ttyUSB0,115200n8 console=${console}
> echo *** Booting To Baremetal_1 ***
>
>
> Before applying USB power to BBB, SD card is inserted and I pressed and hold the Switch-2 to boot from SD Card.
>
> But there is no response from the board at USB0 port.
>
>
> Is it problem with uEnv.txt file.?
>
> Are there required for any changes.?

Plug in a usb serial adapter into the j1 debug port.. did u-boot
actually do what you expected?

subb...@gmail.com

unread,
Oct 31, 2018, 9:54:58 AM10/31/18
to BeagleBoard
Hello Robert:

What you said is normal connection like using USB to TTL cable connecting to J1 Header.

>
>Plug in a usb serial adapter into the j1 debug port.. did u-boot
>actually do what you expected?
>

It is working properly.


Normally, when the board is completely up and Linux Login prompt is only showing in the USB0 port of the board.
But, I am trying to achieve the same on USB0 port on the board, i.e., I wan to see the Uboot debug information on USB0 port.

the following is the uboot log information coming on the UART0 port (J1 Connector)


U-Boot SPL 2011.09-00002-gd0e52e5 (Apr 14 2012 - 22:13:07)
Texas Instruments Revision detection unimplemented
No AC power, disabling frequency switch
OMAP SD/MMC: 0
reading u-boot.img
reading u-boot.img


U-Boot 2011.09-00002-gd0e52e5 (Apr 14 2012 - 22:13:07)

I2C:   ready
DRAM:  256 MiB
WARNING: Caches not enabled
No daughter card present
NAND:  HW ECC Hamming Code selected
No NAND device found!!!
0 MiB
MMC:   OMAP SD/MMC: 0, OMAP SD/MMC: 1
*** Warning - readenv() failed, using default environment

Net:   cpsw
Hit any key to stop autoboot:  3 ��� 2 ��� 1 ��� 0 
SD/MMC found on device 0
reading uEnv.txt

** Unable to read "uEnv.txt" from mmc 0:1 **
reading uImage

3132976 bytes read
## Booting kernel from Legacy Image at 80007fc0 ...
   Image Name:   Linux-3.1.0-00010-g66bfbd2
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    3132912 Bytes = 3 MiB
   Load Address: 80008000
   Entry Point:  80008000
   Verifying Checksum ... OK
   XIP Kernel Image ... OK
OK

Starting kernel ...

Is it possible to see the same on USB0 port with any proper modifications.?

Thanks and Regards,
Siva Prakash Reddy.

Jason Kridner

unread,
Oct 31, 2018, 3:10:19 PM10/31/18
to beagl...@googlegroups.com, Siva Prakash Reddy Nareddy
I did some parts of the task, but not complete. 

--
For more options, visit http://beagleboard.org/discuss
---
You received this message because you are subscribed to the Google Groups "BeagleBoard" group.
To unsubscribe from this group and stop receiving emails from it, send an email to beagleboard...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/beagleboard/CAOCHtYiY%2BY-4iUyu%2BbVkQC4RRMyOysThmV6dmJghF9ON-u98wQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
Reply all
Reply to author
Forward
0 new messages