This chapter introduces the board, its hardware and how to boot it.
The hardware documentation of Pengwyn can be found here:
http://downloads.architechboards.com/doc/Pengwyn/download.html
Pengwyn takes the power from the mini-USB connector CN6 and/or connector CN1. The board is not shipped with an external power adapter.
On connector CN6 you can also have the serial console, so, during your daily development use, you would just connect your workstation to the board using a mini-USB to connector CN6. If you connect some power hungry device to the board, you can give more power to the board by connecting the power adapter.
which you can connect, by means of a mini-USB cable, to your personal computer.
Note
Every operating system has its own killer application to give you a serial terminal interface. In this guide, we are assuming your host operating system is Ubuntu.
On a Linux (Ubuntu) host machine, the console is seen as a ttyUSB***X* device (where X is a number) and you can access to it by means of an application like minicom.
Minicom needs to know the name of the serial device. The simplest way for you to discover the name of the device is by looking to the kernel messages, so:
sudo dmesg -c
dmesg
[ 2614.290675] usb 3-4: >new full-speed USB device number 4 using xhci_hcd
[ 2614.313854] usb 3-4: >New USB device found, idVendor=0403, idProduct=6015
[ 2614.313861] usb 3-4: >New USB device strings: Mfr=1, Product=2, SerialNumber=3
[ 2614.313865] usb 3-4: >Product: FT230X Basic UART
[ 2614.313868] usb 3-4: >Manufacturer: FTDI
[ 2614.313870] usb 3-4: >SerialNumber: DN002OZI
[ 2614.379284] usbcore: registered new interface driver usbserial
[ 2614.379298] usbcore: registered new interface driver usbserial_generic
[ 2614.379306] USB Serial support registered for generic
[ 2614.379310] usbserial: USB Serial Driver core
[ 2614.387899] usbcore: registered new interface driver ftdi_sio
[ 2614.387914] USB Serial support registered for FTDI USB Serial Device
[ 2614.387997] ftdi_sio 3-4:1.0: >FTDI USB Serial Device converter detected
[ 2614.388029] usb 3-4: >Detected FT-X
[ 2614.388031] usb 3-4: >Number of endpoints 2
[ 2614.388034] usb 3-4: >Endpoint 1 MaxPacketSize 64
[ 2614.388035] usb 3-4: >Endpoint 2 MaxPacketSize 64
[ 2614.388037] usb 3-4: >Setting MaxPacketSize 64
[ 2614.388260] usb 3-4: >FTDI USB Serial Device converter now attached to /dev/ttyUSB0
[ 2614.388288] ftdi_sio: v1.6.0:USB FTDI Serial Converters Driver
As you can see, here the device has been recognized as /dev/ttyUSB0.
Now that you know the device name, run minicom:
sudo minicom -ws
If minicom is not installed, you can install it with:
sudo apt-get install minicom
then you can setup your port with these parameters:
+-----------------------------------------------------------------------+
| A - Serial Device : /dev/ttyUSB0 |
| B - Lockfile Location : /var/lock |
| C - Callin Program : |
| D - Callout Program : |
| E - Bps/Par/Bits : 115200 8N1 |
| F - Hardware Flow Control : No |
| G - Software Flow Control : No |
| |
| Change which setting? |
+-----------------------------------------------------------------------+
| Screen and keyboard |
| Save setup as dfl |
| Save setup as.. |
| Exit |
| Exit from Minicom |
+--------------------------+
If on your system the device has not been recognized as /dev/ttyUSB0, just replace /dev/ttyUSB0 with the proper device.
Once you are done configuring the serial port, you are back to minicom main menu and you can select exit.
The boot process of the pengwyn is selected by jumpers J1, J2 and J3. After a Power On Reset (POR) the processor starts executing the internal ROM program. The boot mode is based on information gathered from the SYSBOOT:
Jumper settings
boot sequence | ||||||
---|---|---|---|---|---|---|
J1 | J2 | J3 | 1st | 2nd | 3rd | 4th |
open | open | open | MMC0 | SPI0 | UART0 | USB0 |
open | open | close | EMAC1 | MMC0 | XIP MUX2 | NAND |
open | close | open | Fast ext | EMAC1 | UART0 | Reserved |
open | close | close | UART0 | EMAC1 | Reserved | Reserved |
close | open | open | NAND | NANDI2C | MMC0 | UART0 |
close | open | close | UART0 | SPI0 | XIP MUX2 | MMC0 |
close | close | open | XIP MUX2 | UART0 | SPI0 | MMC0 |
close | close | close | USB0 | NAND | SPI0 | MMC0 |
This procedure will guide you to the installation of the display on the Pengwyn board and the configuration of the software to test it.
If you don’t have a SD card formatted with 2 partitions, one for the boot and one for the root filesystem, create it as in Deploy. Now we want install in rootfs the qt4e-demo-image-pengwyn.tar.gz image.
sudo tar -zxf ~/architech_sdk/architech/pengwyn/yocto/tmp/deploy/images/pengwyn/qt4e-demo-image-pengwyn.tar.gz -C /path/to/sdcard/rootfs
And substitute the pengwyn.dtb with this one:
sudo cp ~/architech_sdk/architech/pengwyn/yocto/tmp/deploy/images/pengwyn/zImage-pengwyn-touch.dtb /path/to/sdcard/boot/pengwyn.dtb
Make sure everything has been really written to the SD card:
sync
Then insert SD card on Pengwyn board and wait Linux start-up. First time, the touch screen calibration is needed, than qt4 demo will start.
Pengwyn networking is powered by TI’s chip AM335x. Under Linux, instead, the default network configuration is:
root@pengwyn:~# ifconfig
eth0 Link encap:Ethernet HWaddr 00:18:30:FD:2D:7E
UP BROADCAST MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
Interrupt:56
lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
UP LOOPBACK RUNNING MTU:65536 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
If you want that configuration to be brought up at boot you can add a few line in file /etc/network/interfaces, for example, if you want eth0 to have a fixed ip address (say 192.168.0.10) and MAC address of value 1e:ed:19:27:1a:b6 you could add the following lines:
auto eth0
iface eth0 inet static
address 192.168.0.10
netmask 255.255.255.0
hwaddress ether 1e:ed:19:27:1a:b6