350 likes | 464 Views
NCHARGE: Remote Management of the Field Programmable Port Extender (FPX). Todd Sproull Washington University, Applied Research Lab August 15, 2001 Supported by: NSF ANI-0096052 and Xilinx Inc. http://www.arl.wustl.edu/arl/projects/fpx. Controlling the FPX. Methods of Communication
E N D
NCHARGE: Remote Management of the Field Programmable Port Extender (FPX) Todd Sproull Washington University, Applied Research Lab August 15, 2001 Supported by: NSF ANI-0096052 and Xilinx Inc. http://www.arl.wustl.edu/arl/projects/fpx
Controlling the FPX • Methods of Communication - NCHARGE - Telnet - Web Interface / CGI - Basic_send - User Applications • Software Plug-ins - Concepts - Functionality • Emulation • Nid_listener • Rad_listener Fip Memory Manager Remote Applications Read Basic WEB Telnet Fip Send Access CGI Basic Send Software Controller NCHARGE NCHARGE 0.0 7.1 VCI 76 (NID), VCI 100 (RAD) VCI 115 (NID), VCI 123 (RAD) OC-3 Link (up to 32 VCIs) Washington University NID NID Gigabit Switch RAD RAD
Pictorial view of FPX software interfaced with hardware NCHARGE {0-7}.{0/1}
NCHARGE • Issues control cells to FPX • Provides reliable connections over ATM • Allows for multiple users to connect remotely Multiple TCP Sockets for Remote Applications NCHARGE {0-7}.{0/1} Control cells Sent to and from FPX (RAD & NID)
Controlling Flows on the NID Consists of 4 ports used for cell traffic 0 - SW (Switch) 1 - LC (Line Card) 2 - RAD_SW 3 - RAD_LC Cells routed based on VCI Lookup Table Cell routes are modified by issuing Write VCI Table Control cells VCI Table Control cells consist of number indicating the destination of a cell VCI Lookup Table is generated based on VCI Updates, default routes, and the table data definitions RAD RAD RAD RAD Switch LineCard Switch LineCard VC VC VC VC VC VC VC VC ccp ccp EC EC EC EC Switch LineCard Switch LineCard Default Flow Action VCI = 0x34 (Bypass) (Control Cell)
VCI Updates and Status • VCI Update Commands • Write VCI entries • Format: T VPI VCI SW LC RAD_SW RAD_LC • Example: T 0 7E 3 2 1 0 • Read VCI entries • Format: A VPI VCI • Example: A 0 7E • Response: A VPI=0 VCI=7E SW=3 LC=2 RAD_SW=1 RAD_LC=0 Table data definitions
VCI Updates and Status • Status Control registers • Lets users check status of FPX • Useful for debugging hardware if problems arise • Displays the following information • RAD Configuration Status (RAD_Done) • Single bit that indicates completion of configuration and beginning of startup sequence • RAD Initialization Status (RAD_Init) • Single bit that indicates when the RAD is ready to accept data • Type Link • Line card identifier ( OC3, Dual G-link…) • VCI Compare Register • Display current VCI to send control updates on • RAD Programming Byte Count • Indicates number of bytes RAD has loaded in memory
VCI Status Control Example • Checking VCI Status • Example: S • Response:VPI 0x0 VCI 0x22 Opcode 0x42 VCI Compare Register 0x22 RAD_DONE 0x1 RAD_INIT 0x1 Type LINK 0x3 RAD Programming Byte Count 0x000
Configuration Memory Updates • Memory updates provide: - A reliable protocol to transfer VHDL designs - Ability to program RAD with multiple modules - A one step transfer and program option - Debugging information by displaying the contents of a specified location in memory
Configuration Memory Example • Transfer vhdl design from PC to NID • Format: L filename offset • Example: L test_file 100 • Program RAD with NID vhdl design • Format: F offset byte_count • Example: F 100 50 NCHARGE Load Configuration Full RAD Configuration NID RAD
RAD Memory Updates • Supports 32/36/64 bit memory reads and writes - Multiple memory updates may be issued in one control cell - Memory updates are issued by module id
RAD Memory Updates Example • Reading and writing 32/36/64 bit words • Format:w32 mod_id address num_updates data • Example:w32 0 20 2 12345678 abcdef01 • Format: r32 mod_id address num_reads • Example: r32 0 20 2 • Response: Data from address 20 is 1234568 Data from address 21 is abcdef01 • Reading and Writing strings • Format: ws mod_id address ‘text’ • Example:ws 0 0 Bob_Smith • Format: rs mod_id address • Example: rs 0 0 • Response: Bob_Smith
Other Features of NCHARGE • NCHARGE also provides: • Ability to log all transactions to and from NID and RAD • Support to add customized software interfaces to hardware plug-in modules - Probe function to display modules present on FPX - An on-screen help menu in case you are lost
Emulation of the FPX • Consists of two applications: - Nid_listener Maintains VC tables Handles file transfers - Rad_listener Simulates RAD SRAM/SDRAM Responds to all memory read/write operations
Communicating with the FPX • Methods of communication -Console Mode -Telnet -Web Access -Basic_send -Library calls -User Applications (FIPL)
Telnet Access • Allows end hosts control of FPX - Supports multiple connections - Provides full functionality of console mode
Web Access to NCHARGE Web Access Provides: - Radio Button Interface - Allows user to submit commands using CGI scripts - Provides for Switch Reset - http://fpx.arl.wustl.edu
Using Basic_send Simple interface to send control cells to FPX - Opens a TCP Socket - Transfers character string command line arguments - Displays output from NCHARGE
FIPL Interface to FPX Flow of information from FIPL to FPX -Remote Host issues Add route from Web -Web Server processes command and sends to writefip over TCP socket -Write_FIP sends stdout command to FIPL -FIPL issues an add route command -Read_FIP takes stdin and packages the strings into 1 large string -Read_FIP opens a TCP socket and sends data to NCHARGE -Fpx_control reads in string and packets commands into multiple control cells for FPX
Setting up the FPX as a Router Use the FPX as a router -Start the FIPL Memory Manager software for a particular port/stack -Download a few (<100) routes from MAE-WEST -Note the name of the file that you downloaded -Submit that list of routes to the FPX on the Fast IP Lookup Page -Now the FIPL software is configured to handle these routes!! -You should be able to add additional routes -You can also delete and modify routes from the webpage
Software Plug-ins for Hardware Modules • Software that allows RAD applications the ability to format unique control cells • Enables developers to easily change the format of a control cell independent of NCHARGE
Contents of a Software Plug-in Module <module> # Module title and version number Fast IP Lookup Example Module 1.0 </module> <input_opcodes> # Input Opcode, Menu_command, Command_argument 0x14, 1,R, Root_Node_Pointer, 0x16, 1,I, IP_Flow_1, </input_opcodes> <output_opcodes> # Output opcode, Text, Command_argument 0x15, 1,Root node pointer Updated to ,Root_Node_Pointer, 0x17, 1,Name changed to ,IP_Flow_1, </output_opcodes> <fields> # Command_argument, argument_type, # start_word,start_bit,stop_word,stop_bit Root_Node_Pointer,x,1,31,1,13, IP_Flow_1,x,2,31,2,16, </fields> <help> # Help Menu R root pointer address update: R address (hex) I Update IP Flow 1: I address (hex) </help> • Tags identify relevant fields • Developer specifies data types and lengths • Provides total control over information sent to RAD application • Example is “Fast IP Lookup” module
Using Software Plug-ins • Issue Probe command to see what modules have been loaded • “p” • Load required module • “n fipl.fpx” • Issue commands for that module • “m1.r 1234” • “m1.I 4321” • Commands follow the format: • m#.command argument (if necessary)
Using Library Call Simple interface to send control cells to FPX - fpx_message(char *command,int port, int stack, char *response)
Programming Exercise Construct a loop that issues sends several strings to a particular memory location Use sleep() between fpx_message calls so you can read the strings from the FPX webpage Be sure to include libNcharge.h When compiling include the libNcharge.cpp file as well g++ your_file.c libNcharge.cpp Include a \n character at the end of the string Format for write string is: ws module_number address text_string Module number for this example is always 0