1
0
mirror of https://github.com/hsoft/collapseos.git synced 2024-11-27 09:58:06 +11:00

recipes/rc2014: fix out-of-date information

This commit is contained in:
Virgil Dupras 2020-08-16 20:54:06 -04:00
parent 124da6adec
commit 6d2a0f749a
2 changed files with 13 additions and 10 deletions

View File

@ -70,13 +70,15 @@ instead.
## Building your binary
The binary built in the base recipe doesn't have SDC drivers. Using the same
instructions as in the `eeprom` recipe, you'll need to assemble a binary with
those drivers. First, we need drivers for the SPI relay. This is done by
declaring `SPI_DATA`, `SPI_CSLOW` and `SPI_CSHIGH`, which are respectively `4`,
`5` and `6` in our relay design. You can then load the driver with `596 LOAD`.
This driver provides `(spix)`, `(spie)` and `(spid)` which are then used in the
SDC driver.
The binary built in the base recipe doesn't have SDC drivers. You'll need to
assemble a binary with those drivers. To do so, you'll modify the xcomp unit
of the base recipe. Look at `xcomp.fs`, you'll see that we load a block. That's
our xcomp block (likely, B599). Open it.
First, we need drivers for the SPI relay. This is done by declaring `SPI_DATA`,
`SPI_CSLOW` and `SPI_CSHIGH`, which are respectively `4`, `5` and `6` in our
relay design. You can then load the driver with `596 LOAD`. This driver provides
`(spix)`, `(spie)` and `(spid)` which are then used in the SDC driver.
The SDC driver is at B420. It gives you a load range. This means that what
you need to insert in `xcomp` will look like:
@ -85,7 +87,8 @@ you need to insert in `xcomp` will look like:
You also need to add `BLK$` to the init sequence.
Build it and write it to EEPROM.
Build it (run `make pack` in `cvm/` first to ensure an up-to-date blkfs) and
write it to EEPROM.
## Testing in the emulator

View File

@ -15,10 +15,10 @@ Build Collapse OS' from within Collapse OS is very similar to how we do
it from the makefile. If you take the time to look at the base recipe
`Makefile`, you'll see `cat xcomp.fs | $(STAGE)`. That's the thing. Open
`xcomp.fs` in a text editor and take a look at it. You'll see that it loads
B618, which contains the meat, and then spits stuff to port 2, which is a
B599, which contains the meat, and then spits stuff to port 2, which is a
special signal for the `stage` binary.
To assemble from RC2014, all you need to do is load B618. This will
To assemble from RC2014, all you need to do is load B599. This will
yield a binary in memory. To know the start/end offset of the binary, you'll
type the same two commands and in `xcomp.fs`, but replace the `/MOD 2 PC! 2 PC!`
words with `.X`. Then, write that binary between those offsets on your target