Forums » Software Development »
How to load Linux Kernel and files system with no Ethernet port
Added by Vivek Ponnani over 7 years ago
Hi,
I have a custom board with
1) MityDspl-138F module (with FPGA)
2) No Ethernet port
3) UART,USB,SD CARD interface
I have built VM with MityDSP-L138_SDK_2012_06_13.ova file from critical link.
I connect the board with serial port xds200 JTAG emulator. I use teraterm application from windows with 1115200 baud to receive information from the board. when I power on the board,I get following info (MityDspl-138 Uboot.txt).
OMAP-L138/AM-1808/AM-1810 initialization passed!
Configuring 128MB mDDR
Booting TI User Boot Loader
UBL Version: 1.65:2.28.1 BuiltJul 11 2011 12:49:53
UBL Flashtype: SPI
Starting SPI Memory Copy...
Valid magicnum, 0x55424CBB, found at offset 0x00010000.
DONE
Jumping to entry point at 0xC1080000.
U-Boot 2009.11-00002-gc6adda5 (May 01 2015 - 11:42:37)
I2C: ready
DRAM: 128 MB
NAND: 256 MiB
MMC: davinci: 0
In: serial
Out: serial
Err: serial
ARM Clock : 300000000 Hz
DDR Clock : 150000000 Hz
EMIFA CLock : 100000000 Hz
DSP Clock : 300000000 Hz
ASYNC3 Clock : 150000000 Hz
Enet config : 2
MMC 0 Enable : 1
Resetting ethernet phy
Net: No ETH PHY detected!!!
U-Boot >
I understand that I have to load Linux kernal and .jffs2 file systems on board with SD card interface.Followings are my questions.
1) Can anyone explain me how to load Linux kernal and .jffs2 file systems on board with SD card interface from Linux or Windows.
2) In Linux VM (MityDSP-L138 SDK) which serial port communication application I can use to communicate with board?
3) I have connected test LEDs at GP01 and GP04 on my board for test purpose.Is there any way that without loading kernel and filesystem,I can toggle test LEDs on my board with CCS.
Thanks.
- Vivek
MityDspl-138 Uboot.txt (764 Bytes) MityDspl-138 Uboot.txt |
Replies (33)
RE: How to load Linux Kernel and files system with no Ethernet port - Added by Michael Williamson over 7 years ago
Did you take a look at the section "Booting off MMC / SD Card" in the Linux Root File System page?
This describes loading images from SD. It requires the u-Boot is properly built with MMC card support.
You can load the .jffs2 files and program the NAND this way, or you can simply boot from MMC and skip the NAND if that makes sense for your application.
-Mike
RE: How to load Linux Kernel and files system with no Ethernet port - Added by Jonathan Cormier over 7 years ago
Vivek Ponnani wrote:
1) Can anyone explain me how to load Linux kernal and .jffs2 file systems on board with SD card interface from Linux or Windows.
2) In Linux VM (MityDSP-L138 SDK) which serial port communication application I can use to communicate with board?
There are a number of serial port programs. For linux or windows you can use putty. If you want a terminal based serial program look at minicom.
First you can toggle LEDs in u-boot by writing to the correct memory registers. You could do the same thing from a debug session using CCS.3) I have connected test LEDs at GP01 and GP04 on my board for test purpose.Is there any way that without loading kernel and filesystem,I can toggle test LEDs on my board with CCS.
- Look up the GPIO memory address in the L138 datasheet
http://www.ti.com/lit/ds/symlink/omap-l138.pdf
Page 23, Table 3-4
GPIO base address is x01E26000 - Next we look at the OMAP-L1x Processor General-Purpose Input/Output (GPIO) Users Guide. It tells us what the register offsets are for configuring the gpio.
http://www.ti.com/lit/ug/sprufl8b/sprufl8b.pdf
page 18, chapter 3 registers - Also read chapters 2.5, 2.6, and 2.7 of the gpio guide for how to use the gpio registers
- You may also need to update the pinmux registers for the pins you are using so they are set as gpio. The pinmux register addresses can be found in the syscfg table 4-1 page 74 in the l138 datasheet mentioned above. To determine which pinmux register you need to update, you need to look at the L138 TRM (http://www.ti.com/lit/ug/spruh77c/spruh77c.pdf) page 236 1.5.11 Pin Multiplexing Control Registers (PINMUX0-PINMUX19)
Thanks.
- Vivek
RE: How to load Linux Kernel and files system with no Ethernet port - Added by Vivek Ponnani over 7 years ago
Michael Williamson wrote:
Did you take a look at the section "Booting off MMC / SD Card" in the Linux Root File System page?
This describes loading images from SD. It requires the u-Boot is properly built with MMC card support.
You can load the .jffs2 files and program the NAND this way, or you can simply boot from MMC and skip the NAND if that makes sense for your application.
-Mike
Hi Mike,
Thanks for your response.
1)First of all, when I start VM, I get that "your Ubuntu release is not supported anymore". I have attached screenshot for it. (Screenshot.png)
It seems because of it I am not able to process further for any update required.
I have MDK_2014-01-13 environment.Is it possible to upgrade Ubuntu from 10.04 to 14.04 for MDK_2014-01-13? Do you have any .ova image which supports Ubuntu 14.04 for mitydspl-138f?
2) I was following section "Booting off MMC / SD Card" in the Linux Root File System page, but when I insert the MMC card on target and checked with mount command, It gives response as below (mount.txt)
mitydsp@mitydsp-dev:~$ mount
/dev/sda1 on / type ext4 (rw,errors=remount-ro)
proc on /proc type proc (rw,noexec,nosuid,nodev)
none on /sys type sysfs (rw,noexec,nosuid,nodev)
none on /sys/fs/fuse/connections type fusectl (rw)
none on /sys/kernel/debug type debugfs (rw)
none on /sys/kernel/security type securityfs (rw)
none on /dev type devtmpfs (rw,mode=0755)
none on /dev/pts type devpts (rw,noexec,nosuid,gid=5,mode=0620)
none on /dev/shm type tmpfs (rw,nosuid,nodev)
none on /var/run type tmpfs (rw,nosuid,mode=0755)
none on /var/lock type tmpfs (rw,noexec,nosuid,nodev)
none on /lib/init/rw type tmpfs (rw,nosuid,mode=0755)
nfsd on /proc/fs/nfsd type nfsd (rw)
binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw,noexec,nosuid,nodev)
gvfs-fuse-daemon on /home/mitydsp/.gvfs type fuse.gvfs-fuse-daemon (rw,nosuid,nodev,user=mitydsp)
/dev/sr0 on /media/VBOXADDITIONS_5.1.16_113841 type iso9660 (ro,nosuid,nodev,uhelper=udisks,uid=1000,gid=1000,iocharset=utf8,mode=0400,dmode=0500)
3)Then if we process further with command sudo -s and unmount /media/mmcblk0p1, it gives response as below (prepare_SD_Card.txt)
mitydsp@mitydsp-dev:~$ sudo -s
[sudo] password for mitydsp:
root@mitydsp-dev:~# unmount /media/mmcblk0p1
No command 'unmount' found, did you mean:
Command 'umount' from package 'mount' (main)
Command 'umount' from package 'loop-aes-utils' (universe)
unmount: command not found
4) Then I follow Exporting as NFS mountable drive, but it seems as there is no more support for Ubuntu 10.04, when I run
sudo apt‐get install nfs‐kernel‐server, It gives response as below(Install_nfs_kernel_server.txt)
mitydsp@mitydsp-dev:~$ sudo apt-get install nfs-kernel-server
[sudo] password for mitydsp:
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages will be upgraded:
nfs-kernel-server
1 upgraded, 0 newly installed, 0 to remove and 273 not upgraded.
Need to get 159kB of archives.
After this operation, 0B of additional disk space will be used.
WARNING: The following packages cannot be authenticated!
nfs-kernel-server
Install these packages without verification [y/N]? y
Err http://us.archive.ubuntu.com/ubuntu/ lucid-updates/main nfs-kernel-server 1:1.2.0-4ubuntu4.2
404 Not Found [IP: 91.189.91.23 80]
Failed to fetch http://us.archive.ubuntu.com/ubuntu/pool/main/n/nfs-utils/nfs-kernel-server_1.2.0-4ubuntu4.2_i386.deb 404 Not Found [IP: 91.189.91.23 80]
E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?
mitydsp@mitydsp-dev:~$
We tried for apt-get update and --fix-missing but no success.
Thanks.
-Vivek
Install_nfs_kernel_server.txt (957 Bytes) Install_nfs_kernel_server.txt | |||
mount.txt (1.01 KB) mount.txt |
RE: How to load Linux Kernel and files system with no Ethernet port - Added by Vivek Ponnani over 7 years ago
Jonathan Cormier wrote:
Vivek Ponnani wrote:
1) Can anyone explain me how to load Linux kernal and .jffs2 file systems on board with SD card interface from Linux or Windows.
2) In Linux VM (MityDSP-L138 SDK) which serial port communication application I can use to communicate with board?There are a number of serial port programs. For linux or windows you can use putty. If you want a terminal based serial program look at minicom.
First you can toggle LEDs in u-boot by writing to the correct memory registers. You could do the same thing from a debug session using CCS.3) I have connected test LEDs at GP01 and GP04 on my board for test purpose.Is there any way that without loading kernel and filesystem,I can toggle test LEDs on my board with CCS.
- Look up the GPIO memory address in the L138 datasheet
http://www.ti.com/lit/ds/symlink/omap-l138.pdf
Page 23, Table 3-4
GPIO base address is x01E26000- Next we look at the OMAP-L1x Processor General-Purpose Input/Output (GPIO) Users Guide. It tells us what the register offsets are for configuring the gpio.
http://www.ti.com/lit/ug/sprufl8b/sprufl8b.pdf
page 18, chapter 3 registers- Also read chapters 2.5, 2.6, and 2.7 of the gpio guide for how to use the gpio registers
- You may also need to update the pinmux registers for the pins you are using so they are set as gpio. The pinmux register addresses can be found in the syscfg table 4-1 page 74 in the l138 datasheet mentioned above. To determine which pinmux register you need to update, you need to look at the L138 TRM (http://www.ti.com/lit/ug/spruh77c/spruh77c.pdf) page 236 1.5.11 Pin Multiplexing Control Registers (PINMUX0-PINMUX19)
Thanks.
- Vivek
Hi Jonathan,
Thanks for your respone.
I tried to install Putty in my VM, but I am not able to install it. It seems, it is because of Ubuntu 10.04 is not supported anymore. I get below response..(Putty.txt)
mitydsp@mitydsp-dev:~$ sudo apt-get install putty
[sudo] password for mitydsp:
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following extra packages will be installed:
putty-tools
The following NEW packages will be installed:
putty putty-tools
0 upgraded, 2 newly installed, 0 to remove and 274 not upgraded.
Need to get 1,087kB of archives.
After this operation, 2,736kB of additional disk space will be used.
Do you want to continue [Y/n]? y
WARNING: The following packages cannot be authenticated!
putty-tools putty
Install these packages without verification [y/N]? y
Err http://us.archive.ubuntu.com/ubuntu/ lucid/universe putty-tools 0.60+2009-11-22-1
404 Not Found [IP: 91.189.91.26 80]
Err http://us.archive.ubuntu.com/ubuntu/ lucid/universe putty 0.60+2009-11-22-1
404 Not Found [IP: 91.189.91.26 80]
Failed to fetch http://us.archive.ubuntu.com/ubuntu/pool/universe/p/putty/putty-tools_0.60+2009-11-22-1_i386.deb 404 Not Found [IP: 91.189.91.26 80]
Failed to fetch http://us.archive.ubuntu.com/ubuntu/pool/universe/p/putty/putty_0.60+2009-11-22-1_i386.deb 404 Not Found [IP: 91.189.91.26 80]
E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?
mitydsp@mitydsp-dev:~$
Please advise further..
Thanks.
- Vivek.
RE: How to load Linux Kernel and files system with no Ethernet port - Added by Vivek Ponnani over 7 years ago
Vivek Ponnani wrote:
Michael Williamson wrote:
Did you take a look at the section "Booting off MMC / SD Card" in the Linux Root File System page?
This describes loading images from SD. It requires the u-Boot is properly built with MMC card support.
You can load the .jffs2 files and program the NAND this way, or you can simply boot from MMC and skip the NAND if that makes sense for your application.
-Mike
Hi Mike,
Thanks for your response.
1)First of all, when I start VM, I get that "your Ubuntu release is not supported anymore". I have attached screenshot for it. (Screenshot.png)
It seems because of it I am not able to process further for any update required.
I have MDK_2014-01-13 environment.Is it possible to upgrade Ubuntu from 10.04 to 14.04 for MDK_2014-01-13? Do you have any .ova image which supports Ubuntu 14.04 for mitydspl-138f?2) I was following section "Booting off MMC / SD Card" in the Linux Root File System page, but when I insert the MMC card on target and checked with mount command, It gives response as below (mount.txt)
mitydsp@mitydsp-dev:~$ mount
/dev/sda1 on / type ext4 (rw,errors=remount-ro)
proc on /proc type proc (rw,noexec,nosuid,nodev)
none on /sys type sysfs (rw,noexec,nosuid,nodev)
none on /sys/fs/fuse/connections type fusectl (rw)
none on /sys/kernel/debug type debugfs (rw)
none on /sys/kernel/security type securityfs (rw)
none on /dev type devtmpfs (rw,mode=0755)
none on /dev/pts type devpts (rw,noexec,nosuid,gid=5,mode=0620)
none on /dev/shm type tmpfs (rw,nosuid,nodev)
none on /var/run type tmpfs (rw,nosuid,mode=0755)
none on /var/lock type tmpfs (rw,noexec,nosuid,nodev)
none on /lib/init/rw type tmpfs (rw,nosuid,mode=0755)
nfsd on /proc/fs/nfsd type nfsd (rw)
binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw,noexec,nosuid,nodev)
gvfs-fuse-daemon on /home/mitydsp/.gvfs type fuse.gvfs-fuse-daemon (rw,nosuid,nodev,user=mitydsp)
/dev/sr0 on /media/VBOXADDITIONS_5.1.16_113841 type iso9660 (ro,nosuid,nodev,uhelper=udisks,uid=1000,gid=1000,iocharset=utf8,mode=0400,dmode=0500)3)Then if we process further with command sudo -s and unmount /media/mmcblk0p1, it gives response as below (prepare_SD_Card.txt)
mitydsp@mitydsp-dev:~$ sudo -s
[sudo] password for mitydsp:
root@mitydsp-dev:~# unmount /media/mmcblk0p1
No command 'unmount' found, did you mean:
Command 'umount' from package 'mount' (main)
Command 'umount' from package 'loop-aes-utils' (universe)
unmount: command not found4) Then I follow Exporting as NFS mountable drive, but it seems as there is no more support for Ubuntu 10.04, when I run
sudo apt‐get install nfs‐kernel‐server, It gives response as below(Install_nfs_kernel_server.txt)mitydsp@mitydsp-dev:~$ sudo apt-get install nfs-kernel-server
[sudo] password for mitydsp:
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages will be upgraded:
nfs-kernel-server
1 upgraded, 0 newly installed, 0 to remove and 273 not upgraded.
Need to get 159kB of archives.
After this operation, 0B of additional disk space will be used.
WARNING: The following packages cannot be authenticated!
nfs-kernel-server
Install these packages without verification [y/N]? y
Err http://us.archive.ubuntu.com/ubuntu/ lucid-updates/main nfs-kernel-server 1:1.2.0-4ubuntu4.2
404 Not Found [IP: 91.189.91.23 80]
Failed to fetch http://us.archive.ubuntu.com/ubuntu/pool/main/n/nfs-utils/nfs-kernel-server_1.2.0-4ubuntu4.2_i386.deb 404 Not Found [IP: 91.189.91.23 80]
E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?
mitydsp@mitydsp-dev:~$We tried for apt-get update and --fix-missing but no success.
Thanks.
-Vivek
Screenshot.png (310 KB) Screenshot.png |
RE: How to load Linux Kernel and files system with no Ethernet port - Added by Jonathan Cormier over 7 years ago
Vivek, Sorry about all this. The apt-get repo's got moved when it went end of life. We've been meaning to post a new VM but things always come up. If your up for it, you can install ubuntu 14.04 or 16.04 in a VM then install the toolchain from https://support.criticallink.com/redmine/projects/arm9-platforms/wiki/GCC_Toolchain and the MDK https://support.criticallink.com/redmine/projects/arm9-platforms/wiki/Updating_devkit_to_latest_MDK
I'll ask around to find out where the update VM project got to.
RE: How to load Linux Kernel and files system with no Ethernet port - Added by Jonathan Cormier over 7 years ago
Uploaded newer VM. This one is based on Ubuntu 14.04. Note this VM has both 335x and L138 toolchains.
https://support.criticallink.com/redmine/projects/arm9-platforms/wiki/Linux_Build_VM
RE: How to load Linux Kernel and files system with no Ethernet port - Added by Vivek Ponnani over 7 years ago
Jonathan Cormier wrote:
Uploaded newer VM. This one is based on Ubuntu 14.04. Note this VM has both 335x and L138 toolchains.
https://support.criticallink.com/redmine/projects/arm9-platforms/wiki/Linux_Build_VM
Hi Jonathan,
Thanks for your response and new VM.
I imported Critical_Link_Unified_VM_14-04_04-2017.ova file with VM 5.1.22. After that I tried to install putty and got response as below.(Putty on ubuntu14.04.txt)
mitydsp@vagrantup:~$ putty
The program 'putty' is currently not installed. You can install it by typing:
sudo apt-get install putty
mitydsp@vagrantup:~$ sudo apt-get install putty
[sudo] password for mitydsp:
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following extra packages will be installed:
putty-tools
Suggested packages:
putty-doc
The following NEW packages will be installed:
putty putty-tools
0 upgraded, 2 newly installed, 0 to remove and 3 not upgraded.
1 not fully installed or removed.
Need to get 582 kB of archives.
After this operation, 2,421 kB of additional disk space will be used.
Do you want to continue? [Y/n] y
Err http://us.archive.ubuntu.com/ubuntu/ trusty-updates/universe putty-tools amd64 0.63-4ubuntu0.1
Cannot initiate the connection to us.archive.ubuntu.com:80 (91.189.91.23). - connect (101: Network is unreachable) [IP: 91.189.91.23 80]
Err http://security.ubuntu.com/ubuntu/ trusty-security/universe putty-tools amd64 0.63-4ubuntu0.1
Cannot initiate the connection to security.ubuntu.com:80 (91.189.88.162). - connect (101: Network is unreachable) [IP: 91.189.88.162 80]
Err http://security.ubuntu.com/ubuntu/ trusty-security/universe putty amd64 0.63-4ubuntu0.1
Cannot initiate the connection to security.ubuntu.com:80 (91.189.88.162). - connect (101: Network is unreachable) [IP: 91.189.88.162 80]
E: Failed to fetch http://security.ubuntu.com/ubuntu/pool/universe/p/putty/putty-tools_0.63-4ubuntu0.1_amd64.deb Cannot initiate the connection to security.ubuntu.com:80 (91.189.88.162). - connect (101: Network is unreachable) [IP: 91.189.88.162 80]
E: Failed to fetch http://security.ubuntu.com/ubuntu/pool/universe/p/putty/putty_0.63-4ubuntu0.1_amd64.deb Cannot initiate the connection to security.ubuntu.com:80 (91.189.88.162). - connect (101: Network is unreachable) [IP: 91.189.88.162 80]
E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?
mitydsp@vagrantup:~$
Is there any missing part, which I should follow before installing Putty or minicom?
Also in this version of Ubuntu, I can not find any software center option where I can find softwares to install.
Please suggest further action.
Thanks
-Vivek
RE: How to load Linux Kernel and files system with no Ethernet port - Added by Jonathan Cormier over 7 years ago
Network is unreachable
Looks like you don't have internet in the VM. When you started the VM did it ask you about specifying your computers network adapter. You can use 'ifconfig' in the VM to print the network adapter information. Paste the output here if you can't get the network adapter working.
https://www.thomas-krenn.com/en/wiki/Network_Configuration_in_VirtualBox
You want bridged networking.
Is there any missing part, which I should follow before installing Putty or minicom?
Nope assuming you get internet to the VM, apt-get will install everything you need.
Also in this version of Ubuntu, I can not find any software center option where I can find softwares to install.
Hmm this was a custom install of Ubuntu. Looks like we forgot the software center. Most of us use apt-get to install everything.
RE: How to load Linux Kernel and files system with no Ethernet port - Added by Jonathan Cormier over 7 years ago
4) Then I follow Exporting as NFS mountable drive, but it seems as there is no more support for Ubuntu 10.04, when I run sudo apt‐get install nfs‐kernel‐server, It gives response as below(Install_nfs_kernel_server.txt)
Note that the nfs server would be used for a network boot. Since you have no ethernet on your board, this won't be needed.
RE: How to load Linux Kernel and files system with no Ethernet port - Added by Vivek Ponnani over 7 years ago
Jonathan Cormier wrote:
Network is unreachable
Looks like you don't have internet in the VM. When you started the VM did it ask you about specifying your computers network adapter. You can use 'ifconfig' in the VM to print the network adapter information. Paste the output here if you can't get the network adapter working.
https://www.thomas-krenn.com/en/wiki/Network_Configuration_in_VirtualBox
You want bridged networking.Is there any missing part, which I should follow before installing Putty or minicom?
Nope assuming you get internet to the VM, apt-get will install everything you need.
Also in this version of Ubuntu, I can not find any software center option where I can find softwares to install.
Hmm this was a custom install of Ubuntu. Looks like we forgot the software center. Most of us use apt-get to install everything.
Hi Jonathan,
Sorry for the late response.
Thanks for your guidance.
You were right, I was not able to connect to network. From the links you provided, I managed to get network by changing setting for Network-> Advanced->Promiscuous mode from Deny to allow all in VM.
I managed to get serial connection with putty and minicom as well.Now , I am trying to make SD card with Linux root file system and uImage. For that I followed Booting off MMC / SD Card in Linux Root file system. It is mentioned that, "you need to prepare the SD card. This can be done on the target by inserting the MMC card and running the commands:".
As I mentioned earlier, I have no Ethernet port. With serial port, I am not able to see card on the target from VM. How could I prepare the SD card?
I tried to do it from VM by inserting card on host machine as following.. but no success. (Prepare_SD_Card.txt)
root@vagrantup:/# cd media
root@vagrantup:/media# ls
cdrom mitydsp sf_Downloads
root@vagrantup:/media# cd mitydsp
root@vagrantup:/media/mitydsp# ls
E4DE-5094 VBOXADDITIONS_5.1.22_115126
root@vagrantup:/media/mitydsp# cd ..
root@vagrantup:/media# cd ..
root@vagrantup:/# cd dev
root@vagrantup:/dev# sudo mkdir E4DE-5094
root@vagrantup:/dev# cd ..
root@vagrantup:/# umount /media/mitydsp/E4DE-5094
root@vagrantup:/# mke2fs -j /dev/E4DE-5094
mke2fs 1.42.9 (4-Feb-2014)
/dev/E4DE-5094 is not a block special device.
Proceed anyway? (y,n) y
mke2fs: Device size reported to be zero. Invalid partition specified, or
partition table wasn't reread after running fdisk, due to
a modified partition being busy and in use. You may need to reboot
to re-read your partition table.
root@vagrantup:/# mount /dev/E4DE-5094 /media/mitydsp/E4DE-5094
mount: mount point /media/mitydsp/E4DE-5094 does not exist
Is there any other method to prepare SD card with serial port?, please suggest.
Thanks
-Vivek
Prepare_SD_Card.txt (923 Bytes) Prepare_SD_Card.txt |
RE: How to load Linux Kernel and files system with no Ethernet port - Added by Jonathan Cormier over 7 years ago
Vivek Ponnani wrote:
Hi Jonathan,
Sorry for the late response.
Thanks for your guidance.
You were right, I was not able to connect to network. From the links you provided, I managed to get network by changing setting for Network-> Advanced->Promiscuous mode from Deny to allow all in VM.
You shouldn't need Promiscuous mode. This mode is usually used to packet sniff a network. It tells your network card to not filter packets destined to other computers.
I managed to get serial connection with putty and minicom as well.Now , I am trying to make SD card with Linux root file system and uImage. For that I followed Booting off MMC / SD Card in Linux Root file system. It is mentioned that, "you need to prepare the SD card. This can be done on the target by inserting the MMC card and running the commands:".
As I mentioned earlier, I have no Ethernet port. With serial port, I am not able to see card on the target from VM. How could I prepare the SD card?
I tried to do it from VM by inserting card on host machine as following.. but no success. (Prepare_SD_Card.txt)root@vagrantup:/# cd media
root@vagrantup:/media# ls
cdrom mitydsp sf_Downloads
root@vagrantup:/media# cd mitydsp
root@vagrantup:/media/mitydsp# ls
E4DE-5094 VBOXADDITIONS_5.1.22_115126
root@vagrantup:/media/mitydsp# cd ..
root@vagrantup:/media# cd ..
root@vagrantup:/# cd dev
root@vagrantup:/dev# sudo mkdir E4DE-5094
In modern linux, you should never have to create a file or folder in the /dev/ directory. uDev or the systemd alternative is responsible for creating files in this directory.
root@vagrantup:/dev# cd ..
root@vagrantup:/# umount /media/mitydsp/E4DE-5094
root@vagrantup:/# mke2fs -j /dev/E4DE-5094
mke2fs 1.42.9 (4-Feb-2014)
/dev/E4DE-5094 is not a block special device.
Proceed anyway? (y,n) y
mke2fs: Device size reported to be zero. Invalid partition specified, or
partition table wasn't reread after running fdisk, due to
a modified partition being busy and in use. You may need to reboot
to re-read your partition table.
This is because you created a folder and are trying to treat it as if it was a block device.
When you insert the sd card into your computer, assuming you are using a USB to SD card reader, you need to go to Devices -> USB and select your sd card reader to be mounted in the linux VM. When the sd card is inserted into the reader, linux should assign it a /dev/sd* block device. /dev/sda is usually going to be the computers harddrive and this is true for the Unified VM.root@vagrantup:/# mount /dev/E4DE-5094 /media/mitydsp/E4DE-5094
mount: mount point /media/mitydsp/E4DE-5094 does not existIs there any other method to prepare SD card with serial port?, please suggest.
- In terminal, run
sudo fdisk -l
. This will list all the storage devices linux detects.
Below you can see the VM's hard drive at /dev/sda and its partitions. Next you will see some /dev/mapper disks, these are for Linux LVM and can be ignored for this. At the bottom you can see /dev/sdd which is my inserted sd card. I can be pretty confident that the disk is the sd card by looking at its total size (3965 MB), this closely matches the 4GB sd card.
Note that the main parition on the disk is /dev/sdd1 and this is were we want to format as ext.mitydsp@vagrantup:~$ sudo fdisk -l [sudo] password for mitydsp: Disk /dev/sda: 128.8 GB, 128849018880 bytes 255 heads, 63 sectors/track, 15665 cylinders, total 251658240 sectors Units = sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x000ad2d4 Device Boot Start End Blocks Id System /dev/sda1 * 2048 499711 248832 83 Linux /dev/sda2 501758 251656191 125577217 5 Extended /dev/sda5 501760 251656191 125577216 8e Linux LVM Disk /dev/mapper/vagrantup--vg-root: 127.0 GB, 127016108032 bytes 255 heads, 63 sectors/track, 15442 cylinders, total 248078336 sectors Units = sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x00000000 Disk /dev/mapper/vagrantup--vg-root doesn't contain a valid partition table Disk /dev/mapper/vagrantup--vg-swap_1: 1572 MB, 1572864000 bytes 255 heads, 63 sectors/track, 191 cylinders, total 3072000 sectors Units = sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x00000000 Disk /dev/mapper/vagrantup--vg-swap_1 doesn't contain a valid partition table Disk /dev/sdd: 3951 MB, 3951034368 bytes 122 heads, 57 sectors/track, 1109 cylinders, total 7716864 sectors Units = sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x00000000 Device Boot Start End Blocks Id System /dev/sdd1 8192 7716863 3854336 83 Linux
- Unmount the drive
sudo umount /dev/sdd1
- Format the partition to ext3
mitydsp@vagrantup:~$ sudo mkfs.ext3 -L "rootfs" /dev/sdd1 mke2fs 1.42.9 (4-Feb-2014) Filesystem label=rootfs OS type: Linux Block size=4096 (log=2) Fragment size=4096 (log=2) Stride=0 blocks, Stripe width=0 blocks 241920 inodes, 967680 blocks 48384 blocks (5.00%) reserved for the super user First data block=0 Maximum filesystem blocks=994050048 30 block groups 32768 blocks per group, 32768 fragments per group 8064 inodes per group Superblock backups stored on blocks: 32768, 98304, 163840, 229376, 294912, 819200, 884736 Allocating group tables: done Writing inode tables: done Creating journal (16384 blocks): done Writing superblocks and filesystem accounting information: done
- Mount the sd card
mitydsp@vagrantup:~$ ls /mnt/ mitydsp@vagrantup:~$ sudo mount /dev/sdd1 /mnt/ mitydsp@vagrantup:~$ ls /mnt/ lost+found
- Extract the tarball and unmount
mitydsp@vagrantup:~$ cd /mnt/ mitydsp@vagrantup:/mnt$ sudo tar xzvf ~/MDK_2014-01-13/fs/mityomap-full.tgz [...] ./mnt/ ./mnt/cf ./mnt/ram ./mnt/card ./mnt/.splash/ ./mnt/net mitydsp@vagrantup:/mnt$ cd ~ mitydsp@vagrantup:~$ sudo umount /dev/sdd1
- If you get a "device is busy" warning when unmounting, make sure you have no terminal or window which is cd'ed into /mnt
mitydsp@vagrantup:/mnt$ sudo umount /dev/sdd1 umount: /mnt: device is busy. (In some cases useful info about processes that use the device is found by lsof(8) or fuser(1)) mitydsp@vagrantup:/mnt$ cd ~ mitydsp@vagrantup:~$ sudo umount /dev/sdd1
- If you get a "device is busy" warning when unmounting, make sure you have no terminal or window which is cd'ed into /mnt
Note: If you feel more comfortable with a GUI, you can use gparted under System -> Administration. Just make sure you select the sd card from the dropdown on the right and select ext3 as the filesystem.
RE: How to load Linux Kernel and files system with no Ethernet port - Added by Jonathan Cormier over 7 years ago
Updated wiki page to hopefully make it clearer.
https://support.criticallink.com/redmine/projects/arm9-platforms/wiki/Linux_Root_File_System#section-6
RE: How to load Linux Kernel and files system with no Ethernet port - Added by Vivek Ponnani over 7 years ago
Jonathan Cormier wrote:
Updated wiki page to hopefully make it clearer.
https://support.criticallink.com/redmine/projects/arm9-platforms/wiki/Linux_Root_File_System#section-6
Hi Jonathan,
Your guidance is really helpful. I am able to load Linux Kernel and files system on SD card and boot from it. Now, I am trying to setup hello world application in VM ( Critical_Link_Unified_VM_14-04_04-2017.OVA) which has Eclipse 3.8.1 and CCS 6.1.3.00033 installed. When I opened these applications for the first time, it starts Install updates. It is not able to install updates in both applications(Eclipse and CCS) as it is giving some errors. Attaching some snapshots for errors. Should I continue to develop Hello world application without installing updates? I am following the links as below for hello world application.
1. https://support.criticallink.com/redmine/projects/arm9-platforms/wiki/Starter_Guide
2. https://support.criticallink.com/redmine/projects/arm9-platforms/wiki/DSP_Hello_World
Please let me know if there are any updated links for new VM (Critical_Link_Unified_VM_14-04_04-2017.OVA).
Thanks.
- Vivek
RE: How to load Linux Kernel and files system with no Ethernet port - Added by Jonathan Cormier over 7 years ago
Vivek, Looks like there is a bug with the VM that is breaking internet.
- Open Terminal
sudo vim /etc/network/interfaces
- Delete the below lines and save the file
#VAGRANT-BEGIN # The contents below are automatically generated by Vagrant. Do not modify. auto eth1 iface eth1 inet dhcp post-up route del default dev $IFACE || true #VAGRANT-END
- Reboot
I'm sorry for the trouble. It looks like TI dropped support for dsp bios in CCS v6. Our instructions are all written for CCSv5.5. I'm currently reworking some of our instructions. I'll let you know in a bit when i'm done. For now you can start by downloading and installing CCSv5.5. https://support.criticallink.com/redmine/projects/arm9-platforms/wiki/Installing_CCS5_for_L138_DSP#section-4
Note: You can build both the ARM and DSP parts in CCSv5.5. No need to do the ARM in eclipse and DSP in CCS.
RE: How to load Linux Kernel and files system with no Ethernet port - Added by Jonathan Cormier over 7 years ago
Okay I was able to successfully install CCSv5.5 in the VM and follow the Starter Guide and DSP Hello World. Let me know if you run into any problems.
RE: How to load Linux Kernel and files system with no Ethernet port - Added by Vivek Ponnani over 7 years ago
Jonathan Cormier wrote:
Okay I was able to successfully install CCSv5.5 in the VM and follow the Starter Guide and DSP Hello World. Let me know if you run into any problems.
Hi Jonathan,
I followed the steps for installing CCSv5.5. But I am stuck at installation of CCSv5. When I give command sudo ./ccs_setup_5.0.0.00077.bin &, It simply returns back as below, and not installing CCSv5.
mitydsp@vagrantup:/$ sudo ./home/mitydsp/CCSv5/CCS5.5.0.00077_linux/ccs_setup_5.5.0.00077.bin &
[1] 3558
mitydsp@vagrantup:/$
I followed steps as below.
1) Open Terminal
sudo vim /etc/network/interfaces
Delete the below lines and save the file
#VAGRANT-BEGIN
#The contents below are automatically generated by Vagrant. Do not modify.
auto eth1
iface eth1 inet dhcp
post-up route del default dev $IFACE || true
#VAGRANT-END
Reboot
Attaching new interfaces file.(interfaces)
It was not allowing to write the interfaces file, so I tried :w !sudo tee % and then :q!. Is that ok?
2)
Install prereqs.
sudo apt-get install libgnomeui-0 libusb-1.0-0-dev
Packages needed for 64-bit Ubuntu only
sudo apt-get install libc6-i386 libx11-6:i386 libasound2:i386 libjpeg62:i386 libatk1.0-0:i386 libcairo2:i386 libdbus-1-3:i386 libdbus-glib-1-2:i386 libfontconfig1:i386 libfreetype6:i386 libgconf-2-4:i386 libgdk-pixbuf2.0-0:i386 libgtk2.0-0:i386 libice6:i386 lib32ncurses5 liborbit2:i386 libpango-1.0-0:i386 libpangocairo-1.0-0:i386 libpangoft2-1.0-0:i386 libpng12-0:i386 libsm6:i386 lib32stdc++6 libusb-0.1-4:i386 libx11-6:i386 libxext6:i386 libxi6:i386 libxrender1:i386 libxt6:i386 libxtst6:i386 lib32z1 libgnomevfs2-0:i386 libcanberra-gtk-module:i386
Attaching response file.(Install_prereqs.txt)
3) Download CCS5.5.0.00077_linux.tar.gz. Copy into /home/mitydsp/CCSv5.
4) Download depends_0.2.tar.gz. Copy depends_0.2 folder into /home/mitydsp.(depends0.2.txt)
5)
sudo apt-get install ia32-libs but it was not sucessful. so as suggested i tried,
sudo apt-get install lib32z1 lib32ncurses5 lib32bz2-1.0 (ia32_libs.txt)
6) Install CCSv5.(CCSv5_installation.txt)
Thanks.
- Vivek.
interfaces (274 Bytes) interfaces | |||
Install_prereqs.txt (5.43 KB) Install_prereqs.txt | |||
depends0.2.txt (282 Bytes) depends0.2.txt | |||
ia32_libs.txt (1.61 KB) ia32_libs.txt | |||
CCSv5_installation.txt (11.4 KB) CCSv5_installation.txt |
RE: How to load Linux Kernel and files system with no Ethernet port - Added by Jonathan Cormier over 7 years ago
Vivek Ponnani wrote:
Jonathan Cormier wrote:
Okay I was able to successfully install CCSv5.5 in the VM and follow the Starter Guide and DSP Hello World. Let me know if you run into any problems.
Hi Jonathan,
I followed the steps for installing CCSv5.5. But I am stuck at installation of CCSv5. When I give command sudo ./ccs_setup_5.0.0.00077.bin &, It simply returns back as below, and not installing CCSv5.
mitydsp@vagrantup:/$ sudo ./home/mitydsp/CCSv5/CCS5.5.0.00077_linux/ccs_setup_5.5.0.00077.bin &
[1] 3558
mitydsp@vagrantup:/$
The '&' tells bash to let the process run in the background. Its not really necessary but it shouldn't break things. The installer should launch a gui install wizard.
I followed steps as below.
1) Open Terminal
sudo vim /etc/network/interfaces
Delete the below lines and save the file
#VAGRANT-BEGIN
#The contents below are automatically generated by Vagrant. Do not modify.
auto eth1
iface eth1 inet dhcp
post-up route del default dev $IFACE || true
#VAGRANT-END
Reboot
Attaching new interfaces file.(interfaces)
It was not allowing to write the interfaces file, so I tried :w !sudo tee % and then :q!. Is that ok?
Yup
2)
Install prereqs.
sudo apt-get install libgnomeui-0 libusb-1.0-0-devPackages needed for 64-bit Ubuntu only
sudo apt-get install libc6-i386 libx11-6:i386 libasound2:i386 libjpeg62:i386 libatk1.0-0:i386 libcairo2:i386 libdbus-1-3:i386 libdbus-glib-1-2:i386 libfontconfig1:i386 libfreetype6:i386 libgconf-2-4:i386 libgdk-pixbuf2.0-0:i386 libgtk2.0-0:i386 libice6:i386 lib32ncurses5 liborbit2:i386 libpango-1.0-0:i386 libpangocairo-1.0-0:i386 libpangoft2-1.0-0:i386 libpng12-0:i386 libsm6:i386 lib32stdc++6 libusb-0.1-4:i386 libx11-6:i386 libxext6:i386 libxi6:i386 libxrender1:i386 libxt6:i386 libxtst6:i386 lib32z1 libgnomevfs2-0:i386 libcanberra-gtk-module:i386
Attaching response file.(Install_prereqs.txt)
Looks good
3) Download CCS5.5.0.00077_linux.tar.gz. Copy into /home/mitydsp/CCSv5.
4) Download depends_0.2.tar.gz. Copy depends_0.2 folder into /home/mitydsp.(depends0.2.txt)
5)
sudo apt-get install ia32-libs but it was not sucessful. so as suggested i tried,
sudo apt-get install lib32z1 lib32ncurses5 lib32bz2-1.0 (ia32_libs.txt)
6) Install CCSv5.(CCSv5_installation.txt)
Doesn't look like you did anything wrong. I never tried the install with the proceeding '&' but i'd be surprised if thats the problem.
Just an FYI, the '.' at the beginning of the path says "start looking in current directory". You could have from the CCSv5 directory run mitydsp@vagrantup:~/CCSv5$ sudo ./CCS5.5.0.00077_linux/ccs_setup_5.5.0.00077.bin
.
mitydsp@vagrantup:~/CCSv5$ mitydsp@vagrantup:~$ cd .. mitydsp@vagrantup:/home$ cd .. mitydsp@vagrantup:/$ sudo ./home/mitydsp/CCSv5/CCS5.5.0.00077_linux/ccs_setup_5.5.0.00077.bin &
I guess try it without the '&', though i can't explain why that would break anything.
RE: How to load Linux Kernel and files system with no Ethernet port - Added by Vivek Ponnani over 7 years ago
Jonathan Cormier wrote:
Vivek Ponnani wrote:
Jonathan Cormier wrote:
Okay I was able to successfully install CCSv5.5 in the VM and follow the Starter Guide and DSP Hello World. Let me know if you run into any problems.
Hi Jonathan,
I followed the steps for installing CCSv5.5. But I am stuck at installation of CCSv5. When I give command sudo ./ccs_setup_5.0.0.00077.bin &, It simply returns back as below, and not installing CCSv5.
mitydsp@vagrantup:/$ sudo ./home/mitydsp/CCSv5/CCS5.5.0.00077_linux/ccs_setup_5.5.0.00077.bin &
[1] 3558
mitydsp@vagrantup:/$The '&' tells bash to let the process run in the background. Its not really necessary but it shouldn't break things. The installer should launch a gui install wizard.
I followed steps as below.
1) Open Terminal
sudo vim /etc/network/interfaces
Delete the below lines and save the file
#VAGRANT-BEGIN
#The contents below are automatically generated by Vagrant. Do not modify.
auto eth1
iface eth1 inet dhcp
post-up route del default dev $IFACE || true
#VAGRANT-END
Reboot
Attaching new interfaces file.(interfaces)
It was not allowing to write the interfaces file, so I tried :w !sudo tee % and then :q!. Is that ok?Yup
2)
Install prereqs.
sudo apt-get install libgnomeui-0 libusb-1.0-0-devPackages needed for 64-bit Ubuntu only
sudo apt-get install libc6-i386 libx11-6:i386 libasound2:i386 libjpeg62:i386 libatk1.0-0:i386 libcairo2:i386 libdbus-1-3:i386 libdbus-glib-1-2:i386 libfontconfig1:i386 libfreetype6:i386 libgconf-2-4:i386 libgdk-pixbuf2.0-0:i386 libgtk2.0-0:i386 libice6:i386 lib32ncurses5 liborbit2:i386 libpango-1.0-0:i386 libpangocairo-1.0-0:i386 libpangoft2-1.0-0:i386 libpng12-0:i386 libsm6:i386 lib32stdc++6 libusb-0.1-4:i386 libx11-6:i386 libxext6:i386 libxi6:i386 libxrender1:i386 libxt6:i386 libxtst6:i386 lib32z1 libgnomevfs2-0:i386 libcanberra-gtk-module:i386
Attaching response file.(Install_prereqs.txt)Looks good
3) Download CCS5.5.0.00077_linux.tar.gz. Copy into /home/mitydsp/CCSv5.
4) Download depends_0.2.tar.gz. Copy depends_0.2 folder into /home/mitydsp.(depends0.2.txt)
5)
sudo apt-get install ia32-libs but it was not sucessful. so as suggested i tried,
sudo apt-get install lib32z1 lib32ncurses5 lib32bz2-1.0 (ia32_libs.txt)
6) Install CCSv5.(CCSv5_installation.txt)Doesn't look like you did anything wrong. I never tried the install with the proceeding '&' but i'd be surprised if thats the problem.
Just an FYI, the '.' at the beginning of the path says "start looking in current directory". You could have from the CCSv5 directory run
mitydsp@vagrantup:~/CCSv5$ sudo ./CCS5.5.0.00077_linux/ccs_setup_5.5.0.00077.bin
.
[...]I guess try it without the '&', though i can't explain why that would break anything.
Hi Jonathan,
I tried following without '&' at both the directory.The response is same to set DISPLAY.
Actually, just FYI,with the same process I installed CCSv5 in your last VM for Ubuntu 10.04 successfully.
mitydsp@vagrantup:/$ sudo ./home/mitydsp/CCSv5/CCS5.5.0.00077_linux/ccs_setup_5.5.0.00077.bin
[sudo] password for mitydsp:
Please set DISPLAY. Code Composer Studio v5 cannot be installed in console mode.
mitydsp@vagrantup:/$
mitydsp@vagrantup:~$ cd CCSv5
mitydsp@vagrantup:~/CCSv5$ sudo ./CCS5.5.0.00077_linux/ccs_setup_5.5.0.00077.bin
[sudo] password for mitydsp:
Please set DISPLAY. Code Composer Studio v5 cannot be installed in console mode.
mitydsp@vagrantup:~/CCSv5$
Thanks.
-Vivek.
RE: How to load Linux Kernel and files system with no Ethernet port - Added by Jonathan Cormier over 7 years ago
Are you connecting to the VM over ssh? How are you opening the terminal?
RE: How to load Linux Kernel and files system with no Ethernet port - Added by Vivek Ponnani over 7 years ago
Jonathan Cormier wrote:
Are you connecting to the VM over ssh? How are you opening the terminal?
I am not using ssh. I have installed VM in Windows 10 machine and start VM from desktop only. I think CCS 5.5 was opening terminal in my last installation for ubuntu 10.04 VM also and then starts ccs installation in GUI.Should I try to uninstall CCSv6.1( already installed in latest VM) and then try to install CCSv5.5?
Thanks
-vivek.
RE: How to load Linux Kernel and files system with no Ethernet port - Added by Jonathan Cormier over 7 years ago
Vivek Ponnani wrote:
Jonathan Cormier wrote:
Are you connecting to the VM over ssh? How are you opening the terminal?
I am not using ssh. I have installed VM in Windows 10 machine and start VM from desktop only. I think CCS 5.5 was opening terminal in my last installation for ubuntu 10.04 VM also and then starts ccs installation in GUI.Should I try to uninstall CCSv6.1( already installed in latest VM) and then try to install CCSv5.5?
No they will both live happily next to each other. I ran through all the steps on the same VM you have so I'm a bit confused. What doesn't make sense is this line which you shouldn't get if you are running via the terminal inside the VM.
Please set DISPLAY. Code Composer Studio v5 cannot be installed in console mode.
I think CCS 5.5 was opening terminal in my last installation for ubuntu 10.04 VM also and then starts ccs installation in GUI.
What do you mean? How was CCS 5.5 opening a terminal before it was installed?
RE: How to load Linux Kernel and files system with no Ethernet port - Added by Vivek Ponnani over 7 years ago
Jonathan Cormier wrote:
Vivek Ponnani wrote:
Jonathan Cormier wrote:
Are you connecting to the VM over ssh? How are you opening the terminal?
I am not using ssh. I have installed VM in Windows 10 machine and start VM from desktop only. I think CCS 5.5 was opening terminal in my last installation for ubuntu 10.04 VM also and then starts ccs installation in GUI.Should I try to uninstall CCSv6.1( already installed in latest VM) and then try to install CCSv5.5?
No they will both live happily next to each other. I ran through all the steps on the same VM you have so I'm a bit confused. What doesn't make sense is this line which you shouldn't get if you are running via the terminal inside the VM.
[...]I think CCS 5.5 was opening terminal in my last installation for ubuntu 10.04 VM also and then starts ccs installation in GUI.
What do you mean? How was CCS 5.5 opening a terminal before it was installed?
Hi Jonathan,
It seems the first command of install Prereqs (sudo apt-get install libgnomeui-0 libusb-1.0-0-dev ) didn't work well in my first installation(may be due to momentarily disruption of net connection). I did all the process all over again and I am able to install CCSv5. I am attaching both files for Install prereqs. commands, for old installtion(Install_prereq_old.txt) and new installation (Install_prereq_new.txt) for your reference.
Now, I am able to execute the helloworld application for both ARM and DSP. As I was following the link https://support.criticallink.com/redmine/projects/arm9-platforms/wiki/Starter_Guide, It shows how to load application image to board with ehernet port.
1)I tried following commands on board.
root@mityomap# opkg update
root@mityomap# opkg install libstdc++6
For the first command it is giving errors, as I have no Ethernet port. For the second command it gives response "libstdc++6 is up to date"
I hope this would be fine.
2) Will scp work over serial connection? If no, please suggest how to load application image to board with serial port.
Thanks.
-Vivek.
RE: How to load Linux Kernel and files system with no Ethernet port - Added by Jonathan Cormier over 7 years ago
I've not really tried to send files over the terminal. But it should be possible using xmodem. The L138 filesystem has the rx program which is used to receive xmodem file streams. sx would be used on the other side. I'm not sure exactly how to run these commands though to get them working.
https://www.systutorials.com/docs/linux/man/1-sz/
Do you have an sd card slot which you could use to transfer files? Or usb?