Writing image in sd-card and connecting to serial terminal in BBB [buildroot part-2]

Writing image to sd-card:
For convenience i create a shell script:
$ vi writesd.sh

#!/usr/bin
sudo dd if=output/images/sdcard.img of=/dev/mmcblk0 conv=fsync

You need to verify the of=/dev/mmcblk0 to match the sd card in your computer, since running dd will erase the of=/dev/mmcblk0 disk completely. After that change writesd.sh permission to enable it to execute:
$ chmod +x

After we write the shell script, we then can call it every time we need to burn the image to sd-card:
$ ./writesd.sh

Connecting Serial Terminal to BBB:
We will need the USB-Serial with TTL level like picture below:

DO NOT use USB-Serial like the picture below:

The above USB Serial have RS-232 level which can broke your BBB Board.

and connect the USB-Serial with the BBB Board according to this pinout:

Remember to connect in Tx-Rx connection

Run the serial terminal in your linux, in this case I use picocom:
$ picocom /dev/ttyUSB -b 115200

If you need sudo, it means your user isn’t included in dialout group (in debian distro.)

Booting the BBB from sdcard:
Before we plug the power supply we need to insert the sd card we already write the image to, into BBB. In some revision BBB we need to press “the button” near the sd-card before pluging the power supply so BBB can boot from sd-card instead internal MMC. Remember to use 5V ONLY for power supply.
Wait for it to get ready to login, the user name is root without password. Then you shall see at your terminal that you can type just like in usual linux terminal.

Feedback and correction is appreciated
See You.

Leave a Reply

Your email address will not be published.