|
NetBurner 3.5.6
PDF Version |
Example of sending a HTTP GET request through serial port when running a serial to Ethernet application.
Hardware Configuration:
Serial Device <–serial--> NetBurner Serial to Ethernet Device <–ethernet--> Internet
In this example we will be using a SB800EX as the "Serial Device", but this would typically be a microprocessor or FPGA with a UART that needs to communicate over a network. The source code in this file is an example of what you would need to implement in your own microprocessor to send a GET request through a NetBurner device to some other device on the network/Internet runnig a web server.
The code in the main.cpp source file was tested with the SB800EX, but should work with any of the NetBurner standard devices. A serial cable was connected from port 1 of the SB800EX to port 1 of the SBL2e development board. Since the SBL2e development board DB9 connector is cross-wired for RX and TX, all you need is a straight through serial cable.
SB800EX <–serial--> SBL2e <–ethernet--> Internet
The web page contacted is myip.dnsdynamic.com, which return the IP address of the HTTP GET request.
Software Configuration for SBL2e, serial port 1:
Running the SBL2e factory serial to Ethernet application. This was done through the web page, but you can also do it through serial AT commands.