* [U-Boot] How to enable to print messages on serial port(ttyS0) in u-boot?
@ 2009-10-22 5:11 sunr2007
2009-10-22 12:04 ` Jerry Van Baren
0 siblings, 1 reply; 7+ messages in thread
From: sunr2007 @ 2009-10-22 5:11 UTC (permalink / raw)
To: u-boot
Dear all ,
Is there a option to print the message or some variable value which i av
modified in code to print it on serial console to check whether it is
getting executed or not? like we use printf in application programming . if
yes how to enable it and use it? . thanks.
warm regards,
Ravi Kulkarni.
--
View this message in context: http://www.nabble.com/How-to-enable-to--print-messages-on-serial-port%28ttyS0%29-in-u-boot--tp26004165p26004165.html
Sent from the Uboot - Users mailing list archive at Nabble.com.
^ permalink raw reply [flat|nested] 7+ messages in thread
* [U-Boot] How to enable to print messages on serial port(ttyS0) in u-boot?
2009-10-22 5:11 [U-Boot] How to enable to print messages on serial port(ttyS0) in u-boot? sunr2007
@ 2009-10-22 12:04 ` Jerry Van Baren
2009-10-22 12:18 ` Ravi Kumar Kulkarni
0 siblings, 1 reply; 7+ messages in thread
From: Jerry Van Baren @ 2009-10-22 12:04 UTC (permalink / raw)
To: u-boot
sunr2007 wrote:
> Dear all ,
> Is there a option to print the message or some variable value which i av
> modified in code to print it on serial console to check whether it is
> getting executed or not? like we use printf in application programming . if
> yes how to enable it and use it? . thanks.
> warm regards,
> Ravi Kulkarni.
Yes, printf(), as you can see by looking at the source. The serial port
and printf() support is one of the first things that is configured
exactly to help debug via print statements.
If it isn't working on your board, you have more fundamental problems
(hardware initialization, serial port configuration, serial port
selection, who knows???). Since we don't know anything about your
board, we cannot help further.
Best regards,
gvb
^ permalink raw reply [flat|nested] 7+ messages in thread
* [U-Boot] How to enable to print messages on serial port(ttyS0) in u-boot?
2009-10-22 12:04 ` Jerry Van Baren
@ 2009-10-22 12:18 ` Ravi Kumar Kulkarni
2009-10-22 12:34 ` Wolfgang Denk
2009-10-22 12:49 ` Jerry Van Baren
0 siblings, 2 replies; 7+ messages in thread
From: Ravi Kumar Kulkarni @ 2009-10-22 12:18 UTC (permalink / raw)
To: u-boot
>>Yes, printf(), as you can see by looking at the source. The serial port
and printf() support is one of the first things that is >>configured exactly
to help debug via print statements.
>>If it isn't working on your board, you have more fundamental problems
(hardware initialization, serial port configuration,
>>serial port selection, who knows???). Since we don't know anything about
your board, we cannot help further.
Hi ! Now im being able to get print on the serial console. My board is
workin fine . its at91sam9261. the problem is something else. i have written
a driver spi-new.c for the SPI interface using BUS 1 . now though this
driver is getting compiled but its not getting executed when my board boots
up . i have modified the following to u-boot source tree.
1) changed Makefile in /drivers/spi/ and added a line
COBJS-$(CONFIG_ATMEL_SPI) +=spi-new.o
2) changed config file in /include/configs/at91sam9261ek.h
added a line
# CONFIG_ATMEL_SPI 1
though my init function is getting executed in the board file located at
/board/atmel/at91sam9261ek/at91sam9261ek.c
my driver code is not gettung executed when my board boots up.
can anyone let me know where else to change to add a new driver in u-boot
so tat ur board recognizes it.
warm regards,
Ravi Kulkarni.
^ permalink raw reply [flat|nested] 7+ messages in thread
* [U-Boot] How to enable to print messages on serial port(ttyS0) in u-boot?
2009-10-22 12:18 ` Ravi Kumar Kulkarni
@ 2009-10-22 12:34 ` Wolfgang Denk
2009-10-22 12:41 ` Ravi Kumar Kulkarni
2009-10-22 12:49 ` Jerry Van Baren
1 sibling, 1 reply; 7+ messages in thread
From: Wolfgang Denk @ 2009-10-22 12:34 UTC (permalink / raw)
To: u-boot
Dear Ravi Kumar Kulkarni,
In message <532dd5840910220518h4df2fe9cy7e66f043a2acd4fc@mail.gmail.com> you wrote:
>
> 2) changed config file in /include/configs/at91sam9261ek.h
> added a line
> # CONFIG_ATMEL_SPI 1
As Mike already pointed out you should probably consider hiring
someone who has a clue of the C programming language.
Best regards,
Wolfgang Denk
--
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
The word "fit", as I understand it, means "appropriate to a purpose",
and I would say the body of the Dean is supremely appropriate to the
purpose of sitting around all day and eating big heavy meals.
- Terry Pratchett, _Moving Pictures_
^ permalink raw reply [flat|nested] 7+ messages in thread* [U-Boot] How to enable to print messages on serial port(ttyS0) in u-boot?
2009-10-22 12:34 ` Wolfgang Denk
@ 2009-10-22 12:41 ` Ravi Kumar Kulkarni
0 siblings, 0 replies; 7+ messages in thread
From: Ravi Kumar Kulkarni @ 2009-10-22 12:41 UTC (permalink / raw)
To: u-boot
On Thu, Oct 22, 2009 at 6:04 PM, Wolfgang Denk <wd@denx.de> wrote:
> Dear Ravi Kumar Kulkarni,
>
> In message <532dd5840910220518h4df2fe9cy7e66f043a2acd4fc@mail.gmail.com>
> you wrote:
>
> >>> # CONFIG_ATMEL_SPI 1
>
correction : its actually
#define CONFIG_ATMEL_SPI 1
>> As Mike already pointed out you should probably consider hiring
>>someone who has a clue of the C programming language.
It was a typing mistake !!.not a known error. I feel let down by these
comments.
warm regards,
Ravi Kulkarni.
^ permalink raw reply [flat|nested] 7+ messages in thread
* [U-Boot] How to enable to print messages on serial port(ttyS0) in u-boot?
2009-10-22 12:18 ` Ravi Kumar Kulkarni
2009-10-22 12:34 ` Wolfgang Denk
@ 2009-10-22 12:49 ` Jerry Van Baren
2009-10-22 13:01 ` Ravi Kumar Kulkarni
1 sibling, 1 reply; 7+ messages in thread
From: Jerry Van Baren @ 2009-10-22 12:49 UTC (permalink / raw)
To: u-boot
Hi Ravi,
Ravi Kumar Kulkarni wrote:
>
> >>Yes, printf(), as you can see by looking at the source. The serial
> port and printf() support is one of the first things that is
> >>configured exactly to help debug via print statements.
> >>If it isn't working on your board, you have more fundamental problems
> (hardware initialization, serial port configuration,
> >>serial port selection, who knows???). Since we don't know anything
> about your board, we cannot help further.
Please use plain text formatting, not HTML. Your quoting will be more
readable and it won't annoy us curmudgeons.
> Hi ! Now im being able to get print on the serial console. My board is
> workin fine . its at91sam9261. the problem is something else. i have
> written a driver spi-new.c for the SPI interface using BUS 1 . now
> though this driver is getting compiled but its not getting executed
> when my board boots up . i have modified the following to u-boot source
> tree.
> 1) changed Makefile in /drivers/spi/ and added a line
> COBJS-$(CONFIG_ATMEL_SPI) +=spi-new.o
> 2) changed config file in /include/configs/at91sam9261ek.h
> added a line
> # CONFIG_ATMEL_SPI 1
I see you actually used "#define"
> though my init function is getting executed in the board file located
> at /board/atmel/at91sam9261ek/at91sam9261ek.c
OK, sounds like you succeeded.
> my driver code is not gettung executed when my board boots up.
> can anyone let me know where else to change to add a new driver in
> u-boot so tat ur board recognizes it.
Since you have succeeded in inserting your new driver in your u-boot
image, it is available. You need to browse the SPI
functionality/framework in u-boot to figure out how to plug your new SPI
driver into the existing code and how to use it.
The statement "my driver code is not gettung[sic] executed when my board
boots up" is too vague for us to address. What do you expect u-boot /
your driver to do when it boots up (that it isn't already doing)?
> warm regards,
> Ravi Kulkarni.
Good luck,
gvb
^ permalink raw reply [flat|nested] 7+ messages in thread
* [U-Boot] How to enable to print messages on serial port(ttyS0) in u-boot?
2009-10-22 12:49 ` Jerry Van Baren
@ 2009-10-22 13:01 ` Ravi Kumar Kulkarni
0 siblings, 0 replies; 7+ messages in thread
From: Ravi Kumar Kulkarni @ 2009-10-22 13:01 UTC (permalink / raw)
To: u-boot
>> Please use plain text formatting, not HTML. ?Your quoting will be more readable and it won't annoy us curmudgeons.
sorry was replying by my gmail. now its plain text . I hope it doesnt
annoy u anymore.
>
>
>> I see you actually used "#define"
yeah its #define CONFIG_ATMEL_SPI 1 . sorry for typing mistake .
>
>> ?though my init function is getting executed in the board file located at /board/atmel/at91sam9261ek/at91sam9261ek.c
>
>> OK, sounds like you succeeded.
yeah i used the printf("U-Boot Ravi at %s:%d!\n", __FILE__,
__LINE__); to confirm . it printed .
>
>> my driver code is not gettung executed when my board boots up.
>> ?can anyone let me ?know where else to change to add a new driver in u-boot so tat ?ur board recognizes it.
>
>> Since you have succeeded in inserting your new driver in your u-boot image, it is available. ?You need to browse the SPI functionality/framework in u-boot to figure out how to plug your new SPI driver into the existing code and how to use it.
>>
yeah, wil try to do tat. .
>> The statement "my driver code is not gettung[sic] executed when my board boots up" is too vague for us to address. ?What do you expect u-boot / your driver to do when it boots up (that it isn't already doing)?
>>
what i meant by the above statement is tat when i insert printf in my
driver code im not getting anything printed on console . so i have
to figure how to plug new spi driver into existing code and use it.
thanks .
warm regards,
Ravi Kulkarni.
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2009-10-22 13:01 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-10-22 5:11 [U-Boot] How to enable to print messages on serial port(ttyS0) in u-boot? sunr2007
2009-10-22 12:04 ` Jerry Van Baren
2009-10-22 12:18 ` Ravi Kumar Kulkarni
2009-10-22 12:34 ` Wolfgang Denk
2009-10-22 12:41 ` Ravi Kumar Kulkarni
2009-10-22 12:49 ` Jerry Van Baren
2009-10-22 13:01 ` Ravi Kumar Kulkarni
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox