ugBASIC 1.18
An isomorphic BASIC language compiler for retrocomputers
Loading...
Searching...
No Matches
vz200.h
Go to the documentation of this file.
1#ifndef __UGBC_VZ200__
2#define __UGBC_VZ200__
3
4/*****************************************************************************
5 * ugBASIC - an isomorphic BASIC language compiler for retrocomputers *
6 *****************************************************************************
7 * Copyright 2021-2026 Marco Spedaletti (asimov@mclink.it)
8 *
9 * Licensed under the Apache License, Version 2.0 (the "License");
10 * you may not use this file except in compliance with the License.
11 * You may obtain a copy of the License at
12 *
13 * http://www.apache.org/licenses/LICENSE-2.0
14 *
15 * Unless required by applicable law or agreed to in writing, software
16 * distributed under the License is distributed on an "AS IS" BASIS,
17 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
18 * See the License for the specific language governing permissions and
19 * limitations under the License.
20 *----------------------------------------------------------------------------
21 * Concesso in licenza secondo i termini della Licenza Apache, versione 2.0
22 * (la "Licenza"); è proibito usare questo file se non in conformità alla
23 * Licenza. Una copia della Licenza è disponibile all'indirizzo:
24 *
25 * http://www.apache.org/licenses/LICENSE-2.0
26 *
27 * Se non richiesto dalla legislazione vigente o concordato per iscritto,
28 * il software distribuito nei termini della Licenza è distribuito
29 * "COSì COM'è", SENZA GARANZIE O CONDIZIONI DI ALCUN TIPO, esplicite o
30 * implicite. Consultare la Licenza per il testo specifico che regola le
31 * autorizzazioni e le limitazioni previste dalla medesima.
32 ****************************************************************************/
33
34#include "../ugbc.h"
35
36#define KEY_NONE 255
37#define KEY_0 '0'
38#define KEY_1 72
39#define KEY_2 65
40#define KEY_3 57
41#define KEY_4 64
42#define KEY_5 49
43#define KEY_6 56
44#define KEY_7 41
45#define KEY_8 48
46#define KEY_9 33
47#define KEY_A 69
48#define KEY_ASTERISK 0xfe
49#define KEY_AT 0xfe
50#define KEY_B 54
51#define KEY_C 62
52#define KEY_CLEAR 0xfe
53#define KEY_COLON 0xfe
54#define KEY_COMMA 38
55#define KEY_COMMODORE 0xfe
56#define KEY_CONTROL 23
57#define KEY_CRSR_LEFT_RIGHT 0xfe
58#define KEY_CRSR_UP_DOWN 0xfe
59#define KEY_D 61
60#define KEY_DELETE 24
61#define KEY_E 58
62#define KEY_EQUAL 0xfe
63#define KEY_F 53
64#define KEY_F1 0xfe
65#define KEY_F2 0xfe
66#define KEY_F3 0xfe
67#define KEY_F4 0xfe
68#define KEY_F5 0xfe
69#define KEY_F6 0xfe
70#define KEY_F7 0xfe
71#define KEY_F8 0xfe
72#define KEY_G 52
73#define KEY_H 44
74#define KEY_HOME 0xfe
75#define KEY_I 35
76#define KEY_INSERT 0xfe
77#define KEY_J 45
78#define KEY_K 37
79#define KEY_L 36
80#define KEY_LEFT_ARROW 0xfe
81#define KEY_LEFT_SHIFT 21
82#define KEY_M 29
83#define KEY_MINUS 0xfe
84#define KEY_N 46
85#define KEY_O 34
86#define KEY_P 27
87#define KEY_PERIOD 39
88#define KEY_PLUS 32
89#define KEY_POUND 0xfe
90#define KEY_Q 69
91#define KEY_R 50
92#define KEY_RETURN 18
93#define KEY_RIGHT_SHIFT 21
94#define KEY_RUNSTOP 0xfe
95#define KEY_S 60
96#define KEY_SEMICOLON 0xfe
97#define KEY_SLASH 0xfe
98#define KEY_SPACE 47
99#define KEY_T 51
100#define KEY_U 42
101#define KEY_UP_ARROW 8
102#define KEY_V 5
103#define KEY_W 71
104#define KEY_X 63
105#define KEY_Y 43
106#define KEY_Z 59
107#define KEY_BACKSLASH 19
108#define KEY_SQUARE_OPEN 0xfe
109#define KEY_SQUARE_CLOSED 0xfe
110#define KEY_SEMICOMMA 0xfe
111#define KEY_QUOTE 0xfe
112#define KEY_APIX 0xfe
113#define KEY_DEAD 0xfe
114#define KEY_SHIFT 21
115#define KEY_CTRL 23
116#define KEY_GRAPH 0xfe
117#define KEY_CAPS 70
118#define KEY_CODE 0xfe
119#define KEY_ESC 66
120#define KEY_TAB 68
121#define KEY_STOP 0xfe
122#define KEY_BS 79
123#define KEY_SELECT 0xfe
124#define KEY_RET 0xfe
125#define KEY_INS 0xfe
126#define KEY_DEL 24
127#define KEY_LEFT 8
128#define KEY_UP 0
129#define KEY_DOWN 2
130#define KEY_RIGHT 1
131#define KEY_DIVISION 0xfe
132
133#define KEYBOARD_CONFIG_DEFAULT_SYNC 1
134
135#define INPUT_DEFAULT_SEPARATOR ','
136#define INPUT_DEFAULT_SIZE 32
137#define INPUT_DEFAULT_CURSOR 95
138#define INPUT_DEFAULT_RATE 16
139#define INPUT_DEFAULT_DELAY 16
140
141#define SCREEN_CAPABILITIES ( ( 1<<BITMAP_NATIVE ) )
142
143#define JOY_COUNT 2
144
145#define JOY_UP 0
146#define JOY_DOWN 1
147#define JOY_LEFT 2
148#define JOY_RIGHT 3
149#define JOY_FIRE 4
150
151#define JOYSTICK_CONFIG_DEFAULT_SYNC 1
152
153#define DEFAULT_PAINT_BUCKET_SIZE 1024
154
155#define BANK_BASE_ADDRESS 0
156
157#define BANK_COUNT 0
158#define BANK_SIZE 0
159
160#define MAX_AUDIO_CHANNELS 1
161
162#define DSTRING_DEFAULT_COUNT 127
163#define DSTRING_DEFAULT_SPACE 1024
164
165void vz200_wait_key( Environment * _environment, int _release );
166void vz200_wait_fire( Environment * _environment, int _port, int _release );
167void vz200_wait_fire_semivar( Environment * _environment, char * _port, int _release );
168void vz200_wait_key_or_fire( Environment * _environment, int _port, int _release );
169void vz200_wait_key_or_fire_semivar( Environment * _environment, char * _port, int _release );
170void vz200_key_state( Environment * _environment, char *_scancode, char * _result );
171void vz200_scancode( Environment * _environment, char * _scacode );
172void vz200_asciicode( Environment * _environment, char * _asciicode );
173void vz200_inkey( Environment * _environment, char * _key );
174void vz200_key_pressed( Environment * _environment, char *_scancode, char * _result );
175
176void vz200_scanshift( Environment * _environment, char * _shifts );
177void vz200_keyshift( Environment * _environment, char * _shifts );
178void vz200_clear_key( Environment * _environment );
179void vz200_put_key( Environment * _environment, char *_string, char * _size );
180
181void vz200_joy( Environment * _environment, int _port, char * _value );
182void vz200_joy_vars( Environment * _environment, char * _port, char * _value );
183
184void vz200_timer_set_status_on( Environment * _environment, char * _timer );
185void vz200_timer_set_status_off( Environment * _environment, char * _timer );
186void vz200_timer_set_counter( Environment * _environment, char * _timer, char * _counter );
187void vz200_timer_set_init( Environment * _environment, char * _timer, char * _init );
188void vz200_timer_set_address( Environment * _environment, char * _timer, char * _address );
189void vz200_dload( Environment * _environment, char * _filename, char * _offset, char * _address, char * _size );
190void vz200_dsave( Environment * _environment, char * _filename, char * _offset, char * _address, char * _size );
191void vz200_flip_image( Environment * _environment, Resource * _image, char * _frame, char * _sequence, int _frame_size, int _frame_count, char * _direction );
192void vz200_sys_call( Environment * _environment, int _destination );
193
194#endif
struct _Resource Resource
struct _Environment Environment
Structure of compilation environment.
void vz200_keyshift(Environment *_environment, char *_shifts)
Definition vz200.c:204
void vz200_clear_key(Environment *_environment)
Definition vz200.c:215
void vz200_inkey(Environment *_environment, char *_key)
Definition vz200.c:44
void vz200_wait_key_or_fire(Environment *_environment, int _port, int _release)
Definition vz200.c:70
void vz200_key_pressed(Environment *_environment, char *_scancode, char *_result)
Definition vz200.c:185
void vz200_sys_call(Environment *_environment, int _destination)
Definition vz200.c:553
void vz200_timer_set_status_off(Environment *_environment, char *_timer)
Definition vz200.c:354
void vz200_wait_fire_semivar(Environment *_environment, char *_port, int _release)
Definition vz200.c:125
void vz200_joy(Environment *_environment, int _port, char *_value)
Definition vz200.c:265
void vz200_put_key(Environment *_environment, char *_string, char *_size)
Definition vz200.c:540
void vz200_timer_set_init(Environment *_environment, char *_timer, char *_init)
Definition vz200.c:393
void vz200_asciicode(Environment *_environment, char *_asciicode)
Definition vz200.c:174
void vz200_flip_image(Environment *_environment, Resource *_image, char *_frame, char *_sequence, int _frame_size, int _frame_count, char *_direction)
void vz200_wait_key(Environment *_environment, int _release)
Definition vz200.c:55
void vz200_dsave(Environment *_environment, char *_filename, char *_offset, char *_address, char *_size)
Definition vz200.c:486
void vz200_joy_vars(Environment *_environment, char *_port, char *_value)
Definition vz200.c:225
void vz200_timer_set_address(Environment *_environment, char *_timer, char *_address)
Definition vz200.c:415
void vz200_dload(Environment *_environment, char *_filename, char *_offset, char *_address, char *_size)
Definition vz200.c:438
void vz200_timer_set_status_on(Environment *_environment, char *_timer)
Definition vz200.c:338
void vz200_wait_fire(Environment *_environment, int _port, int _release)
Definition vz200.c:104
void vz200_wait_key_or_fire_semivar(Environment *_environment, char *_port, int _release)
Definition vz200.c:87
void vz200_timer_set_counter(Environment *_environment, char *_timer, char *_counter)
Definition vz200.c:371
void vz200_scanshift(Environment *_environment, char *_shifts)
Definition vz200.c:200
void vz200_key_state(Environment *_environment, char *_scancode, char *_result)
Definition vz200.c:140
void vz200_scancode(Environment *_environment, char *_scacode)
Definition vz200.c:155