zephyr/samples/net/dns_client
Anas Nashif d622b09bc0 samples: tests: remove obsolete KERNEL_TYPE and kernel variables
Remove those from Makefiles and testcase.ini, we now support unified kernel
only and sanitycheck script now knows how to deal with this.

Change-Id: I853ebcadfa7b56a4de5737d95f2ba096babb2e13
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2016-11-04 15:47:25 -04:00
..
src dns: Remove deprecated functionality 2016-09-12 02:15:44 +00:00
KNOWN_ISSUES samples/net: Add KNOWN_ISSUES file for NATS and DNS sample apps 2016-08-24 23:36:45 +00:00
Makefile samples: tests: remove obsolete KERNEL_TYPE and kernel variables 2016-11-04 15:47:25 -04:00
README dns: Remove deprecated functionality 2016-09-12 02:15:44 +00:00
README_API dns: Remove deprecated functionality 2016-09-12 02:15:44 +00:00
prj_galileo.conf samples/net: DNS client application 2016-08-01 18:54:07 +00:00
testcase.ini dns: Remove deprecated functionality 2016-09-12 02:15:44 +00:00

README

DNS Client Application


Requirements
------------

* Ethernet LAN for testing purposes.

* Galileo Gen 2 Development Board.

* USB-UART cable: CH340, FTDI 6-pin or equivalent for debugging.

* dnsmasq application. The dnsmasq version used in this sample is:

    dnsmasq -v
    Dnsmasq version 2.75  Copyright (c) 2000-2015 Simon Kelley


Building instructions
---------------------

* Read src/tcp_config.h, change the IP addresses according to the LAN
  environment.

* make pristine && make are enough to build this sample.

* Follow the steps indicated here:

  https://www.zephyrproject.org/doc/board/galileo.html

  to load the binary into the Galileo Dev Board.


Usage
-----

* Open a terminal window and type:

    dnsmasq -d

* Connect the USB-UART cable to the Galileo. Open a terminal and run:

    screen /dev/ttyUSB0 115200

* Connect Galileo to the LAN, Turn on the board.

* The screen terminal window will show:

    -----------------------------------------
    Domain name: not_a_real_domain_name
    [fiber:89] DNS Query: OK, ID: 0
    [fiber:92] TX: OK
    [fiber:97] RX: OK
    [fiber:102] DNS Response: ERROR <- :)

    -----------------------------------------
    Domain name: linuxfoundation.org
    [fiber:89] DNS Query: OK, ID: 1
    [fiber:92] TX: OK
    [fiber:97] RX: OK

    ****** DNS ANSWER: 0 ******
    Response: IP address            Size: 4:        140 211 169 4

    [fiber:102] DNS Response: OK

    -----------------------------------------
    Domain name: www.linuxfoundation.org
    [fiber:89] DNS Query: OK, ID: 2
    [fiber:92] TX: OK
    [fiber:97] RX: OK

    ****** DNS ANSWER: 0 ******
    Response: IP address            Size: 4:        140 211 169 4

    [fiber:102] DNS Response: OK

    -----------------------------------------
    Domain name: gnu.org
    [fiber:89] DNS Query: OK, ID: 3
    [fiber:92] TX: OK
    [fiber:97] RX: OK

    ****** DNS ANSWER: 0 ******
    Response: IP address            Size: 4:        208 118 235 148

    [fiber:102] DNS Response: OK

    -----------------------------------------
    Domain name: www.gnu.org
    [fiber:89] DNS Query: OK, ID: 4
    [fiber:92] TX: OK
    [fiber:97] RX: OK

    ****** DNS ANSWER: 0 ******
    Response: CNAME NO IP address
    CNAME: wildebeest.gnu.org


    ****** DNS ANSWER: 1 ******
    Response: IP address            Size: 4:        208 118 235 148

    [fiber:102] DNS Response: OK

    -----------------------------------------
    Domain name: npr.org
    [fiber:89] DNS Query: OK, ID: 5
    [fiber:92] TX: OK
    [fiber:97] RX: OK

    ****** DNS ANSWER: 0 ******
    Response: IP address            Size: 4:        216 35 221 76

    [fiber:102] DNS Response: OK

    -----------------------------------------
    Domain name: www.npr.org
    [fiber:89] DNS Query: OK, ID: 6
    [fiber:92] TX: OK
    [fiber:97] RX: OK

    ****** DNS ANSWER: 0 ******
    Response: CNAME NO IP address
    CNAME: www-cdn.npr.org.edgesuite.net


    ****** DNS ANSWER: 1 ******
    Response: CNAME NO IP address
    CNAME: a1723.g.akamai.net


    ****** DNS ANSWER: 2 ******
    Response: IP address            Size: 4:        63 80 4 192


    ****** DNS ANSWER: 3 ******
    Response: IP address            Size: 4:        63 80 4 161

    [fiber:102] DNS Response: OK