Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
118 commits
Select commit Hold shift + click to select a range
ab11e37
Update build-ed64-example-rom.yml
networkfusion Nov 22, 2021
f5ecf7b
Fix build warnings.
networkfusion Nov 22, 2021
37f4424
Further fix for dma_wait()
networkfusion Nov 22, 2021
f18bd62
Correct spelling in last commit.
networkfusion Nov 22, 2021
d29caae
try fatff weak import
networkfusion Nov 22, 2021
6e46991
Use inbuilt libdragon fatFS?
networkfusion Nov 22, 2021
0027696
Try only diskio.h commented out.
networkfusion Nov 22, 2021
d175b6f
Add NDEBUG flag to exclude libdragon SD support
networkfusion Nov 22, 2021
df05584
Fix for last commit
networkfusion Nov 22, 2021
6f0ebd4
Double fix for libdragon debug flag.
networkfusion Nov 22, 2021
50115e5
Use libdragon diskio def?
networkfusion Nov 22, 2021
f07a290
Uncomment diskio
networkfusion Nov 22, 2021
9947564
Add no debug to libdragon build in CI?
networkfusion Nov 22, 2021
d2358aa
Revert last commit.
networkfusion Nov 22, 2021
14d6fcf
Try specific commands for libdragon make.
networkfusion Nov 22, 2021
837e07a
Fix spelling
networkfusion Nov 22, 2021
c41ca22
try without hyphens
networkfusion Nov 22, 2021
09257e8
No flags (not cmake).
networkfusion Nov 22, 2021
052e86b
with flags...
networkfusion Nov 22, 2021
8bbb114
try again.
networkfusion Nov 22, 2021
102cbc6
try with folder
networkfusion Nov 22, 2021
2faaff4
try within folder
networkfusion Nov 22, 2021
6a04ac3
should work...
networkfusion Nov 22, 2021
32c2f8b
Roll the default docker...
networkfusion Nov 22, 2021
0267550
remove . from make.
networkfusion Nov 22, 2021
b0b3180
remove flag
networkfusion Nov 22, 2021
7ab2c7b
use FF code from libdragon
networkfusion Nov 22, 2021
c4d754b
Correct makefile
networkfusion Nov 22, 2021
67ead91
Fix size.
networkfusion Nov 22, 2021
1b9a242
try different flag...
networkfusion Nov 22, 2021
bd20fcd
Try commenting install flag.
networkfusion Nov 22, 2021
15a34f5
Try removing colon and hyphen
networkfusion Nov 22, 2021
c305a36
try exec function
networkfusion Nov 22, 2021
0ee9e1d
fix char
networkfusion Nov 22, 2021
c731280
try without commentation.
networkfusion Nov 22, 2021
a67fc2f
try using bash -c
networkfusion Nov 22, 2021
fc39640
try direct command
networkfusion Nov 22, 2021
7eb5a2d
try more local var.
networkfusion Nov 22, 2021
281a117
worth a try...
networkfusion Nov 22, 2021
93d984b
try sed
networkfusion Nov 23, 2021
5e41a6c
try this...
networkfusion Nov 23, 2021
09d52e0
Extra try.
networkfusion Nov 23, 2021
69dff54
try backup writing.
networkfusion Nov 23, 2021
bf144f4
check this...
networkfusion Nov 23, 2021
f332e4e
last try.
networkfusion Nov 23, 2021
c91098e
without flag.
networkfusion Nov 23, 2021
78ad1b7
Try D flag
networkfusion Nov 23, 2021
71a7b70
Patch libdragon.
networkfusion Nov 25, 2021
09dfb72
Try no CD
networkfusion Nov 25, 2021
5e85377
Try within folder
networkfusion Nov 25, 2021
3cff8bc
Try patch flag.
networkfusion Nov 25, 2021
dc6969e
fallback to sed?!
networkfusion Nov 25, 2021
0035e32
Missing bit from sed.
networkfusion Nov 25, 2021
2b12452
Add undef for NDBUG.
networkfusion Nov 25, 2021
6d8c5d0
Fix xm.
networkfusion Nov 25, 2021
29df90c
debug check for file debug.c
networkfusion Nov 25, 2021
ba1b973
Change CI to use tagged libdragon.
networkfusion Dec 3, 2021
5e4d9b6
try without defining extra path.
networkfusion Dec 3, 2021
b9840ad
patch warnings as errors.
networkfusion Dec 3, 2021
ad2d3e5
correct path.
networkfusion Dec 3, 2021
98a31c9
Futher try.
networkfusion Dec 3, 2021
e9f60bf
add ls for debugging
networkfusion Dec 3, 2021
ed9392d
correct path.
networkfusion Dec 3, 2021
00e1d7e
add export for install location
networkfusion Dec 3, 2021
5000a15
remove export, it should already be set!
networkfusion Dec 3, 2021
8510f31
try with env arg
networkfusion Dec 3, 2021
dff8bec
add export before docker
networkfusion Dec 3, 2021
561beb1
Install toolchain to somewhere with permissions!
networkfusion Dec 3, 2021
8e1a58a
add env to docker.
networkfusion Dec 3, 2021
437542a
comment out libdragon install
networkfusion Dec 3, 2021
8cad7af
yaml fix?!
networkfusion Dec 3, 2021
6f7d645
second attempt
networkfusion Dec 3, 2021
c675850
add back &&
networkfusion Dec 3, 2021
305c870
trial and error!
networkfusion Dec 3, 2021
a4bfb19
try this...
networkfusion Dec 3, 2021
c1f6946
next try...
networkfusion Dec 3, 2021
d07a208
start work on rom build.
networkfusion Dec 3, 2021
a463e7e
add ls for debug.
networkfusion Dec 3, 2021
28e2e10
try sub dir?!
networkfusion Dec 3, 2021
e39e193
Try this then...
networkfusion Dec 3, 2021
e8867b0
Fix branch build?
networkfusion Dec 3, 2021
d50a273
revert buildon ci for the moment...
networkfusion Dec 3, 2021
25942ec
cd unrecognised?!
networkfusion Dec 3, 2021
0351f2a
second path?
networkfusion Dec 3, 2021
f4f7dd0
interesting!
networkfusion Dec 3, 2021
4a53482
lets try this then...
networkfusion Dec 3, 2021
354d04a
re-evaluate docker use.
networkfusion Dec 3, 2021
b370027
See what happens!
networkfusion Dec 3, 2021
f836887
okay try this...
networkfusion Dec 3, 2021
20c9298
add dir ls check...
networkfusion Dec 3, 2021
1b4b67b
correct yaml
networkfusion Dec 3, 2021
ceafba1
try listing dirs
networkfusion Dec 3, 2021
77d8867
correct paths
networkfusion Dec 3, 2021
de19653
damn linux
networkfusion Dec 3, 2021
6581273
further corrections
networkfusion Dec 3, 2021
2829842
Try this
networkfusion Dec 3, 2021
1444ecf
correct docker dirs
networkfusion Dec 3, 2021
eaa7ee5
correct working dir
networkfusion Dec 3, 2021
45625b8
just try it!
networkfusion Dec 3, 2021
bc6933e
Simplify...
networkfusion Dec 4, 2021
e1eea27
try again...
networkfusion Dec 4, 2021
12b1939
And again!
networkfusion Dec 4, 2021
087f926
and again
networkfusion Dec 4, 2021
7c9aac2
and again...
networkfusion Dec 4, 2021
2104315
correct libdragon path.
networkfusion Dec 4, 2021
10bb02b
Further attempt
networkfusion Dec 4, 2021
5987ff3
try.
networkfusion Dec 4, 2021
046112f
try this
networkfusion Dec 4, 2021
1be2915
and this
networkfusion Dec 4, 2021
4a45cca
or this
networkfusion Dec 4, 2021
a5d1fc0
now?
networkfusion Dec 4, 2021
b36e321
fix Setup Build environment
networkfusion Dec 4, 2021
47da6a1
correct dir
networkfusion Dec 4, 2021
e8aaa57
some sudo magic?
networkfusion Dec 4, 2021
9dbe0b8
fixes?
networkfusion Dec 4, 2021
f8d989f
start in dragon dir
networkfusion Dec 4, 2021
44164e8
try.
networkfusion Dec 4, 2021
b470aab
docker dir
networkfusion Dec 4, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
84 changes: 70 additions & 14 deletions .github/workflows/build-ed64-example-rom.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,14 @@
name: Build ED64 Example ROM

on: [push, pull_request]
on: [push] #, pull_request]
# on:
# push:
# paths:
# - '/**/ED64-XIO/*'
# pull_request:
# paths:
# - '/**/ED64-XIO/*'

jobs:
build:
runs-on: ubuntu-latest
Expand All @@ -10,27 +18,75 @@ jobs:
steps:
- uses: actions/checkout@v2
name: Checkout Code
with:
path: ${{ github.workspace }}
- name: Checkout libdragon repo
uses: actions/checkout@v2
with:
repository: dragonminded/libdragon
path: ${{ github.workspace }}/ED64-XIO/libdragon/
ref: '89d17be8563a44a9b95873d436832a1222757cdc'

- name: Install Libdragon container

- name: check current work dir
working-directory: ${{ github.workspace }}
run: |
sudo npm install -g libdragon
libdragon make
libdragon make install
libdragon make tools-install
# libdragon init
# libdragon install
ls
echo "switch to ED64-XIO"
cd ./ED64-XIO
ls
echo "switch to libdragon"
cd ./libdragon/
ls
echo "switch back to ED64-XIO"
cd ..
ls

- name: Setup Build environment
working-directory: ${{ github.workspace }}
run: |
cd ${{ github.workspace }}/ED64-XIO/
mkdir bin && mkdir bin/release && mkdir bin/debug && mkdir obj
libdragon start
ls
mkdir -p ED64-XIO/bin && mkdir -p ED64-XIO/bin/release && mkdir -p ED64-XIO/bin/debug && mkdir obj

- name: patch libdragon make (workaround ignore warnings as errors)
working-directory: ${{ github.workspace }}/ED64-XIO/libdragon
run: |
ls
sed -z -i.bak 's/ -Wall -Werror / /' ./Makefile



- name: Buid libdragon and ROM
working-directory: ${{ github.workspace }}/ED64-XIO
run: >-
docker run
--mount type=bind,source=$(pwd),target=/libdragon
--workdir=/libdragon
ghcr.io/dragonminded/libdragon:latest
echo "ED64-XIO dir" && ls &&
cd libdragon &&
echo "libdragon dir" && ls &&
make libdragon && sudo make install &&
make tools && sudo make tools-install &&
cd .. &&
echo "ED64-XIO dir" && ls &&
make ${{ matrix.releasetype }}

- name: Build ROM
run: cd ${{ github.workspace }}/ED64-XIO/ && libdragon make ${{ matrix.releasetype }}
# sudo npm install -g libdragon
# libdragon init
# #libdragon exec bash -c 'export N64_CFLAGS="-DNDEBUG"'
# #libdragon exec bash -c N64_CFLAGS="-DNDEBUG"
# #N64_CFLAGS="-DNDEBUG" && libdragon install
# sed -z -i.bak 's/CFLAGS+=$(N64_CFLAGS) /CFLAGS+=$(N64_CFLAGS) -DNDEBUG /' ./libdragon/Makefile
# sed -z -i.bak 's/#define assertf(expr, msg, ...) ({ })/#define assertf(expr, msg, ...) ({ (void)(expr); })/' ./libdragon/include/debug.h
# sed -z -i.bak '1s/^/#undef NDEBUG\n/' ./libdragon/src/debug.c
# sed -z -i.bak 's/bool direction = (out<=in);/bool direction = (out<=in); (void)direction;/' ./libdragon/src/audio/libxm/context.c
# sed -z -i.bak 's/assert(sz == dec_size);/assert(sz == dec_size); (void)sz;/' ./libdragon/src/audio/libxm/play.c
# libdragon install
# libdragon start

- name: Upload Artifact
uses: actions/[email protected]
with:
name: ED64-XIO-SAMPLE_N64_ROM-${{ matrix.releasetype }}
path: ${{ github.workspace }}/ED64-XIO/bin/${{ matrix.releasetype }}/ED64-XIO-SAMPLE.v64
path: ${{ github.workspace }}/**/ED64-XIO/bin/${{ matrix.releasetype }}/ED64-XIO-SAMPLE.v64
9 changes: 8 additions & 1 deletion .github/workflows/build-usb64-linux.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,13 @@
name: Build Linux Usb64 App

on: [push, pull_request]
on:
push:
paths:
- '/**/usb64/*'
pull_request:
paths:
- '/**/usb64/*'

jobs:
build:
runs-on: ubuntu-latest
Expand Down
9 changes: 8 additions & 1 deletion .github/workflows/build-usb64-windows.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,13 @@
name: Build Windows Usb64 App

on: [push, pull_request]
on:
push:
paths:
- '/**/usb64/*'
pull_request:
paths:
- '/**/usb64/*'

jobs:
build:
runs-on: windows-latest
Expand Down
2 changes: 1 addition & 1 deletion ED64-XIO/Makefile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
PROG_NAME = ED64-XIO-SAMPLE
ROMSIZE = 256K
ROMSIZE = 1048576B


ifdef SystemRoot
Expand Down
2 changes: 1 addition & 1 deletion ED64-XIO/ff/diskio.h
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*-----------------------------------------------------------------------/
/ Low level disk interface modlue include file (C)ChaN, 2019 /
/ Low level disk interface module include file (C)ChaN, 2019 /
/-----------------------------------------------------------------------*/

#ifndef _DISKIO_DEFINED
Expand Down
2 changes: 1 addition & 1 deletion ED64-XIO/src/bios.c
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ void ed64_bios_init() {
ed64_bios_rom_savetype_set(ED64_SAVE_OFF);

/* Always successful for now */
return 0;
//return 0;
}

/**
Expand Down
8 changes: 4 additions & 4 deletions ED64-XIO/src/sys.c
Original file line number Diff line number Diff line change
Expand Up @@ -165,12 +165,12 @@ void sys_n64_pi_read(void *ram, unsigned long pi_address, unsigned long len) {
data_cache_hit_writeback_invalidate(ram, len);
disable_interrupts();

while (dma_busy());
dma_wait();
IO_WRITE(PI_STATUS_REG, 3);
PI_regs->ram_address = ram;
PI_regs->pi_address = pi_address; //(pi_address | 0x10000000) & 0x1FFFFFFF;
PI_regs->write_length = len - 1;
while (dma_busy());
dma_wait();

enable_interrupts();
}
Expand All @@ -182,12 +182,12 @@ void sys_n64_pi_write(void *ram, unsigned long pi_address, unsigned long len) {
data_cache_hit_writeback(ram, len);
disable_interrupts();

while (dma_busy());
dma_wait();
IO_WRITE(PI_STATUS_REG, 3);
PI_regs->ram_address = ram;
PI_regs->pi_address = pi_address; //(pi_address | 0x10000000) & 0x1FFFFFFF;
PI_regs->read_length = len - 1;
while (dma_busy());
dma_wait();

enable_interrupts();

Expand Down