PLEASE NOTE: This article is obsolete or related to a discontinued product.

HOW TOs

Tips and tricks to help you to use the FOX board in the every day life

How to change the IP address

The default IP address of the FOX board is 192.168.0.90. To change it on the fly type:
# ifconfig eth0 x.x.x.x
Where x.x.x.x is the new IP address.

Note: In this way the new address will remain changed up to the new reboot of the board. To change it permanently you need to modify the file /etc/conf.d/net.eth0. In the last 4 rows of this file are specified the network parameters used at startup:

IP="192.168.0.90"
NETMASK="255.255.255.0"
BROADCAST="192.168.0.255"
GATEWAY="192.168.0.1"

Once changed the IP address the board could became unreachable since the ARP cache inside the PC used for accessing the board has stored the old address of the FOX board. To avoid it just type the arp -d from a prompt window on your PC.


How to change the MAC address

The factory default MAC address of the FOX Board Ethernet port is:
00:40:8C:xx:xx:xx
Where:
  • xx:xx:xx is a changeble part configured by Acme Systems during the board factory testing and
  • 00:40:8C is a fixed part configured by Axis during the CPU factory testing.
To change the last three double digits you have to reflash the board using the -F option (see How to reflash a FOX Board) then set the MAC address from the FOX Board command line (not in the SDK but on a FOX Board console session or telnet or ssh) with the command:
bootblocktool -a SERNO 00408Cxxxxxx
Where "xxxxxx" is the new hexadecimal number you have selected in the range of 000000 to FFFFFF. For example:
bootblocktool -a SERNO 00408C000001
After a complete reflashing with -F option the default MAC address is 00408CCD0000. In this case the red led DL1 flash to indicate that you have to change this address.

Once changed the MAC address the board could became unreachable since the ARP cache inside the PC used for accessing the board has stored the old address of the FOX board. To avoid it just type the arp -d from a prompt window on your PC.


How to set the DNS Server

By default the FOX Boards are delivered without any specified DNS server IP. The DNS Server IP should be specified in the file /etc/resolv.conf adding the following line:
# nameserver x.x.x.x
Anyway this file will be overwritten at startup with the contents of the file /etc/resolv.conf.def so you have to add the same line also to this file otherwise you will lost the DNS Server IP at the first restart.

How to revert to the factory default settings

If you make errors during file manipulation of the FOX filesystem and get stuck with the board not responding anymore or not booting at all you can restore the original factory settings switching off the board and then switching it on during pressing the SW1 switch for approximately ten seconds.

Switch then the Fox off again and then on without pressing the switch. You will be reverted to the original condition of the read/write filesystem.

You will loose all your modifications done on the files in the read/write directory /etc that will be reverted to the factory default. To revert deeper modifications you will have to reflash the Fox board with the SDK environment.

This procedure doesn't work if you got stuck during the flashing process and damage the kernel read only partition flash contents. In this case you have to use the LAN flashing procedure to recover the board: @h4='703'


How to turn off the flashing red led DL1

When you reprogram the all flash memory of the FOX Board with the -F option (see How to reflash a FOX Board) the factory default MAC address configured by Axis is 00408CCD0000. In this situation when the FOX Board starts the red led DL1 blinks to indicate that you have to change this number. Only the last 6 digit can be changed using this command:
bootblocktool -a SERNO 00408Cxxxxxx
Where "xxxxxx" is the new hexadecimal number you have selected in the range of 000000 to FFFFFF. For example:
bootblocktool -a SERNO 00408C000001
After a reboot the red led DL1 will not blink anymore.

To see the new MAC address type:

# ifconfig eth0
eth0      Link encap:Ethernet  HWaddr 00:40:8C:00:00:01
          inet addr:192.168.0.90  Bcast:192.168.0.255  Mask:255.255.255.0
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:47 errors:0 dropped:0 overruns:0 frame:0
          TX packets:36 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:2837 (2.7 KiB)  TX bytes:2069 (2.0 KiB)
          Interrupt:17 DMA chan:1

Once changed the IP address the board could became unreachable since the ARP cache inside the PC used for accessing the board has stored the old address of the FOX board. To avoid it just type the arp -d from a prompt window on your PC.


How to read the system messages

All the system log messages generated from the kernel or from other applications that use syslog are sent to the file:
/var/log/messages
To see its content type:
# cat /var/log/messages
or
# dmesg /var/log/messages
To see it continuously while you are using the system, open a new telnet session and type:
# tail -f /var/log/messages

How to restart the Web server

After any change to the Web server configuration file /etc/httpd/conf.d/boa.conf you have to restart the Web server to make the changes active.

To do this type:

# /etc/init.d/httpd restart
Alternatively it's possible to stop and then start again the web server with the following commands:
# /etc/init.d/httpd stop
# /etc/init.d/httpd start
WEB access

How to set the system date

When the FOX Board starts without the RTC circuitry its system date is set at 1 January 1970.
To manually change the system date use this command:
# date MMDDHHMMYYYY

where MM is the month (01-12), DD is the day (01-31), HH is the hour (00-23), MM is the minute (00-59), YYYY is the year (i.e. 2005). By example to set 11:26 of December 13th 2005 type:

# date 121311262005
Tue Dec 13 11:26:00 UTC 2005
System date is usually based on periodic hardware interrupts. The kernel maintains the current time and advances it at every interrupt. The alarm clock functionality, however, relies on the interrupts and cannot provide a higher accuracy than the interrupt frequency, which is 10ms. (Clock Granularity).

How to set the Real Time Clock date

When the FOX Board is connected to a RTC circuitry and the RTC support is enabled it read the clock from the RTC chip at startup.
...
 ds1302: RTC found.
 ds1302: SDA, SCL, RST on PB0, PB1, GENIO2
 rtc_time    : 16:51:18
 rtc_date    : 2007-07-15
 ...
To change the date inside the RTC chip set the system date then type:
# hwclock -w
To read the RTC date type:
# hwclock -r

How to activate the DHCP client

If in your LAN you have a DHCP server, it is possible to setup your FOX board to be able to get an automatic LAN configuration from this DHCP server at startup modifying the file: /etc/conf.d/net.eth0.

In particular you have to change the line:

BOOTPROTO="none"
in:
BOOTPROTO="dhcp"
Once acquired the dynamic IP from the DHCP server it is possible to verify on the DHCP server web page which is the IP address obtained from the FOX board. Check the SW releases

To view the version of the Linux Kernel on your FOX Board type:

# uname -a
Linux axis 2.4.31 #9 Wed Jan 18 10:03:57 CET 2006 cris unknown
To know more about the uname options type:
# uname --help
BusyBox v1.00 (2005.11.04-15:07+0000) multi-call binary

Usage: uname [OPTION]...
Print certain system information. With no OPTION, same as -s.
Options:
      -a      print all information
      -m      the machine (hardware) type
      -n      print the machine's network node hostname
      -r      print the operating system release
      -s      print the operating system name
      -p      print the host processor type
      -v      print the operating system version
The command cat/etc/release instead shows the release number of the SDK used to generate your FOX Board firmware:
# cat /etc/release
JFFSID="2.01"

How to start a program at FOX boot time

If you need to startup a script after the bootstrap simple save it inside the folder /etc/init.d/boottime.

How to compile against uClibc with the SDK 2.01

The default configuration for the Fox when installing SDK 2.01 is with kernel 2.4.31 and glibc Standard C library. To be able to compile application programs against uClibc library you have first to switch to this library also for the kernel and install the necessary packages inside the SDK 2.01.

To change the Standard C library in your SDK environment follow these steps: On a session in your devboard-R2_01 directory do:

make menuconfig
and in the "General configuration" menu change the "Standard C library" option to uClibc then exit saving the changed option and do:
./configure
to add the necessary packages needed and then:
make
to rebuild the kernel and to make an fimage containing the uClibc library.

Only then you can go on your apps/yourdir and do:

make cris-axis-linux-gnuuclibc
to enable the environment to cross compile correctly against the uClibc library, and then:
make
to effectively compile the application.

Otherwise in the environment there is no reference on the requested uclibc library.

So when you have both environments (for glibc and uClibc) installed you can cross compile correctly.

Remember to compile for the Standard C library installed in your Fox (check your /lib directory inside the Fox to see the installed library) otherwise a message of:

file not found
will be displayed with no other clues around the wrong library linked.

How to disable the console port messages to enable the use of J10 as normal serial port /dev/ttyS0

Disabling all debug, kernel and syslogd messages, coming out from the ttyS0 serial port (physically on the J10 header), you will be able to use the ttyS0 as a general serial port without any disturbing boot and debug messages. To do this you have to change an option in the kernelconfig. (These notes are based on the new Fox Board SDK but can be adapted easily to the old one)

Open the kernel options with the command:

[..../devboard-R2_01]$ make kernelconfig
in the "Hardware setup" submenu, look for "Product debug-port" and set it to "disabled".

Enter in the directory packages/param/syslog/development-R1_1_0/ and edit the file syslog.conf so that the first line is like this:

*.debug;kern.none                                       /dev/null

Only for kernel 2.6

From the os/linux-2.6/arch/cris/arch-v10/boot/compressed/ directory do a:

[....boot/compressed]$ rm misc.o

Only for kernel 2.4

From the /os/linux/arch/cris/boot/compressed/ directory do a:

[....boot/compressed]$ rm misc.o

Now for any kernel version recompile the fimage with the command:

[..../devboard-R2_01]$ make
All boot and kernel messages are now gone. You can use the J10 serial port ttyS0 as a normal serial port without problems.

How to enable the Real Time Clock support

Go inside the SDK root folder (i.e. /devboard-R2_01) and type:
# source init_env
...
# make kernelconfig
Select the item:
Driver for built.in interfaces --->
Then if you have a FOXGM or a FOXZB (or if you have wired the RTC chip as explained on Add a Dallas DS1302 I2C Real Time Clock) configure the RTC section parms like on this screenshot:

Otherwise if you have a FOXCOM or a SX18 carrier board configure the RTC section parms like on this screenshot:

Exit and save the configuration then type:

# make
...
to generate a new image to flash on the FOX Board (see How to reflash a FOX Board>

How to enable the MMC support

Go inside the SDK root folder (i.e. /devboard-R2_01) and type:
# source init_env
...
# make menuconfig
Select the item:
Driver settings --->
The configure the RTC section parms like on this screenshot:

Exit and save the configuration then type:

# ./configure
...
# make
...
to generate a new image to flash on the FOX Board (see How to reflash a FOX Board>

Troubleshootings

This section covers some of the issues that can occur with your FOX Board, and provides all the troubleshooting steps you need to resolve them by yourself

FOX Board leaflet errata corrige

There are some errors on the leaflet recently released with the FOX Board. The errors concern the four jumpers near the white J2 power connector and the defaulf IP address.
Read more...

The Telit modem doesn't turn on on FOXGM

When you are using the FOXGM board, with some factory default images it is impossible to turn on the Telit Modem setting the PB7 line when PB7 line is defined as input by default at startup. The same is for the PB6 line that is used to reset the modem.

There are two solutions:

  1. Set PB6 and PB7 as output by a C program. This program will work on a factory default image. The code to use is:
    #include "linux/gpio_syscalls.h"
    
    int main(void) {
      gpiosetdir(PORTB,DIROUT,PB6);
      gpiosetdir(PORTB,DIROUT,PB7);
      gpioclearbits(PORTB,PB6);
      gpioclearbits(PORTB,PB7);
      return 0;
    }
    
    You can compile it by Webcompiler.

  2. Change the setting for PB6 and PB7 on the SDK.
    • Go to the SDK root directory.
    • Type make kernelconfig
    • Select Hardware Setup
    • Go to R_PORT_PB_CONFIG and set it, if necessary, to 0x00
    • Go to R_PORT_PB_DIR and set it, if necessary, to 0xce (bit=0 means input; bit=1 means output initial direction at boot)
    • Go to R_PORT_PB_DATA and set it, if necessary, to 0x03 (bit=1 means high initial state for the bit)
    • Select Driver for built-in interfaces
    • Go to PB user changeable dir mask and set it, if necessary, to 0xFF (bit=1 means user changeable direction of the pin)
    • Go to PB user changeable bit mask and set it, if necessary, to 0xFF (bit=1 means user changeable logic state of of the pin)
    • Save and exit.
    • Generate the new image with make
    • Flash the new image on the FOX Board (see How to reflash a FOX Board)

Make message: Makefile:23: *** missing separator. Stop.

If you get this message during the building of the SDK you should check if your Linux distribution /bin/sh is linked to dash instead of bash as in Ubuntu. You should change to bash and the problem should disappear.

Image this far exceeds alignment offset - it is too large!

The fimage you have generated is too large. See on How to reflash a FOX Board how to change the flash memory partition.

When compiling an image with the old Axis SDK 2.01, the new FOX Board LX doesn't work

Change the timing configuration word for the SDRAM chip named CONFIG_ETRAX_DEF_R_SDRAM_TIMING inside the file kernelconfig or kernelconfig-2.6.
  • For the red FOX "classic" the value is CONFIG_ETRAX_DEF_R_SDRAM_TIMING=0x80608002
  • For the new FOX Board LX the value is CONFIG_ETRAX_DEF_R_SDRAM_TIMING=0x80008002

During SDK installation the make process stops and shows "make[4]: yacc: Command not found"

You have to install Bison.
On the Linux distributions derivated from Debian type:
# apt-get install bison

During SDK installation the make process not found the idea.h and engine.h files

Create this link:
cd devboard-R2_01/apps/crypto/openssl/openssl/include/openssl/
ln -s ../../crypto/idea/idea.h
ln -s ../../crypto/engine/engine.h

After Webcompiler has compiled a source (i.e. hello.c) I obtain this error: "/bin/sh: ./hello.out: not found"

This problem happen when you link your code to glibc library instead of uClibc or viceversa.

Real Time Clock doesn't work


Missing microwindows-0.91 for NANOX

If you are unable to install the microwindows directory under apps download this file: microwindows-0.91.tar.gz inside devboard-R2_01/apps and decompress it with the command:

tar xvfz microwindows-0.91.tar.gz

Frequently Asked Questions

This page contains answers to commonly-asked questions about the FOX Board and other Acme Systems products

What is the acceptable range of voltage on the 5.00 volt input on J2 or J14 ?

The maximum input voltage specification for the Fox should be under +5.5 Volt. Infact, even if the processor has its regulator onboard that is able to accept up to 8 Volts and deliver the +3.3 Volt regulated there is another component: LM3526 that has a limitation on its maximum voltage input at +5.5 Volts. On the matter of regulation: it affects primarily the behaviour of the USB devices connected to the board since the power supply of +5Volt is passed to them. If it is poorly regulated it could compromise the correct working of the peripherals. We found some USB sticks that require a very well regulated 5.00 volts for working. Some times even 4.75 is too low. The board alone for running Linux withour USB peripherals connected can accept 4.75 Volts.

Is it possible to power a FOX board with the 5V power coming from a PC USB ?

Yes, you can safely attach the +5V coming from a USB from a PC. Those ports are able to deliver up to 500mA on the +5V. It is not possible to connect the power supply of +5V at the Fox USB port. You have to connect the +5V to the proper pin of J2 or J6 or J7. Of course I am speaking for the board alone. Since the Fox needs approx. 280 mA from the +5V no much current is left for any dongle USB to be connected at the Fox USB ports.

Video how tos

How to mount the FOX Board inside the FOX Case

This video shows how to mount the FOX Board inside a FOX Case




Insert Lego (c) blocks on the FOX Case

This video shows the Lego's blocks placements available on the FOX Board.




How to mount the FOX Board inside the TUX Case

TUX Case is a TUX-shaped plastic enclosure that is designed to house the Acme Systems tiny Embedded Linux FOX Board LX and runs a fully Linux OS inside its belly. This video shows how to mount the FOX Board a TUX Case.