Until OSD335X runs U-boot on a custom board (memo)

2020/07/25 First description

Synopsis so far

I bought OSD3358-512M-BCB. https://www.mouser.jp/ProductDetail/415-OSD3358-512M-BCB

I made a board. https://twitter.com/nonNoise/status/1278465569499447298?s=20

Implemented. https://www.youtube.com/watch?v=acrJceh3bkU

115929400_3171100156300596_3359527061697752589_o.jpg

Power on

It worked.

A large amount of CCCCCCC ... flows from the serial (UART0).

The serial setting is *Baud rate: 115,200 *Data bits: 8 *Parity: None *Stop bits: 1 *Flow control: None

U-boot binary data preparation

Apparently it needs to be compiled.

Compile in Ubuntu environment. Ubuntu environment was newly prepared with Vertual Box.

ARM GCC environment setup

wget -c https://releases.linaro.org/components/toolchain/binaries/7.5-2019.12/arm-linux-gnueabihf/gcc-linaro-7.5.0-2019.12-x86_64_arm-linux-gnueabihf.tar.xz

tar xf gcc-linaro-7.5.0-2019.12-x86_64_arm-linux-gnueabihf.tar.xz

export CC=[PWD]/gcc-linaro-7.5.0-2019.12-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-

U-Boot compilation

git clone https://github.com/u-boot/u-boot cd u-boot/ git checkout v2018.01 -b tmp

Patch U-Boot

wget -c https://rcn-ee.com/repos/git/u-boot-patches/v2018.01/0001-am335x_evm-uEnv.txt-bootz-n-fixes.patch wget -c https://rcn-ee.com/repos/git/u-boot-patches/v2018.01/0002-U-Boot-BeagleBone-Cape-Manager.patch wget -c https://raw.githubusercontent.com/RobertCNelson/Bootloader-Builder/master/patches/v2018.03-rc1/0002-NFM-Production-eeprom-assume-device-is-BeagleBone-Bl.patch

patch -p1 < 0001-am335x_evm-uEnv.txt-bootz-n-fixes.patch patch -p1 < 0002-U-Boot-BeagleBone-Cape-Manager.patch patch -p1 < 0002-NFM-Production-eeprom-assume-device-is-BeagleBone-Bl.patch

Make U-Boot.

export CC=[PWD]/gcc-linaro-7.5.0-2019.12-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-

make ARCH=arm CROSS_COMPILE={CC} distclean make ARCH=arm CROSS_COMPILE={CC} am335x_evm_defconfig make ARCH=arm CROSS_COMPILE=${CC}

Hand over the necessary files to Windows

ARM U-Boot requires two types of files u-boot-spl.bin (for first stage boot) and u-boot.img (for next stage boot)

u-boot-spl.bin will be in u-boot / spl.

Write with TeraTerm

Foreigners also use TeraTerm.

Check that CCC CC ..... and C are flowing in the terminal.

File-> Transfer-> XMODEM-> Send Select u-boot-spl.bin Check 1K at the bottom left Transferred.

コメント 2020-07-25 014135.png

File-> Transfer-> YMODEM-> Send Select u-boot.img Transferred. コメント 2020-07-25 014502.png At first, it will be 0% for a while, but be patient (about 1 minute) until the bar moves.

safely? to start. コメント 2020-07-25 014806.png

So what?

However, in this state, the two U-Boot programs are still expanded in RAM, so when you reset or power cycle, CCCC .... is displayed again. This is the best way to debug U-Boot.

Looking at the U-Boot log, it complains that the EEPROM is an error or that there is no USB or Ethernet. It can't be left as it is, so it seems that U-Boot custom is needed. For the time being, I just chose the procedure to write U-Boot.

The destination seems to be long. (I'm looking forward to it) Fufufu.

References

https://processors.wiki.ti.com/index.php?title=AM335x_U-Boot_User%27s_Guide&oldid=151545#Boot_Over_UART

https://octavosystems.com/forums/topic/osd3358-boot/

Real memo (1)

I've dealt with it because I got an error, but I'll leave it just in case.

bad value (‘armv5’) for ‘-march=’ switch

Error with make ARCH = arm CROSS_COMPILE = $ {CC} when this article is correct or when I try to compile again

It seems that export was cleared by restarting Ubuntu. (Hey ~) So before compiling export CC=[PWD]/gcc-linaro-7.5.0-2019.12-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf- Changed the article to write again.

Real memo (2)

When writing U-Boot serially, X-MODEM and Y-MODEM came out, and I wondered why, so I looked it up. https://ja.wikipedia.org/wiki/XMODEM https://ja.wikipedia.org/wiki/YMODEM I didn't know (I'm sorry I'm sorry) TeraTerm is convenient and easy to use, but I have trouble when I want to automate it, so I searched for a library in Python. https://pythonhosted.org/xmodem/ https://github.com/alexwoo1900/ymodem I see?

Recommended Posts

Until OSD335X runs U-boot on a custom board (memo)
How to customize U-Boot with OSD335X on a custom board (memo)
Until PythonCGI runs on UbuntuServer18.04 + Apache2
Let's implement a custom prefix on discord.py!
A memo with Python2.7 and Python3 on CentOS
A memo of a tutorial on running python on heroku