home *** CD-ROM | disk | FTP | other *** search
/ Dream 57 / Amiga_Dream_57.iso / Amiga / Programmation / e / Modules / AmiTCP_beta.lha / AmiTCP.beta.readme
Encoding:
Text File  |  1996-08-13  |  2.1 KB  |  59 lines

  1. AmiTCP modules for Amiga E
  2. ==========================
  3.  
  4. This is pretty much a beta release of these modules, since I've had no
  5. bug reports on the last version (which was some time ago).  I'm still
  6. in the rather poor position of not actually running AmiTCP myself, so
  7. I am reliant on those who are...
  8.  
  9. The sources are included but, as ever, they are just for reference.
  10. In particular, you shouldn't try compiling the sources as some of the
  11. modules have had to be fiddled with to get unions etc. (and this will
  12. affect not just the module with the fiddle in it, but all those that
  13. use it).
  14.  
  15. The big difference over the last version is that one of the bitfield
  16. operations has been corrected (Wouter's documentation mislead me, but
  17. there's no real excuse for me not testing that bit!), and there is now
  18. some initialisation code.  This was present in the net.lib link
  19. library of the SAS/C version, so I guess it might be pretty important.
  20. The rest of net.lib has not yet been ported to E (unless someone knows
  21. different...).  I may start working on it but, again, I'm hardly the
  22. best person to do this, not having AmiTCP running on my Amiga!
  23.  
  24. To use the initialisation do something like this:
  25.  
  26.   MODULE 'amitcp/init/amitcp_init'
  27.  
  28.   PROC main() HANDLE
  29.     -> AmiTCP: initialise everything
  30.     amitcp_init()
  31.  
  32.     -> Your code
  33.  
  34.   EXCEPT DO
  35.  
  36.     -> Your cleanup code
  37.  
  38.     -> AmiTCP: cleanup everything
  39.     amitcp_cleanup()
  40.   ENDPROC
  41.  
  42. The initialisation code opens the 'bsdsocket' and 'usergroup'
  43. libraries, initialises I/O variables and opens a timer.  It also sets
  44. up various other arrays.  If you want your can just use the bits you
  45. need from the 'amitcp/init' directory.  It should be fairly
  46. self-explanatory.
  47.  
  48. Anyway, the key thing is this: if you use one of the init routines
  49. (e.g., amitcp_init() for the whole lot), then you must make sure you
  50. match it with the corresponding cleanup call (amitcp_cleanup() for
  51. amitcp_init()).  I'd advise that you use the exception handling method
  52. shown above.  Also, your program should *NEVER* use E's CleanUp()
  53. function, as this terminates your program immediately and gives it no
  54. chance to perform its own cleanup.
  55.  
  56. Have fun!
  57.  
  58. Jason  (jason@fsel.com)
  59.