Difference between revisions of "What can I do with BASE0010"

From IGEP - ISEE Wiki

Jump to: navigation, search
m (Redirected old article)
 
(14 intermediate revisions by 2 users not shown)
Line 1: Line 1:
= How to enable BASE0010 support =
+
#REDIRECT:[[Category:BASE0010]]
 +
__NOTOC__
  
The required [[How do I edit my kernel command line | kernel command line]] option here is
+
If you have '''successfully completed the [[Getting_Started_with_BASE0010_board|getting started guide]]''' for BASE0010, you can follow this first introduction about what can you do with this board:
  
buddy=base0010
+
{{Navigation/IGEP Technology Guides|device=BASE0010}}
  
= How to get DVI output =
+
= How to get DVI output =
  
By default the DVI is outputs 1024 x 768 @ 60Hz, so if your monitor support this resolution you'll see the desktop when board is up.
+
By default the DVI is outputs 1024 x 768 @ 60Hz, so if your monitor support this resolution you'll see the desktop when board is up.  
  
Unfortunately the capability to automatically set the display resolution to match your monitor isn't yet available. The simplest method to customize the display resolution is to set it using [[How do I edit my kernel command line | kernel command line]
+
Unfortunately the capability to automatically set the display resolution to match your monitor isn't yet available. The simplest method to customize the display resolution is to set it using [[How do I edit my kernel command line | kernel command line]  
  
The required arguments use the following pattern: omapfb.mode=<display>:<resolutionMR-bpp@refresh> omapdss.def_disp=<display> where:
+
The required arguments use the following pattern: omapfb.mode=&lt;display&gt;:&lt;resolutionMR-bpp@refresh&gt; omapdss.def_disp=&lt;display&gt; where:  
  
For example:
+
For example:  
  
 
  omapdss.def_disp=dvi omapfb.mode=1024x768MR-16@60
 
  omapdss.def_disp=dvi omapfb.mode=1024x768MR-16@60
 
  omapdss.def_disp=dvi omapfb.mode=hd720-16@60
 
  omapdss.def_disp=dvi omapfb.mode=hd720-16@60
  
See also: [[How do I edit my kernel command line]].
+
See also: [[How do I edit my kernel command line]].  
  
= How to configure ethernet =
+
= How to configure ethernet =
  
There are two Ethernets on the BASE0010 board which can be used, for example if your access to the internet is via a route you can configure one of them with following command:
+
There are two Ethernets on the BASE0010 board which can be used, for example if your access to the internet is via a route you can configure one of them with following command:  
  
 
  ifconfig eth0 up
 
  ifconfig eth0 up
 
  udhcpc -i eth0
 
  udhcpc -i eth0
  
For second interface just change the eth0 device for eth1
+
For second interface just change the eth0 device for eth1  
  
= How to get sound out (audio out) =
+
= How to get sound out (audio out) =
  
The amplifiers for the headset output are disabled by default, so the first thing you'll do is enable these amplifiers with
+
The amplifiers for the headset output are disabled by default, so the first thing you'll do is enable these amplifiers with  
  
 
  amixer set -D hw:0 'Headset' 0dB
 
  amixer set -D hw:0 'Headset' 0dB
Line 37: Line 38:
 
  amixer set -D hw:0 'HeadsetR Mixer AudioR2' on
 
  amixer set -D hw:0 'HeadsetR Mixer AudioR2' on
  
Then you can easily play a wav sound, for example
+
Then you can easily play a wav sound, for example  
  
 
  aplay sample.wav
 
  aplay sample.wav
  
= How to get sound in (audio in) =
+
= How to get sound in (audio in) =
  
You can record audio in with
+
You can record audio in with  
  
 
  arecord -t wav -c 2 -r 44100 -f S16_LE -v audio-in.wav
 
  arecord -t wav -c 2 -r 44100 -f S16_LE -v audio-in.wav
  
Following output is expected on console
+
Following output is expected on console  
  
  Recording WAVE 'audio-in.wav' : Signed 16 bit Little Endian, Rate 44100 Hz, Stereo
+
  Recording WAVE 'audio-in.wav'&nbsp;: Signed 16 bit Little Endian, Rate 44100 Hz, Stereo
 
  Plug PCM: Hardware PCM card 0 'TWL4030' device 0 subdevice 0
 
  Plug PCM: Hardware PCM card 0 'TWL4030' device 0 subdevice 0
 
  Its setup is:
 
  Its setup is:
  stream       : CAPTURE
+
stream     &nbsp;: CAPTURE
  access       : RW_INTERLEAVED
+
access     &nbsp;: RW_INTERLEAVED
  format       : S16_LE
+
format     &nbsp;: S16_LE
   subformat    : STD
+
subformat   &nbsp;: STD
  channels     : 2
+
channels   &nbsp;: 2
  rate         : 44100
+
rate       &nbsp;: 44100
  exact rate   : 44100 (44100/1)
+
exact rate &nbsp;: 44100 (44100/1)
  msbits       : 16
+
msbits     &nbsp;: 16
  buffer_size : 32768
+
buffer_size &nbsp;: 32768
  period_size : 2048
+
period_size &nbsp;: 2048
  period_time : 46439
+
period_time &nbsp;: 46439
   tick_time    : 7812
+
tick_time   &nbsp;: 7812
  tstamp_mode : NONE
+
tstamp_mode &nbsp;: NONE
  period_step : 1
+
period_step &nbsp;: 1
   sleep_min    : 0
+
sleep_min   &nbsp;: 0
   avail_min    : 2048
+
avail_min   &nbsp;: 2048
  xfer_align   : 2048
+
xfer_align &nbsp;: 2048
  start_threshold : 1
+
start_threshold &nbsp;: 1
  stop_threshold   : 32768
+
stop_threshold &nbsp;: 32768
  silence_threshold: 0
+
silence_threshold: 0
  silence_size : 0
+
silence_size&nbsp;: 0
  boundary     : 1073741824
+
boundary   &nbsp;: 1073741824
  
When ever you think you want to stop just press CONTRL+C
+
When ever you think you want to stop just press CONTRL+C  
  
= How to get user button =
+
= How to get user button =
  
There is one button on the BASE0010 board which can be used by the software for user interaction.
+
There is one button on the BASE0010 board which can be used by the software for user interaction.  
  
The kernel driver creates a device in /dev/input directory. To access to the button you will use the Linux Input Device subsystem. In Particular evdev, which is a generic input event interface. It passes the events generated in the kernel straight to the program, with timestamps. The event codes are the same on all architectures and are hardware independent.
+
The kernel driver creates a device in /dev/input directory. To access to the button you will use the Linux Input Device subsystem. In Particular evdev, which is a generic input event interface. It passes the events generated in the kernel straight to the program, with timestamps. The event codes are the same on all architectures and are hardware independent.  
  
For example, the test program ([http://beagleboard.googlecode.com/files/evtest.c evtest.c]) listens on the /dev/input/event0 file descriptor, trying to read any events
+
For example, the test program evtest ([http://beagleboard.googlecode.com/files/evtest.c evtest.c]) listens on the /dev/input/event0 file descriptor, trying to read any events  
  
 
  evtest /dev/input/event0
 
  evtest /dev/input/event0
Line 91: Line 92:
 
  Input device name: "gpio-keys"
 
  Input device name: "gpio-keys"
 
  Supported events:
 
  Supported events:
  Event type 0 (Sync)
+
  Event type 0 (Sync)
  Event type 1 (Key)
+
  Event type 1 (Key)
    Event code 276 (ExtraBtn)
+
    Event code 276 (ExtraBtn)
 
  Testing ... (interrupt to exit)
 
  Testing ... (interrupt to exit)
  
If you'll press the button you'll see
+
If you'll press the button you'll see  
  
 
  Event: time 8354.388305, type 1 (Key), code 276 (ExtraBtn), value 0
 
  Event: time 8354.388305, type 1 (Key), code 276 (ExtraBtn), value 0
Line 103: Line 104:
 
  Event: time 8354.573364, -------------- Report Sync ------------
 
  Event: time 8354.573364, -------------- Report Sync ------------
  
For more information please read:
+
For more information please read:  
# linux-2.6/Documentation/input/input.txt
+
 
# linux-2.6/Documentation/input/input-programming.txt
+
#linux-2.6/Documentation/input/input.txt  
 +
#linux-2.6/Documentation/input/input-programming.txt
 +
 
 +
 
 +
{{Navigation/IGEP Technology Guides/What can I do/Ending|device=BASE0010}}
 +
 
 +
[[Category:Work in progress]]
 +
[[Category:Tutorials]]

Latest revision as of 15:21, 18 January 2013

Redirect to:


If you have successfully completed the getting started guide for BASE0010, you can follow this first introduction about what can you do with this board:

[[Image:{{{Image}}}|100px|center|link={{{Community_MainPage}}}]]

{{{Name}}}

  • [{{{ISEE_MainPage}}} Product Page]
  • [{{{ISEE_Hardware}}} Hardware manual]
  • {{{Name}}} guides:
  1. [[{{{Community_Guides_1}}}|Getting started]]
  2. [[{{{Community_Guides_2}}}|What can I do with {{{Name}}}]]
  3. Start developing

How to get DVI output

By default the DVI is outputs 1024 x 768 @ 60Hz, so if your monitor support this resolution you'll see the desktop when board is up.

Unfortunately the capability to automatically set the display resolution to match your monitor isn't yet available. The simplest method to customize the display resolution is to set it using [[How do I edit my kernel command line | kernel command line]

The required arguments use the following pattern: omapfb.mode=<display>:<resolutionMR-bpp@refresh> omapdss.def_disp=<display> where:

For example:

omapdss.def_disp=dvi omapfb.mode=1024x768MR-16@60
omapdss.def_disp=dvi omapfb.mode=hd720-16@60

See also: How do I edit my kernel command line.

How to configure ethernet

There are two Ethernets on the BASE0010 board which can be used, for example if your access to the internet is via a route you can configure one of them with following command:

ifconfig eth0 up
udhcpc -i eth0

For second interface just change the eth0 device for eth1

How to get sound out (audio out)

The amplifiers for the headset output are disabled by default, so the first thing you'll do is enable these amplifiers with

amixer set -D hw:0 'Headset' 0dB
amixer set -D hw:0 'HeadsetL Mixer AudioL2' on
amixer set -D hw:0 'HeadsetR Mixer AudioR2' on

Then you can easily play a wav sound, for example

aplay sample.wav

How to get sound in (audio in)

You can record audio in with

arecord -t wav -c 2 -r 44100 -f S16_LE -v audio-in.wav

Following output is expected on console

Recording WAVE 'audio-in.wav' : Signed 16 bit Little Endian, Rate 44100 Hz, Stereo
Plug PCM: Hardware PCM card 0 'TWL4030' device 0 subdevice 0
Its setup is:
stream       : CAPTURE
access       : RW_INTERLEAVED
format       : S16_LE
subformat    : STD
channels     : 2
rate         : 44100
exact rate   : 44100 (44100/1)
msbits       : 16
buffer_size  : 32768
period_size  : 2048
period_time  : 46439
tick_time    : 7812
tstamp_mode  : NONE
period_step  : 1
sleep_min    : 0
avail_min    : 2048
xfer_align   : 2048
start_threshold  : 1
stop_threshold   : 32768
silence_threshold: 0
silence_size : 0
boundary     : 1073741824

When ever you think you want to stop just press CONTRL+C

How to get user button

There is one button on the BASE0010 board which can be used by the software for user interaction.

The kernel driver creates a device in /dev/input directory. To access to the button you will use the Linux Input Device subsystem. In Particular evdev, which is a generic input event interface. It passes the events generated in the kernel straight to the program, with timestamps. The event codes are the same on all architectures and are hardware independent.

For example, the test program evtest (evtest.c) listens on the /dev/input/event0 file descriptor, trying to read any events

evtest /dev/input/event0
Input driver version is 1.0.0
Input device ID: bus 0x19 vendor 0x1 product 0x1 version 0x100
Input device name: "gpio-keys"
Supported events:
 Event type 0 (Sync)
 Event type 1 (Key)
   Event code 276 (ExtraBtn)
Testing ... (interrupt to exit)

If you'll press the button you'll see

Event: time 8354.388305, type 1 (Key), code 276 (ExtraBtn), value 0
Event: time 8354.388335, -------------- Report Sync ------------
Event: time 8354.573364, type 1 (Key), code 276 (ExtraBtn), value 1
Event: time 8354.573364, -------------- Report Sync ------------

For more information please read:

  1. linux-2.6/Documentation/input/input.txt
  2. linux-2.6/Documentation/input/input-programming.txt




You have successfully completed this chapter of the guide.


Continue this tutorial guide: 3/3 - Start developing under IGEP Technology
Igep forum.png If you have any question, don't ask to ask at the IGEP Community Forum or the IGEP Community Chat Irc.png