Added PC port for working on flight model.

This commit is contained in:
Scott Duensing 2024-04-19 20:10:25 -05:00
parent 43a5c4870c
commit 695b7daa7d
11 changed files with 9288 additions and 15 deletions

2
.gitignore vendored
View file

@ -4,3 +4,5 @@ backup/
*~
*.pgz
apple2/
build-*/
*.user

49
pc/CMakeLists.txt Normal file
View file

@ -0,0 +1,49 @@
cmake_minimum_required(VERSION 3.12)
project(sierrahotel LANGUAGES C)
find_package(SDL2 REQUIRED)
set(HEADERS
app.h
flight.h
vrEmu6502.h
a23d2bin.h
a23d2.h
)
list(TRANSFORM HEADERS PREPEND "${CMAKE_CURRENT_SOURCE_DIR}/include/")
set(SOURCE
main.c
flight.c
vrEmu6502.c
)
list(TRANSFORM SOURCE PREPEND "${CMAKE_CURRENT_SOURCE_DIR}/src/")
add_executable(${CMAKE_PROJECT_NAME}
${HEADERS}
${SOURCE}
)
target_include_directories(${CMAKE_PROJECT_NAME} PUBLIC
${CMAKE_CURRENT_SOURCE_DIR}/include
${SDL2_INCLUDE_DIRS}
)
target_link_libraries(${CMAKE_PROJECT_NAME}
${SDL2_LIBRARIES}
-lGLEW
-lGL
-lm
-lpthread
)
target_compile_options(${CMAKE_PROJECT_NAME} PRIVATE -fsanitize=address)
target_link_options(${CMAKE_PROJECT_NAME} PRIVATE -fsanitize=address)

149
pc/include/a23d2.h Normal file
View file

@ -0,0 +1,149 @@
/*
* Copyright (c) 2024 Scott Duensing, scott@kangaroopunch.com
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*/
#ifdef __F256K__
#include "f256lib.h"
#else
#include <stdint.h>
#include <stdbool.h>
typedef uint8_t byte;
#endif
//#define scdMemCpy memcpy
#define scdMemCpy(d,s,l) \
({ \
volatile byte *dp = (d); \
volatile byte *sp = (s); \
uint16_t i = 0; \
for (i=0; i<(l); i++) *dp++ = *sp++; \
})
#define A23D2_FAR_BLOCK 42
#define DATABASE_FAR_BLOCK 43
#define DATABASE_FAR 0x56000
#define DRAWLIST_P0_FAR 0x57000
#define DRAWLIST_P1_FAR 0x57800
#define DATABASE 0x8000
#define DRAWLIST_P0 0x9000
#define DRAWLIST_P1 0x9800
// A2-3D2 Function Addresses.
#define A23D2_ENTRYN 0x6090
#define A23D2_NXTPT 0x6118
#define A23D2_SINEX 0x61f6
#define A23D2_COSEX 0x620f
// A2-3D2 Data Addresses.
#define A23D2_TEST_DATABASE 0x80fb
#define A23D2_TDATA 0x613e
#define A23D2_IBP 0x9b
// Stuff A2-3D2 is going to clobber that our compiler may want.
#define COMPILER_ZP_START 0x60 // To 0xC2
#define COMPILER_ZP_LENGTH 0x62
#define A23D2_ZP_START COMPILER_ZP_START
#define A23D2_ZP_LENGTH COMPILER_ZP_LENGTH
// Our Scratch Addresses.
#define CAMERA_SHARED_START 0x200 // To 0x209
#define CAMERA_SHARED_LENGTH 0x9
#define SCRATCH_END 0x2ff
#define COMPILER_ZP_SAVE (CAMERA_SHARED_START + CAMERA_SHARED_LENGTH)
#define A23D2_ZP_SAVE (COMPILER_ZP_SAVE + COMPILER_ZP_LENGTH)
// A2-3D1 Commands. Commented out items are Apple ][ only.
#define PNT 0x00 // xLSB, xMSB, yLSB, yMSB, zLSB, zMSB - Define 3D Point
#define SPNT 0x01 // xLSB, xMSB, yLSB, yMSB, zLSB, zMSB - Define 3D Start Point
#define CPNT 0x02 // xLSB, xMSB, yLSB, yMSB, zLSB, zMSB - Define 3D Continue Point
#define RAY 0x03 // xLSB, xMSB, yLSB, yMSB, zLSB, zMSB - Define 3D Ray
#define CLPSW 0x04 // N - Define Clipper (0=off, 1=on)
#define EYE 0x05 // xLSB, xMSB, yLSB, yMSB, zLSB, zMSB, P, B, H - Define 3D Eye/Camera
#define LIN2D 0x06 // X1, Y1, X2, Y2 - Draw 2D Line
//#define DISP 0x07 // N - Display Select (50=set graphics, 51=set text, 52=clear mixed, 53=set mixed, 54=set page 1, 55=set page 2, 56=clear hi-res, 57=set hi-res)
//#define ERAS 0x08 // N - Erase Screen (0=erase page 1, 1=erase page 2, 2=fill page 1, 3=fill page 2)
//#define DRAW 0x09 // N - Select Draw Page (0=page 1, 1=page 2)
#define PNT2D 0x0a // X1, Y1 - Draw 2D Point
#define JMP 0x0b // LSB, MSB - Interpretive Jump
//#define LMODE 0x0c // N - Line Drawing Mode (0=solid, 1=xor)
#define ARRAY 0x0d // LSB, MSB - Enable Output Array
#define SCRSZ 0x0e // WIDTH, HEIGHT, xCENTER, yCENTER - Define Screen Size
#define FIELD 0x0f // xLSB, xMSB, yLSB, yMSB, zLSB, zMSB - Field of View Selection
#define INIT 0x10 // Easy Init
#define NOP 0x11 // No Operation
// A2-3D2 Commands. Commented out items are Apple ][ only.
#define STCOL 0x12 // COL - Set Color
#define ICALL 0x13 // STAT, LOC, ADDR - Independent Object Call
#define SRES 0x14 // RES - Set Resolution (0=140x192, 1=280x192)
//#define HLIN 0x15 // x1L, x1H, y1, x2L, x2H, y2 - Hi-Res (280x192) Line 2D
//#define SHRB 0x16 // xL, xH, y - Set Hi-Res Bias
//#define HLIN2 0x17 // x1, y1, x2, y2 - Hi-Res (x limited) Line 2D
//#define HPNT 0x18 // xL, xH, y - Hi-Res (280x192) Point 2D
//#define HPNT2 0x19 // x, y - Hi-Res (x limited) Point 2D
#define SKIP 0x1a // SIZE, STATUS - Skip Segment
//#define PAUS 0x1b // TIME - Pause for TIME/5ths of a Second
#define SET323 0x1c // LSB, MSB - Set 3D to 3D Array Address
#define GN323 0x1d // STATUS - Set 3D to 3D Status
#define END 0x79 // End of Database
typedef struct cameraS { // 9 bytes.
int16_t x;
int16_t y;
int16_t z;
byte p;
byte b;
byte h;
} cameraT;
extern volatile cameraT *_camera;
extern volatile cameraT *_cameraInDatabase;
extern volatile byte *_pointer;
extern uint16_t _drawlist;
extern uint16_t _drawlistInDatabase;
extern uint16_t _bytes;
extern uint8_t _x1;
#define _tdata _x1 // Alias.
extern uint8_t _y1;
extern uint8_t _x2;
extern uint8_t _y2;
extern bool _useColor;
extern byte _mmu;
extern byte _ram;
extern float _trig;
void a23d2Cos(void);
void a23d2Draw(void);
void a23d2Init(void);
void a23d2Render(void);
void a23d2Sin(void);

707
pc/include/a23d2bin.h Normal file
View file

@ -0,0 +1,707 @@
unsigned char a23d2bin[] = {
0x4c, 0x6c, 0x60, 0x4c, 0x90, 0x60, 0x4c, 0xf7, 0x61, 0x4c, 0x10, 0x62,
0x08, 0x16, 0x08, 0x7e, 0x7e, 0x06, 0x08, 0x06, 0x08, 0x0f, 0x00, 0xf5,
0xf5, 0x3e, 0x10, 0x3e, 0x10, 0x00, 0x00, 0xd3, 0x74, 0xc3, 0x24, 0x01,
0xd2, 0x3f, 0x01, 0xd2, 0x3f, 0x01, 0xd2, 0x3f, 0x01, 0xd2, 0x3f, 0x01,
0xd2, 0x3f, 0x01, 0xd2, 0x3f, 0x01, 0xd2, 0x3f, 0x01, 0xd2, 0x3f, 0x01,
0xd2, 0x3f, 0x01, 0x3e, 0x50, 0x3e, 0x50, 0x00, 0x00, 0xd3, 0x74, 0xf1,
0xf1, 0xe3, 0xe3, 0xe3, 0xe3, 0x05, 0x00, 0xc3,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, 0x24, 0x03, 0x00,
0x00, 0x38, 0xe9, 0x40, 0xaa, 0x30, 0x1f, 0xc9, 0x40, 0x30, 0x12, 0x18,
0x69, 0x7f, 0x49, 0xff, 0x0a, 0xa8, 0x38, 0xa9, 0x00, 0xf9, 0x48, 0x61,
0xaa, 0xf9, 0x47, 0x61, 0x60, 0x0a, 0xa8, 0xbe, 0x48, 0x61, 0xb9, 0x47,
0x61, 0x60, 0x49, 0xff, 0x18, 0x69, 0x01, 0x10, 0xda, 0x30, 0xe1, 0x08,
0x48, 0x8a, 0x48, 0x98, 0x48, 0xad, 0x3e, 0x61, 0x20, 0xc9, 0x61, 0x8e,
0x3f, 0x61, 0x8d, 0x3e, 0x61, 0x68, 0xa8, 0x68, 0xaa, 0x68, 0x28, 0x60,
0x08, 0x48, 0x8a, 0x48, 0x98, 0x48, 0xad, 0x3e, 0x61, 0x20, 0xcc, 0x61,
0x4c, 0x03, 0x62, 0x00, 0x18, 0x65, 0x9b, 0x85, 0x9b, 0x90, 0x02, 0xe6,
0x9c, 0x60, 0xa0, 0x68, 0x20, 0x62, 0x68, 0x20, 0x90, 0x6a, 0xa2, 0x07,
0xb5, 0x67, 0x95, 0x6f, 0xca, 0xd0, 0xf9, 0xa9, 0x07, 0x20, 0x20, 0x62,
0xad, 0x1f, 0x62, 0xc9, 0x02, 0xf0, 0x1a, 0xa5, 0x66, 0x25, 0x6e, 0x60,
0xa0, 0x60, 0x20, 0x62, 0x68, 0x20, 0x37, 0x6a, 0xa9, 0x07, 0x20, 0x20,
0x62, 0xad, 0x1f, 0x62, 0xc9, 0x02, 0xf0, 0x01, 0x60, 0x68, 0x68, 0x4c,
0x18, 0x61, 0x20, 0x4c, 0x62, 0x20, 0x2a, 0x62, 0xd0, 0x55, 0xa5, 0x66,
0xd0, 0x14, 0xa5, 0x6e, 0xd0, 0x03, 0x4c, 0x33, 0x63, 0xa5, 0x7c, 0xd0,
0x1e, 0x20, 0x03, 0x6b, 0xc6, 0xb1, 0xf0, 0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, 0x60, 0xa8, 0xa9, 0x00, 0x38,
0xe5, 0x7a, 0x85, 0x7a, 0xa9, 0x00, 0xe5, 0x7b, 0x85, 0x7b, 0x98, 0x60,
0x20, 0x41, 0x66, 0xa9, 0x00, 0x38, 0xe5, 0x78, 0x85, 0x78, 0xa9, 0x00,
0xe5, 0x79, 0x85, 0x79, 0x60, 0xa0, 0x0f, 0x86, 0xa5, 0xaa, 0xa5, 0xa5,
0x38, 0xe5, 0x7a, 0x85, 0xa5, 0x8a, 0xe5, 0x7b, 0x30, 0x0d, 0x38, 0x26,
0x78, 0x26, 0x79, 0x06, 0xa5, 0x2a, 0x88, 0xd0, 0xe8, 0xf0, 0x19, 0x06,
0x78, 0x26, 0x79, 0x06, 0xa5, 0x2a, 0x88, 0xf0, 0x0f, 0xaa, 0xa5, 0xa5,
0x18, 0x65, 0x7a, 0x85, 0xa5, 0x8a, 0x65, 0x7b, 0x30, 0xe9, 0x10, 0xda,
0x06, 0x78, 0x26, 0x79, 0x10, 0x04, 0xc6, 0x78, 0xc6, 0x79, 0x60, 0xa5,
0x96, 0x20, 0xc9, 0x61, 0x85, 0x60, 0x86, 0x61, 0xa5, 0x97, 0x20, 0xc9,
0x61, 0x85, 0x62, 0x86, 0x63, 0xa5, 0x98, 0x20, 0xc9, 0x61, 0x85, 0x64,
0x86, 0x65, 0xa5, 0x96, 0x20, 0xcc, 0x61, 0x85, 0x66, 0x86, 0x67, 0xa5,
0x97, 0x20, 0xcc, 0x61, 0x85, 0x68, 0x86, 0x69, 0xa5, 0x98, 0x20, 0xcc,
0x61, 0x85, 0x6a, 0x86, 0x6b, 0xa2, 0x6a, 0xa0, 0x68, 0xa9, 0x6c, 0x20,
0x76, 0x64, 0xa2, 0x64, 0xa0, 0x62, 0xa9, 0x6e, 0x20, 0x76, 0x64, 0xa2,
0x6a, 0xa0, 0x62, 0xa9, 0x70, 0x20, 0x76, 0x64, 0xa2, 0x64, 0xa0, 0x68,
0xa9, 0x72, 0x20, 0x76, 0x64, 0xa2, 0x60, 0xa0, 0x6e, 0xa9, 0x74, 0x20,
0x76, 0x64, 0xa2, 0x60, 0xa0, 0x72, 0xa9, 0x76, 0x20, 0x76, 0x64, 0xa2,
0x70, 0xa0, 0x60, 0xa9, 0xb3, 0x20, 0x76, 0x64, 0xa2, 0x60, 0xa0, 0x6c,
0xa9, 0xb5, 0x20, 0x76, 0x64, 0x18, 0xa5, 0x6c, 0x65, 0x74, 0x85, 0x7e,
0xa5, 0x6d, 0x65, 0x75, 0x85, 0x7f, 0x38, 0xa5, 0x76, 0xe5, 0x70, 0x85,
0x80, 0xa5, 0x77, 0xe5, 0x71, 0x85, 0x81, 0xa2, 0x64, 0xa0, 0x66, 0xa9,
0x82, 0x20, 0x76, 0x64, 0xa2, 0x62, 0xa0, 0x66, 0xa9, 0x84, 0x20, 0x76,
0x64, 0xa2, 0x66, 0xa0, 0x68, 0xa9, 0x86, 0x20, 0x76, 0x64, 0xa9, 0x00,
0x38, 0xe5, 0x60, 0x85, 0x88, 0xa9, 0x00, 0xe5, 0x61, 0x85, 0x89, 0x38,
0xa5, 0xb3, 0xe5, 0x72, 0x85, 0x8a, 0xa5, 0xb4, 0xe5, 0x73, 0x85, 0x8b,
0x18, 0xa5, 0x6e, 0x65, 0xb5, 0x85, 0x8c, 0xa5, 0x6f, 0x65, 0xb6, 0x85,
0x8d, 0xa2, 0x6a, 0xa0, 0x66, 0xa9, 0x8e, 0x20, 0x76, 0x64, 0xae, 0x41,
0x61, 0xe0, 0x7f, 0xd0, 0x07, 0xad, 0x40, 0x61, 0xc9, 0xff, 0xf0, 0x45,
0x85, 0x78, 0x86, 0x79, 0xa5, 0x7e, 0xa6, 0x7f, 0x85, 0x7a, 0x86, 0x7b,
0x20, 0x95, 0x64, 0x85, 0x7e, 0x86, 0x7f, 0xa5, 0x84, 0xa6, 0x85, 0x85,
0x78, 0x86, 0x79, 0xad, 0x40, 0x61, 0xae, 0x41, 0x61, 0x85, 0x7a, 0x86,
0x7b, 0x20, 0x95, 0x64, 0x85, 0x84, 0x86, 0x85, 0xa5, 0x8a, 0xa6, 0x8b,
0x85, 0x78, 0x86, 0x79, 0xad, 0x40, 0x61, 0xae, 0x41, 0x61, 0x85, 0x7a,
0x86, 0x7b, 0x20, 0x95, 0x64, 0x85, 0x8a, 0x86, 0x8b, 0xae, 0x43, 0x61,
0xe0, 0x7f, 0xd0, 0x07, 0xad, 0x42, 0x61, 0xc9, 0xff, 0xf0, 0x45, 0x85,
0x78, 0x86, 0x79, 0xa5, 0x80, 0xa6, 0x81, 0x85, 0x7a, 0x86, 0x7b, 0x20,
0x95, 0x64, 0x85, 0x80, 0x86, 0x81, 0xad, 0x42, 0x61, 0xae, 0x43, 0x61,
0x85, 0x78, 0x86, 0x79, 0xa5, 0x86, 0xa6, 0x87, 0x85, 0x7a, 0x86, 0x7b,
0x20, 0x95, 0x64, 0x85, 0x86, 0x86, 0x87, 0xad, 0x42, 0x61, 0xae, 0x43,
0x61, 0x85, 0x78, 0x86, 0x79, 0xa5, 0x8c, 0xa6, 0x8d, 0x85, 0x7a, 0x86,
0x7b, 0x20, 0x95, 0x64, 0x85, 0x8c, 0x86, 0x8d, 0xae, 0x45, 0x61, 0xe0,
0x7f, 0xd0, 0x07, 0xad, 0x44, 0x61, 0xc9, 0xff, 0xf0, 0x45, 0x85, 0x78,
0x86, 0x79, 0xa5, 0x82, 0xa6, 0x83, 0x85, 0x7a, 0x86, 0x7b, 0x20, 0x95,
0x64, 0x85, 0x82, 0x86, 0x83, 0xad, 0x44, 0x61, 0xae, 0x45, 0x61, 0x85,
0x78, 0x86, 0x79, 0xa5, 0x88, 0xa6, 0x89, 0x85, 0x7a, 0x86, 0x7b, 0x20,
0x95, 0x64, 0x85, 0x88, 0x86, 0x89, 0xad, 0x44, 0x61, 0xae, 0x45, 0x61,
0x85, 0x78, 0x86, 0x79, 0xa5, 0x8e, 0xa6, 0x8f, 0x85, 0x7a, 0x86, 0x7b,
0x20, 0x95, 0x64, 0x85, 0x8e,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xb1, 0x9b, 0xc8, 0xe5, 0x95, 0x70, 0x02,
0xc9, 0x80, 0x6a, 0x85, 0xb0, 0x66, 0xaf, 0x4c, 0xa2, 0x68, 0x6a, 0x85,
0xae, 0x66, 0xad, 0xa5, 0xac, 0x2a, 0x66, 0xac, 0x66, 0xab, 0x4c, 0xc9,
0x69, 0x6a, 0x85, 0xb0, 0x66, 0xaf, 0xa5, 0xae, 0x2a, 0x66, 0xae, 0x66,
0xad, 0xa5, 0xac, 0x2a, 0x66, 0xac, 0x66, 0xab, 0x4c, 0xa2, 0x68, 0x18,
0x65, 0xa7, 0xa8, 0x8a, 0x65, 0xa8, 0xaa, 0x98, 0x18, 0x65, 0xa9, 0xa8,
0x8a, 0x65, 0xaa, 0xa6, 0xb2, 0x95, 0x01, 0x94, 0x00, 0xe6, 0xb2, 0xe6,
0xb2, 0xaa, 0xf0, 0x12, 0xc9, 0xff, 0xf0, 0x0e, 0xee, 0x60, 0x68, 0x29,
0xe0, 0xf0, 0x07, 0xc9, 0xe0, 0xf0, 0x03, 0xee, 0x61, 0x68, 0x60, 0xa2,
0x00, 0xa5, 0x60, 0x18, 0x65, 0x64, 0xa5, 0x61, 0x65, 0x65, 0x30, 0x04,
0x50, 0x06, 0x70, 0x02, 0x70, 0x02, 0xa2, 0x40, 0xa5, 0x64, 0x38, 0xe5,
0x60, 0xa5, 0x65, 0xe5, 0x61, 0x30, 0x04, 0x50, 0x08, 0x70, 0x02, 0x70,
0x04, 0x8a, 0x09, 0x20, 0xaa, 0xa5, 0x62, 0x18, 0x65, 0x64, 0xa5, 0x63,
0x65, 0x65, 0x30, 0x04, 0x50, 0x08, 0x70, 0x02, 0x70, 0x04, 0x8a, 0x09,
0x10, 0xaa, 0xa5, 0x64, 0x38, 0xe5, 0x62, 0xa5, 0x65, 0xe5, 0x63, 0x30,
0x04, 0x50, 0x0a, 0x70, 0x02, 0x70, 0x06, 0x8a, 0x09, 0x08, 0x85, 0x66,
0x60, 0x86, 0x66, 0x60, 0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c, 0x61, 0x85, 0x62, 0x86, 0x63, 0xa5,
0x97, 0x20, 0xcc, 0x61, 0x85, 0x66, 0x86, 0x67, 0xa5, 0x98, 0x20, 0xcc,
0x61, 0x85, 0x6a, 0x86, 0x6b, 0xa2, 0x90, 0xa0, 0x6a, 0xa9, 0xab, 0x20,
0x76, 0x64, 0xa2, 0x90, 0xa0, 0x68, 0xa9, 0xaf, 0x20, 0x76, 0x64, 0xa2,
0x94, 0xa0, 0x68, 0xa9, 0xad, 0x20, 0x76, 0x64, 0x38, 0xa5, 0xab, 0xe5,
0xad, 0x85, 0x90, 0xa5, 0xac, 0xe5, 0xae, 0x85, 0x91, 0xa2, 0x94, 0xa0,
0x6a, 0xa9, 0xad, 0x20, 0x76, 0x64, 0x18, 0xa5, 0xad, 0x65, 0xaf, 0x85,
0x94, 0xa5, 0xae, 0x65, 0xb0, 0x85, 0x95, 0xa2, 0x92, 0xa0, 0x62, 0xa9,
0xab, 0x20, 0x76, 0x64, 0xa2, 0x92, 0xa0, 0x60, 0xa9, 0xaf, 0x20, 0x76,
0x64, 0xa2, 0x94, 0xa0, 0x60, 0xa9, 0xad, 0x20, 0x76, 0x64, 0x18, 0xa5,
0xab, 0x65, 0xad, 0x85, 0x92, 0xa5, 0xac, 0x65, 0xae, 0x85, 0x93, 0xa2,
0x94, 0xa0, 0x62, 0xa9, 0xad, 0x20, 0x76, 0x64, 0x38, 0xa5, 0xad, 0xe5,
0xaf, 0x85, 0x94, 0xa5, 0xae, 0xe5, 0xb0, 0x85, 0x95, 0xa2, 0x90, 0xa0,
0x66, 0xa9, 0xab, 0x20, 0x76, 0x64, 0xa2, 0x90, 0xa0, 0x64, 0xa9, 0xaf,
0x20, 0x76, 0x64, 0xa2, 0x92, 0xa0, 0x64, 0xa9, 0xad, 0x20, 0x76, 0x64,
0x18, 0xa5, 0xab, 0x65, 0xad, 0x85, 0x90, 0xa5, 0xac, 0x65, 0xae, 0x85,
0x91, 0xa2, 0x92, 0xa0, 0x66, 0x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0xa5, 0x8d, 0x65, 0x73, 0x85, 0x8d, 0xa5, 0x6e, 0xa6, 0x6f, 0x85,
0x80, 0x86, 0x81, 0xa2, 0x68, 0xa0, 0x82, 0xa9, 0x72, 0x20, 0x76, 0x64,
0xa2, 0x6a, 0xa0, 0x8e, 0xa9, 0x8e, 0x20, 0x76, 0x64, 0x18, 0xa5, 0x8e,
0x65, 0x72, 0x85, 0x8e, 0xa5, 0x8f, 0x65, 0x73, 0x85, 0x8f, 0xa5, 0x70,
0xa6, 0x71, 0x85, 0x82, 0x86, 0x83, 0xa9, 0x00, 0x38, 0xe5, 0x60, 0x85,
0x74, 0xa9, 0x00, 0xe5, 0x61, 0x85, 0x75, 0xa2, 0x62, 0xa0, 0x84, 0xa9,
0x6c, 0x20, 0x76, 0x64, 0xa2, 0x60, 0xa0, 0x8a, 0xa9, 0x72, 0x20, 0x76,
0x64, 0x18, 0xa5, 0x6c, 0x65, 0x72, 0x85, 0x6c, 0xa5, 0x6d, 0x65, 0x73,
0x85, 0x6d, 0xa2, 0x62, 0xa0, 0x86, 0xa9, 0x6e, 0x20, 0x76, 0x64, 0xa2,
0x60, 0xa0, 0x8c, 0xa9, 0x72, 0x20, 0x76, 0x64, 0x18, 0xa5, 0x6e, 0x65,
0x72, 0x85, 0x6e, 0xa5, 0x6f, 0x65, 0x73, 0x85, 0x6f, 0xa2, 0x62, 0xa0,
0x88, 0xa9, 0x70, 0x20, 0x76, 0x64, 0xa2, 0x60, 0xa0, 0x8e, 0xa9, 0x72,
0x20, 0x76, 0x64, 0x18, 0xa5, 0x70, 0x65, 0x72, 0x85, 0x70, 0xa5, 0x71,
0x65, 0x73, 0x85, 0x71, 0xa2, 0x74, 0xa0, 0x84, 0xa9, 0x72, 0x20, 0x76,
0x64, 0xa2, 0x62, 0xa0, 0x8a, 0xa9, 0x8a, 0x20, 0x76, 0x64, 0x18, 0xa5,
0x8a, 0x65, 0x72, 0x85, 0x8a, 0xa5, 0x8b, 0x65, 0x73, 0x85, 0x8b, 0xa5,
0x6c, 0xa6, 0x6d, 0x85, 0x84, 0x86, 0x85, 0xa2, 0x74, 0xa0, 0x86, 0xa9,
0x72, 0x20, 0x76, 0x64, 0xa2, 0x62, 0xa0, 0x8c, 0xa9, 0x8c, 0x20, 0x76,
0x64, 0x18, 0xa5, 0x8c, 0x65, 0x72, 0x85, 0x8c, 0xa5, 0x8d, 0x65, 0x73,
0x85, 0x8d, 0xa5, 0x6e, 0xa6, 0x6f, 0x85, 0x86, 0x86, 0x87, 0xa2, 0x74,
0xa0, 0x88, 0xa9, 0x72, 0x20, 0x76, 0x64, 0xa2, 0x62, 0xa0, 0x8e, 0xa9,
0x8e, 0x20, 0x76, 0x64, 0x18, 0xa5, 0x8e, 0x65, 0x72, 0x85, 0x8e, 0xa5,
0x8f, 0x65, 0x73, 0x85, 0x8f, 0xa5, 0x70, 0xa6, 0x71, 0x85, 0x88, 0x86,
0x89, 0xa9, 0x00, 0x38, 0xe5, 0x64, 0x85, 0x74, 0xa9, 0x00, 0xe5, 0x65,
0x85, 0x75, 0xa2, 0x66, 0xa0, 0x7e, 0xa9, 0x6c, 0x20, 0x76, 0x64, 0xa2,
0x64, 0xa0, 0x84, 0xa9, 0x72, 0x20, 0x76, 0x64, 0x18, 0xa5, 0x6c, 0x65,
0x72, 0x85, 0x6c, 0xa5, 0x6d, 0x65, 0x73, 0x85, 0x6d, 0xa2, 0x66, 0xa0,
0x80, 0xa9, 0x6e, 0x20, 0x76, 0x64, 0xa2, 0x64, 0xa0, 0x86, 0xa9, 0x72,
0x20, 0x76, 0x64, 0x18, 0xa5, 0x6e, 0x65, 0x72, 0x85, 0x6e, 0xa5, 0x6f,
0x65, 0x73, 0x85, 0x6f, 0xa2, 0x66, 0xa0, 0x82, 0xa9, 0x70, 0x20, 0x76,
0x64, 0xa2, 0x64, 0xa0, 0x88, 0xa9, 0x72, 0x20, 0x76, 0x64, 0x18, 0xa5,
0x70, 0x65, 0x72, 0x85, 0x70, 0xa5, 0x71, 0x65, 0x73, 0x85, 0x71, 0xa2,
0x74, 0xa0, 0x7e, 0xa9, 0x72, 0x20, 0x76, 0x64, 0xa2, 0x66, 0xa0, 0x84,
0xa9, 0x84, 0x20, 0x76, 0x64, 0x18, 0xa5, 0x84, 0x65, 0x72, 0x85, 0x84,
0xa5, 0x85, 0x65, 0x73, 0x85, 0x85, 0xa5, 0x6c, 0xa6, 0x6d, 0x85, 0x7e,
0x86, 0x7f, 0xa2, 0x74, 0xa0, 0x80, 0xa9, 0x72, 0x20, 0x76, 0x64, 0xa2,
0x66, 0xa0, 0x86, 0xa9, 0x86, 0x20, 0x76, 0x64, 0x18, 0xa5, 0x86, 0x65,
0x72, 0x85, 0x86, 0xa5, 0x87, 0x65, 0x73, 0x85, 0x87, 0xa5, 0x6e, 0xa6,
0x6f, 0x85, 0x80, 0x86, 0x81, 0xa2, 0x74, 0xa0, 0x82, 0xa9, 0x72, 0x20,
0x76, 0x64, 0xa2, 0x66, 0xa0, 0x88, 0xa9, 0x88, 0x20, 0x76, 0x64, 0x18,
0xa5, 0x88, 0x65, 0x72, 0x85, 0x88, 0xa5, 0x89, 0x65, 0x73, 0x85, 0x89,
0xa5, 0x70, 0xa6, 0x71, 0x85, 0x82, 0x86, 0x83, 0x20, 0x18, 0x61, 0xa2,
0xe1, 0x68, 0x95, 0x9d, 0xe8, 0xd0, 0xfa, 0xa9, 0x0d, 0x4c, 0xcc, 0x63,
0x38, 0xb5, 0x00, 0xc8, 0xf1, 0x9b, 0x95, 0x00, 0xe8, 0xb5, 0x00, 0xc8,
0xf1, 0x9b, 0x95, 0x00, 0xe8, 0x60, 0xc8, 0xb1, 0x9b, 0x85, 0xb3, 0xc8,
0xb1, 0x9b, 0x6a, 0x66, 0xb3, 0xa9, 0x00, 0x6a, 0x85, 0xa4, 0xc8, 0xb1,
0x9b, 0x85, 0xb4, 0xc8, 0xb1, 0x9b, 0x85, 0xb5, 0xc8, 0xb1, 0x9b, 0x6a,
0x66, 0xb5, 0xa9, 0x00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x1e,
0x1e, 0x1e, 0x1e, 0x1f, 0x1f, 0x1f, 0x20, 0x20, 0x20, 0x20, 0x21, 0x21,
0x21, 0x22, 0x22, 0x22, 0x22, 0x23, 0x23, 0x23, 0x24, 0x24, 0x24, 0x24,
0x25, 0x25, 0x25, 0x26, 0x26, 0x26, 0x26, 0x27, 0x27, 0x27, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01,
0x01, 0x02, 0x02, 0x02, 0x02, 0x03, 0x03, 0x03, 0x04, 0x04, 0x04, 0x04,
0x05, 0x05, 0x05, 0x06, 0x06, 0x06, 0x06, 0x07, 0x07, 0x07, 0x08, 0x08,
0x08, 0x08, 0x09, 0x09, 0x09, 0x0a, 0x0a, 0x0a, 0x0a, 0x0b, 0x0b, 0x0b,
0x0c, 0x0c, 0x0c, 0x0c, 0x0d, 0x0d, 0x0d, 0x0e, 0x0e, 0x0e, 0x0e, 0x0f,
0x0f, 0x0f, 0x10, 0x10, 0x10, 0x10, 0x11, 0x11, 0x11, 0x12, 0x12, 0x12,
0x12, 0x13, 0x13, 0x13, 0x03, 0x0c, 0x30, 0xc0, 0x06, 0x18, 0x60, 0x03,
0x0c, 0x30, 0xc0, 0x06, 0x18, 0x60, 0x03, 0x0c, 0x30, 0xc0, 0x06, 0x18,
0x60, 0x03, 0x0c, 0x30, 0xc0, 0x06, 0x18, 0x60, 0x03, 0x0c, 0x30, 0xc0,
0x06, 0x18, 0x60, 0x03, 0x0c, 0x30, 0xc0, 0x06, 0x18, 0x60, 0x03, 0x0c,
0x30, 0xc0, 0x06, 0x18, 0x60, 0x03, 0x0c, 0x30, 0xc0, 0x06, 0x18, 0x60,
0x03, 0x0c, 0x30, 0xc0, 0x06, 0x18, 0x60, 0x03, 0x0c, 0x30, 0xc0, 0x06,
0x18, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x0c,
0x30, 0xc0, 0x06, 0x18, 0x60, 0x03, 0x0c, 0x30, 0xc0, 0x06, 0x18, 0x60,
0x03, 0x0c, 0x30, 0xc0, 0x06, 0x18, 0x60, 0x03, 0x0c, 0x30, 0xc0, 0x06,
0x18, 0x60, 0x03, 0x0c, 0x30, 0xc0, 0x06, 0x18, 0x60, 0x03, 0x0c, 0x30,
0xc0, 0x06, 0x18, 0x60, 0x03, 0x0c, 0x30, 0xc0, 0x06, 0x18, 0x60, 0x03,
0x0c, 0x30, 0xc0, 0x06, 0x18, 0x60, 0x03, 0x0c, 0x30, 0xc0, 0x06, 0x18,
0x60, 0x03, 0x0c, 0x30, 0xc0, 0x06, 0x18, 0x60, 0x20, 0xe6, 0x74, 0x4c,
0xca, 0x63, 0xa2, 0x00, 0x9d, 0x00, 0x20, 0x9d, 0x00, 0x21, 0x9d, 0x00,
0x22, 0x9d, 0x00, 0x23, 0x9d, 0x00, 0x24, 0x9d, 0x00, 0x25, 0x9d, 0x00,
0x26, 0x9d, 0x00, 0x27, 0x9d, 0x00, 0x28, 0x9d, 0x00, 0x29, 0x9d, 0x00,
0x2a, 0x9d, 0x00, 0x2b, 0x9d, 0x00, 0x2c, 0x9d, 0x00, 0x2d, 0x9d, 0x00,
0x2e, 0x9d, 0x00, 0x2f, 0x9d, 0x00, 0x30, 0x9d, 0x00, 0x31, 0x9d, 0x00,
0x32, 0x9d, 0x00, 0x33, 0x9d, 0x00, 0x34, 0x9d, 0x00, 0x35, 0x9d, 0x00,
0x36, 0x9d, 0x00, 0x37, 0x9d, 0x00, 0x38, 0x9d, 0x00, 0x39, 0x9d, 0x00,
0x3a, 0x9d, 0x00, 0x3b, 0x9d, 0x00, 0x3c, 0x9d, 0x00, 0x3d, 0x9d, 0x00,
0x3e, 0x9d, 0x00, 0x3f, 0xe8, 0xe8, 0xe8, 0xd0, 0x9b, 0x60, 0xc8, 0xb1,
0x9b, 0xf0, 0x93, 0xc9, 0x02, 0x30, 0x0a, 0xf0, 0x04, 0xa9, 0xff, 0xd0,
0x08, 0xa9, 0xff, 0xd0, 0x85, 0xa9, 0x00, 0xf0, 0x00, 0xa2, 0x00, 0x9d,
0x00, 0x40, 0x9d, 0x00, 0x41, 0x9d, 0x00, 0x42, 0x9d, 0x00, 0x43, 0x9d,
0x00, 0x44, 0x9d, 0x00, 0x45, 0x9d, 0x00, 0x46, 0x9d, 0x00, 0x47, 0x9d,
0x00, 0x48, 0x9d, 0x00, 0x49, 0x9d, 0x00, 0x4a, 0x9d, 0x00, 0x4b, 0x9d,
0x00, 0x4c, 0x9d, 0x00, 0x4d, 0x9d, 0x00, 0x4e, 0x9d, 0x00, 0x4f, 0x9d,
0x00, 0x50, 0x9d, 0x00, 0x51, 0x9d, 0x00, 0x52, 0x9d, 0x00, 0x53, 0x9d,
0x00, 0x54, 0x9d, 0x00, 0x55, 0x9d, 0x00, 0x56, 0x9d, 0x00, 0x57, 0x9d,
0x00, 0x58, 0x9d, 0x00, 0x59, 0x9d, 0x00, 0x5a, 0x9d, 0x00, 0x5b, 0x9d,
0x00, 0x5c, 0x9d, 0x00, 0x5d, 0x9d, 0x00, 0x5e, 0x9d, 0x00, 0x5f, 0xe8,
0xe8, 0xe8, 0xd0, 0x9b, 0x60, 0xa9, 0x00, 0x85, 0xa4, 0x20, 0x64, 0x7d,
0x11, 0x99, 0x91, 0x99, 0x60, 0x4c, 0x74, 0x75, 0x98, 0x4a, 0x85, 0xa4,
0x29, 0x18, 0x85, 0xa3, 0x98, 0x29, 0x07, 0x05, 0xa3, 0xa8, 0xb9, 0x38,
0x72, 0x18, 0x65, 0xbb, 0x85, 0x9a, 0xa5, 0xa4, 0x4a, 0x4a, 0xa8, 0xb9,
0x58, 0x72, 0x18, 0x7d, 0x78, 0x72, 0xa8, 0xbd, 0x78, 0x73, 0x30, 0x05,
0x11, 0x99, 0x91, 0x99, 0x60, 0x11, 0x99, 0x91, 0x99, 0xc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0xca, 0x63, 0x0b, 0xfb, 0x80,
0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11,
0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11,
0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11,
0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11,
0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11,
0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11,
0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11,
0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11,
0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11,
0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11,
0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11,
0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11,
0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11,
0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11,
0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11,
0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11,
0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11,
0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11,
0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11,
0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11,
0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11,
0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11,
0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11,
0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11,
0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11,
0x11, 0x11, 0x11, 0x11, 0x11, 0x11, 0x11
};
unsigned int a23d2bin_len = 8443;

4819
pc/include/app.h Normal file

File diff suppressed because it is too large Load diff

92
pc/include/flight.h Normal file
View file

@ -0,0 +1,92 @@
/*
* Copyright (c) 2024 Scott Duensing, scott@kangaroopunch.com
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*/
#ifndef FLIGHT_H
#define FLIGHT_H
#include <stdbool.h>
#include <stdint.h>
#include <string.h>
#include <math.h>
typedef unsigned char byte;
typedef struct airplaneS {
int8_t aileron; // -15 to 15
int8_t elevator; // -15 to 15
int8_t rudder; // -15 to 15
int8_t throttle; // -15 to 15
bool ignition;
bool engine;
int16_t rpm;
float hSpeed;
float vSpeed;
float deltaZ;
float efAOF;
float climbRate;
bool airborne;
bool stall;
bool brake;
int16_t x;
int16_t y;
int16_t z;
double pitch; // 0 to 255
double yaw; // 0 to 255
double roll; // 0 to 255
// Flight model stuff below here.
float tmpX;
float tmpY;
float tmpZ;
float newX;
float newY;
float newZ;
float iSpeed;
float lSpeed;
float hAccel;
float lVeloc;
float gVeloc;
float AOA;
float torque;
float torque2;
uint16_t loopTime;
// Used to be static. Need preserved.
double dPitch;
double dYaw;
double dRoll;
float collectX;
float collectY;
float collectZ;
} airplaneT;
extern airplaneT _plane;
void resetAircraft(void);
void updateAircraft(void);
#endif // FLIGHT_H

283
pc/include/vrEmu6502.h Normal file
View file

@ -0,0 +1,283 @@
/*
* Troy's 6502 Emulator
*
* Copyright (c) 2022 Troy Schrapel
*
* This code is licensed under the MIT license
*
* https://github.com/visrealm/vrEmu6502
*
*/
#ifndef _VR_EMU_6502_H_
#define _VR_EMU_6502_H_
/* ------------------------------------------------------------------
* LINKAGE MODES:
*
* Default (nothing defined): When your executable is using vrEmuTms9918 as a DLL
* VR_EMU_6502_COMPILING_DLL: When compiling vrEmuTms9918 as a DLL
* VR_EMU_6502_STATIC: When linking vrEmu6502 statically in your executable
*/
#if __EMSCRIPTEN__
#include <emscripten.h>
#ifdef __cplusplus
#define VR_EMU_6502_DLLEXPORT EMSCRIPTEN_KEEPALIVE extern "C"
#else
#define VR_EMU_6502_DLLEXPORT EMSCRIPTEN_KEEPALIVE extern
#endif
#elif VR_EMU_6502_COMPILING_DLL
#define VR_EMU_6502_DLLEXPORT __declspec(dllexport)
#elif defined WIN32 && !defined VR_EMU_6502_STATIC
#define VR_EMU_6502_DLLEXPORT __declspec(dllimport)
#else
#ifdef __cplusplus
#define VR_EMU_6502_DLLEXPORT extern "C"
#else
#define VR_EMU_6502_DLLEXPORT extern
#endif
#endif
#include <stdint.h>
#include <stdbool.h>
/* ------------------------------------------------------------------
* PRIVATE DATA STRUCTURE
*/
struct vrEmu6502_s;
typedef struct vrEmu6502_s VrEmu6502;
/* ------------------------------------------------------------------
* CONSTANTS
*/
typedef enum
{
CPU_6502, /* NMOS 6502/6510 with documented opcodes only */
CPU_6502U, /* NMOS 6502/6510 with undocumented opcodes */
CPU_65C02, /* Standard CMOS 65C02 */
CPU_W65C02, /* Western Design Centre CMOS 65C02 */
CPU_R65C02, /* Rockwell CMOS 65C02 */
CPU_6510 = CPU_6502U,
CPU_8500 = CPU_6510,
CPU_8502 = CPU_8500,
CPU_7501 = CPU_6502,
CPU_8501 = CPU_6502
} vrEmu6502Model;
typedef enum
{
IntRequested,
IntCleared,
IntLow = IntRequested,
IntHigh = IntCleared
} vrEmu6502Interrupt;
typedef enum
{
BitC = 0,
BitZ,
BitI,
BitD,
BitB,
BitU,
BitV,
BitN
} vrEmu6502FlagBit;
typedef enum
{
FlagC = 0x01 << BitC, /* carry */
FlagZ = 0x01 << BitZ, /* zero */
FlagI = 0x01 << BitI, /* interrupt */
FlagD = 0x01 << BitD, /* decimal */
FlagB = 0x01 << BitB, /* brk */
FlagU = 0x01 << BitU, /* undefined */
FlagV = 0x01 << BitV, /* oVerflow */
FlagN = 0x01 << BitN /* negative */
} vrEmu6502Flag;
typedef enum
{
AddrModeAbs,
AddrModeAbsX,
AddrModeAbsY,
AddrModeAcc,
AddrModeImm,
AddrModeImp,
AddrModeAbsInd,
AddrModeAbsIndX,
AddrModeIndX,
AddrModeIndY,
AddrModeRel,
AddrModeZP,
AddrModeZPI,
AddrModeZPX,
AddrModeZPY,
} vrEmu6502AddrMode;
/* ------------------------------------------------------------------
* PUBLIC INTERFACE
*/
/*
* memory write function pointer
*/
typedef void(*vrEmu6502MemWrite)(uint16_t addr, uint8_t val);
/*
* memory read function pointer
*
* isDbg: some devices change their state when read
* (eg. TMS9918 increments its address pointer)
* this flag will be false when the cpu is running
* however it can be true when querying the memory
* for other purposes. devices should NOT change state
* when isDbg is true.
*
*/
typedef uint8_t(*vrEmu6502MemRead)(uint16_t addr, bool isDbg);
/*
* create a new 6502
*/
VR_EMU_6502_DLLEXPORT VrEmu6502* vrEmu6502New(
vrEmu6502Model model,
vrEmu6502MemRead readFn,
vrEmu6502MemWrite writeFn);
/* ------------------------------------------------------------------
*
* destroy a 6502
*/
VR_EMU_6502_DLLEXPORT void vrEmu6502Destroy(VrEmu6502* vr6502);
/* ------------------------------------------------------------------
*
* reset the 6502
*/
VR_EMU_6502_DLLEXPORT void vrEmu6502Reset(VrEmu6502* vr6502);
/* ------------------------------------------------------------------
*
* a single clock tick
*/
VR_EMU_6502_DLLEXPORT void vrEmu6502Tick(VrEmu6502* vr6502);
/* ------------------------------------------------------------------
*
* a single instruction cycle
*/
VR_EMU_6502_DLLEXPORT uint8_t vrEmu6502InstCycle(VrEmu6502* vr6502);
/* ------------------------------------------------------------------
*
* returns a pointer to the interrupt signal.
* externally, you can modify it to set/reset the interrupt signal
*/
VR_EMU_6502_DLLEXPORT vrEmu6502Interrupt *vrEmu6502Int(VrEmu6502* vr6502);
/* ------------------------------------------------------------------
*
* returns a pointer to the nmi signal.
* externally, you can modify it to set/reset the interrupt signal
*/
VR_EMU_6502_DLLEXPORT vrEmu6502Interrupt *vrEmu6502Nmi(VrEmu6502* vr6502);
/* ------------------------------------------------------------------
*
* return the program counter
*/
VR_EMU_6502_DLLEXPORT uint16_t vrEmu6502GetPC(VrEmu6502* vr6502);
/* ------------------------------------------------------------------
*
* set the program counter
*/
VR_EMU_6502_DLLEXPORT void vrEmu6502SetPC(VrEmu6502* vr6502, uint16_t pc);
/* ------------------------------------------------------------------
*
* return the accumulator
*/
VR_EMU_6502_DLLEXPORT uint8_t vrEmu6502GetAcc(VrEmu6502* vr6502);
/* ------------------------------------------------------------------
*
* return the x index register
*/
VR_EMU_6502_DLLEXPORT uint8_t vrEmu6502GetX(VrEmu6502* vr6502);
/* ------------------------------------------------------------------
*
* return the y index register
*/
VR_EMU_6502_DLLEXPORT uint8_t vrEmu6502GetY(VrEmu6502* vr6502);
/* ------------------------------------------------------------------
*
* return the processor status register
*/
VR_EMU_6502_DLLEXPORT uint8_t vrEmu6502GetStatus(VrEmu6502* vr6502);
/* ------------------------------------------------------------------
*
* return the stack pointer register
*/
VR_EMU_6502_DLLEXPORT uint8_t vrEmu6502GetStackPointer(VrEmu6502* vr6502);
/* ------------------------------------------------------------------
*
* return the current opcode
*/
VR_EMU_6502_DLLEXPORT uint8_t vrEmu6502GetCurrentOpcode(VrEmu6502* vr6502);
/* ------------------------------------------------------------------
*
* return the current opcode address
*/
VR_EMU_6502_DLLEXPORT uint16_t vrEmu6502GetCurrentOpcodeAddr(VrEmu6502* vr6502);
/* ------------------------------------------------------------------
*
* return the next opcode
*/
VR_EMU_6502_DLLEXPORT uint8_t vrEmu6502GetNextOpcode(VrEmu6502* vr6502);
/* ------------------------------------------------------------------
*
* return the opcode cycle
*/
VR_EMU_6502_DLLEXPORT uint8_t vrEmu6502GetOpcodeCycle(VrEmu6502* vr6502);
/* ------------------------------------------------------------------
*
* return the opcode mnemonic string
*/
VR_EMU_6502_DLLEXPORT
const char* vrEmu6502OpcodeToMnemonicStr(VrEmu6502* vr6502, uint8_t opcode);
/* ------------------------------------------------------------------
*
* return the opcode address mode
*/
VR_EMU_6502_DLLEXPORT
vrEmu6502AddrMode vrEmu6502GetOpcodeAddrMode(VrEmu6502* vr6502, uint8_t opcode);
/* ------------------------------------------------------------------
*
* get disassembled instruction as a string. returns next instruction address
*/
VR_EMU_6502_DLLEXPORT
uint16_t vrEmu6502DisassembleInstruction(
VrEmu6502* vr6502, uint16_t addr,
int bufferSize, char *buffer,
uint16_t *refAddr, const char* const labelMap[0x10000]);
#endif // _VR_EMU_6502_CORE_H_

313
pc/src/flight.c Normal file
View file

@ -0,0 +1,313 @@
/*
* Copyright (c) 2024 Scott Duensing, scott@kangaroopunch.com
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*/
#include "flight.h"
airplaneT _plane;
#define SEGMENT_MATH
#define PI 3.1415926
#define Rads(d) (((d) < 0 ? (d) + 360 : (d)) * (PI / 180))
#define Degs(r) ((r) * (180 / PI))
// https://www.reddit.com/r/programming/comments/3e7ghi/discrete_arctan_in_6502/
#define ATAN_SPLINE_C0 (double)(-0.14380550980765507115) /* 3pi/4 - 5/2 */
#define ATAN_SPLINE_C1 (double)(-0.07079632679489661923) /* 3/2 - pi/2 */
double ourAtan(double x){
if (x >= 0) {
if ( x<= 1) {
return x + (ATAN_SPLINE_C0 + ATAN_SPLINE_C1 * x) * x * x;
} else {
x = 1 / x;
return PI / 2 - (x + (ATAN_SPLINE_C0 + ATAN_SPLINE_C1 * x) * x * x);
}
} else {
if (x >= -1) {
return x - (ATAN_SPLINE_C0 - ATAN_SPLINE_C1 * x) * x * x;
} else {
x = -1 / x;
return (x + (ATAN_SPLINE_C0 + ATAN_SPLINE_C1 * x) * x * x) - PI / 2;
}
}
}
float cosD(float d) {
return cos(Rads(d));
}
float sinD(float d) {
return sin(Rads(d));
}
#define SEGMENT_FLIGHT_MODEL_1
// This flight model is basically the one from "Build Your Own Flight Sim
// in C++" by Michael Radtke and Chris Lampton.
void lightPlane(void) {
// Flight model. Power Dynamics.
if (_plane.ignition) {
// Start engine.
if (!_plane.engine) _plane.engine = true;
// Adjust RPM.
if (_plane.rpm < (375 + (_plane.throttle * 117))) _plane.rpm += _plane.loopTime * 0.5; //***TODO*** T
if (_plane.rpm > (375 + (_plane.throttle * 117))) _plane.rpm -= _plane.loopTime * 0.5;
} else {
// Stop engine.
if (_plane.engine) _plane.engine = false;
// Run down engine.
if (_plane.rpm > 0) _plane.rpm -= (int16_t)(_plane.loopTime / 2); //***TODO*** This will never work.
if (_plane.rpm < 0) _plane.rpm = 0;
}
// Flight model. Flight Dynamics.
// Calculate speed from RPM.
_plane.iSpeed = _plane.rpm / 17.5;
// Modify speed by pitch.
_plane.iSpeed += (_plane.pitch * 1.5);
// Horizontal acceleration - thrust.
_plane.hAccel = ((_plane.rpm * (_plane.iSpeed - _plane.hSpeed)) / 10000);
_plane.hAccel /= 1000;
_plane.hAccel *= _plane.loopTime;
if (_plane.brake && !_plane.airborne) {
// Handle brakes.
if (_plane.hSpeed > 0) {
_plane.hSpeed -= 1;
} else {
_plane.hSpeed = 0;
}
} else {
// Accelerate normally.
_plane.hSpeed += _plane.hAccel;
}
// Force speed to range -1..1.
_plane.lSpeed = (_plane.hSpeed / 65) - 1;
if (_plane.lSpeed > 1) _plane.lSpeed = 1;
// Lift curve.
_plane.lVeloc = Degs(ourAtan(_plane.lSpeed));
// Force lift to range 0..90.
_plane.lVeloc += 45;
// Shift range to 0..-17.
_plane.lVeloc /= 5.29;
// Multiply by pitch modifier.
_plane.lVeloc *= (-(_plane.pitch * .157) + 1);
// Time slice.
_plane.lVeloc /= 1000;
_plane.lVeloc *= _plane.loopTime;
// Gravity.
_plane.gVeloc = _plane.loopTime * (-16.0 / 10000); // -16.0 is ft/sec for gravity.
// Sum vertical velocity.
_plane.vSpeed = _plane.gVeloc + _plane.lVeloc;
// No vertical speed if we're on the ground.
if (!_plane.airborne && (_plane.vSpeed < 0)) _plane.vSpeed = 0;
// Save climb rate in ft/min.
_plane.climbRate = _plane.vSpeed / _plane.loopTime;
_plane.climbRate *= 60000L;
// Expand to ft/hr.
_plane.deltaZ = _plane.hSpeed * 5280;
// Get ft/ms.
_plane.deltaZ /= 3600000L;
_plane.deltaZ *= _plane.loopTime;
// Find effective angle of flight.
if (_plane.deltaZ) {
_plane.efAOF = -(ourAtan(_plane.vSpeed / _plane.deltaZ));
} else {
_plane.efAOF = -(ourAtan(_plane.vSpeed));
}
// Convert to degrees.
_plane.AOA = Degs(_plane.efAOF);
// Handle stalling.
if (((_plane.pitch < _plane.AOA) && (_plane.AOA < 0)) && (_plane.hSpeed < 40)) {
if ((_plane.pitch - _plane.AOA) < -20) _plane.stall = true;
}
if (_plane.stall) {
if (_plane.pitch > 30) {
_plane.stall = false;
} else {
_plane.pitch++;
}
}
}
#define SEGMENT_FLIGHT_MODEL_2
void lightPlane2(void) {
// Flight model. Inertial Damping.
if (_plane.dPitch) {
_plane.dPitch -= _plane.dPitch / 10;
if (((_plane.dPitch > 0) && (_plane.dPitch < 0.01)) || ((_plane.dPitch < 0) && (_plane.dPitch > -0.01))) _plane.dPitch = 0;
}
if (_plane.dYaw) {
_plane.dYaw -= _plane.dYaw / 10;
if (((_plane.dYaw > 0) && (_plane.dYaw < 0.01)) || ((_plane.dYaw < 0) && (_plane.dYaw > -0.01))) _plane.dYaw = 0;
}
if (_plane.dRoll) {
_plane.dRoll -= _plane.dRoll / 10;
if (((_plane.dRoll > 0) && (_plane.dRoll < 0.01)) || ((_plane.dRoll < 0) && (_plane.dRoll > -0.01))) _plane.dRoll = 0;
}
// Flight model. Rate of Change.
if (_plane.airborne) {
if (_plane.aileron != 0) {
_plane.torque = ((_plane.hSpeed * _plane.aileron) / 10000);
if (_plane.dRoll != (_plane.torque * _plane.loopTime)) _plane.dRoll += _plane.torque * 6;
}
}
if (_plane.elevator != 0) {
_plane.torque = ((_plane.hSpeed * _plane.elevator) / 10000);
if ((!_plane.airborne) && (_plane.torque > 0)) _plane.torque = 0; //***FIX*** This is dumb.
if (_plane.dPitch != (_plane.torque * _plane.loopTime)) _plane.dPitch += _plane.torque * 1.5;
}
if (_plane.hSpeed) {
_plane.torque = 0.0;
if (_plane.rudder != 0) _plane.torque -= ((_plane.hSpeed * _plane.rudder) / 10000);
_plane.torque2 = 0.0;
if ((_plane.roll > 0) && (_plane.roll <= 90)) { //***FIX*** This is dumb.
_plane.torque2 = _plane.roll * 0.00050;
} else {
if ((_plane.roll < 0) && (_plane.roll >= -90)) {
_plane.torque2 = _plane.roll * 0.00050;
}
}
_plane.torque += _plane.torque2;
if (_plane.dYaw != (_plane.torque * _plane.loopTime)) _plane.dYaw += _plane.torque * 1.5;
}
// Flight model. Apply Rotations.
// Transform pitch into components of yaw and pitch based on roll.
_plane.roll += _plane.dRoll;
_plane.yaw += _plane.dYaw;
_plane.pitch += (_plane.dPitch * cosD(_plane.roll));
_plane.yaw += -(_plane.dPitch * sinD(_plane.roll));
if (_plane.roll > 180) {
_plane.roll = -180 + (_plane.roll - 180);
} else {
if (_plane.roll < -180) _plane.roll = 180 + (_plane.roll + 180);
}
if (_plane.yaw > 180) {
_plane.yaw = -180 + (_plane.yaw - 180);
} else {
if (_plane.yaw < -180) _plane.yaw = 180 + (_plane.yaw + 180);
}
// Handle special case when aircraft pitch passes vertical.
if ((_plane.pitch > 90) || (_plane.pitch < -90)) {
if (_plane.roll >= 0) {
_plane.roll -= 180;
} else {
if (_plane.roll < 0) _plane.roll += 180;
}
if (_plane.yaw >= 0) {
_plane.yaw -= 180;
} else {
if (_plane.yaw < 0) _plane.yaw += 180;
}
if (_plane.pitch > 0) {
_plane.pitch = (180 - _plane.pitch);
} else {
if (_plane.pitch < 0) _plane.pitch = (-180 - _plane.pitch);
}
}
// Dampen everything out to 0 if they get close enough.
if ((_plane.pitch > -0.5) && (_plane.pitch < 0.5)) _plane.pitch = 0;
if ((_plane.roll > -0.5) && (_plane.roll < 0.5)) _plane.roll = 0;
if ((_plane.yaw > -0.5) && (_plane.yaw < 0.5)) _plane.yaw = 0;
}
#define SEGMENT_FLIGHT_MODEL_3
void moveAircraft(void) {
// Calculate new aircraft position. Each coordinate is 1 foot in 3D space.
_plane.tmpX = 0;
_plane.tmpY = 0;
_plane.tmpZ = _plane.deltaZ;
// Order of these points is significant.
// Rotate in Z.
_plane.newX = (_plane.tmpX * cosD(_plane.roll)) - (_plane.tmpY * sinD(_plane.roll));
_plane.newY = (_plane.tmpX * sinD(_plane.roll)) + (_plane.tmpY * cosD(_plane.roll));
_plane.tmpX = _plane.newX;
_plane.tmpY = _plane.newY;
// Rotate in X;
_plane.efAOF = Degs(_plane.efAOF);
_plane.newY = (_plane.tmpY * cosD(_plane.efAOF)) - (_plane.tmpZ * sinD(_plane.efAOF));
_plane.newZ = (_plane.tmpY * sinD(_plane.efAOF)) + (_plane.tmpZ * cosD(_plane.efAOF));
_plane.tmpY = _plane.newY;
_plane.tmpZ = _plane.newZ;
// Rotate in X;
_plane.newX = (_plane.tmpZ * sinD(_plane.yaw)) + (_plane.tmpX * cosD(_plane.yaw));
_plane.newZ = (_plane.tmpZ * cosD(_plane.yaw)) - (_plane.tmpX * sinD(_plane.yaw));
_plane.tmpX = _plane.newX;
_plane.tmpZ = _plane.newZ;
// Translate rotated point back to where it should be
// relative to it's last position.
_plane.collectX += _plane.newX;
if ((_plane.collectX > 1) || (_plane.collectX < -1)) {
_plane.x -= _plane.collectX;
_plane.collectX = 0;
}
_plane.collectY += _plane.newY;
if ((_plane.collectY > 1) || (_plane.collectY < -1)) {
_plane.y -= _plane.collectY;
_plane.collectY = 0;
}
_plane.collectZ += _plane.newZ;
if ((_plane.collectY > 1) || (_plane.collectY < -1)) {
_plane.z += _plane.collectZ;
_plane.collectZ = 0;
}
// Are we flying?
if ((!_plane.airborne) && (-_plane.y)) _plane.airborne = true;
}
void resetAircraft(void) {
// Initialize airplane.
memset(&_plane, 0, sizeof(airplaneT));
_plane.loopTime = 40;
}
#define SEGMENT_MAIN
void updateAircraft(void) {
// Do the actual flying!
lightPlane();
lightPlane2();
moveAircraft();
}

569
pc/src/main.c Normal file
View file

@ -0,0 +1,569 @@
/*
* Copyright (c) 2024 Scott Duensing, scott@kangaroopunch.com
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*/
#include "vrEmu6502.h"
#include "a23d2bin.h"
#include "a23d2.h"
#include "flight.h"
#define APP_IMPLEMENTATION
#define APP_SDL
#define APP_S16 int16_t
#define APP_U32 uint32_t
#define APP_U64 uint64_t
#include "app.h"
#define HEIGHT 240
#define WIDTH 320
#define JOY_UP 1
#define JOY_DOWN 2
#define JOY_LEFT 4
#define JOY_RIGHT 8
#define JOY_BUTTON_1 16
#define JOY_BUTTON_2 32
#define JOY_BUTTON_3 64
typedef struct ArgsS {
int count;
char **args;
} ArgsT;
typedef struct ColorS {
byte r;
byte g;
byte b;
} ColorT;
// Foenix Stuff.
byte _gamepad;
// Graphics Stuff.
byte _ega[16][3] = {
{ 0x00, 0x00, 0x00 },
{ 0x00, 0x00, 0xaa },
{ 0x00, 0xaa, 0x00 },
{ 0x00, 0xaa, 0xaa },
{ 0xaa, 0x00, 0x00 },
{ 0xaa, 0x00, 0xaa },
{ 0xaa, 0x55, 0x00 },
{ 0xaa, 0xaa, 0xaa },
{ 0x55, 0x55, 0x55 },
{ 0x55, 0x55, 0xff },
{ 0x55, 0xff, 0x55 },
{ 0x55, 0xff, 0xff },
{ 0xff, 0x55, 0x55 },
{ 0xff, 0x55, 0xff },
{ 0xff, 0xff, 0x55 },
{ 0xff, 0xff, 0xff }
};
byte *_pixels = NULL;
ColorT _color;
// Emulator Stuff.
byte _RAM[0x10000]; // 6502 memory.
VrEmu6502 *_v6502 = NULL;
// A2-3D2 Stuff.
volatile cameraT *_camera;
uint16_t _drawlistInDatabase;
#define LOW_BYTE(x) ((uint8_t)(x))
#define HIGH_BYTE(x) ((uint8_t)(((uint16_t)(x)) >> 8))
// ***FIX*** Somehow we're getting invalid drawing coordinates from A2-3D2.
#define bitmapPutPixelIOSet(x,y) \
({ \
if ((x < WIDTH) && (y < HEIGHT)) { \
byte *p = _pixels + ((x) * 4 + ((y) * WIDTH * 4)); \
*p++ = _color.r; \
*p++ = _color.g; \
*p++ = _color.b; \
*p++ = 255; \
} \
})
void bitmapLine(uint16_t x1, uint16_t y1, uint16_t x2, uint16_t y2);
void colorSet(byte ega);
void draw(void);
void jsr(uint16_t addr);
void landscape(void);
byte memoryRead(uint16_t addr, bool isDebug);
void memoryWrite(uint16_t addr, byte value);
int appMain(app_t *app, void *userData);
void bitmapLine(uint16_t x1, uint16_t y1, uint16_t x2, uint16_t y2) {
uint16_t x;
uint16_t y;
int16_t dx;
int16_t dy;
int16_t incX;
int16_t incY;
int16_t balance;
if (x2 >= x1) {
dx = x2 - x1;
incX = 1;
} else {
dx = x1 - x2;
incX = -1;
}
if (y2 >= y1) {
dy = y2 - y1;
incY = 1;
} else {
dy = y1 - y2;
incY = -1;
}
x = x1;
y = y1;
if (dx >= dy) {
dy <<= 1;
balance = dy - dx;
dx <<= 1;
while (x != x2) {
bitmapPutPixelIOSet(x, y);
if (balance >= 0) {
y += incY;
balance -= dx;
}
balance += dy;
x += incX;
}
bitmapPutPixelIOSet(x, y);
} else {
dx <<= 1;
balance = dx - dy;
dy <<= 1;
while (y != y2) {
bitmapPutPixelIOSet(x, y);
if (balance >= 0) {
x += incX;
balance -= dy;
}
balance += dx;
y += incY;
}
bitmapPutPixelIOSet(x, y);
}
}
void colorSet(byte ega) {
_color.r = _ega[ega][0];
_color.g = _ega[ega][1];
_color.b = _ega[ega][2];
}
void draw(void) {
uint16_t pointer = DRAWLIST_P0;
int16_t x1;
int16_t y1;
int16_t x2;
int16_t y2;
while (true) {
switch (_RAM[pointer++]) {
// Line.
case LIN2D:
x1 = (int8_t)_RAM[pointer++] + 128;
y1 = 255 - ((int8_t)_RAM[pointer++] + 128);
x2 = (int8_t)_RAM[pointer++] + 128;
y2 = 255 - ((int8_t)_RAM[pointer++] + 128);
bitmapLine(x1, y1, x2, y2);
continue;
// Point.
case PNT2D:
x1 = (int8_t)_RAM[pointer++] + 128;
y1 = 255 - ((int8_t)_RAM[pointer++] + 128);
bitmapPutPixelIOSet(x1, y1);
continue;
// Set Color.
case STCOL:
x1 = _RAM[pointer++];
colorSet(x1);
continue;
// Set Resolution.
case SRES:
// Eat this byte. We don't need it.
pointer++;
continue;
// End.
case END:
break;
}
break;
}
}
void jsr(uint16_t addr) {
int32_t depth = 0;
int32_t instructions = 0;
uint16_t PC = addr;
vrEmu6502SetPC(_v6502, PC);
while (true) {
// Did we execute an instruction?
if (PC != vrEmu6502GetPC(_v6502)) {
PC = vrEmu6502GetPC(_v6502);
instructions++;
// Track JSRs & RTSs.
if (vrEmu6502GetCurrentOpcode(_v6502) == 0x20) depth++;
if (vrEmu6502GetCurrentOpcode(_v6502) == 0x60) {
depth--;
if (depth < 0) break;
}
}
// Step.
vrEmu6502Tick(_v6502);
}
//printf("%x = %d instructions\n", addr, instructions);
}
void landscape(void) {
int16_t i;
int16_t x;
int16_t y;
int16_t min = 0;
int16_t max = 10000;
byte *db = _RAM;
uint16_t bytes = DATABASE;
// All scene databases need to begin with the ARRAY and EYE records.
// The CLPSW clipping setting is up to you. :-)
db[bytes++] = ARRAY; // Will be filled in by the program.
db[bytes++] = 0;
db[bytes++] = 0;
db[bytes++] = EYE; // Will be filled in by the program.
db[bytes++] = 0x00; // X
db[bytes++] = 0x00;
db[bytes++] = 0x00; // Y
db[bytes++] = 0x00;
db[bytes++] = 0x00; // Z
db[bytes++] = 0x00;
db[bytes++] = 0x00; // P
db[bytes++] = 0x00; // B
db[bytes++] = 0x00; // H
db[bytes++] = CLPSW;
db[bytes++] = 0x00;
// Landscape
db[bytes++] = STCOL;
db[bytes++] = 2; // Green
for (i=min; i<=max; i+=1000) {
db[bytes++] = SPNT;
db[bytes++] = LOW_BYTE(i); // X
db[bytes++] = HIGH_BYTE(i);
db[bytes++] = 0; // Y
db[bytes++] = 0;
db[bytes++] = LOW_BYTE(min); // Z
db[bytes++] = HIGH_BYTE(min);
db[bytes++] = CPNT;
db[bytes++] = LOW_BYTE(i); // X
db[bytes++] = HIGH_BYTE(i);
db[bytes++] = 0; // Y
db[bytes++] = 0;
db[bytes++] = LOW_BYTE(max); // Z
db[bytes++] = HIGH_BYTE(max);
db[bytes++] = SPNT;
db[bytes++] = LOW_BYTE(min); // X
db[bytes++] = HIGH_BYTE(min);
db[bytes++] = 0; // Y
db[bytes++] = 0;
db[bytes++] = LOW_BYTE(i); // Z
db[bytes++] = HIGH_BYTE(i);
db[bytes++] = CPNT;
db[bytes++] = LOW_BYTE(max); // X
db[bytes++] = HIGH_BYTE(max);
db[bytes++] = 0; // Y
db[bytes++] = 0;
db[bytes++] = LOW_BYTE(i); // Z
db[bytes++] = HIGH_BYTE(i);
}
// Runway - 3000' x 100'
min = 3500;
max = min + 300;
x = 3500;
db[bytes++] = STCOL;
db[bytes++] = 8; // Dark Grey
for (i=0; i<=10; i+=2) {
db[bytes++] = SPNT;
db[bytes++] = LOW_BYTE(x+i); // X
db[bytes++] = HIGH_BYTE(x+i);
db[bytes++] = 0; // Y
db[bytes++] = 0;
db[bytes++] = LOW_BYTE(min); // Z
db[bytes++] = HIGH_BYTE(min);
db[bytes++] = CPNT;
db[bytes++] = LOW_BYTE(x+i); // X
db[bytes++] = HIGH_BYTE(x+i);
db[bytes++] = 0; // Y
db[bytes++] = 0;
db[bytes++] = LOW_BYTE(max); // Z
db[bytes++] = HIGH_BYTE(max);
}
db[bytes++] = END;
}
byte memoryRead(uint16_t addr, bool isDebug) {
(void)isDebug;
return _RAM[addr];
}
void memoryWrite(uint16_t addr, byte value) {
_RAM[addr] = value;
}
int appMain(app_t *app, void *userData) {
ArgsT *args = (ArgsT *)userData;
uint16_t bytes;
app_input_t input;
// Set up window.
app_screenmode(app, APP_SCREENMODE_WINDOW);
app_title(app, "Sierra Hotel Flight Model Test");
app_interpolation(app, APP_INTERPOLATION_NONE);
app_window_size(app, WIDTH * 2, HEIGHT * 2);
// Clear VM RAM.
memset(_RAM, 0, 0x10000);
// Create our VM.
_v6502 = vrEmu6502New(CPU_W65C02, memoryRead, memoryWrite);
// Copy A2-3D2 into 6502 RAM.
memcpy(&_RAM[0x6000], a23d2bin, a23d2bin_len);
// Initialize A2-3D2 so we can use the "fast entry point" (NXTPT) when rendering.
bytes = A23D2_TEST_DATABASE;
_RAM[bytes++] = SCRSZ; // Screen size. 256x240. Center is 0,0.
_RAM[bytes++] = 255;
_RAM[bytes++] = 239;
_RAM[bytes++] = 0;
_RAM[bytes++] = 0;
_RAM[bytes++] = END; // Setup complete!
jsr(A23D2_ENTRYN);
// Generate scene database.
landscape();
// Set up drawlist.
_drawlistInDatabase = DATABASE + 1;
_RAM[DRAWLIST_P0] = END;
// Set up camera.
_camera = (cameraT *)&_RAM[DATABASE + 4];
_camera->x = 5000;
_camera->y = 1000;
_camera->z = 5000;
_camera->p = 25;
// Set up render surface.
_pixels = (byte *)malloc(HEIGHT * WIDTH * 4);
// Build a plane!
resetAircraft();
// No input.
_gamepad = 0;
// Loop until exit.
while (app_yield(app) != APP_STATE_EXIT_REQUESTED) {
// Clear screen.
memset(_pixels, 0, HEIGHT * WIDTH * 4);
// 3D Viewport edge.
colorSet(14);
bitmapLine(256, 0, 256, 239);
// Update drawlist.
_RAM[_drawlistInDatabase + 1] = HIGH_BYTE(DRAWLIST_P0);
_RAM[_drawlistInDatabase + 0] = LOW_BYTE(DRAWLIST_P0);
// Set IBP.
_RAM[A23D2_IBP + 1] = HIGH_BYTE(DATABASE);
_RAM[A23D2_IBP + 0] = LOW_BYTE(DATABASE);
// Render.
jsr(A23D2_NXTPT);
draw();
// Get input.
input = app_input(app);
for (bytes=0; bytes<input.count; bytes++) {
if (input.events[bytes].type == APP_INPUT_KEY_DOWN) {
switch (input.events[bytes].data.key) {
case APP_KEY_W:
_gamepad |= JOY_UP;
break;
case APP_KEY_A:
_gamepad |= JOY_LEFT;
break;
case APP_KEY_S:
_gamepad |= JOY_DOWN;
break;
case APP_KEY_D:
_gamepad |= JOY_RIGHT;
break;
case APP_KEY_J:
_gamepad |= JOY_BUTTON_1;
break;
case APP_KEY_K:
_gamepad |= JOY_BUTTON_2;
break;
case APP_KEY_L:
_gamepad |= JOY_BUTTON_3;
break;
default:
break;
}
}
if (input.events[bytes].type == APP_INPUT_KEY_UP) {
switch (input.events[bytes].data.key) {
case APP_KEY_W:
_gamepad &= ~JOY_UP;
break;
case APP_KEY_A:
_gamepad &= ~JOY_LEFT;
break;
case APP_KEY_S:
_gamepad &= ~JOY_DOWN;
break;
case APP_KEY_D:
_gamepad &= ~JOY_RIGHT;
break;
case APP_KEY_J:
_gamepad &= ~JOY_BUTTON_1;
break;
case APP_KEY_K:
_gamepad &= ~JOY_BUTTON_2;
break;
case APP_KEY_L:
_gamepad &= ~JOY_BUTTON_3;
break;
default:
break;
}
}
}
// Update aircraft control state.
if ((_gamepad & JOY_BUTTON_1) || (_gamepad & JOY_BUTTON_2) || (_gamepad & JOY_BUTTON_3)) {
// Modified input with button down.
if ((_gamepad & JOY_UP) && (_plane.throttle > -15)) _plane.throttle++;
if ((_gamepad & JOY_DOWN) && (_plane.throttle < 15)) _plane.throttle--;
if (_gamepad & JOY_RIGHT) _plane.brake = !_plane.brake;
} else {
// No button pressed.
if ((_gamepad & JOY_UP) && (_plane.elevator > -15)) _plane.elevator--;
if ((_gamepad & JOY_DOWN) && (_plane.elevator < 15)) _plane.elevator++;
if ((_gamepad & JOY_LEFT) && (_plane.aileron > -15)) _plane.aileron--;
if ((_gamepad & JOY_RIGHT) && (_plane.aileron < 15)) _plane.aileron++;
}
// "Coordinated" flight.
_plane.rudder = _plane.aileron;
// FLY!
updateAircraft();
// Move camera.
//_camera->p += 1; // Change pitch angle.
//_camera->b += 2; // Change bank angle.
_camera->h += 1; // Change heading angle.
//printf("H = %d\n", _camera->h);
// Update screen.
app_present(app, (APP_U32 *)_pixels, WIDTH, HEIGHT, 0xffffff, 0x000000);
}
// Destroy VM.
vrEmu6502Destroy(_v6502);
_v6502 = NULL;
// Free render surface.
free(_pixels);
return 0;
}
int main(int argc, char *argv[]) {
ArgsT args;
args.count = argc;
args.args = argv;
return app_run(appMain, &args, NULL, NULL, NULL);
}

2290
pc/src/vrEmu6502.c Normal file

File diff suppressed because it is too large Load diff

View file

@ -128,11 +128,21 @@
#include <string.h>
#define WITHOUT_FILE
#define WITHOUT_SPRITE
#define WITHOUT_TILE
#define F256LIB_IMPLEMENTATION
#include "f256lib.h"
#ifdef __F256K__
#define WITHOUT_FILE
#define WITHOUT_SPRITE
#define WITHOUT_TILE
#define F256LIB_IMPLEMENTATION
#include "f256lib.h"
/*
* embedded.bin is loaded at 0x54000:
*
* 8k a2-3d2.bin @ 0x54000
* 8k scene.3d @ 0x56000
*
*/
EMBED(".binarydata.embedded", embedded, "embedded.bin");
#endif
#include "a23d2.h"
@ -168,16 +178,6 @@ byte _gamepad;
#endif
/*
* embedded.bin is loaded at 0x54000:
*
* 8k a2-3d2.bin @ 0x54000
* 8k scene.3d @ 0x56000
*
*/
EMBED(".binarydata.embedded", embedded, "embedded.bin");
#if 0
//#define SEGMENT_MATH