Introduction for SPI mapping Service Discovery Interoperability Testing. 20, Sep PWG Fumio Nagasaka

Similar documents
STUDY OF SOCKET PROGRAMMING

Outline. Distributed Computing Systems. Socket Basics (1 of 2) Socket Basics (2 of 2) 3/28/2014

Outline. Distributed Computer Systems. Socket Basics An end-point for a IP network connection. Ports. Sockets and the OS. Transport Layer.

Processes communicating. Network Communication. Sockets. Addressing processes 4/15/2013

sottotitolo Socket Programming Milano, XX mese 20XX A.A. 2016/17 Federico Reghenzani

UNIX Sockets. Developed for the Azera Group By: Joseph D. Fournier B.Sc.E.E., M.Sc.E.E.

NETWORK PROGRAMMING. Instructor: Junaid Tariq, Lecturer, Department of Computer Science

EEC-484/584 Computer Networks

Chapter 6. The Transport Layer. Transport Layer 3-1

Outline. Operating Systems. Socket Basics An end-point for a IP network connection. Ports. Network Communication. Sockets and the OS

Network Communication

TCP: Three-way handshake

Oral. Total. Dated Sign (2) (5) (3) (2)

Socket Programming for TCP and UDP

Systems software design NETWORK COMMUNICATIONS & RPC SYSTEMS

Programming with TCP/IP. Ram Dantu

Ports under 1024 are often considered special, and usually require special OS privileges to use.

Unix Network Programming

Hybrid of client-server and P2P. Pure P2P Architecture. App-layer Protocols. Communicating Processes. Transport Service Requirements

Group-A Assignment No. 6

Socket Programming. CSIS0234A Computer and Communication Networks. Socket Programming in C

CS 640: Computer Networking

Lecture 2. Outline. Layering and Protocols. Network Architecture. Layering and Protocols. Layering and Protocols. Chapter 1 - Foundation

What s an API? Do we need standardization?

CSE/EE 461 Lecture 14. Connections. Last Time. This Time. We began on the Transport layer. Focus How do we send information reliably?

Review. Preview. Closing a TCP Connection. Closing a TCP Connection. Port Numbers 11/27/2017. Packet Exchange for TCP Connection

Elementary TCP Sockets

CS 428/528 Computer Networks Lecture 01. Yan Wang

Client Server Computing

A. Basic Function Calls for Network Communications

MSc Integrated Electronics Networks Assignment. Investigation of TCP/IP Sockets and Ports. Gavin Cameron

Announcements. CS 5565 Network Architecture and Protocols. Queuing. Demultiplexing. Demultiplexing Issues (1) Demultiplexing Issues (2)

CSMC 412. Computer Networks Prof. Ashok K Agrawala Ashok Agrawala Set 2. September 15 CMSC417 Set 2 1

CS4700/CS5700 Fundamentals of Computer Networking

Tutorial on Socket Programming

Networked Applications: Sockets. Goals of Todayʼs Lecture. End System: Computer on the ʻNet. Client-server paradigm End systems Clients and servers

Socket Programming. #In the name of Allah. Computer Engineering Department Sharif University of Technology CE443- Computer Networks

A Socket Example. Haris Andrianakis & Angelos Stavrou George Mason University

Computer Networks Prof. Ashok K. Agrawala

UNIX Sockets. COS 461 Precept 1

Agenda. Before we start: Assignment #1. Routing in a wide area network. Protocols more concepts. Internetworking. Congestion control

CSE 124 Discussion Section Sockets Programming 10/10/17

System Programming. Sockets

Programming Internet with Socket API. Hui Chen, Ph.D. Dept. of Engineering & Computer Science Virginia State University Petersburg, VA 23806

The TCP Protocol Stack

Session NM056. Programming TCP/IP with Sockets. Geoff Bryant Process software

CS 351 Week 15. Course Review

Lecture 7. Followup. Review. Communication Interface. Socket Communication. Client-Server Model. Socket Programming January 28, 2005

Sockets. Jin-Soo Kim Computer Systems Laboratory Sungkyunkwan University

Networked Applications: Sockets. End System: Computer on the Net

Lecture 5 Overview! Last Lecture! This Lecture! Next Lecture! I/O multiplexing! Source: Chapter 6 of Stevens book!

Socket Programming. Sungkyunkwan University. Hyunseung Choo Copyright Networking Laboratory

Epson / 1394PWG/1212 Task Group Chair Warp 9 / 1394PWG Secretary

Content 1. SDK Library Overview API Library Introduction API Data Structure HAL Driver Function Type LIB

Communication. Sockets (Haviland Ch. 10)

Introduction to Socket Programming

Hyo-bong Son Computer Systems Laboratory Sungkyunkwan University

PA #2 Reviews. set_name, get_name, del_name. Questions? Will be modified after PA #4 ~

UNIT IV- SOCKETS Part A

Socket Programming(2/2)

UDP CONNECT TO A SERVER

CSE 333 Section 8 - Client-Side Networking

Socket Programming TCP UDP

Programming Ethernet with Socket API. Hui Chen, Ph.D. Dept. of Engineering & Computer Science Virginia State University Petersburg, VA 23806

Server-side Programming

Socket Programming. Dr. -Ing. Abdalkarim Awad. Informatik 7 Rechnernetze und Kommunikationssysteme

Lecture 3 Overview! Last Lecture! TCP/UDP and Sockets introduction!

The User Datagram Protocol

The BSD UNIX Socket Interface (CS 640 Lecture) Assignment 1. Interprocess Communication (IPC) Work Individually (no groups)

Programming Ethernet with Socket API. Hui Chen, Ph.D. Dept. of Engineering & Computer Science Virginia State University Petersburg, VA 23806

Sockets. Dong-kun Shin Embedded Software Laboratory Sungkyunkwan University Embedded Software Lab.

CS 351 Week Advanced UNIX Programming: Rochkind, Marc J. 1. To learn about System Interprocess Communication (IPC). 2. To learn about Sockets.

A Client-Server Exchange

Dependent Types in the Idris Programming Language

Computer Network Lab, SS Fachgebiet Technische Informatik, Joachim Zumbrägel. Overview. Sockets. Sockets in C.

API Reference 12/13/2014

Sockets 15H2. Inshik Song

CLIENT-SIDE PROGRAMMING

WinSock. What Is Sockets What Is Windows Sockets What Are Its Benefits Architecture of Windows Sockets Network Application Mechanics

Network Software Implementations

How do we Communicate? Introduction to Unix Network Programming. What does Alice do? What does Bob do? Two simplest networking programs

CSC209H Lecture 9. Dan Zingaro. March 11, 2015

CS321: Computer Networks Introduction to Application Layer

Internet applications

Unix Network Programming Chapter 4. Elementary TCP Sockets 광운대학교컴퓨터과학과 정보통신연구실 석사과정안중현

Introduction to Socket Programming

10th Slide Set Operating Systems

Lenuta Alboaie Computer Networks

SOCKETS. COMP750 Distributed Systems

CSc 450/550 Computer Networks Network Architectures & Client-Server Model

Department of Computer Science

Server-side Programming

CPS 214: Computer Networks. Slides by Adolfo Rodriguez

Network programming(i) Lenuta Alboaie

Networks. Practical Investigation of TCP/IP Ports and Sockets. Gavin Cameron

Distributed Systems. 02. Networking. Paul Krzyzanowski. Rutgers University. Fall 2017

CS118 Discussion 1B, Week 1. Taqi Raza BUNCHE 1209B, Fridays 12:00pm to 1:50pm

CptS 360 (System Programming) Unit 17: Network IPC (Sockets)

LAB MANUAL ( INDEX )

Ken French HELP Session 1 CS4514

Transcription:

Introduction for SPI mapping Service Discovery Interoperability Testing 20, Sep. 1999 1394 PWG Fumio Nagasaka

Open Issues are related to each other requires authorized API specification Interoperability Testing Service discovery shall be tested API definition Service discovery is one API binding to a service provided in a target How to support service discovery in API

Service Provider Interface mapping for PPDT Fumio Nagasaka Seiko Epson 20, Sep. 1999

Why API? Still API definition is an open issue Clients use API Interoperability testing requires authorized API

API policy, Type A API only includes few atomic functions Layered wrapper class satisfies more complex requirements from a client Pros simple Cons layered overhead and redundancy

Example of Type A Client side Server side Services Client A Client B Client C Name biding service lookup ISO 15740 BSD Socket Read, Write ISO 15740 BSD Socket Read/Write primitive API PPDT Server IEEE P1394.n-2000 PPDT transport layer ANSI NTICS 325-1998 SBP-2 IEEE 1394-1995

API policy, Type B well examined traditional set of functions common access from several types of clients (for example BSD sockets?) Pros reusability and compatibility with existing protocol Cons every common set has exceptions

Example of Type B Client side Client B Client A Client C Server side ISO 15740 Spooler other Server Processes BSD sockets as common API PPDT Clients API PPDT Server IEEE P1394.n-2000 PPDT transport layer ANSI NTICS 325-1998 SBP-2 IEEE 1394-1995

what shall ppdt-api provide? Clients ISO 15740 BSD Sockets Spooler Status Monitor API PPDT SBP-2 Initiator Services Connection oriented services, datagram and stream Connectionless services API PPDT SBP-2 Target IEEE 1394 bus level transaction

Example 1 Camera may use ISO 15740(PTP) directly over PPDT PC Application ISO 15740 PPDT API set Context of PPDT virtual connection Vender specific Camera BIOS and protocol driver Context of PPDT SBP-2 Initiator SBP-2 Target physical connection IEEE Std 1394-1995 IEEE Std 1394-1995

Example 2 Camera may use ISO 15740(PTP) over common API like Winsock 2.0 PC Application ISO 15740 Winsock 2.0 PPDT API set Context of PPDT virtual connection Vender specific Camera BIOS and protocol driver Context of PPDT SBP-2 Initiator SBP-2 Target physical connection IEEE Std 1394-1995 IEEE Std 1394-1995

Example 3 Other service would use their own API Image Capturing ISO 15740 Printing other PPDT API set virtual connection Vender specific Camera BIOS and protocol driver Vender specific Printer BIOS and protocol driver Context of PPDT Context of PPDT SBP-2 Initiator SBP-2 Target physical connection IEEE Std 1394-1995 IEEE Std 1394-1995

Abstraction Application shall be abstracted from a transport USB proprietary imaging class IrDA proprietary imaging class PPDT SBP-2 USB IrDA IEEE 1394 Hardware and wire protocol layer USB IrDA IEEE 1394 SBP-2 PPDT ISO 15740 PC Application

PWG shall assume four clients Print Spooler Status Monitor normally connected services with read/write/open/close style API ISO 15740 connection oriented session layer requires {event, operation, data transfer and response}, PC2001 requirements for image input device BSD Sockets

Services and Clients Symmetry of PPDT allows each peer to start session Symmetry of PPDT requests both PPDT at SBP-2 target and PPDT at SBP-2 initiator to provide same API for their clients process

Proposal { PPDT server at a target, PPDT server at an initiator, PPDT client at a target and PPDT client at an initiator } require different design, consequently these are different contexts. To facilitate these contexts to have common API for client applications, make wrapper class for each context. Common API shall be Socket Style API. Address family shall be AF_1394PWG.

Proposal (continued ) PPDT server implementation shall provide service-name registry PPDT context shall not have static name string programmed in source code, but PPDT context shall have internal name space known as name registry. Client processes of PPDT server may register service name utilizing API

Address family registration The 1394 PWG shall contact Windows Socket 2 Identifier Clearinghouse. Address families are shown from, http://www.stardust.com/wsresou rce/winsock2/ws2ident.html

Case Study for BSD Socket following up Brian s idea

Socket API BSD UNIX Sockets normally requires association of the set of { protocol, local-addr, local-process, foreign-addr, foreign-process } PPDT requires association of the set of { mode, local-addr, client-application, foreign-addr, service }

PPDT facilities PPDT provides two types of queue Control queue queue == 0 Open/Close uses management queue Data transaction queue queue <> 0 Read/Write uses data transaction queue

Service Provider I/F wrapper SPI requires wrapper layer to map each functions to PPDT queues Socket API Socket(), bind(), Listen(), Accept(), connect(), shutdwon(), Send(), Recv(), Sendto(), Recvfrom(),... SPI-PPDT wrapper PPDT control queue data queue Pure SBP-2 session IEEE 1394 bus level transaction

Socket int socket(int family, int type, int protocol); each context of PPDT peer internally allocate working memory and build task set.

Listen int listen(int sockfd, int backlog); sockfd : socket descriptor, backlog : maximum task set size. PPDT server on SBP-2 initiator tries to LOGIN to the target device, if not yet logged in, PPDT server on SBP-2 target indicate the initiator to solicit LOGIN, if yet the initiator has not logged in.

Listen (continued ) Requester at SBP-2 target Responder at SBP-2 initiator listen() Internal operation in the context (1) Please Login to me if not yet 1394 bus write to register Configuration ROM Management Agent accept() SBP-2 transaction (2) Connection Request Phase connect() IN queue number OUT reply error code Control Queue

Accept int accept(int sockfd, struct sockaddr *peer, int addrlen); sockfd : socket descriptor, peer : address of the connected peer, addrlen : length of the data structure listed in previous line.

Accept (continued ) PPDT server on SBP-2 initiator provides control queue to accept connect() request, PPDT server on SBP-2 target initialize the fetch agent for the control queue.

Bind the server of connection oriented transport requires bind() to register the mapping for a service descriptor and a queue number. The client and the server of connectionless transport also requires to call bind() by the same reason.

Bind (continued ) Client application of a server calls this function to map service name and queue number in its name space. int bind(int sockfd, struct sockaddr *myaddr, int addrlen); sockfd : socket descriptor, myaddr : protocol specific data structure for address, addrlen : length of data structure specified in previous line,

Bind (continued ) protocol specific data structure requires; { service handle, service name, node GUID } the pair of [service handle] and [service name] is internally registered and stored in name space of the server. the implementation of Bind()" for a PPDT at a target and a PPDT at an initiator might be same.

Proposal PPDT client specifies the ASCII string of required service PPDT context returns the service handle of associated service The service handle shall be associated internally for queue id The context shall keep association described above

Proposal (continued ) IN PPDT client requests ServiceName string PPDT Client PPDT context OUT PPDT context returns Service_Handle Name Registry Service A Service B Service C Queue 1 Queue 2 Queue 3

Name space and queue id PPDT server context does not know Service ID client shall register the name string of service Client Application context of PPDT client Client Application bind(s, addr, addrlen); context of PPDT server Which queue number shall I use? IN name of service OUT queue id Name Space

Service Discovery Fumio Nagasaka Seiko Epson 20, Sep. 1999

Connect Connect specifies name of service utilizing ServiceDiscovery then gets service handle to connect int connect(int sockfd, struct sockaddr *servaddr, int addrlen) sockfd : socket descriptor, myaddr : protocol specific data structure for server s address, addrlen : length of data structure specified in previous line,

Connect (continued ) Requester Responder connect() Internal operation in the context (1) Service Discovery Phase IN > Service_Name pwg1394/host_a/service_name OUT < service handle which is internally mapped to queue number Control Queue (2) Connection Request Phase IN queue number OUT reply error code Control Queue

Send int send(int sockfd, char *buff, int nbytes, int flags); sockfd : socket descriptor, buff : output buffer, nbytes : length of data in the buffer, flags : MSG_OOB = send out of band data

Sendto int sendto(int sockfd, char *buff, int nbytes, int flags, struct sockaddr *to, int addrlen); sockfd : socket descriptor, buff : output buffer, nbytes : length of data in the buffer, flags : MSG_OOB = send out of band data to : destination address, addrlen : length of data structure specified in previous line.

Recv int recv(int sockfd, char *buff, int nbytes, int flags); sockfd : socket descriptor, buff : output buffer, nbytes : length of data in the buffer, flags : { MSG_OOB, MSG_PEEK }

Recvfrom int recvfrom(int sockfd, char *buff, int nbytes, int flags, struct sockaddr *from, int addrlen); sockfd : socket descriptor, buff : output buffer, nbytes : length of data in the buffer, flags : { MSG_OOB, MSG_PEEK }, from : source address, addrlen : length of data structure specified in previous line.

Interoperability testing for PPDT Fumio Nagasaka Seiko Epson 20, Sep. 1999

Testing cases Test 2, scanning Test 1, printing Target device PC Initiator Test 3, direct printing Initiator device Target device Test 4, scanning PC Target

Testing cases Case operation how to test Testing 1 Testing 2 Testing 3 Testing 4 Printing from PC SBP-2 initiator to SBP-2 target printer Scanning from SBP-2 target scanner to PC SBP-2 initiator Direct Printing from SBP-2 initiator Scanner to SBP-2 target printer Scanning from SBP-2 initiator Scanner to PC SBP-2 target Use universal Printer Driver and PC based PPDT driver made by IHV Use WIA or TWAIN application and PC based PPDT driver made by IHV IHV dependent solution No testing guidelines Use authorized PC PPDT server process and WIA or TWAIN compliant Scanner

Application for PPDT Initiator Spooler Socket API ISO 15740 PPDT at an Initiator Application PPDT Target PPDT at a target ORB list SBP-2 Protocol ORB list Fetch Agent 1394 Bus Read 1394 Bus Write 1394 Bus Class 1394 Bus Read 1394 Bus Write

Protocol Layer (idea in 1997) may talk to has dependency Direct Printing (PC-less) OS Specific Imaging Process Application Layer Presentation Layer Session Layer Transport Layer (Device Abstracted) Network Layer AV/C DPP Digital Still Image Class 1394 PWG Cmd SBP-2 MIB TCP/UDP IP/1394 ESC/P Apple Print Access Protocol PCL Service Provider Interface (ex. WinSock 2.0, OpenTransport, Socket API) Apple Transaction Protocol PostScript IEEE 1284.4 USB Printer Class Data Link Layer FCP IP IEEE 1284.3 Physical Layer IEEE 1394 Ethernet IEEE 1284 USB Fumio Nagasaka @ PWG meeting September 16, 1997

Protocol Layer (idea in 1999) may talk to Direct Printing (PC-less) OS Specific Imaging Process has dependency TIFF, JPEG MIB ESC/P PCL PostScript Application Layer Presentation Layer Session Layer Transport Layer (Device Abstracted) Network Layer AV/C DPP ISO 15740 Picture Transfer Protocol Service Provider Interface (ex. WinSock 2.0, OpenTransport, Socket API) IEEE P1394.n Peer To Peer Data Transfer Protocol SBP-2 TCP/UDP IP/1394 Apple Print Access Protocol Apple Transaction Protocol IEEE 1284.4 USB Printer Class Data Link Layer FCP IP IEEE 1284.3 Physical Layer IEEE 1394 Ethernet IEEE 1284 USB Fumio Nagasaka @ PWG meeting September 20, 1999

Testing requirements 1 PC Initiator PC99 or PC2001 conplient hardware Windows 98 Second Edition Windows 2000 G3/G4 Power Macintosh hardware Macintosh OS 8.5 or later PPDT context provided for each OS

Testing requirements 2 PC target downloadable Configuration ROM space applicable PCI 1394 board IEEE 1212r compliant Configuration ROM, CSR space PWG authorized PPDT server process

Testing requirements 3 1394 PWG standard testing application to test basic facilities of PPDT context

Thank you! Contact me for more information Fumio.Nagasaka@exc.epson.co.jp EPSON Software Development Laboratory