All of lore.kernel.org
 help / color / mirror / Atom feed
From: Stefano Babic <sbabic@denx.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH] imx_common: check for Serial Downloader in spl_boot_device
Date: Fri, 4 Dec 2015 12:49:48 +0100	[thread overview]
Message-ID: <56617DDC.2050100@denx.de> (raw)
In-Reply-To: <CAOMZO5C+drLiKb5n8iWCCTLxzK-y5qXpKPCEKwBxBcB5q90p0g@mail.gmail.com>

Hi Fabio,

On 04/12/2015 11:51, Fabio Estevam wrote:
> Hi Stefano,
> 
> On Fri, Dec 4, 2015 at 7:02 AM, Stefano Babic <sbabic@denx.de> wrote:
>> Check for bmode before reading the boot device
>> to check if a serial downloader is started,
>> and returns UART if the serial downloader is set,
>> letting SPL to wait for an image if
>> CONFIG_SPL_YMODEM_SUPPORT is set.
>>
>> This allows to load again a SPL based board
>> with imx_usb_loader together with a tool
>> such as kermit.
> 
> Just curious: what were the commands you usned with imx_usb_loader to
> load SPL + u-boot.img?
> 

I did in this way:

sudo ../imx_usb_loader/imx_usb -v SPL
kermit kermit_uboot

And kermit_uboot (a kermit script) contains the lines:

set line /dev/ttyUSB1
set speed 115200
SET CARRIER-WATCH OFF
set flow-control none
set handshake none
set prefixing all
set file type bin
set protocol ymodem
send u-boot.img
c

The last "c" command tells kermit (from ckermit package in most distro)
to switch from command line mode to communication mode, and when the
script is finished, I get U-Boot prompt in the same shell. I tested on a
custom board booting from SPI (when internal mode is used), and changing
BOOT_MODE to serial, SPL starts automatically a download with y-modem.

Best regards,
Stefano

-- 
=====================================================================
DENX Software Engineering GmbH,      Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-53 Fax: +49-8142-66989-80 Email: sbabic at denx.de
=====================================================================

  reply	other threads:[~2015-12-04 11:49 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-12-04  9:02 [U-Boot] [PATCH] imx_common: check for Serial Downloader in spl_boot_device Stefano Babic
2015-12-04 10:51 ` Fabio Estevam
2015-12-04 11:49   ` Stefano Babic [this message]
2015-12-04 13:09     ` Stefan Roese
2015-12-04 14:30       ` Tim Harvey
2015-12-05  7:10       ` Stefano Babic
2015-12-05 20:13 ` Eric Nelson
2015-12-07  9:55   ` Stefano Babic
2015-12-07 11:59     ` Stefano Babic
2015-12-07 14:08     ` Eric Nelson
2015-12-07 14:24       ` Stefano Babic

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=56617DDC.2050100@denx.de \
    --to=sbabic@denx.de \
    --cc=u-boot@lists.denx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.