Subversion Repositories Spectranet

[/] [trunk/] [z88dk/] [socklib/] [spectranet.asm] - Blame information for rev 495

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 138 winston
; Note that this version of spectranet.asm is intended for the C compiler.
2
; However, if your assembler doesn't like ../rom/libspectranet.asm you
3
; can try this one instead; it defines exactly the same values just using
4
; the syntax for z88dk's z80asm.
5 91 winston
DEFC PAGEIN = 0x3FF9
6
DEFC PAGEOUT = 0x007C
7
DEFC HLCALL = 0x3FFA
8
DEFC IXCALL = 0x3FFD
9
DEFC SOCKET = 0x3E00    ; Allocate a socket
10
DEFC CLOSE = 0x3E03     ; Close a socket
11
DEFC LISTEN = 0x3E06    ; Listen for incoming connections
12
DEFC ACCEPT = 0x3E09    ; Accept an incoming connection
13
DEFC BIND = 0x3E0C      ; Bind a local address to a socket
14
DEFC CONNECT = 0x3E0F   ; Connect to a remote host
15
DEFC SEND = 0x3E12      ; Send data
16
DEFC RECV = 0x3E15      ; Receive data
17
DEFC SENDTO = 0x3E18    ; Send data to an address
18
DEFC RECVFROM = 0x3E1B  ; Receive data from an address
19
DEFC POLL_ROM = 0x3E1E  ; Poll a list of sockets
20
DEFC POLLALL_ROM = 0x3E21       ; Poll all open sockets
21
DEFC POLLFD_ROM = 0x3E24        ; Poll a single socket
22
DEFC GETHOSTBYNAME_ROM = 0x3E27 ; Look up a hostname
23 138 winston
DEFC PUTCHAR42_ROM = 0x3E2A     ; 42 column print write a character
24
DEFC PRINT42_ROM = 0x3E2D       ; 42 column print a null terminated string
25
DEFC CLEAR42_ROM = 0x3E30       ; Clear the screen and reset 42-col print
26
DEFC SETPAGEA_ROM = 0x3E33      ; Sets page area A
27
DEFC SETPAGEB_ROM = 0x3E36      ; Sets page area B
28
DEFC LONG2IPSTRING_ROM = 0x3E39 ; Convert a 4 byte big endian long to an IP
29
DEFC IPSTRING2LONG_ROM = 0x3E3C ; Convert an IP to a 4 byte big endian long
30
DEFC RAND16_ROM = 0x3E42        ; 16 bit PRNG
31 91 winston
DEFC REMOTEADDRESS = 0x3E45     ; Fill struct sockaddr_in
32 138 winston
DEFC IFCONFIG_INET_ROM = 0x3E48 ; set inet4 address
33
DEFC IFCONFIG_NETMASK_ROM = 0x3E4B      ; Set netmask
34
DEFC IFCONFIG_GW_ROM = 0x3E4E   ; Set gateway
35
DEFC SETHWADDR_ROM = 0x3E51     ; Set the MAC address
36
DEFC GETHWADDR_ROM = 0x3E54     ; Read the MAC address
37
DEFC DECONFIG_ROM = 0x3E57      ; Deconfigure inet, netmask and gateway
38
DEFC MAC2STRING_ROM = 0x3E5A    ; Convert 6 byte MAC address to a string
39
DEFC STRING2MAC_ROM = 0x3E5D    ; Convert a hex string to a 6 byte MAC address
40
DEFC INPUTSTRING_ROM = 0x3E6C   ; Read a string into buffer at DE
41
DEFC GET_IFCONFIG_INET_ROM = 0x3E6F     ; Gets the current IPv4 address
42
DEFC GET_IFCONFIG_NETMASK_ROM = 0x3E72  ; Gets the current netmask
43
DEFC GET_IFCONFIG_GW_ROM = 0x3E75       ; Gets the current gateway address
44
DEFC SETTRAP_ROM = 0x3E78       ; Sets the programmable trap
45
DEFC DISABLETRAP_ROM = 0x3E7B   ; Disables the programmable trap
46
DEFC ENABLETRAP_ROM = 0x3E7E    ; Enables the programmable trap
47
DEFC PUSHPAGEA_ROM = 0x3E81     ; Pages a page into area A, pushing the old one
48
DEFC POPPAGEA_ROM = 0x3E84      ; Restores the previous page in area A
49
DEFC PUSHPAGEB_ROM = 0x3E87     ; Pages into area B pushing the old one
50
DEFC POPPAGEB_ROM = 0x3E8A      ; Restores the previous page in area B
51
DEFC PAGETRAPRETURN_ROM = 0x3E8D ; Returns from a trap to page area B
52
DEFC TRAPRETURN_ROM = 0x3E90    ; Returns from a trap that didn't page area B
53
DEFC ADDBASICEXT_ROM = 0x3E93   ; Adds a BASIC command
54
DEFC STATEMENT_END_ROM = 0x3E96 ; Check for statement end, exit at syntax time
55
DEFC EXIT_SUCCESS_ROM = 0x3E99  ; Use this to exit successfully after cmd
56
 
57 91 winston
DEFC POLLNVAL = 0x80
58
 
59 495 winston
; Port defines
60
DEFC CTRLREG = 0x033B
61
DEFC CPLDINFO = 0x023B