If I don't want to have any extra hardware connected to my X1000, how can I make use of Xena?
Assume I create a simple Xena/XC program (using XTools on Mac/PC) that, for instance, flips all bits of some data. Would it be possible for me to, from AmigaOS, send the bits "000111" and then get "111000" back?
Yes, but it's not quite getting the best of the Xena chip.

First, "XTools" are the AmigaOS tools, "xTIMEcomposer" is the name of their developers kit.
For output from Xena, there are two LEDs on the Nemo board, and another one or two on the Xorro card. But I've heard it too many times, nobody wants to flash LEDs. *
There is also the localbus connection. This is used to write or read 16 bit Words to and from Xena. Each write or read has a large bank of addresses to choose from, which the Xena chip may use to interpret different meanings.. much like ports in networking.
In real hardware it's all going in and out from the same places on Xena side, but the address used may indicate to Xena the purpose of the communication. There is not an established standard protocol for this yet, just the hardware support.
The localbus interface has been improved in the Cyrus board, and as soon as I get a chance I'll work out localbus routines that take full advantage of the improvements in a backwards compatible manner.
Other than that, there is a single bit from Xena to a GPIO of the PA6T, this is intended as an interrupt, and I discourage using it for anbything else. THere is also one "extra" bit going back to the PLD, but I have no idea how to access that, or what effect it might have on the system
In my own opinion, Xenas greatest strength is the ability to stream data very quickly. The localbus interface is not the place for that to happen. I see the localbus mostly as a port for control and feedback from the various processes.
But there is public code for various encryption standards at the XMOS GIT hub. instead of flipping bits you could do sometrhing a bit more useful there.
Oh, and while I'm at it: how do I transfer programs to Xena, and how do I start it? I kind of get that it might be a stupid question , but I really don't know where to start; it should be possible from AmigaOS, right?
There are a set of XTools for that.
Usually located in Sys:Utilities/Xena/XTools, these command line tools can be used to push code to the Xena chip (xrunxe), or to reset the chip (xreset) or quite a few different views of internal registers. One thing I watch is the program counter of any individual thread.. when this stops moving you can bet that the thread is holding for incoming our outgoing data.. as all channels are blocking by nature.
These tools have been updated a few times, and will be a few more in the near future. Only the very first version released were "wrong".. they did not set the PLL correctly, and as a result the Xena chip ran considerably slower than expected.
The example code you saw does include both the Xena and the AmigaOS sides of the localbus code.. I'm sure you could figure it out after a quick reading.
You should expect the localbus code to be extended to take advantage of the Cyrus improvements at some future time.
*note
Even though flashing LEDs is boring, with the exceptional speed of Xena I/O, it would be a simple modification to dim LEDs instead.. Simple to do and requires no hardware. Could use localbus to deliver change requests..
Yes, still simple, but it starts with what we have available now, and expands on it gently, which is not a bad way to learn a new language.
And later, with a few constant-current drivers, you could begin to animate your case..
** for the case modders, there is a VERY simple mod available right now that could be fun to play with.. this is NOT Xena related, but (assuming the standard case) you can move the power LED from it's usual header to P31..
With that done, it will light up automatically every power up.. but it is then under command of any program or script you want.. So if you can detect inbox activity, you could make your power LED flash.. or whatever..
It's a very simple hardware link that can be reached easily from any program, but using the executables in Nemo_LED_P31.lha, from OS4Depot.
