
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">



<html xmlns="http://www.w3.org/1999/xhtml">
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    
<title>RED Brick – Tinkerforge</title>

<!--<link type="text/css" rel="stylesheet" href="http://www.tinkerforge.com/static/base_tf.css" />-->
<link type="text/css" rel="stylesheet" href="http://www.tinkerforge.com/static/jquery.lightbox-0.5.css" />
<meta name="keywords" content="Tinkerforge, Open Source Hardware, Bricks, Bricklets, USB Controllable, USB Sensing, USB Controlling" />
<meta name="description" content="Easy-to-use open source hardware. Control motors and sense the environment over USB, Ethernet or Wi-Fi/WLAN with C/C++, C#, Delphi/Lazarus, Java, JavaScript, LabVIEW, Mathematica, MATLAB/Octave, Perl, PHP, Python, Ruby, Shell, Visual Basic .NET or directly over TCP/IP." />
<meta name="copyright" content="Tinkerforge GmbH" />
<!--<script type="text/javascript">document.write('<style>.noscript { display: none; }</style>');</script>-->


    
    <link rel="stylesheet" href="../../_static/documentation_tf.css" type="text/css" />
    <link rel="stylesheet" href="../../_static/pygments.css" type="text/css" />
    
    <script type="text/javascript">
      var DOCUMENTATION_OPTIONS = {
        URL_ROOT:    '../../',
        VERSION:     '1.0',
        COLLAPSE_INDEX: false,
        FILE_SUFFIX: '.html',
        HAS_SOURCE:  true
      };
    </script>
    <script type="text/javascript" src="../../_static/jquery.js"></script>
    <script type="text/javascript" src="../../_static/underscore.js"></script>
    <script type="text/javascript" src="../../_static/doctools.js"></script>
    <link rel="top" title="Tinkerforge" href="../../index.html" />
    <link rel="up" title="Bricks" href="Bricks.html" />
    <link rel="next" title="RED Brick - Program Tab" href="RED_Brick_Program_Tab.html" />
    <link rel="prev" title="Master Brick" href="Master_Brick.html" />

<script type="text/javascript" src="http://www.tinkerforge.com/static/jquery.lightbox-0.5.js"></script>
<script type="text/javascript">$(function() { $('#gallery a').lightBox(); });</script>
<script type="text/javascript">$(function() { $(".sphinxsidebarwrapper").filter(function() { return $.trim($(this).text()).length == 0; }).parent().hide(); });</script>


  </head>
  <body>
<div id="wrapper">
	<div id="tfcontent">
		<div class="boxContent3">


<div class="toctree">
<ul class="current">
<li class="toctree-l1"><a class="reference internal" href="../../Getting_Started.html">Getting Started</a><ul>
<li class="toctree-l2"><a class="reference internal" href="../../Primer.html">Primer</a></li>
<li class="toctree-l2"><a class="reference internal" href="../../Tutorials/Tutorials.html">Tutorials</a></li>
<li class="toctree-l2"><a class="reference internal" href="../../FAQ.html">FAQ</a></li>
</ul>
</li>
<li class="toctree-l1 current"><a class="reference internal" href="../Hardware.html">Hardware</a><ul class="current">
<li class="toctree-l2 current"><a class="reference internal" href="Bricks.html">Bricks</a><ul class="current">
<li class="toctree-l3"><a class="reference internal" href="DC_Brick.html">DC Brick</a></li>
<li class="toctree-l3"><a class="reference internal" href="Debug_Brick.html">Debug Brick</a></li>
<li class="toctree-l3"><a class="reference internal" href="IMU_Brick.html">IMU Brick</a></li>
<li class="toctree-l3"><a class="reference internal" href="Master_Brick.html">Master Brick</a></li>
<li class="toctree-l3 current"><a class="current reference internal" href="">RED Brick</a><ul>
<li class="toctree-l4"><a class="reference internal" href="#features">Features</a></li>
<li class="toctree-l4"><a class="reference internal" href="#description">Description</a></li>
<li class="toctree-l4"><a class="reference internal" href="#technical-specifications">Technical Specifications</a></li>
<li class="toctree-l4"><a class="reference internal" href="#resources">Resources</a></li>
<li class="toctree-l4"><a class="reference internal" href="#first-steps-test-your-red-brick">First Steps / Test your RED Brick</a></li>
<li class="toctree-l4"><a class="reference internal" href="#brick-viewer">Brick Viewer</a><ul>
<li class="toctree-l5"><a class="reference internal" href="#overview-tab-status-information">Overview Tab (Status Information)</a></li>
<li class="toctree-l5"><a class="reference internal" href="#settings-tab">Settings Tab</a><ul>
<li class="toctree-l6"><a class="reference internal" href="#network">Network</a></li>
<li class="toctree-l6"><a class="reference internal" href="#wireless-access-point">Wireless Access Point</a></li>
<li class="toctree-l6"><a class="reference internal" href="#server-monitoring">Server Monitoring</a></li>
<li class="toctree-l6"><a class="reference internal" href="#openhab">openHAB</a></li>
<li class="toctree-l6"><a class="reference internal" href="#brick-daemon">Brick Daemon</a></li>
<li class="toctree-l6"><a class="reference internal" href="#date-time">Date/Time</a></li>
<li class="toctree-l6"><a class="reference internal" href="#file-system">File System</a></li>
<li class="toctree-l6"><a class="reference internal" href="#services">Services</a></li>
</ul>
</li>
<li class="toctree-l5"><a class="reference internal" href="#program-tab-upload-and-execution">Program Tab (Upload and Execution)</a><ul>
<li class="toctree-l6"><a class="reference internal" href="RED_Brick_Program_Tab.html">Wizard Steps</a></li>
</ul>
</li>
<li class="toctree-l5"><a class="reference internal" href="#console-tab-remote-access">Console Tab (Remote Access)</a></li>
<li class="toctree-l5"><a class="reference internal" href="#versions-tab-daemon-bindings-and-libraries">Versions Tab (Daemon, Bindings and Libraries)</a></li>
<li class="toctree-l5"><a class="reference internal" href="#extensions-tab-configure-manage">Extensions Tab (Configure, Manage)</a><ul>
<li class="toctree-l6"><a class="reference internal" href="#ethernet-extension">Ethernet Extension</a></li>
<li class="toctree-l6"><a class="reference internal" href="#rs485-extension">RS485 Extension</a></li>
</ul>
</li>
<li class="toctree-l5"><a class="reference internal" href="#import-export">Import/Export</a><ul>
<li class="toctree-l6"><a class="reference internal" href="#system-logs">System Logs</a></li>
<li class="toctree-l6"><a class="reference internal" href="#import">Import</a></li>
<li class="toctree-l6"><a class="reference internal" href="#export">Export</a></li>
</ul>
</li>
</ul>
</li>
<li class="toctree-l4"><a class="reference internal" href="#red-brick-web-interface">RED Brick Web Interface</a><ul>
<li class="toctree-l5"><a class="reference internal" href="#html-javascript">HTML/JavaScript</a></li>
<li class="toctree-l5"><a class="reference internal" href="#python">Python</a></li>
<li class="toctree-l5"><a class="reference internal" href="#php">PHP</a></li>
</ul>
</li>
<li class="toctree-l4"><a class="reference internal" href="#red-brick-software-image">RED Brick Software Image</a><ul>
<li class="toctree-l5"><a class="reference internal" href="RED_Brick_Installed_Versions.html">Installed Library Versions</a></li>
<li class="toctree-l5"><a class="reference internal" href="#build-your-own-image">Build your own Image</a></li>
<li class="toctree-l5"><a class="reference internal" href="#copy-image-to-sd-card">Copy Image to SD Card</a><ul>
<li class="toctree-l6"><a class="reference internal" href="#windows">Windows</a></li>
<li class="toctree-l6"><a class="reference internal" href="#linux">Linux</a></li>
<li class="toctree-l6"><a class="reference internal" href="#mac-os-x">Mac OS X</a></li>
</ul>
</li>
<li class="toctree-l5"><a class="reference internal" href="#change-default-password">Change Default Password</a></li>
<li class="toctree-l5"><a class="reference internal" href="#change-hdmi-display-resolution">Change HDMI Display Resolution</a><ul>
<li class="toctree-l6"><a class="reference internal" href="#using-tf-set-resolution">Using tf-set-resolution</a></li>
</ul>
</li>
</ul>
</li>
<li class="toctree-l4"><a class="reference internal" href="#hardware-description">Hardware Description</a><ul>
<li class="toctree-l5"><a class="reference internal" href="#power-button">Power Button</a></li>
<li class="toctree-l5"><a class="reference internal" href="#leds">LEDs</a></li>
<li class="toctree-l5"><a class="reference internal" href="#micro-sd-card-slot">Micro-SD-Card Slot</a></li>
<li class="toctree-l5"><a class="reference internal" href="#usb-2-0-host">USB 2.0 Host</a></li>
<li class="toctree-l5"><a class="reference internal" href="#mini-usb">Mini-USB</a></li>
<li class="toctree-l5"><a class="reference internal" href="#micro-hdmi">Micro-HDMI</a></li>
<li class="toctree-l5"><a class="reference internal" href="#brick-stack-connector">Brick Stack Connector</a></li>
<li class="toctree-l5"><a class="reference internal" href="#gpio-header">GPIO Header</a></li>
<li class="toctree-l5"><a class="reference internal" href="#power-supply">Power Supply</a></li>
</ul>
</li>
<li class="toctree-l4"><a class="reference internal" href="#faq">FAQ</a></li>
<li class="toctree-l4"><a class="reference internal" href="#known-issues">Known Issues</a></li>
<li class="toctree-l4"><a class="reference internal" href="#history">History</a></li>
<li class="toctree-l4"><a class="reference internal" href="#programming-interface">Programming Interface</a></li>
</ul>
</li>
<li class="toctree-l3"><a class="reference internal" href="Servo_Brick.html">Servo Brick</a></li>
<li class="toctree-l3"><a class="reference internal" href="Stepper_Brick.html">Stepper Brick</a></li>
</ul>
</li>
<li class="toctree-l2"><a class="reference internal" href="../Bricklets/Bricklets.html">Bricklets</a></li>
<li class="toctree-l2"><a class="reference internal" href="../Master_Extensions/Master_Extensions.html">Master Extensions</a></li>
<li class="toctree-l2"><a class="reference internal" href="../Power_Supplies/Power_Supplies.html">Power Supplies</a></li>
<li class="toctree-l2"><a class="reference internal" href="../Accessories/Accessories.html">Accessories</a></li>
<li class="toctree-l2"><a class="reference internal" href="../../Timeline.html">Timeline</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="../../Software/Software.html">Software</a><ul>
<li class="toctree-l2"><a class="reference internal" href="../../Software/Brickd.html">Brick Daemon (brickd)</a></li>
<li class="toctree-l2"><a class="reference internal" href="../../Software/Brickv.html">Brick Viewer (brickv)</a></li>
<li class="toctree-l2"><a class="reference internal" href="../../Software/API_Bindings.html">API Bindings</a></li>
<li class="toctree-l2"><a class="reference internal" href="../../Software/Firmwares_And_Plugins.html">Firmwares and Plugins</a></li>
<li class="toctree-l2"><a class="reference internal" href="../../Software/Device_Identifier.html">Device Identifier</a></li>
<li class="toctree-l2"><a class="reference internal" href="../../Source_Code.html">Source Code and Bug Tracking</a></li>
<li class="toctree-l2"><a class="reference internal" href="../../Programming_Interface.html">Programming Interface</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="../../Kits/Kits.html">Starter Kits</a><ul>
<li class="toctree-l2"><a class="reference internal" href="../../Kits/WeatherStation/WeatherStation.html">Weather Station</a></li>
<li class="toctree-l2"><a class="reference internal" href="../../Kits/HardwareHacking/HardwareHacking.html">Hardware Hacking</a></li>
<li class="toctree-l2"><a class="reference internal" href="../../Kits/ServerRoomMonitoring/ServerRoomMonitoring.html">Server Room Monitoring</a></li>
<li class="toctree-l2"><a class="reference internal" href="../../Kits/Blinkenlights/Blinkenlights.html">Blinkenlights</a></li>
<li class="toctree-l2"><a class="reference internal" href="../../Kits/InternetOfThings/InternetOfThings.html">Internet of Things</a></li>
<li class="toctree-l2"><a class="reference internal" href="../../Kits/CameraSlider/CameraSlider.html">Camera Slider</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="../../Embedded/Boards.html">Embedded Boards</a><ul>
<li class="toctree-l2"><a class="reference internal" href="../../Embedded/Raspberry_Pi.html">Raspberry Pi</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="../../Specifications.html">Specifications</a><ul>
<li class="toctree-l2"><a class="reference internal" href="../../Technical_Data.html">Technical Data</a></li>
<li class="toctree-l2"><a class="reference internal" href="../../Low_Level_Protocols/TCPIP.html">TCP/IP Protocol</a></li>
<li class="toctree-l2"><a class="reference internal" href="../../Low_Level_Protocols/Modbus.html">Modbus Protocol</a></li>
<li class="toctree-l2"><a class="reference internal" href="../../Low_Level_Protocols/Wireshark_Dissector.html">Wireshark Dissector</a></li>
</ul>
</li>
</ul>

</div>



<div id="shoplink_img">
	<a href="../../../shop/bricks/red-brick.html"><img alt="Shop" width="32" height="40" src="../../_images/Misc/cart-icon.png" /></a>
</div>
<div id="shoplink_a">
	<a href="../../../shop/bricks/red-brick.html">In Shop</a>
</div>



    <div class="document">
      <div class="documentwrapper">
        <div class="bodywrapper">
          <div class="body">
            
  <div class="section" id="red-brick">
<span id="id1"></span><h1>RED Brick<a class="headerlink" href="#red-brick" title="Permalink to this headline">¶</a></h1>
{% from "macros.html" import tfdocstart, tfdocimg, tfdocend %}
{{
    tfdocstart("Bricks/brick_red_tilted_top_front_350.jpg",
               "Bricks/brick_red_tilted_top_front_800.jpg",
               "RED Brick")
}}
{{
    tfdocimg("Bricks/brick_red_hand_100.jpg",
             "Bricks/brick_red_hand_800.jpg",
             "RED Brick in a hand")
}}
{{
    tfdocimg("Bricks/brick_red_master_temp_eth_100.jpg",
             "Bricks/brick_red_master_temp_eth_800.jpg",
             "RED Brick with Master Brick, Temperature Bricklet and Ethernet Extension")
}}
{{
    tfdocimg("Bricks/brick_red_w_monitor_100.jpg",
             "Bricks/brick_red_w_monitor_800.jpg",
             "RED Brick with Step-Down Power Supply and small HDMI monitor")
}}
{{
    tfdocimg("Bricks/brick_red_tilted_top_back_100.jpg",
             "Bricks/brick_red_tilted_top_back_800.jpg",
             "RED Brick")
}}
{{
    tfdocimg("Bricks/brick_red_tilted_bottom_front_100.jpg",
             "Bricks/brick_red_tilted_bottom_front_800.jpg",
             "RED Brick")
}}
{{
    tfdocimg("Bricks/brick_red_tilted_bottom_back_100.jpg",
             "Bricks/brick_red_tilted_bottom_back_800.jpg",
             "RED Brick")
}}
{{
    tfdocimg("Bricks/brick_red_side_front_100.jpg",
             "Bricks/brick_red_side_front_800.jpg",
             "RED Brick")
}}
{{
    tfdocimg("Bricks/brick_red_side_back_100.jpg",
             "Bricks/brick_red_side_back_800.jpg",
             "RED Brick")
}}
{{
    tfdocimg("Bricks/brick_red_top_100.jpg",
             "Bricks/brick_red_top_800.jpg",
             "RED Brick")
}}
{{
    tfdocimg("Bricks/brick_red_bottom_100.jpg",
             "Bricks/brick_red_bottom_800.jpg",
             "RED Brick")
}}
{{
    tfdocimg("Bricks/brick_red_big_stack_100.jpg",
             "Bricks/brick_red_big_stack_800.jpg",
             "RED Brick with big stack")
}}
{{
    tfdocimg("Bricks/brick_red_caption_top_100.jpg",
             "Bricks/brick_red_caption_top_800.jpg",
             "RED Brick with caption")
}}
{{
    tfdocimg("Bricks/brick_red_caption_bottom_100.jpg",
             "Bricks/brick_red_caption_bottom_800.jpg",
             "RED Brick with caption")
}}
{{
    tfdocimg("Dimensions/red_brick_dimensions_100.png",
             "Dimensions/red_brick_dimensions_600.png",
             "Outline and drilling plan")
}}
{{ tfdocend() }}<div class="section" id="features">
<h2>Features<a class="headerlink" href="#features" title="Permalink to this headline">¶</a></h2>
<ul class="simple">
<li>Controls other Bricks and Bricklets</li>
<li>Executes your program directly on the Brick</li>
<li>Supports nearly all programming languages</li>
</ul>
</div>
<div class="section" id="description">
<span id="red-brick-description"></span><h2>Description<a class="headerlink" href="#description" title="Permalink to this headline">¶</a></h2>
<p>The Rapid Embedded Development <a class="reference internal" href="../../Primer.html#primer-bricks"><em>Brick</em></a> (RED Brick) can
control other Bricks and
<a class="reference internal" href="../../Primer.html#primer-bricklets"><em>Bricklets</em></a>. The programming languages C/C++, C#,
Delphi/Lazarus, Java, JavaScript, Octave, Perl, PHP, Python, Ruby, Shell
and Visual Basic .NET can be executed on the Brick.</p>
<p>A program that controls Bricks and Bricklets can be written and tested
on a normal PC or Mac. Afterwards the program can be transferred to the RED Brick
by the press of a button and can then be executed without any changes. Multiple
programs can be executed simultaneously. The execution of programs can be
scheduled (execution on boot up, every hour, etc.) and monitored.</p>
<p>This approach enables a very easy and very fast solution to realize projects.
To our knowledge there is no other solution available that is even remotely
comparable.</p>
<p>For each supported programming language the <a class="reference internal" href="../../Software/API_Bindings.html#api-bindings"><em>Tinkerforge API</em></a>
and commonly used software libraries are pre-installed on the system. Other
necessary libraries can be installed manually.</p>
<p>The Brick is equipped with a <a class="reference external" href="http://en.wikipedia.org/wiki/HDMI">Micro-HDMI</a>
connector, which can be used by programs to show a graphical user interface. A
<a class="reference external" href="http://en.wikipedia.org/wiki/USB">USB-2.0</a> Host connector can be used to
connect Wi-Fi dongles, mouses, keyboards, touchscreens and similar.</p>
<p>With an <a class="reference internal" href="../Master_Extensions/Ethernet_Extension.html#ethernet-extension"><em>Ethernet Master Extension</em></a> the RED Brick can
be extended by an Ethernet interface. The
<a class="reference internal" href="../Master_Extensions/RS485_Extension.html#rs485-extension"><em>RS485 Master Extension</em></a> can be used to connect
other remote stacks of Bricks and Bricklets.</p>
<p>Advanced users can use the RED Brick with full access to the underlying
<a class="reference external" href="http://www.debian.org/">Debian</a> system.
The expert user can directly access GPIO/SPI/I2C pins for individual
hardware development over a GPIO FPC header.</p>
<p>An introduction video is available on Youtube:</p>
<center><iframe width="640" height="360" src="http://www.youtube-nocookie.com/embed/NORpY81Ss6o" frameborder="0" allowfullscreen></iframe></center></div>
<div class="section" id="technical-specifications">
<h2>Technical Specifications<a class="headerlink" href="#technical-specifications" title="Permalink to this headline">¶</a></h2>
<table border="1" class="docutils">
<colgroup>
<col width="26%" />
<col width="74%" />
</colgroup>
<thead valign="bottom">
<tr class="row-odd"><th class="head">Property</th>
<th class="head">Value</th>
</tr>
</thead>
<tbody valign="top">
<tr class="row-even"><td>Processor</td>
<td>Allwinner A10s, Cortex A8 1GHz, 3D Mali400 GPU, NEON</td>
</tr>
<tr class="row-odd"><td>Memory</td>
<td>512MB DDR3 SDRAM, Micro-SD-Card as Flash</td>
</tr>
<tr class="row-even"><td>Connectors</td>
<td>USB-2.0-Host, Micro-HDMI (type D), Mini-USB, Stack connectors, GPIO FPC connector</td>
</tr>
<tr class="row-odd"><td>&nbsp;</td>
<td>&nbsp;</td>
</tr>
<tr class="row-even"><td>Dimensions (W x D x H)</td>
<td>40 x 40 x 16mm (1.57 x 1.57 x 0.63&quot;)</td>
</tr>
<tr class="row-odd"><td>Weight</td>
<td>14g</td>
</tr>
<tr class="row-even"><td>Power Consumption</td>
<td>0.75W (5V/150mA, idle), 1.1W (5V/220mA, 100% load)</td>
</tr>
</tbody>
</table>
</div>
<div class="section" id="resources">
<h2>Resources<a class="headerlink" href="#resources" title="Permalink to this headline">¶</a></h2>
<ul class="simple">
<li>Schematic (<a class="reference external" href="https://github.com/Tinkerforge/red-brick/raw/master/hardware/red-schematic.pdf">Download</a>)</li>
<li>Outline and drilling plan (<a class="reference external" href="../../_images/Dimensions/red_brick_dimensions.png">Download</a>)</li>
<li>Linux image and hardware design files (<a class="reference external" href="https://github.com/Tinkerforge/red-brick/zipball/master">Download</a>)</li>
</ul>
</div>
<div class="section" id="first-steps-test-your-red-brick">
<span id="red-brick-test"></span><h2>First Steps / Test your RED Brick<a class="headerlink" href="#first-steps-test-your-red-brick" title="Permalink to this headline">¶</a></h2>
<p>With the following instructions you can test your RED Brick.
A full step-by-step tutorial regarding the RED Brick can be found here:
<a class="reference internal" href="../../Tutorials/Tutorial_RED_Brick/Tutorial.html#tutorial-red-brick"><em>RED Brick Tutorial</em></a>.</p>
<p>First install the <a class="reference internal" href="../../Software/Brickd.html#brickd"><em>Brick Daemon</em></a> and the
<a class="reference internal" href="../../Software/Brickv.html#brickv"><em>Brick Viewer</em></a> software on your PC or Mac. Insert the prepared
Micro-SD card into the <a class="reference internal" href="#red-brick-micro-sd-card-slot"><em>Micro-SD-Card slot</em></a>
of the RED Brick. The location of the slot and an overview of the different
hardware interfaces of the RED Brick is given in the
<a class="reference internal" href="#red-brick-hardware"><em>hardware description</em></a>. You can order a <a class="reference external" href="https://www.tinkerforge.com/en/shop/accessories/red-brick.html">SD card with
pre-installed image</a>
in our shop. Otherwise you can prepare an SD card yourself, see the
<a class="reference internal" href="#red-brick-copy-image"><em>copy image to SD card</em></a> section.</p>
<p>After that your RED Brick is ready to go and can be connected to your PC or Mac
with a Mini-USB cable.</p>
<a class="reference external image-reference" href="../../_images/Bricks/brick_red_mini_usb_800.jpg"><img alt="RED Brick with Mini-USB cable" class="align-center" src="../../_images/brick_red_mini_usb_600.jpg" style="width: 600.0px; height: 376.0px;" /></a>
<p>If you start the Brick Viewer software and press &quot;Connect&quot;. A tab should show up
labeled with &quot;RED Brick&quot;. Click on it.</p>
<p>On the left side of the tab you see different additional tabs. The &quot;Overview&quot;
tab shows information about the CPU load,
memory usage and other status information. This view means that your RED Brick
works as expected and you can start to upload your programs. See the
<a class="reference internal" href="#red-brick-brickv"><em>Brick Viewer section</em></a> on how to configure the Brick
and how to upload your programs.</p>
<p>You can also test the graphical user interface (HDMI). To do so, connect a
monitor to the <a class="reference internal" href="#red-brick-hdmi"><em>HDMI port</em></a> and a USB hub with keyboard
and mouse to the <a class="reference internal" href="#red-brick-usb-host"><em>USB port</em></a> of the RED Brick. If you
power the Brick you can see the LXDE desktop environment booting. After
the boot process you should be able to use it as a normal desktop PC.</p>
<p>You can log in to the underlying Linux with user <tt class="docutils literal"><span class="pre">tf</span></tt> and password <tt class="docutils literal"><span class="pre">tf</span></tt>.
The <tt class="docutils literal"><span class="pre">tf</span></tt> user is a sudoer.</p>
<div class="admonition note">
<p class="first admonition-title">Note</p>
<p class="last">For security reasons you may want to change the password. The
procedure is documented <a class="reference internal" href="#red-brick-change-password"><em>here</em></a>.</p>
</div>
</div>
<div class="section" id="brick-viewer">
<span id="red-brick-brickv"></span><h2>Brick Viewer<a class="headerlink" href="#brick-viewer" title="Permalink to this headline">¶</a></h2>
<p>This section describes the configuration of the RED Brick with the
<a class="reference internal" href="../../Software/Brickv.html#brickv"><em>Brick Viewer</em></a> software. The RED Brick can also be configured by
the <a class="reference internal" href="#red-brick-programming-interface"><em>RED Brick API</em></a> (only for power
users).</p>
<a class="reference internal image-reference" href="../../_images/brickv_red_tab_and_labels.jpg"><img alt="Screenshot of tab selection and labels." class="align-center" src="../../_images/brickv_red_tab_and_labels.jpg" style="width: 472.2px; height: 147.0px;" /></a>
<p>The RED Brick representation in Brick Viewer consists of different tabs, each
described in detail below. At the top the UID of the RED Brick, the position
in the stack, the name of the used image, number of timeouts and the word
<em>System</em> is shown. If you click on it, you can restart the Brick Daemon on the
RED Brick and reboot or shut down the RED Brick itself.</p>
<div class="section" id="overview-tab-status-information">
<h3>Overview Tab (Status Information)<a class="headerlink" href="#overview-tab-status-information" title="Permalink to this headline">¶</a></h3>
<p>This tab is selected by default. It shows the uptime of your RED Brick
and the usage of CPU, memory (RAM) and storage. You can see
the top processes based on CPU or memory usage and the up- and download speed
of the configured network interfaces.</p>
<a class="reference internal image-reference" href="../../_images/brickv_red_tab_overview.jpg"><img alt="Screenshot of overview tab." class="align-center" src="../../_images/brickv_red_tab_overview.jpg" style="width: 472.2px; height: 423.0px;" /></a>
<p>The list can contain the following network interfaces
(X is a number, typically 0):</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">lo</span></tt>: This is the loopback interface. It is a local interface, used for
example for the communication between your program and the local Brick Daemon.</li>
<li><tt class="docutils literal"><span class="pre">wlanX</span></tt> : This is a Wi-Fi interface. It is created if you attach a Wi-Fi
dongle to the <a class="reference internal" href="#red-brick-usb-host"><em>USB Host connector</em></a>.</li>
<li><tt class="docutils literal"><span class="pre">ethX</span></tt> : This is a Ethernet interface. It is created if you attach a
Ethernet dongle to the <a class="reference internal" href="#red-brick-usb-host"><em>USB Host connector</em></a>.</li>
<li><tt class="docutils literal"><span class="pre">tfX</span></tt> : This is the Ethernet interface created if you add an
<a class="reference internal" href="../Master_Extensions/Ethernet_Extension.html#ethernet-extension"><em>Ethernet Extension</em></a> on top of the RED Brick.</li>
</ul>
<p>The data in the overview tab is automatically refreshed every 3 seconds.</p>
</div>
<div class="section" id="settings-tab">
<span id="red-brick-brickv-settings"></span><h3>Settings Tab<a class="headerlink" href="#settings-tab" title="Permalink to this headline">¶</a></h3>
<p>The Settings tab is subdivided into several sections.</p>
<div class="section" id="network">
<span id="red-brick-brickv-settings-network"></span><h4>Network<a class="headerlink" href="#network" title="Permalink to this headline">¶</a></h4>
<p>In the Network section of this tab you can configure settings
related to networking.</p>
<a class="reference internal image-reference" href="../../_images/brickv_red_tab_settings_network.jpg"><img alt="Screenshot of settings tab showing network configurations." class="align-center" src="../../_images/brickv_red_tab_settings_network.jpg" style="width: 577.2px; height: 314.4px;" /></a>
<p>The <em>Current Network Status</em> subsection shows you the status of the configured
and currently used network interface. The status is updated automatically every
3 seconds.</p>
<p>You can configure the used interface in the <em>Configuration</em> subsection. First
choose the interface you want to configure (An USB Ethernet dongle will show
up as <tt class="docutils literal"><span class="pre">ethX</span></tt>, the Ethernet Extension as <tt class="docutils literal"><span class="pre">tfX</span></tt> and a USB Wi-Fi dongle
as <tt class="docutils literal"><span class="pre">wlanX</span></tt> (X is a number). Dependent on the selected interface you will get
other configuration options:</p>
<ul>
<li><p class="first"><strong>Configure an Ethernet Interface:</strong></p>
<p>After selecting an Ethernet interface, choose between DHCP or static IP
configuration and press the <em>Connect</em> button.</p>
</li>
<li><p class="first"><strong>Configure a Wi-Fi Interface:</strong></p>
<p>After selecting a Wi-Fi interface press the <em>Scan</em> button to scan for
access points. It will take some time to get the scan results.</p>
<p>Select the desired access point and enter the secret and select between DHCP or
static IP address. After that press <em>Connect</em>.
<a class="reference external" href="https://www.tinkerforge.com/en/shop/accessories/red-brick.html">Supported USB Wi-Fi dongles</a>
can be found in our shop.</p>
</li>
</ul>
</div>
<div class="section" id="wireless-access-point">
<span id="red-brick-brickv-settings-ap"></span><h4>Wireless Access Point<a class="headerlink" href="#wireless-access-point" title="Permalink to this headline">¶</a></h4>
<p>In the Wireless Access Point section (requires Image &gt;= 1.4 and
Brick Viewer &gt;= 2.2.2) of this tab, you can turn
the RED Brick into a wireless access point. This section is only
available if the <a class="reference internal" href="#red-brick-brickv-settings-services"><em>Access Point service</em></a>
is activated and you have connected the <a class="reference external" href="https://www.tinkerforge.com/en/shop/accessories/red-brick/wifi-usb-adapter.html">Wi-Fi USB Adapter</a>
to the RED Brick USB port.</p>
<a class="reference internal image-reference" href="../../_images/brickv_red_tab_settings_access_point.jpg"><img alt="Screenshot of settings tab showing access point configuration." class="align-center" src="../../_images/brickv_red_tab_settings_access_point.jpg" style="width: 388.2px; height: 307.8px;" /></a>
<p>If you use Access Point mode, the RED Brick will provide a DHCP and DNS server.
It will give devices that connect to it an IP address and provide a domain.
You can configure the IP address, SSID, WPA passphrase, DHCP pool, DNS domain
and other options that you might expect from an access point.</p>
<p>It is also possible to show the current DHCP leases, which can help you
to identify devices that are connected to the RED Brick access point.</p>
<p>If you use the Access Point mode, there is no external network infrastructure
necessary. Your smart phone, tablet or laptop can directly connect to the
RED Brick.</p>
</div>
<div class="section" id="server-monitoring">
<span id="red-brick-brickv-settings-server-monitoring"></span><h4>Server Monitoring<a class="headerlink" href="#server-monitoring" title="Permalink to this headline">¶</a></h4>
<a class="reference internal image-reference" href="../../_images/brickv_red_tab_settings_srm.jpg"><img alt="Screenshot of settings tab showing Server Monitoring configurations." class="align-center" src="../../_images/brickv_red_tab_settings_srm.jpg" style="width: 657.6px; height: 424.2px;" /></a>
<p>The server monitoring functionality (requires Image &gt;= 1.6 and
Brick Viewer &gt;= 2.2.3) is designed to be used with the
<a class="reference internal" href="../../Kits/ServerRoomMonitoring/ServerRoomMonitoring.html#starter-kit-server-room-monitoring-red-brick"><em>Starter Kit: Server Room Monitoring</em></a>.
For further details see the documentation of the kit.</p>
</div>
<div class="section" id="openhab">
<span id="red-brick-brickv-settings-openhab"></span><h4>openHAB<a class="headerlink" href="#openhab" title="Permalink to this headline">¶</a></h4>
<a class="reference internal image-reference" href="../../_images/brickv_red_tab_settings_openhab.jpg"><img alt="Screenshot of settings tab showing openHAB configurations." class="align-center" src="../../_images/brickv_red_tab_settings_openhab.jpg" style="width: 470.4px; height: 246.6px;" /></a>
<p>In the <a class="reference external" href="http://www.openhab.org/">openHAB</a> section (requires Image &gt;= 1.6 and
Brick Viewer &gt;= 2.2.3) of this tab you can configure the openHAB service
running on the RED Brick. This section is only available if the <a class="reference internal" href="#red-brick-brickv-settings-services"><em>openHAB
service</em></a> is activated.</p>
<p>Using the <em>New</em> and <em>Delete</em> buttons you can create new <tt class="docutils literal"><span class="pre">.items</span></tt>, <tt class="docutils literal"><span class="pre">.rules</span></tt>
and <tt class="docutils literal"><span class="pre">.sitemap</span></tt> config files and delete existing config files. Brick Viewer
will automatically store the new config files in the correct openHAB config
directory depending on the file extension.</p>
<p>After you changed the content of a config file you can click the <em>Apply Changes</em>
button to save the changes or click the <em>Discard Changes</em> button to discard
the changes. Config files with unsaved changes are marked as <tt class="docutils literal"><span class="pre">(modified)</span></tt>.</p>
<p>An openHAB configuration example can be found in the documentation of the
<a class="reference internal" href="../../Kits/WeatherStation/WeatherStation.html#starter-kit-weather-station-openhab"><em>Starter Kit: Weather Station</em></a>.</p>
</div>
<div class="section" id="brick-daemon">
<span id="red-brick-brickv-settings-brickd"></span><h4>Brick Daemon<a class="headerlink" href="#brick-daemon" title="Permalink to this headline">¶</a></h4>
<p>In the Brick Daemon section of this tab you can configure
settings related to the local Brick Daemon.</p>
<a class="reference internal image-reference" href="../../_images/brickv_red_tab_settings_brickd.jpg"><img alt="Screenshot of settings tab showing brickd configurations." class="align-center" src="../../_images/brickv_red_tab_settings_brickd.jpg" style="width: 781.2px; height: 241.8px;" /></a>
<p>The configuration includes listen address, corresponding port, port for
WebSockets, authentication secret and several other low level configurations
including the LED trigger for the red and green LED.</p>
<p>WebSockets are used by the browser version of the
<a class="reference internal" href="../../Software/API_Bindings_JavaScript.html#api-bindings-javascript"><em>JavaScript bindings</em></a> to control Bricks and
Bricklets.</p>
</div>
<div class="section" id="date-time">
<span id="red-brick-brickv-settings-date"></span><h4>Date/Time<a class="headerlink" href="#date-time" title="Permalink to this headline">¶</a></h4>
<p>In the Date/Time section you can synchronize the clock of the RED Brick to
the clock of your PC. There is no battery on the RED Brick, so the
time won't be incremented if the RED Brick is not powered.</p>
<a class="reference internal image-reference" href="../../_images/brickv_red_tab_settings_date.jpg"><img alt="Screenshot of settings tab showing date and time configurations." class="align-center" src="../../_images/brickv_red_tab_settings_date.jpg" style="width: 387.6px; height: 240.6px;" /></a>
<p>If you have a connection to the Internet (trough the Ethernet Extension
or a USB Wi-Fi dongle), the date and time are automatically set by
NTP. You only have to configure the timezone, which is saved even if
the RED Brick is powered down.</p>
<p>If you need the correct time after bootup but you can't guarantee
or can't obtain Internet access, you can also use the
<a class="reference internal" href="../Bricklets/GPS.html#gps-bricklet"><em>GPS Bricklet</em></a>. You can find a small
<a class="reference external" href="https://github.com/Tinkerforge/red-brick/tree/master/programs/gps_time">program on GitHub</a>
that could be uploaded to the RED Brick to sync the Linux system time with
the GPS time.</p>
</div>
<div class="section" id="file-system">
<span id="red-brick-brickv-settings-file-system"></span><h4>File System<a class="headerlink" href="#file-system" title="Permalink to this headline">¶</a></h4>
<p>In the File System section (requires Brick Viewer &gt;= 2.2.1) you can expand the
file system on the Micro-SD card.</p>
<a class="reference internal image-reference" href="../../_images/brickv_red_tab_settings_file_system.jpg"><img alt="Screenshot of settings tab showing file system expansion." class="align-center" src="../../_images/brickv_red_tab_settings_file_system.jpg" style="width: 370.2px; height: 223.2px;" /></a>
<p>Depending on the image size and the capacity of the Micro-SD card you might
not be using the total capacity of the Micro-SD card. In this case expanding
the file system will provide you with some extra storage space. If the file
system uses less than 95% of the Micro-SD card's size then it can be expanded.
To do this follow the instructions in Brick Viewer.</p>
</div>
<div class="section" id="services">
<span id="red-brick-brickv-settings-services"></span><h4>Services<a class="headerlink" href="#services" title="Permalink to this headline">¶</a></h4>
<a class="reference internal image-reference" href="../../_images/brickv_red_tab_settings_services.jpg"><img alt="Screenshot of settings tab showing services." class="align-center" src="../../_images/brickv_red_tab_settings_services.jpg" style="width: 388.2px; height: 192.0px;" /></a>
<p>In the Services section (requires Image &gt;= 1.4 and Brick Viewer &gt;= 2.2.2)
you can enable and disable different services on the RED Brick.
If you don't need a web server or a desktop environment on your
RED Brick you can disable them and make the RED Brick boot faster. You can also
enable the <a class="reference internal" href="#red-brick-brickv-settings-ap"><em>wireless access point mode</em></a> to
directly connect from your smart phone or notebook to the RED Brick.</p>
<ul class="simple">
<li>GPU: Enables hardware acceleration for graphics. If you enable
this, some parts of the RAM are shared with the GPU. If you don't use HDMI
we would recommend to disable the GPU.</li>
<li>Desktop Environment: Starting the desktop environment (LXDE) takes
some time, if you don't use it you can disable it to save boot time</li>
<li>Web Server: The web server is necessary if you want to use web
services on the RED Brick. If enabled, it adds about 10 seconds to the
boot time!</li>
<li>Splash Screen: If enabled, a splash screen is shown on startup
(during the boot process of the Linux kernel). If disabled you can
see the kernel messages.</li>
<li>Access Point: If access point mode is enabled, you can configure
the RED Brick to be an <a class="reference internal" href="#red-brick-brickv-settings-ap"><em>access point in the settings tab</em></a>.</li>
<li>Server Monitoring: Enables the <a class="reference external" href="http://www.nagios.org/">Nagios</a>
monitoring system, see <a class="reference internal" href="#red-brick-brickv-settings-server-monitoring"><em>server monitoring in the settings tab</em></a>.</li>
<li>openHAB: Enables the <a class="reference external" href="http://www.openhab.org/">openHAB</a> runtime, see
<a class="reference internal" href="#red-brick-brickv-settings-openhab"><em>openHAB in the settings tab</em></a>.</li>
</ul>
<p>If you change the services and save the changes, the RED Brick will reboot
and the new configuration will be available after the reboot.</p>
</div>
</div>
<div class="section" id="program-tab-upload-and-execution">
<span id="red-brick-brickv-program"></span><h3>Program Tab (Upload and Execution)<a class="headerlink" href="#program-tab-upload-and-execution" title="Permalink to this headline">¶</a></h3>
<p>The documentation of the program tab can be found on
<a class="reference internal" href="RED_Brick_Program_Tab.html#red-brick-program-tab"><em>a separate site</em></a>.</p>
<div class="toctree-wrapper compound">
</div>
</div>
<div class="section" id="console-tab-remote-access">
<span id="red-brick-brickv-console"></span><h3>Console Tab (Remote Access)<a class="headerlink" href="#console-tab-remote-access" title="Permalink to this headline">¶</a></h3>
<p>If you have attached the RED Brick over its
<a class="reference external" href="red_brick_mini_usb">Mini-USB Connector</a> to your PC it will also register
a USB serial interface. This serial interface can be used to access the Linux
shell of the Brick. Select the serial port of the Brick and press <em>Connect</em>.
Under Linux the typical interface is <tt class="docutils literal"><span class="pre">/dev/ttyACMX</span></tt> (X is number) under
Windows it is <tt class="docutils literal"><span class="pre">Serial</span> <span class="pre">Port</span> <span class="pre">COMX</span></tt> (X is number) with device name
<tt class="docutils literal"><span class="pre">RED</span> <span class="pre">Brick</span> <span class="pre">Serial</span> <span class="pre">Console</span></tt> and on OS X usually shows up as
<tt class="docutils literal"><span class="pre">/dev/tty.usbmodemXYZ</span></tt> with XYZ is part of RED Bricks UID. You can log in as
user <tt class="docutils literal"><span class="pre">tf</span></tt> with password <tt class="docutils literal"><span class="pre">tf</span></tt>. If you are not sure what the right port is
test them all, until you see the shell. It might be necessary to press ENTER to
see the prompt.</p>
<p>Below you can see a screenshot of the console executing <tt class="docutils literal"><span class="pre">htop</span></tt>.</p>
<a class="reference internal image-reference" href="../../_images/brickv_red_tab_console.jpg"><img alt="Screenshot of console tab showing htop." class="align-center" src="../../_images/brickv_red_tab_console.jpg" style="width: 459.6px; height: 373.8px;" /></a>
<p>A good shell tutorial can be found at
<a class="reference external" href="http://linuxcommand.org/lc3_learning_the_shell.php">linuxcommand.org</a>.</p>
</div>
<div class="section" id="versions-tab-daemon-bindings-and-libraries">
<span id="red-brick-brickv-versions-tab"></span><h3>Versions Tab (Daemon, Bindings and Libraries)<a class="headerlink" href="#versions-tab-daemon-bindings-and-libraries" title="Permalink to this headline">¶</a></h3>
<p>The versions tab shows version information of the installed Brick Daemon and
RED Brick API Daemon as well as the installed Bindings and their associated
libraries.</p>
<a class="reference internal image-reference" href="../../_images/brickv_red_tab_versions.jpg"><img alt="Screenshot of versions tab." class="align-center" src="../../_images/brickv_red_tab_versions.jpg" style="width: 455.4px; height: 373.8px;" /></a>
<p>If you want to use other libraries than the installed ones, you can
<a class="reference internal" href="#red-brick-brickv-program"><em>upload</em></a> them with your program or use the
<a class="reference internal" href="#red-brick-brickv-console"><em>console</em></a> to install them via <tt class="docutils literal"><span class="pre">apt-get</span></tt>,
<tt class="docutils literal"><span class="pre">pip</span></tt>, <tt class="docutils literal"><span class="pre">pear</span></tt>, <tt class="docutils literal"><span class="pre">npm</span></tt> or similar package managers. The listed package
managers are all installed in all RED Brick images.</p>
</div>
<div class="section" id="extensions-tab-configure-manage">
<h3>Extensions Tab (Configure, Manage)<a class="headerlink" href="#extensions-tab-configure-manage" title="Permalink to this headline">¶</a></h3>
<p>Two <a class="reference internal" href="../../Primer.html#primer-master-extensions"><em>Master Extensions</em></a> are supported by the
RED Brick: <a class="reference internal" href="../Master_Extensions/Ethernet_Extension.html#ethernet-extension"><em>Ethernet Extension</em></a> and
<a class="reference internal" href="../Master_Extensions/RS485_Extension.html#rs485-extension"><em>RS485 Extension</em></a>.</p>
<p>Changing the settings on either of the Extensions will restart the
Brick Daemon on the RED Brick, i.e. your RED Brick tab in the Brick
Viewer will disappear for a few seconds and then pop up again.</p>
<div class="section" id="ethernet-extension">
<h4>Ethernet Extension<a class="headerlink" href="#ethernet-extension" title="Permalink to this headline">¶</a></h4>
<a class="reference internal image-reference" href="../../_images/brickv_red_tab_extension_ethernet.jpg"><img alt="Screenshot of extension tab showing Ethernet Extension configuration." class="align-center" src="../../_images/brickv_red_tab_extension_ethernet.jpg" style="width: 399.6px; height: 145.2px;" /></a>
<p>Only the MAC address of the Ethernet Extension can be changed here.
Since the Ethernet Extension shows up as a normal network interface in the
underlying Linux, you can configure it like any other network interface
through the <a class="reference internal" href="#red-brick-brickv-settings"><em>Settings Tab</em></a>.</p>
</div>
<div class="section" id="rs485-extension">
<h4>RS485 Extension<a class="headerlink" href="#rs485-extension" title="Permalink to this headline">¶</a></h4>
<a class="reference internal image-reference" href="../../_images/brickv_red_tab_extension_rs485.jpg"><img alt="Screenshot of extension tab showing RS485 Extension configuration." class="align-center" src="../../_images/brickv_red_tab_extension_rs485.jpg" style="width: 403.8px; height: 174.6px;" /></a>
<p>The configuration of the RS485 Extension is the same as it can be
done through a Master Brick. See the
<a class="reference internal" href="../Master_Extensions/RS485_Extension.html#rs485-configuration"><em>RS485 Extension documentation</em></a>.</p>
<p>The recommended baudrates to be used on the RED Brick are 500000, 250000,
166666, 125000, 100000, 83333, 71428, 62500, 55555, 50000, 45454 or
41666 baud.</p>
</div>
</div>
<div class="section" id="import-export">
<h3>Import/Export<a class="headerlink" href="#import-export" title="Permalink to this headline">¶</a></h3>
<p>The Import/Export tab (requires Brick Viewer &gt;= 2.2.2) allows to import/export
programs and system logs.</p>
<div class="section" id="system-logs">
<h4>System Logs<a class="headerlink" href="#system-logs" title="Permalink to this headline">¶</a></h4>
<a class="reference internal image-reference" href="../../_images/brickv_red_tab_imexport_system_logs.jpg"><img alt="Screenshot of Import/Export tab showing system logs." class="align-center" src="../../_images/brickv_red_tab_imexport_system_logs.jpg" style="width: 677.4px; height: 292.2px;" /></a>
<p>Choose a log file and click <tt class="docutils literal"><span class="pre">Refresh</span></tt> to download it from the RED Brick and
show it in the viewer. With the <tt class="docutils literal"><span class="pre">Save</span></tt> button you can save it on your disk.</p>
</div>
<div class="section" id="import">
<h4>Import<a class="headerlink" href="#import" title="Permalink to this headline">¶</a></h4>
<a class="reference internal image-reference" href="../../_images/brickv_red_tab_imexport_import.jpg"><img alt="Screenshot of Import/Export tab showing import." class="align-center" src="../../_images/brickv_red_tab_imexport_import.jpg" style="width: 389.4px; height: 255.0px;" /></a>
<p>Choose a file you previously exported (see below) and select the
programs you want to import to your RED Brick. Press <tt class="docutils literal"><span class="pre">Import</span></tt>
to upload the selected programs.</p>
</div>
<div class="section" id="export">
<h4>Export<a class="headerlink" href="#export" title="Permalink to this headline">¶</a></h4>
<a class="reference internal image-reference" href="../../_images/brickv_red_tab_imexport_export.jpg"><img alt="Screenshot of Import/Export tab showing export." class="align-center" src="../../_images/brickv_red_tab_imexport_export.jpg" style="width: 405.0px; height: 234.6px;" /></a>
<p>In the export tab you can select the programs that you want to export
from the RED Brick. Press <tt class="docutils literal"><span class="pre">Export</span></tt> to save them on your disk.</p>
<p>The export file will contain the configuration of the program, all of the
program files as well as the logs that have been accumulated. If your
program is running and continuously writing files, you may want to
shut the program down before you export it. Otherwise you might export
the program with a file that is only partly written.</p>
<p>With this option programs can be exported and on a different RED Brick be
imported (see above).</p>
</div>
</div>
</div>
<div class="section" id="red-brick-web-interface">
<span id="id2"></span><h2>RED Brick Web Interface<a class="headerlink" href="#red-brick-web-interface" title="Permalink to this headline">¶</a></h2>
<p>If your RED Brick is equipped with a USB Wi-Fi dongle, an Ethernet
Extension or has other network connectivity, you can access a
web interface. The web interface is available at the IP address of the
RED Brick or the hostname (<tt class="docutils literal"><span class="pre">red-brick</span></tt> by default).</p>
<p>The RED Brick web interface shows the installed programs. You
can view the logs and configs of the programs as well as the
uploaded binaries. Since Image version 1.6 the available <a class="reference internal" href="#red-brick-brickv-settings-openhab"><em>openHAB</em></a> sitemaps and a link to the
<a class="reference internal" href="#red-brick-brickv-settings-server-monitoring"><em>server monitoring</em></a> website
are included as well.</p>
<a class="reference internal image-reference" href="../../_images/red_brick_web_interface.jpg"><img alt="Screenshot of RED Brick web interface." class="align-center" src="../../_images/red_brick_web_interface.jpg" style="width: 414.8px; height: 392.8px;" /></a>
<p>Besides the default web interface you can also put your own
web interfaces on the RED Brick. Currently we support web applications
written in HTML/JavaScript, Python and PHP. If you upload an <tt class="docutils literal"><span class="pre">index.py</span></tt>,
<tt class="docutils literal"><span class="pre">index.php</span></tt> or <tt class="docutils literal"><span class="pre">index.html</span></tt>, the respective file will be used as
directory index for the binary folder.</p>
<p><strong>Example to clarify:</strong> If you want to write a PHP website that controls
Bricks/Bricklets you can upload your PHP program <tt class="docutils literal"><span class="pre">EXAMPLE</span></tt> with id
<tt class="docutils literal"><span class="pre">EXAMPLE-ID</span></tt> that includes an <tt class="docutils literal"><span class="pre">index.php</span></tt> as starting point. If you now
go to the RED Brick web interface and click on the &quot;Bin&quot; button for the
newly created <tt class="docutils literal"><span class="pre">EXAMPLE</span></tt> program, you will get a link to
<tt class="docutils literal"><span class="pre">/programs/EXAMPLE-ID/bin</span></tt>, which will directly execute the <tt class="docutils literal"><span class="pre">index.php</span></tt>
if opened since it will act as index for this directory.</p>
<p>This way you can easily implement a web page that shows environment information
gathered from Temperature/Barometer/Humidity Bricklets or you can
have a web page with buttons that control Relay Bricklets, etc.</p>
<p>With the RED Brick it is super simple to write web applications that can
control hardware.</p>
<div class="section" id="html-javascript">
<h3>HTML/JavaScript<a class="headerlink" href="#html-javascript" title="Permalink to this headline">¶</a></h3>
<p>If you upload HTML with embedded JavaScript you can use the JavaScript
Bindings. They are available in the root directory, import them with:</p>
<div class="highlight-html"><div class="highlight"><pre><span class="nt">&lt;script </span><span class="na">src=</span><span class="s">&quot;/Tinkerforge.js&quot;</span> <span class="na">type=</span><span class="s">&#39;text/javascript&#39;</span><span class="nt">&gt;&lt;/script&gt;</span>
</pre></div>
</div>
<p>Note that the JavaScript is executed in the browser of the user and not
on the RED Brick, so you have to connect to the IP address of the RED Brick,
not localhost!</p>
</div>
<div class="section" id="python">
<h3>Python<a class="headerlink" href="#python" title="Permalink to this headline">¶</a></h3>
<p>The webserver on the RED Brick (Apache) uses WSGI
(<a class="reference external" href="https://code.google.com/p/modwsgi/">mod_wsgi</a>) to interface with
Python programs. It is configured to recognize an <tt class="docutils literal"><span class="pre">index.py</span></tt> as the
starting point for a WSGI script. All of the common Python web frameworks
support WSGI. The <a class="reference external" href="http://flask.pocoo.org/">Flask framework</a> is
preinstalled on the RED Brick (including
<a class="reference external" href="http://werkzeug.pocoo.org/">Werkzeug</a> and
<a class="reference external" href="http://jinja.pocoo.org/">Jinja</a>).</p>
<p>A minimal flask web interface that can be uploaded to the RED Brick
is an <tt class="docutils literal"><span class="pre">index.py</span></tt> with the following content:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="kn">from</span> <span class="nn">flask</span> <span class="kn">import</span> <span class="n">Flask</span>       <span class="c"># Use Flask framework</span>
<span class="n">application</span> <span class="o">=</span> <span class="n">Flask</span><span class="p">(</span><span class="n">__name__</span><span class="p">)</span> <span class="c"># Function &quot;application&quot; is used by Apache/wsgi</span>
<span class="n">app</span> <span class="o">=</span> <span class="n">application</span>             <span class="c"># Use shortcut for routing</span>

<span class="nd">@app.route</span><span class="p">(</span><span class="s">&#39;/&#39;</span><span class="p">)</span>
<span class="k">def</span> <span class="nf">index</span><span class="p">():</span>
    <span class="k">return</span> <span class="s">&#39;&lt;html&gt;&lt;body&gt;Hello World!&lt;/body&gt;&lt;/html&gt;&#39;</span>
</pre></div>
</div>
<p>To control Bricks/Bricklets you can just import the Tinkerforge Bindings as for
all Python programs:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="kn">from</span> <span class="nn">tinkerforge.ip_connection</span> <span class="kn">import</span> <span class="n">IPConnection</span>
<span class="kn">from</span> <span class="nn">tinkerforge.bricklet_temperature</span> <span class="kn">import</span> <span class="n">Temperature</span>

<span class="c"># ...</span>
</pre></div>
</div>
<p>The default web interface of the RED Brick uses Python/Flask.
You can find the code
<a class="reference external" href="https://github.com/Tinkerforge/red-brick/blob/master/image/patches/root-fs/common/tmp/index.py">on GitHub</a>.</p>
<p>It is of course also possible to use templates, static files and so on. You
can just use them as it is shown in most Flask tutorials.</p>
</div>
<div class="section" id="php">
<h3>PHP<a class="headerlink" href="#php" title="Permalink to this headline">¶</a></h3>
<p>The webserver on the RED Brick is configured to recognize an <tt class="docutils literal"><span class="pre">index.php</span></tt>.</p>
<p>An minimal hello world <tt class="docutils literal"><span class="pre">index.php</span></tt> might look like this:</p>
<div class="highlight-php"><div class="highlight"><pre><span class="cp">&lt;?php</span> <span class="nv">$greeting</span> <span class="o">=</span> <span class="s1">&#39;Hello World!&#39;</span><span class="p">;</span> <span class="cp">?&gt;</span><span class="x"></span>

<span class="x">&lt;html&gt;</span>
<span class="x"> &lt;head&gt;</span>
<span class="x">  &lt;title&gt;PHP Example&lt;/title&gt;</span>
<span class="x"> &lt;/head&gt;</span>
<span class="x"> &lt;body&gt;</span>
<span class="x">  &lt;p&gt;</span><span class="cp">&lt;?php</span> <span class="k">echo</span> <span class="nv">$greeting</span><span class="p">;</span> <span class="cp">?&gt;</span><span class="x">&lt;p&gt;</span>
<span class="x">  &lt;p&gt;</span><span class="cp">&lt;?php</span> <span class="nb">phpinfo</span><span class="p">();</span> <span class="cp">?&gt;</span><span class="x">&lt;p&gt;</span>
<span class="x"> &lt;/body&gt;</span>
<span class="x">&lt;/html&gt;</span>
</pre></div>
</div>
<p>To control Bricks/Bricklets you can import the Tinkerforge Bindings:</p>
<div class="highlight-python"><div class="highlight"><pre>require_once(&#39;Tinkerforge/IPConnection.php&#39;);
require_once(&#39;Tinkerforge/BrickletTemperature.php&#39;);

// ...
</pre></div>
</div>
</div>
</div>
<div class="section" id="red-brick-software-image">
<span id="red-brick-images"></span><h2>RED Brick Software Image<a class="headerlink" href="#red-brick-software-image" title="Permalink to this headline">¶</a></h2>
<p>The RED Brick software image is based on <a class="reference external" href="http://www.debian.org/">Debian</a>
and is stored on a Micro-SD-Card. Previously the image was available in two
different flavors: The &quot;full&quot; and the &quot;fast&quot; image. Since image version 1.4
there is only one image (previously known as the full image) with configurable
services (desktop environment, web server, wireless access point, etc.) that
allow to customize your image for your individual requirements.</p>
<p>The image comes with a driver for the GPU and all necessary graphical user
interface libraries. If enabled, it boots an X server and the
<a class="reference external" href="http://www.lxde.org">LXDE desktop environment</a>
with auto login. If the program you run on the RED Brick uses a graphical
interface it will show up on the desktop. The screen resolution should
automatically adapt to the preferred resolution of the connected HDMI monitor.
If you want to change it, you can configure the screen resolution through LXDE.
You don't have to use the HDMI port and can execute non graphical
programs on this image.</p>
<p>New software can be installed. See the <a class="reference internal" href="#red-brick-brickv-versions-tab"><em>description of the versions tab</em></a> on how to install new software.</p>
<p>A list of pre-installed programming language libraries is available:
<a class="reference internal" href="RED_Brick_Installed_Versions.html#red-brick-installed-versions"><em>Installed library versions</em></a>.</p>
<div class="toctree-wrapper compound">
</div>
<p>If you want to log into the Linux system by command line or LXDE, the standard
user is <tt class="docutils literal"><span class="pre">tf</span></tt> with default password <tt class="docutils literal"><span class="pre">tf</span></tt>. The user is a sudoer, i.e.
you can get root access by calling:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="n">sudo</span> <span class="o">-</span><span class="n">s</span>
</pre></div>
</div>
<p>The images can be downloaded from the <a class="reference internal" href="../../Downloads.html#downloads-red-images"><em>download page</em></a>.</p>
<div class="section" id="build-your-own-image">
<span id="red-brick-build-image"></span><h3>Build your own Image<a class="headerlink" href="#build-your-own-image" title="Permalink to this headline">¶</a></h3>
<p>For the building steps we are assuming a <a class="reference external" href="https://www.debian.org/">Debian Linux</a>
or derivative (Ubuntu etc) as the host platform.</p>
<ol class="arabic simple">
<li>Clone the <a class="reference external" href="https://github.com/Tinkerforge/red-brick">RED Brick repository</a>
from GitHub</li>
<li>Change to the <tt class="docutils literal"><span class="pre">image</span></tt> folder, open the <tt class="docutils literal"><span class="pre">README.rst</span></tt> file and execute the
documented  steps.</li>
</ol>
<p>The build process will take at least 4-6 hours, depending on the processing power
of your PC it might also take considerably longer.</p>
</div>
<div class="section" id="copy-image-to-sd-card">
<span id="red-brick-copy-image"></span><h3>Copy Image to SD Card<a class="headerlink" href="#copy-image-to-sd-card" title="Permalink to this headline">¶</a></h3>
<p>Start by downloading the <a class="reference internal" href="#red-brick-images"><em>image</em></a> from
the <a class="reference internal" href="../../Downloads.html#downloads-red-images"><em>download page</em></a> and unpack it. You'll also
need a Micro-SD card and a card reader. We recommend a fast card
(e.g. Class 10, &gt; 30MB/s read) with enough space (at least 8GB).</p>
<div class="section" id="windows">
<h4>Windows<a class="headerlink" href="#windows" title="Permalink to this headline">¶</a></h4>
<p>For Windows we recommend a tool like <a class="reference external" href="http://sourceforge.net/p/win32diskimager/wiki/Home/">Win32DiskImager</a> to copy the image to
the card.</p>
<ol class="arabic simple">
<li>Connect the SD card to the PC using the card reader.</li>
<li>Start Win32DiskImager as Administrator.</li>
<li>Choose the image and SD card and click &quot;Write&quot;.</li>
</ol>
</div>
<div class="section" id="linux">
<h4>Linux<a class="headerlink" href="#linux" title="Permalink to this headline">¶</a></h4>
<ol class="arabic simple">
<li>Connect the SD card to the PC using the card reader.</li>
<li>Identify the path of the SD card (e.g. using <tt class="docutils literal"><span class="pre">dmesg</span></tt>) with this format:
<tt class="docutils literal"><span class="pre">/dev/sdX</span></tt>, where <tt class="docutils literal"><span class="pre">X</span></tt> is a letter.</li>
<li>Use <tt class="docutils literal"><span class="pre">dd</span></tt> to write the image (e.g. <tt class="docutils literal"><span class="pre">/tmp/red_image_1_5_full.img</span></tt>) to the
SD card (e.g. <tt class="docutils literal"><span class="pre">/dev/sdb</span></tt>):</li>
</ol>
<div class="highlight-bash"><div class="highlight"><pre>sudo dd <span class="nv">bs</span><span class="o">=</span>64M <span class="k">if</span><span class="o">=</span>/tmp/red_image_1_5_full.img <span class="nv">of</span><span class="o">=</span>/dev/sdb
</pre></div>
</div>
</div>
<div class="section" id="mac-os-x">
<h4>Mac OS X<a class="headerlink" href="#mac-os-x" title="Permalink to this headline">¶</a></h4>
<ol class="arabic simple">
<li>Connect the SD card to the Mac using the card reader.</li>
<li>Mac OS X might complain that the SD card is not readable, ignore this message.</li>
<li>Identify the path of the SD card (e.g. using <tt class="docutils literal"><span class="pre">diskutil</span> <span class="pre">list</span></tt>), it should
have this format: <tt class="docutils literal"><span class="pre">/dev/diskN</span></tt>, where <tt class="docutils literal"><span class="pre">N</span></tt> is a number.</li>
<li>Unmount the SD card (e.g. using <tt class="docutils literal"><span class="pre">diskutil</span> <span class="pre">unmountDisk</span> <span class="pre">/dev/diskN</span></tt>).</li>
<li>Use <tt class="docutils literal"><span class="pre">dd</span></tt> to write the image (e.g. <tt class="docutils literal"><span class="pre">/tmp/red_image_1_5_full.img</span></tt>) to the
SD card (e.g. <tt class="docutils literal"><span class="pre">/dev/disk4</span></tt>), but use <tt class="docutils literal"><span class="pre">/dev/rdiskN</span></tt> instead of
<tt class="docutils literal"><span class="pre">/dev/diskN</span></tt> for higher throughput:</li>
</ol>
<div class="highlight-bash"><div class="highlight"><pre>sudo dd <span class="nv">bs</span><span class="o">=</span>64m <span class="k">if</span><span class="o">=</span>/tmp/red_image_1_5_full.img <span class="nv">of</span><span class="o">=</span>/dev/rdisk4
</pre></div>
</div>
<p>If this does not work for you (e.g. the RED Brick does not boot) then you can
use this slower method instead:</p>
<div class="highlight-bash"><div class="highlight"><pre>sudo dd <span class="nv">bs</span><span class="o">=</span>1m <span class="k">if</span><span class="o">=</span>/tmp/red_image_1_5_full.img <span class="nv">of</span><span class="o">=</span>/dev/disk4
</pre></div>
</div>
</div>
</div>
<div class="section" id="change-default-password">
<span id="red-brick-change-password"></span><h3>Change Default Password<a class="headerlink" href="#change-default-password" title="Permalink to this headline">¶</a></h3>
<p>The default password of user <tt class="docutils literal"><span class="pre">tf</span></tt> is <tt class="docutils literal"><span class="pre">tf</span></tt>. To change the password open
the <a class="reference internal" href="#red-brick-brickv-console"><em>console tab</em></a>.
Choose the correct serial port and press the <em>Connect</em>
button. You should be logged in as user <tt class="docutils literal"><span class="pre">tf</span></tt> (if you see nothing press Enter).
Type <tt class="docutils literal"><span class="pre">passwd</span></tt>. You will be asked for the current password. Type <tt class="docutils literal"><span class="pre">tf</span></tt>. After
that you can enter your new password.</p>
</div>
<div class="section" id="change-hdmi-display-resolution">
<span id="red-brick-change-hdmi-resolution"></span><h3>Change HDMI Display Resolution<a class="headerlink" href="#change-hdmi-display-resolution" title="Permalink to this headline">¶</a></h3>
<p>The RED Brick will automatically configure the correct display resolution using
the <a class="reference external" href="http://en.wikipedia.org/wiki/Extended_display_identification_data">Extended Display Identification Data</a>
(EDID) interface of the connected display. But EDID only works reliable if the
display is already connected to HDMI and powered on before the RED Brick boots.</p>
<p>If you connect the display to HDMI or power on the display when the RED Brick
is already running then EDID might not work and a wrong resolution might be
configured. The easiest way to fix this is to reboot the RED Brick so that the
display is connected and powered on before the RED Brick boots.</p>
<p>If you have to connect the display when the RED Brick is already running or the
automatically configured resolution is wrong for some other reason you can
manually set the resolution using the <tt class="docutils literal"><span class="pre">tf-set-resolution</span></tt> tool.</p>
<div class="section" id="using-tf-set-resolution">
<h4>Using tf-set-resolution<a class="headerlink" href="#using-tf-set-resolution" title="Permalink to this headline">¶</a></h4>
<p>To change the display resolution open the <a class="reference internal" href="#red-brick-brickv-console"><em>console tab</em></a>. Choose the correct serial port and press the
<em>Connect</em> button. You should be logged in as user <tt class="docutils literal"><span class="pre">tf</span></tt> (if you see nothing
press Enter). Type the following command (you might be asked to enter the
password for tf, the default password is <tt class="docutils literal"><span class="pre">tf</span></tt>):</p>
<div class="highlight-python"><div class="highlight"><pre>sudo tf-set-resolution hdmi mode &lt;mode-number&gt;
</pre></div>
</div>
<p>But instead of <tt class="docutils literal"><span class="pre">&lt;mode-number&gt;</span></tt> you need to put the number of the mode you
want to enable. The following manually settable modes are currently supported:</p>
<ul class="simple">
<li>0 = 480i</li>
<li>1 = 576i</li>
<li>2 = 480p</li>
<li>3 = 576p</li>
<li>4 = 720p &#64; 50Hz</li>
<li>5 = 720p &#64; 60Hz</li>
<li>6 = 1080i &#64; 50Hz</li>
<li>7 = 1080i &#64; 60Hz</li>
<li>8 = 1080p &#64; 24Hz</li>
<li>9 = 1080p &#64; 50Hz</li>
<li>10 = 1080p &#64; 60Hz</li>
<li>11 = PAL</li>
<li>12 = PAL (S-Video)</li>
<li>14 = NTSC</li>
<li>15 = NTSC (S-Video)</li>
<li>17 = PAL-M</li>
<li>18 = PAL-M (S-Video)</li>
<li>20 = PAL-NC</li>
<li>21 = PAL-NC (S-Video)</li>
<li>23 = 1080p &#64; 24Hz (3D)</li>
<li>24 = 720p &#64; 50Hz (3D)</li>
<li>25 = 720p &#64; 60Hz (3D)</li>
<li>26 = 1360 x 768 &#64; 60Hz</li>
<li>27 = 1280 x 1024 &#64; 60Hz</li>
<li>28 = 800 x 480 &#64; 60Hz (requires Image version &gt;= 1.6)</li>
</ul>
<p>If your desired display resolution is not listed as a settable mode above then
we can extend the kernel tables for this to support it. To do this you need
to tell us the relevant information for your display. First, ensure that the
resolution for your display was properly automatically configured on boot. Then
type the following command:</p>
<div class="highlight-python"><div class="highlight"><pre>dmesg | egrep &quot;(PCLK=|disp clks:)&quot;
</pre></div>
</div>
<p>and send us an email (<a class="reference external" href="mailto:info&#37;&#52;&#48;tinkerforge&#46;com">info<span>&#64;</span>tinkerforge<span>&#46;</span>com</a>) with the output of that command.</p>
</div>
</div>
</div>
<div class="section" id="hardware-description">
<span id="red-brick-hardware"></span><h2>Hardware Description<a class="headerlink" href="#hardware-description" title="Permalink to this headline">¶</a></h2>
<a class="reference external image-reference" href="../../_images/Bricks/brick_red_caption_top_1000.jpg"><img alt="RED Brick caption top" class="align-center" src="../../_images/brick_red_caption_top_fixed_width.jpg" style="width: 700.0px; height: 410.0px;" /></a>
<a class="reference external image-reference" href="../../_images/Bricks/brick_red_caption_bottom_1000.jpg"><img alt="RED Brick caption bottom" class="align-center" src="../../_images/brick_red_caption_bottom_fixed_width.jpg" style="width: 700.0px; height: 410.0px;" /></a>
<div class="section" id="power-button">
<h3>Power Button<a class="headerlink" href="#power-button" title="Permalink to this headline">¶</a></h3>
<p>The button on the RED Brick is a power button. Press it longer than 5 seconds
and the RED Brick will turn off immediately.
If the Brick is off, press the button until the blue LED lights up (ca. 3
seconds) and the Brick will boot again.</p>
</div>
<div class="section" id="leds">
<span id="red-brick-leds"></span><h3>LEDs<a class="headerlink" href="#leds" title="Permalink to this headline">¶</a></h3>
<p>The RED Brick has three LEDs on the top side: A blue, a red and a green LED.</p>
<ul class="simple">
<li>The blue LED is directly connected to the internal power supply of the
processor. The LED is on if the processor is powered.</li>
<li>The red LED shows if an error is present. If the red LED stays on during
startup, no image could be found. There may be no SD card inserted or there is
no valid image on the SD card.</li>
<li>The green LED shows the current state. If on startup the red LED is off
and the green LED does not turn on, Linux could not boot properly. During
boot-time the green LED turns on. After the RED Brick has booted up
and all of the services are available the green led starts showing a
heartbeat.</li>
</ul>
<p>To summarize, a proper boot up of the RED Brick will result in the following
sequence:</p>
<ol class="arabic simple">
<li>Blue and red on, green off (power on).</li>
<li>Red turns off (U-Boot loaded).</li>
<li>Green turns on (Linux boots).</li>
<li>Green starts blinking (heartbeat: Linux booted successfully and all
services available).</li>
</ol>
<p>You can change the function of the green and red LED. They can also
<a class="reference internal" href="#red-brick-brickv-settings-brickd"><em>show CPU or SD card usage</em></a> instead of a
heartbeat.</p>
</div>
<div class="section" id="micro-sd-card-slot">
<span id="red-brick-micro-sd-card-slot"></span><h3>Micro-SD-Card Slot<a class="headerlink" href="#micro-sd-card-slot" title="Permalink to this headline">¶</a></h3>
<p>The Linux system and your data is stored on a Micro-SD card. The slot
is located at the bottom side of the Brick.
Micro-SD (1.0), Micro-SDHC (2.0) and Micro-SDXC (3.0) cards
are supported. As a minimum we recommend a class 10 Micro-SD Card, with a read
data rate of 30MB/s as minimum, to ensure fast reads and writes.</p>
<p>A description of the images can be found in the
<a class="reference internal" href="#red-brick-images"><em>image section</em></a>.</p>
</div>
<div class="section" id="usb-2-0-host">
<span id="red-brick-usb-host"></span><h3>USB 2.0 Host<a class="headerlink" href="#usb-2-0-host" title="Permalink to this headline">¶</a></h3>
<p>The RED Brick is equipped with a standard
<a class="reference external" href="http://en.wikipedia.org/wiki/USB">USB-2.0</a> (480Mb/s) type A jack. It can
power other USB devices with up to 7.5W (5V/1.5A) and is short circuit
protected. Typical USB devices such as Wi-Fi or Ethernet dongles, webcams,
printers, keyboards, mouses or USB touch screens are supported.
The wiki has a growing <a class="reference external" href="http://www.tinkerunity.org/wiki/index.php/EN/RED_USB">list of USB devices</a> that users have
successfully tested with a RED Brick.</p>
<p>Some Ethernet or Wi-Fi dongles can be directly configured with the Brick Viewer.
<a class="reference external" href="https://www.tinkerforge.com/en/shop/accessories/red-brick.html">Supported dongles</a>
can be found in our shop. Other devices might have
to be configured directly in the Linux system and can't be configured with the
Brick Viewer.</p>
</div>
<div class="section" id="mini-usb">
<span id="red-brick-mini-usb"></span><h3>Mini-USB<a class="headerlink" href="#mini-usb" title="Permalink to this headline">¶</a></h3>
<p>With the Mini-USB connector, the RED Brick can be controlled and configured
through the <a class="reference internal" href="#red-brick-brickv"><em>Brick Viewer</em></a>. It can also be used to
power the Brick.</p>
</div>
<div class="section" id="micro-hdmi">
<span id="red-brick-hdmi"></span><h3>Micro-HDMI<a class="headerlink" href="#micro-hdmi" title="Permalink to this headline">¶</a></h3>
<p>With the Micro-<a class="reference external" href="http://en.wikipedia.org/wiki/HDMI">HDMI</a> connector
(also called type D), all standard HDMI monitors and TVs can be connected to
the RED Brick. HDMI Ethernet Channel (HEC) is not supported.</p>
</div>
<div class="section" id="brick-stack-connector">
<h3>Brick Stack Connector<a class="headerlink" href="#brick-stack-connector" title="Permalink to this headline">¶</a></h3>
<p>The RED Brick can control up to eight other Bricks through the stack
connectors. Additionally up to two Master Extensions can be used with the RED
Brick. Currently only the <a class="reference internal" href="../Master_Extensions/RS485_Extension.html#rs485-extension"><em>RS485 Extension</em></a> all versions
of the <a class="reference internal" href="../Master_Extensions/Ethernet_Extension.html#ethernet-extension"><em>Ethernet Extension</em></a> are supported. In a stack
each Extension can only be present one time,
such that two RS485 or two Ethernet Extension can't be used.</p>
<p>The <a class="reference internal" href="../Master_Extensions/WIFI_Extension.html#wifi-extension"><em>WIFI Extension</em></a> is currently not supported. We
recommend to use a USB Wi-Fi dongle to add Wi-Fi connectivity to the RED Brick.</p>
<p>The Ethernet Extension shows up as a normal Ethernet interface in the
underlying Linux system.</p>
<p>A <a class="reference internal" href="../Power_Supplies/Step_Down.html#step-down-power-supply"><em>Step-Down Power Supply</em></a> can be put below the
RED Brick and can power the whole stack.</p>
</div>
<div class="section" id="gpio-header">
<h3>GPIO Header<a class="headerlink" href="#gpio-header" title="Permalink to this headline">¶</a></h3>
<div class="admonition note">
<p class="first admonition-title">Note</p>
<p class="last">This header is intended for advanced users to connect their own hardware.
Currently there is no software support for any of the functions of this
GPIO connector.</p>
</div>
<p>The RED Brick is equipped with a 21 pin (0.25mm pitch) FPC GPIO connector
(Molex 502078-2110).</p>
<p>All signals of Port E of the A10s processor are connected to this GPIO
connector. These signals can be configured for several functions:</p>
<p>General Purpose Input/Output, Transport Stream Controller (TS), Camera Sensor
Interface (CSI), Serial Peripheral Interface (SPI), Secure Digital Memory 3.0
Card Controller (SDC), Universal Asynchronous Receiver Transmitter (UART),
Interrupt capable. Additionally a I2C (TWI) interface is connected to this GPIO.</p>
<table border="1" class="docutils">
<colgroup>
<col width="6%" />
<col width="12%" />
<col width="83%" />
</colgroup>
<thead valign="bottom">
<tr class="row-odd"><th class="head">Pin</th>
<th class="head">Signal</th>
<th class="head">Description</th>
</tr>
</thead>
<tbody valign="top">
<tr class="row-even"><td>1</td>
<td>5V</td>
<td>5V Power Supply</td>
</tr>
<tr class="row-odd"><td>2</td>
<td>3V3</td>
<td>3.3V Power Supply</td>
</tr>
<tr class="row-even"><td>3</td>
<td>PE0</td>
<td>TS Clock, CSI Pixel Clock, SPI Chip Select 0, INT14, GPIO</td>
</tr>
<tr class="row-odd"><td>4</td>
<td>GND</td>
<td>Ground</td>
</tr>
<tr class="row-even"><td>5</td>
<td>PE1</td>
<td>TS Error, CSI Sensor Clock, SPI Clock, INT15, GPIO</td>
</tr>
<tr class="row-odd"><td>6</td>
<td>GND</td>
<td>Ground</td>
</tr>
<tr class="row-even"><td>7</td>
<td>PE2</td>
<td>TS Sync, CSI Horizontal Sync, SPI MOSI, GPIO</td>
</tr>
<tr class="row-odd"><td>8</td>
<td>GND</td>
<td>Ground</td>
</tr>
<tr class="row-even"><td>9</td>
<td>PE3</td>
<td>TS Data Valid, CSI Vertical Sync, SPI MISO, GPIO</td>
</tr>
<tr class="row-odd"><td>10</td>
<td>GND</td>
<td>Ground</td>
</tr>
<tr class="row-even"><td>11</td>
<td>PE4</td>
<td>TS Data 0, CSI Data 0, SD Controller Data 0, GPIO</td>
</tr>
<tr class="row-odd"><td>12</td>
<td>PE5</td>
<td>TS Data 1, CSI Data 1, SD Controller Data 1, GPIO</td>
</tr>
<tr class="row-even"><td>13</td>
<td>PE6</td>
<td>TS Data 2, CSI Data 2, SD Controller Data 2, GPIO</td>
</tr>
<tr class="row-odd"><td>14</td>
<td>PE7</td>
<td>TS Data 3, CSI Data 3, SD Controller Data 3, GPIO</td>
</tr>
<tr class="row-even"><td>15</td>
<td>PE8</td>
<td>TS Data 4, CSI Data 4, SD Controller Command, GPIO</td>
</tr>
<tr class="row-odd"><td>16</td>
<td>PE9</td>
<td>TS Data 5, CSI Data 5, SD Controller Clock, GPIO</td>
</tr>
<tr class="row-even"><td>17</td>
<td>PE10</td>
<td>TS Data 6, CSI Data 6, UART TX, GPIO</td>
</tr>
<tr class="row-odd"><td>18</td>
<td>PE11</td>
<td>TS Data 7, CSI Data 7, UART RX, GPIO</td>
</tr>
<tr class="row-even"><td>19</td>
<td>GND</td>
<td>Ground</td>
</tr>
<tr class="row-odd"><td>20</td>
<td>PB15</td>
<td>I2C Clock (with 2k2 Pullup), GPIO</td>
</tr>
<tr class="row-even"><td>21</td>
<td>PB16</td>
<td>I2C Data (with 2k2 Pullup), GPIO</td>
</tr>
</tbody>
</table>
</div>
<div class="section" id="power-supply">
<h3>Power Supply<a class="headerlink" href="#power-supply" title="Permalink to this headline">¶</a></h3>
<p>The RED Brick needs to be powered by a 5V supply. It can be powered through
the Mini-USB connector or a
<a class="reference internal" href="../Power_Supplies/Step_Down.html#step-down-power-supply"><em>Step-Down Power Supply</em></a>. A single RED Brick needs
up to 1.1 Watts, so that a typical 5W (5V/1A) USB power supply will suffice to
power it and a Master Brick with a few connected Bricklets. If you use a
larger setup, calculate the power requirements and choose a suitable power
supply with enough power reserves. Don't forget to add the consumption of
additionally connected USB devices.</p>
</div>
</div>
<div class="section" id="faq">
<span id="red-brick-faq"></span><h2>FAQ<a class="headerlink" href="#faq" title="Permalink to this headline">¶</a></h2>
<ul>
<li><p class="first">Q: I connected the RED Brick to my Linux PC. Why is there no <tt class="docutils literal"><span class="pre">/dev/ttyACM0</span></tt>
device to access its serial console?</p>
<p>A: The <tt class="docutils literal"><span class="pre">cdc_acm</span></tt> driver has to be loaded for this to work.</p>
</li>
<li><p class="first">Q: The red and blue LED are on. But nothing happens.</p>
<p>A: The RED Brick is not booting. Please check your Micro-SD card.</p>
</li>
</ul>
</div>
<div class="section" id="known-issues">
<span id="red-brick-known-issues"></span><h2>Known Issues<a class="headerlink" href="#known-issues" title="Permalink to this headline">¶</a></h2>
<p><strong>Second Master Extension does not work all the time</strong> (solved)</p>
<p>The kernel configuration in image version 1.0 is erroneous.
This results in the second Master Extension not working all the time if two
Extension are used at the same time.</p>
<p>Since image version 1.1 the kernel configuration is fixed and this problem
does not occur anymore.</p>
<p><strong>C# program crashes on startup</strong> (solved)</p>
<p>Image version 1.0 contain C# bindings, that were compiled for
CLR version 4. With this C# bindings Mono crashes if the C# program was compiled
for CLR version 2:</p>
<div class="highlight-python"><div class="highlight"><pre>Missing method .ctor in assembly /usr/lib/Tinkerforge.dll, type System.Runtime.Versioning.TargetFrameworkAttribute
</pre></div>
</div>
<p>This problem can be avoided by compiling the C# program for CLR version 4 or
by adding the following line to the Mono options in <a class="reference internal" href="RED_Brick_Program_Tab.html#red-brick-program-tab-step3-csharp"><em>C# configuration</em></a> of the program:</p>
<div class="highlight-python"><div class="highlight"><pre>--runtime=v4.0
</pre></div>
</div>
<p>This problem only affect image version 1.0. Since image version 1.1 the
C# bindings are compiled for CLR version 2 again, which fixes the problem.</p>
<p><strong>Stack with NFC/RFID Bricklet on RED Brick does not show up in Brick Viewer</strong> (solved)</p>
<p>Problematic setup: Master Brick with NFC/RFID Bricklet and any other Bricklet
on top of a RED Brick. In this cases on the RED Brick shows up in Brick Viewer
but none of the Bricks and Bricklets in the stack.</p>
<p>The problem is caused by an incompatibility in the NFC/RFID Bricklet plugin
version 2.0.0. The incompatibility is fixed in plugin version 2.0.1.</p>
<p><strong>FPC (Delphi/Lazarus) Library not available on RED Brick</strong> (solved)</p>
<p>Unfortunately we introduced a bug in the Delphi/Lazarus Bindings through
a last-minute change. Because of the bug there is no FPC Library installed
on the RED Brick image (version 1.0 and 1.1). This will be fixed in version 1.2,
in the meantime you can fix this issue through the console with the following
commands:</p>
<div class="highlight-python"><div class="highlight"><pre>sudo su
# password = tf

cd /usr/tinkerforge/bindings/delphi/source/
sed -i -e &#39;s/BrickRED//g&#39; Makefile.fpc
export FPCDIR=/usr/lib/fpc/`ls /usr/lib/fpc/ | grep -E [0-9].[0-9].[0-9] | head -n1`
fpcmake
make
make install
</pre></div>
</div>
<p>Now the FPC Library should be installed properly and everything should work as
expected!</p>
<p>The problem only affects image version 1.0 and 1.1, it is fixed since image
version 1.2.</p>
<p><strong>No name resolution</strong> (solved)</p>
<p>In Image version 1.2 there is no name resolution (DNS) by default. You
can fix this through the console:</p>
<div class="highlight-python"><div class="highlight"><pre>sudo su
# enter password tf

echo &quot;nameserver 8.8.8.8&quot; &gt; /etc/resolv.conf
</pre></div>
</div>
<p>The problem only affects image version 1.2, it is fixed since image
version 1.3.</p>
<p><strong>Ethernet Extension shows up in Extension tab but not in network settings</strong> (solved)</p>
<p>In Image version 1.4 the RED Bricks may have problems finding the driver for the
Ethernet extension. If you encounter this problem you can fix this through the
console:</p>
<div class="highlight-python"><div class="highlight"><pre>sudo su
# enter password tf

ln -s /lib/modules/3.4.103+/kernel/drivers/net/ethernet/wiznet/w5x00.ko /lib/modules/3.4.90+/kernel/drivers/net/ethernet/wiznet/
</pre></div>
</div>
<p>The problem only affects the RED Brick Image with version 1.4.</p>
</div>
<div class="section" id="history">
<span id="red-brick-history"></span><h2>History<a class="headerlink" href="#history" title="Permalink to this headline">¶</a></h2>
<p>The development of the RED Brick took almost a year and is documented in
several blog posts:</p>
<ul class="simple">
<li><a class="reference external" href="http://www.tinkerforge.com/en/blog/2014/2/21/tinkerforge-goes-stand-alone-aka-red-brick">Tinkerforge goes Stand-Alone aka RED Brick</a></li>
<li><a class="reference external" href="http://www.tinkerforge.com/en/blog/2014/4/10/red-brick-circuit-boards-arrived">RED Brick circuit boards arrived</a></li>
<li><a class="reference external" href="http://www.tinkerforge.com/en/blog/2014/5/13/red-brick-news">RED Brick news</a></li>
<li><a class="reference external" href="http://www.tinkerforge.com/en/blog/2014/5/23/red-brick:-does-it-work">RED Brick: Does it work?</a></li>
<li><a class="reference external" href="http://www.tinkerforge.com/en/blog/2014/6/20/red-brick-software-infrastructure">RED Brick Software Infrastructure</a></li>
<li><a class="reference external" href="http://www.tinkerforge.com/en/blog/2014/8/28/red-brick-in-emc-laboratory">RED Brick in EMC laboratory</a></li>
<li><a class="reference external" href="http://www.tinkerforge.com/en/blog/2014/10/16/red-brick-status-report">RED Brick status report</a></li>
<li><a class="reference external" href="http://www.tinkerforge.com/en/blog/2014/11/12/the-red-brick-countdown-has-started">The RED Brick Countdown has started</a></li>
</ul>
</div>
<div class="section" id="programming-interface">
<span id="red-brick-programming-interface"></span><h2>Programming Interface<a class="headerlink" href="#programming-interface" title="Permalink to this headline">¶</a></h2>
<p>The RED Brick API is meant to be used by the Brick Viewer to implement the
offered  functionality (getting status information, managing programs etc.).
Normal users will not need to use this API, it may only be interesting for
power users.</p>
<p>See <a class="reference internal" href="../../Programming_Interface.html#programming-interface"><em>Programming Interface</em></a> for a detailed description.</p>
<table border="1" class="docutils">
<colgroup>
<col width="45%" />
<col width="18%" />
<col width="18%" />
<col width="18%" />
</colgroup>
<thead valign="bottom">
<tr class="row-odd"><th class="head">Language</th>
<th class="head">API</th>
<th class="head">Examples</th>
<th class="head">Installation</th>
</tr>
</thead>
<tbody valign="top">
<tr class="row-even"><td>Modbus</td>
<td><a class="reference internal" href="../../Software/Bricks/RED_Brick_Modbus.html#red-brick-modbus-api"><em>API</em></a></td>
<td>&nbsp;</td>
<td>&nbsp;</td>
</tr>
<tr class="row-odd"><td>TCP/IP</td>
<td><a class="reference internal" href="../../Software/Bricks/RED_Brick_TCPIP.html#red-brick-tcpip-api"><em>API</em></a></td>
<td>&nbsp;</td>
<td>&nbsp;</td>
</tr>
<tr class="row-even"><td>C/C++</td>
<td><a class="reference internal" href="../../Software/Bricks/RED_Brick_C.html#red-brick-c-api"><em>API</em></a></td>
<td><a class="reference internal" href="../../Software/Bricks/RED_Brick_C.html#red-brick-c-examples"><em>Examples</em></a></td>
<td><a class="reference internal" href="../../Software/API_Bindings_C.html#api-bindings-c"><em>Installation</em></a></td>
</tr>
<tr class="row-odd"><td>C#</td>
<td><a class="reference internal" href="../../Software/Bricks/RED_Brick_CSharp.html#red-brick-csharp-api"><em>API</em></a></td>
<td><a class="reference internal" href="../../Software/Bricks/RED_Brick_CSharp.html#red-brick-csharp-examples"><em>Examples</em></a></td>
<td><a class="reference internal" href="../../Software/API_Bindings_CSharp.html#api-bindings-csharp"><em>Installation</em></a></td>
</tr>
<tr class="row-even"><td>Delphi/Lazarus</td>
<td><a class="reference internal" href="../../Software/Bricks/RED_Brick_Delphi.html#red-brick-delphi-api"><em>API</em></a></td>
<td><a class="reference internal" href="../../Software/Bricks/RED_Brick_Delphi.html#red-brick-delphi-examples"><em>Examples</em></a></td>
<td><a class="reference internal" href="../../Software/API_Bindings_Delphi.html#api-bindings-delphi"><em>Installation</em></a></td>
</tr>
<tr class="row-odd"><td>Java</td>
<td><a class="reference internal" href="../../Software/Bricks/RED_Brick_Java.html#red-brick-java-api"><em>API</em></a></td>
<td><a class="reference internal" href="../../Software/Bricks/RED_Brick_Java.html#red-brick-java-examples"><em>Examples</em></a></td>
<td><a class="reference internal" href="../../Software/API_Bindings_Java.html#api-bindings-java"><em>Installation</em></a></td>
</tr>
<tr class="row-even"><td>JavaScript</td>
<td><a class="reference internal" href="../../Software/Bricks/RED_Brick_JavaScript.html#red-brick-javascript-api"><em>API</em></a></td>
<td><a class="reference internal" href="../../Software/Bricks/RED_Brick_JavaScript.html#red-brick-javascript-examples"><em>Examples</em></a></td>
<td><a class="reference internal" href="../../Software/API_Bindings_JavaScript.html#api-bindings-javascript"><em>Installation</em></a></td>
</tr>
<tr class="row-odd"><td>LabVIEW</td>
<td><a class="reference internal" href="../../Software/Bricks/RED_Brick_LabVIEW.html#red-brick-labview-api"><em>API</em></a></td>
<td><a class="reference internal" href="../../Software/Bricks/RED_Brick_LabVIEW.html#red-brick-labview-examples"><em>Examples</em></a></td>
<td><a class="reference internal" href="../../Software/API_Bindings_LabVIEW.html#api-bindings-labview"><em>Installation</em></a></td>
</tr>
<tr class="row-even"><td>Mathematica</td>
<td><a class="reference internal" href="../../Software/Bricks/RED_Brick_Mathematica.html#red-brick-mathematica-api"><em>API</em></a></td>
<td><a class="reference internal" href="../../Software/Bricks/RED_Brick_Mathematica.html#red-brick-mathematica-examples"><em>Examples</em></a></td>
<td><a class="reference internal" href="../../Software/API_Bindings_Mathematica.html#api-bindings-mathematica"><em>Installation</em></a></td>
</tr>
<tr class="row-odd"><td>MATLAB/Octave</td>
<td><a class="reference internal" href="../../Software/Bricks/RED_Brick_MATLAB.html#red-brick-matlab-api"><em>API</em></a></td>
<td><a class="reference internal" href="../../Software/Bricks/RED_Brick_MATLAB.html#red-brick-matlab-examples"><em>Examples</em></a></td>
<td><a class="reference internal" href="../../Software/API_Bindings_MATLAB.html#api-bindings-matlab"><em>Installation</em></a></td>
</tr>
<tr class="row-even"><td>Perl</td>
<td><a class="reference internal" href="../../Software/Bricks/RED_Brick_Perl.html#red-brick-perl-api"><em>API</em></a></td>
<td><a class="reference internal" href="../../Software/Bricks/RED_Brick_Perl.html#red-brick-perl-examples"><em>Examples</em></a></td>
<td><a class="reference internal" href="../../Software/API_Bindings_Perl.html#api-bindings-perl"><em>Installation</em></a></td>
</tr>
<tr class="row-odd"><td>PHP</td>
<td><a class="reference internal" href="../../Software/Bricks/RED_Brick_PHP.html#red-brick-php-api"><em>API</em></a></td>
<td><a class="reference internal" href="../../Software/Bricks/RED_Brick_PHP.html#red-brick-php-examples"><em>Examples</em></a></td>
<td><a class="reference internal" href="../../Software/API_Bindings_PHP.html#api-bindings-php"><em>Installation</em></a></td>
</tr>
<tr class="row-even"><td>Python</td>
<td><a class="reference internal" href="../../Software/Bricks/RED_Brick_Python.html#red-brick-python-api"><em>API</em></a></td>
<td><a class="reference internal" href="../../Software/Bricks/RED_Brick_Python.html#red-brick-python-examples"><em>Examples</em></a></td>
<td><a class="reference internal" href="../../Software/API_Bindings_Python.html#api-bindings-python"><em>Installation</em></a></td>
</tr>
<tr class="row-odd"><td>Ruby</td>
<td><a class="reference internal" href="../../Software/Bricks/RED_Brick_Ruby.html#red-brick-ruby-api"><em>API</em></a></td>
<td><a class="reference internal" href="../../Software/Bricks/RED_Brick_Ruby.html#red-brick-ruby-examples"><em>Examples</em></a></td>
<td><a class="reference internal" href="../../Software/API_Bindings_Ruby.html#api-bindings-ruby"><em>Installation</em></a></td>
</tr>
<tr class="row-even"><td>Shell</td>
<td><a class="reference internal" href="../../Software/Bricks/RED_Brick_Shell.html#red-brick-shell-api"><em>API</em></a></td>
<td><a class="reference internal" href="../../Software/Bricks/RED_Brick_Shell.html#red-brick-shell-examples"><em>Examples</em></a></td>
<td><a class="reference internal" href="../../Software/API_Bindings_Shell.html#api-bindings-shell"><em>Installation</em></a></td>
</tr>
<tr class="row-odd"><td>Visual Basic .NET</td>
<td><a class="reference internal" href="../../Software/Bricks/RED_Brick_VBNET.html#red-brick-vbnet-api"><em>API</em></a></td>
<td><a class="reference internal" href="../../Software/Bricks/RED_Brick_VBNET.html#red-brick-vbnet-examples"><em>Examples</em></a></td>
<td><a class="reference internal" href="../../Software/API_Bindings_VBNET.html#api-bindings-vbnet"><em>Installation</em></a></td>
</tr>
</tbody>
</table>
</div>
</div>


          </div>
        </div>
      </div>
      <div class="clearer"></div>
    </div>
		<div id="tf_license">
			<a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/">
				<img alt="Creative Commons Licence" width="88" height="31" style="border-width:0" src="/static/images/cc_license_logo.png" />
			</a>
			The content of this page is licensed under
			<a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/">Creative Commons Attribution 3.0 Unported License</a>.
		</div>
		</div>
	</div>
</div>

    <div class="footer">
        &copy; Copyright 2011-2015, Olaf Lüke (olaf@tinkerforge.com).
      Created using <a href="http://sphinx-doc.org/">Sphinx</a> 1.2.2.
    </div>
  </body>
</html>