If you are developing software for an Ethernet (or Wifi) device, you’ll need to access the board for debugging and/or testing purpose. If your board does not have user interface or the serial port is not available, you’ll have to find the IP address (assuming it is using DHCP) before accessing the board thru telnet or ssh. A simple way to do that is to ping the broadcast address and check the arp table. > ping -b 192.168.0.255 WARNING: pinging broadcast address PING 192.168.0.255 (192.168.0.255) 56(84) bytes of data. 64 bytes from 192.168.0.246: icmp_seq=0 ttl=64 time=0.018 ms 64 bytes from 192.168.0.101: icmp_seq=0 ttl=64 time=0.217 ms (DUP!) 64 bytes from 192.168.0.246: icmp_seq=1 ttl=64 time=0.023 ms > arp -i eth0 arp -i eth1 Address HWtype HWaddress Flags Mask Iface 192.168.0.103 ether 00:50:FC:00:00:01 C eth1 192.168.0.109 ether 00:13:20:01:01:01 C eth1 If you cannot find your device, it may be configured to […]
Netgem Set-top-box N5000 – Toshiba Places
Mid-september, Netgem showcased their new set-top box at IBC 2010: the Netbox N5000 Internet/TV Adaptor. A modified version of this Set-top box will be used by Toshiba (Toshiba places) and be available for purchase for 99 Euros starting in October 2010 in France and later in 2011 in some other Europeans countries. [ad#Google Adsense – Wide Banner] First let’s have a look at the casing (Not the one used by Toshiba places). The front panel has the Power LED, a USB port and the remote sensor. They’ll either provide Infrared or RF remotes depending on the end customer requirements. The back of the set-top box features TV In/Out, Digital Audio (S/PDIF) output, HDMI output, an Ethernet port and the power jack (+12V). Their product brief also mentions a USB port on the rear as an option and Wifi support (802.11n). The Netbox N5000 hardware is based on Sigma Designs SMP8655 […]
Resources for Telechips TCC890x: TCC8900 & TCC8902
Telechips TCC 890x is now widely used in low cost Android Tablets among other applications (automotive, portable media player..). Here’s the description provided by Telechips: The TCC890x is a system LSI for digital multimedia applications based on ARM1176JZF-S, an ARM’s proprietary RISC CPU core. It is designed for high-end multimedia entertainment devices such as car AVN, portable multimedia player and home entertainment. The TCC890x supports decoding and encoding various types of video and audio standards with software and dedicated hardware codecs including JPEG / MPEG1 / MPEG2 / MPEG4 / H.264 / VC-1 up to Full HD (1080p) and MP3 / WMA / EAAC+ / AC3, etc. In addition, TCC890x offers a hardwired 3D graphic accelerator to enrich next generation GUI and other graphical applications. Although, Telechips claims to support WinCE, Embedded Linux and Android, they now fully focus on Android development giving other OSes a lower priority. However, the development board […]
D-link Boxee Box available for pre-order
D-link Boxee set-top-box is available for pre-order on amazon for 199 USD. It can only be pre-ordered to addresses in the US for now and shipments should start in November. D-Link disclosed that its device is based on an Intel Atom processor CE4100 (Sodaville), not an ARM or MIPS processor as many other STBs do. It is running on embedded Linux. Key features listed by D-Link for the device (beside its weird shape) are basically those of the Boxee media-streaming software on which it’s based: Enjoy thousands of shows available for free from your favorite networks, ready to watch at any time Check-out free movies from the web & watch new releases in stunning HD from premium movie services Play videos, songs, or pictures from your computer or home network Plays any non-DRM video, music, and photos and media from anywhere on the Internet The device features the following input/output and […]
Quick guide to install Samba/CIFS in Linux
You may want to install Samba/CIFS in a Linux host to share files with other Windows computer or to use as a media server with a networked media player. If samba is missing, install it in the host machine (foomachine):
1 |
sudo yum install samba |
Create a new smb user:
1 |
/sbin/smbpasswd -a foouser |
Start / check status / restart samba service:
1 |
/etc/rc.d/init.d/smb start / status / restart |
To make samba service run automatically at startup:
1 |
/sbin/chkconfig smb on |
Type \\foomachine\foouser in Windows Explorer and type the username foouser and the password to access your Linux files. To add other directories to share with samba, edit /etc/samba/smb.conf Resource: http://www.cpqlinux.com/samba.html Jean-Luc Aufranc (CNXSoft)Jean-Luc started CNX Software in 2010 as a part-time endeavor, before quitting his job as a software engineering manager, and starting to write daily news, and reviews full time later in 2011. www.cnx-software.com
Embedded Software Books
I’m often asked what useful books software engineers should read when they start to work on embedded systems. So here’s a list of books I would recommend as starters. First, nowadays many embedded systems are written in C (although lower end systems using 8-bit MCU are still likely to be written in Assembler), so software engineers had better make themselves very familiar with C/C++ and GNU tools (gcc, libtool. automake…) with a focus on embedded systems (e.g. interrupts handling, real-time capabilities, volatile variables, processes and threads’ stack handling, , cross compilers…). Programming Embedded Systems: With C and GNU Development Tools, 2nd Edition is just the right book for that purpose. It deals with embedded Linux and eCos and provides useful examples. You may also read part of it online Once you start developing embedded systems you are likely to write device drivers at some points. Linux Device Drivers, 3rd Edition […]
Enabling swap in embedded systems
If your embedded system running Linux does not have enough memory, you can enable swap to get more memory. However if your platform does not have MMU (Memory Management Unit) as is the case for Sigma Designs EM8620 series, it won’t support swap, so forget it. If your platform does have MMU, as is the case for many newer platforms such as Sigma Designs SMP8630, SMP8640 and SMP8650 series, you can enable swap support. First you’ll have to make sure swap support is enabled in your kernel:
1 2 |
CONFIG_SWAP=y CONFIG_SWAP_PREFETCH=y |
and swapon/swapoff is enabled in busybox. So for example if you have an IDE harddisk with the second partition configured as swap. (Use fdisk to create a partition and mkswap /dev/hda2 to initialize the partition), you can enable the swap as follows:
1 |
swapon /dev/hda2 |
If you get out-of-memory killer kernel error, you can change the “swapiness” to avoid oom-killer to kick in.
1 |
echo 0 > /proc/sys/vm/mapped |
[…]
How to do a framebuffer screenshot
I’ll explain how to do framebuffer screenshots on 16-bit and 32-bit framebuffer. For 16-bit this is fully based on http://docs.blackfin.uclinux.org/doku.php?id=framebuffer Capturing screenshots Whatever the bit-depth of your framebuffer, the first step is to capture the frambuffer raw data on the board:
1 |
cat /dev/fb0 > screen.raw |
Now the you need to take the raw image, and convert it to a standard image format. This step depends on what type of display is there Converting 16-bit Framebuffer screenshot (RGB565) into png To convert the raw rgb data extracted from /dev/fb0, use iraw2png perl script
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 |
#!/usr/bin/perl -w $w = shift || 240; $h = shift || 320; $pixels = $w * $h; open OUT, "|pnmtopng" or die "Can't pipe pnmtopng: $!\n"; printf OUT "P6%d %d\n255\n", $w, $h; while ((read STDIN, $raw, 2) and $pixels--) { $short = unpack('S', $raw); print OUT pack("C3", ($short & 0xf800) >> 8, ($short & 0x7e0) >> 3, ($short & 0x1f) << 3); } close OUT; |
To do the conversion, type the following command in the host:
1 |
./iraw2png 640 480 < screen.raw > screen.png |
where 640 and 480 are respectively the width and height of your framebuffer. This has been tried on a 16-bit framebuffer on EM8620 series. Converting 32-bit Framebuffer screenshot (ARGB, RGBA, BGRA…) into png The solution proposed here is not as neat as the blackfin’s solution for 16-bit framebuffer, […]