|
Basic Examples |
Top Previous Next |
|
Except for Remote_loopback, all examples assume a network where the DSP has IP address “192.168.0.2” and the PC “192.168.0.1”. You can adjust the constants myIP, netmask, gateway, and destination if you need a different network configuration.
UDP Examples
Simple_send tests basic UDP communications from the DSP to the PC.
When the sender is started and the connection has been established, the sender will transmit several messages to the receiver. Both sender and receiver display the messages on the console.
Simple_receive tests UDP communications in the other direction.
TCP Examples
Simple_server makes the DSP a server that exchanges data with a PC client.
Simple_client makes the DSP a client that exchanges data with a PC server.
Remote_loopback tests communication with a computer located outside your local network. The example connects to our server and sends few kilobytes of data to it. The server is programmed to invert data and send it back to the client. The client receives the data, checks if they are correct and reports status on the screen.
|