Embedded TCP/IP stack  4.0.0
FNET Shell mbedTLS Demo Quick Start

Requirements

Tools used during this quick start:

  • Supported IDE.
  • Terminal program (Tera Term Pro v4.63 http://ttssh2.sourceforge.jp).
  • WEB browser.
  • FNET project source code, coming with this document.

Step by step

Follow these steps to run the FNET Shell demo application:

  • Prepare your evaluation board according to your board User Manual.
  • Use USB or RS-232 male/female DB-9 serial cable to connect your PC (through COM port) to the evaluation board.
  • Connect the evaluation board to an Ethernet network.
  • Power the board up.
  • Invoke the terminal program on the PC to which the evaluation board is connected and configure it to:
    • Bits per second: 115200.
    • Data bits: 8.
    • Parity: none.
    • Stop bits: 1.
    • Flow control: None.

      fnet_serial_setup.jpg
      Serial port setup
  • Launch IDE.
  • Open the project:
    fnet\fnet_demos\boards\<board_name>\shell_mbedtls\<compiler_name>\
    
  • In the IDE, choose a project target you want to compile.
  • Compile, load (or flash) the application to the board and run the project.
  • In your terminal program window you should see the FNET application welcome message:
    ************************************************
     FNET Shell Application (mbedTLS)
    ************************************************
     FNET TCP/IP Stack for MK64FN1
     Version 4.0.0
     Built Oct 26 2017 at 14:14:13 by IAR
    
     Enter 'help' for command list.
    ************************************************
    [FAPP] Application parameters loaded from Flash.
    SHELL>
    [LINK] eth0: connected => Script: dhcpc autoip -n eth0; mdns -n eth0; llmnr -n eth0;
    ************************************************
     DHCPv4 Client started.
     Interface            : eth0
    ************************************************
    Press [Ctr+C] to cancel.
    [DHCP] Discovering...
    
    ************************************************
     IPv4 parameters updated :
    ************************************************
    Ethernet Interface <default>:
     Name                 : eth0
     ScopeID              : 1
     Media State          : connected
     IPv4 Address         : 192.168.0.102 <dhcp>
     IPv6 Address         : fe80::211:22ff:fe33:4455 <autoconfigurable>
     IPv4 Subnet mask     : 255.255.255.0
     IPv4 Gateway         : 192.168.0.1
     IPv4 DNS             : 192.168.0.1
     DHCP Client          : on
     DHCP Server Address  : 192.168.0.1
     AUTOIP Service       : off
     LLMNR Server         : off
     MDNS Server          : off
    
    ************************************************
     mDNS server started.
     Interface            : eth0
     Host Name            : fnet
    ************************************************
    ************************************************
     LLMNR server started.
     Interface            : eth0
     Host Name            : fnet
    ************************************************
    SHELL>
    
  • This application has absolutely the same features and behavior as the Shell demo application. So before next steps, read about it in FNET Shell Demo Quick Start.
  • You can run the HTTPS Server on the board, by typing the command https into your terminal program window.
    In your terminal program window you should see:
    SHELL> https
    ************************************************
     HTTPS server started.
     IPv4 Address     : 192.168.0.103
     IPv6 Address     : fe80::211:22ff:fe33:4455
    ************************************************
    SHELL>
    
  • Then run your Web browser and navigate to the server address (the address you have assigned to the system or obtained from the DHCP server):
    https:// 192.168.0.103
    
    or
    https:// [fe80::211:22ff:fe33:4455]
    
  • Depending on the used Web browser, you may get a warning message about that there is a problem with the security certificate. It occurs because the demo HTTPS server uses the test security certificate which was not signed by a trusted certificate authority. But a real application should use a valid certificate acquired from one of trusted certificate authorities.
    So just ignore this warning and continue to the website.
  • You should see a Web page served by the FNET HTTPS server. The HTTPS server uses the same Web pages as the normal HTTP server but transfered over the TLS protocol set.
Note
  • The application project includes mbedTLS library (https://tls.mbed.org/). Its source code is located in fnet/third_party/mbedtls-x.x.x/.
  • The mbedTLS FNET application configuration parameters are in the fnet_mdedtls_user_config.h file.
  • The MBEDTLS_CONFIG_FILE definition is set to "fnet_mbedtls_user_config.h" in preprocessor project options.

© 2005-2017 by Andrey Butok. http://fnet.sourceforge.net