Previous journal: | Next journal: |
---|---|
0097-2023-06-18.md | 0099-2023-06-20.md |
- Maybe change some of the arguments and defaults to be more convenient:
=
command take value first (since we know this earlier) then also support an arg of*
to be equiv. toffffffff
.- Start off in
hex
mode by default, withdebug
off?
- Provide a timing function, i.e. a command to start a timer on pico_de0, then stop it and see what the delta is. This will allow us to work out how fast the pico_de0 can respond to USB streams.
- Create GUI for receiving keyboard/mouse input, then interpreting it, then sending as vector updates to
pico_de0 over USB?
- This will allow proper user control over the Raybox design.
- It could borrow code from the Raybox sim.
- Needs to run under Windows to get proper mouse capture and deltas.
- Can we make the Raybox design on the FPGA work like an async bus/register device?
i.e. Pico-DE0 can pretend to be a CPU that writes to its registers whenever it wants,
but these get buffered (also with metastability avoidance) for when the design
is next ready to load them (i.e. just before ray-casting DDA loop) so that:
- we don't need to sync with the design.
- we can write data anytime we've got it.
- the controller can write to a register that confirms when the data is actually ready/valid; ensures atomicity.
- the design could send us an IRQ for when the ray-casting loop is done, for better efficiency.
- Get a timestamp both at the start of a return to READY state, and once a new command has been started.
- If the command just started is
[
then store both timestamps. - As soon as a
]
command starts, store the current timestamp. - Upon executing the
]
command, print the time since READY and the time since the[
was first started. - NOTE: The
]
can be issued again later, to keep printing the delta since the last mark was started with[
.
I'm going to try using Python to send data from Windows to the Pico-DE0...
- In Python we could do the basics of what raybox-app does with vectors from mouse/KB input.
- pygame is probably good for basic mouse/keyboard capture.
- pygame could also display a basic map on the host.
- PySerial can do COM port access on Windows.
- Download Python 3.11.4 installer for Windows from here.
- Run it, tick option to add to PATH, and click "Install Now".
- Install Microsoft's Python VSCode extension.
- Check out this guide
On Windows...
cd pi_pico\pico-de0\client
py -m pip install -r requirements.txt
I've started it. This proves comms works, though there's a lot more to do yet.