#include "imd.h"#include "vmdsock.h"#include <string.h>#include <errno.h>#include <stdlib.h>Go to the source code of this file.
| Compounds | |
| struct | IMDheader | 
| IMD communication protocol message header structure. More... | |
| struct | netint | 
| structure used to perform byte swapping operations. More... | |
| Defines | |
| #define | HEADERSIZE 8 | 
| #define | IMDVERSION 2 | 
| Functions | |
| void | swap4_aligned (void *v, long ndata) | 
| int32 | imd_htonl (int32 h) | 
| int32 | imd_ntohl (int32 n) | 
| void | fill_header (IMDheader *header, IMDType type, int32 length) | 
| void | swap_header (IMDheader *header) | 
| int32 | imd_readn (void *s, char *ptr, int32 n) | 
| int32 | imd_writen (void *s, const char *ptr, int32 n) | 
| int | imd_disconnect (void *s) | 
| int | imd_pause (void *s) | 
| int | imd_kill (void *s) | 
| int | imd_go (void *s) | 
| int | imd_handshake (void *s) | 
| int | imd_trate (void *s, int32 rate) | 
| int | imd_send_mdcomm (void *s, int32 n, const int32 *indices, const float *forces) | 
| int | imd_send_energies (void *s, const IMDEnergies *energies) | 
| int | imd_send_fcoords (void *s, int32 n, const float *coords) | 
| IMDType | imd_recv_header_nolengthswap (void *s, int32 *length) | 
| IMDType | imd_recv_header (void *s, int32 *length) | 
| int | imd_recv_handshake (void *s) | 
| int | imd_recv_mdcomm (void *s, int32 n, int32 *indices, float *forces) | 
| int | imd_recv_energies (void *s, IMDEnergies *energies) | 
| int | imd_recv_fcoords (void *s, int32 n, float *coords) | 
| 
 | 
| 
 Definition at line 37 of file imd.C. Referenced by imd_disconnect, imd_go, imd_handshake, imd_kill, imd_pause, imd_recv_header, imd_recv_header_nolengthswap, imd_send_energies, imd_send_fcoords, imd_send_mdcomm, and imd_trate. | 
| 
 | 
| 
 Definition at line 38 of file imd.C. Referenced by imd_handshake, and imd_recv_handshake. | 
| 
 | ||||||||||||||||
| 
 Definition at line 79 of file imd.C. References imd_htonl, IMDType, IMDheader::length, length, and IMDheader::type. | 
| 
 | 
| leave sim running but close IMD Definition at line 127 of file imd.C. References fill_header, HEADERSIZE, IMD_DISCONNECT, and imd_writen. | 
| 
 | 
| 
 Definition at line 145 of file imd.C. References fill_header, HEADERSIZE, IMD_GO, and imd_writen. Referenced by imd_recv_handshake. | 
| 
 | 
| check endianness, version compat Definition at line 152 of file imd.C. References fill_header, HEADERSIZE, IMD_HANDSHAKE, imd_writen, IMDVERSION, and IMDheader::length. | 
| 
 | 
| 
 Definition at line 53 of file imd.C. References n. Referenced by fill_header. | 
| 
 | 
| kill simulation, shutdown IMD Definition at line 139 of file imd.C. References fill_header, HEADERSIZE, IMD_KILL, and imd_writen. | 
| 
 | 
| 
 Definition at line 70 of file imd.C. References netint::high, netint::highest, netint::low, netint::lowest, and n. Referenced by swap_header. | 
| 
 | 
| pause simulation Definition at line 133 of file imd.C. References fill_header, HEADERSIZE, IMD_PAUSE, and imd_writen. | 
| 
 | ||||||||||||||||
| 
 Definition at line 89 of file imd.C. References n, and vmdsock_read. | 
| 
 | ||||||||||||
| Receive energies Definition at line 251 of file imd.C. References imd_readn. | 
| 
 | ||||||||||||||||
| Receive atom coordinates and forces, units are Kcal/mol/angstrom | 
| 
 | 
| recv_handshake returns 0 if server and client have the same relative endianism; returns 1 if they have opposite endianism, and -1 if there was an error in the handshake process. Definition at line 219 of file imd.C. References imd_go, IMD_HANDSHAKE, imd_recv_header_nolengthswap, IMDType, IMDVERSION, swap4_aligned, and vmdsock_selread. | 
| 
 | ||||||||||||
| Receive header and data Definition at line 210 of file imd.C. References HEADERSIZE, IMD_IOERROR, imd_readn, IMDType, IMDheader::length, length, swap_header, and IMDheader::type. | 
| 
 | ||||||||||||
| 
 Definition at line 201 of file imd.C. References HEADERSIZE, IMD_IOERROR, imd_readn, IMDType, IMDheader::length, length, swap_header, and IMDheader::type. Referenced by imd_recv_handshake. | 
| 
 | ||||||||||||||||||||
| Receive MDComm-style forces, units are Kcal/mol/angstrom | 
| 
 | ||||||||||||
| Send energies Definition at line 178 of file imd.C. References fill_header, HEADERSIZE, IMD_ENERGIES, imd_writen, and size. | 
| 
 | ||||||||||||||||
| Send atom forces and coordinates, units are Kcal/mol/angstrom Definition at line 189 of file imd.C. References fill_header, HEADERSIZE, IMD_FCOORDS, imd_writen, n, and size. | 
| 
 | ||||||||||||||||||||
| Send MDComm compatible forces, units are Kcal/mol/angstrom Definition at line 166 of file imd.C. References fill_header, HEADERSIZE, IMD_MDCOMM, imd_writen, n, and size. | 
| 
 | ||||||||||||
| set IMD update transmission rate Definition at line 159 of file imd.C. References fill_header, HEADERSIZE, IMD_TRATE, and imd_writen. | 
| 
 | ||||||||||||||||
| 
 Definition at line 108 of file imd.C. References n, and vmdsock_write. | 
| 
 | ||||||||||||
| 
 Definition at line 42 of file imd.C. References data. | 
| 
 | 
| 
 Definition at line 84 of file imd.C. References imd_ntohl, IMDheader::length, and IMDheader::type. | 
 1.2.14 written by Dimitri van Heesch,
 © 1997-2002
1.2.14 written by Dimitri van Heesch,
 © 1997-2002