USB slice kit audio examples

Technical discussions related to any XMOS development kit or reference design. Eg XK-1A, sliceKIT, etc.
rklingler
Junior Member
Posts: 7
Joined: Tue Jul 29, 2014 6:42 pm

USB slice kit audio examples

Post by rklingler »

I just received today my USB slice kit together with an audio and and ethernet to test.

From the USB kit hardware manual it is fairly unclear which slice can be plugged in where...
Guess the ethernet slice can only be plugged in onto the square slot (whoever came up with this idea ;o)

For the audio slice I am not sure if it is compatible at all...I would rather see a compatibility matrix then go through each manual and write down those fancy diamond/square/triangle symbols...


Now comes my next problem....the pin mapping of the hardware manual of the USB kit and the port defines in the audio examples...

In app_global.h there is:

#define PORT_I2S_DAC0 XS1_PORT_1D
#define PORT_I2S_DAC1 XS1_PORT_1H


But in the USB slicekit manual I nowhere find any similar pin description...

So the diamond port gives me:

X1D49 P32A0
X1D50 P32A1

So what exactly do I have to define in the audio example to successfully pipe the audio I2S signals onto the diamond port for the audio slice?


User avatar
Folknology
XCore Legend
Posts: 1274
Joined: Thu Dec 10, 2009 10:20 pm
Contact:

Post by Folknology »

You have them in the right slots (ethernet square,audio Diamond), Looking at the audio slice pinouts and how they match up to Diamond or ALT Diamond:

Code: Select all

Func - PIN - Port or ALTport
-----------------------------------------
BCLK - B2 -> P1A0 or P1A0
DAC_DATA0 - B4 -> P1D0 or P1D0
MCLK - A3 -> P1E0 or P1E0
LRCLK - A4 -> P1H0 or P1H0
SPDIF_OUT - B10 -> P1K0 or P1K0
ADC_DATA0 - B15 -> P1I0 or P1I0
ADC_DATA01 - A15 -> P1L0 or P1L0
MIDI_IN - A8 -> P1J0 or P1J0
MCLK_FSEL - B7 -> P32A1 or P32A1
CODEC_RST_N - A6 -> P32A6 or P32A7
LED - A7 -> P32A7 or P32A8
SCL - B9 -> P32A2 or P4E0
SDA - B11 -> P32A3 or P4E1
DAC_DATA1 - B12 -> P32A8 or P1M0
PLL_SYNC - B18 -> P32A11 or P1P0
Looks like Alt Diamond is the way to go as it provides more ports which is what the Audio slice needs, so map those in the header. Or if there is a newer version which includes ALT Diamond definitions for the audio slice use that.

P.S. you may need to change the P32 port masks like this StartKit version has xa_sk_audio_1v0.h, your masks will prob differ

regards
Al
rklingler
Junior Member
Posts: 7
Joined: Tue Jul 29, 2014 6:42 pm

Post by rklingler »

Hmm...so I am not that stupid after all (o;

How would this map onto the defines?
What would I need to put at the end to:

#define PORT_I2S_DAC0

This is where I'm mostly struggling at the moment...
User avatar
Folknology
XCore Legend
Posts: 1274
Joined: Thu Dec 10, 2009 10:20 pm
Contact:

Post by Folknology »

The StartKit app_global.h shows how to redefine the ports for an audio slice application (Remember the Slice socket on the StartKit is different again from the SliceKits), you need to do a similar port replacement matching them to the Alt Diamond ports on the USB SliceKit I listed above.

regards
Al
rklingler
Junior Member
Posts: 7
Joined: Tue Jul 29, 2014 6:42 pm

Post by rklingler »

Hmm...think I'm getting there (o;

So the pin mapping is not defined by the development kit, but by the slice board and where it can be plugged in by means of the symbols...
User avatar
Folknology
XCore Legend
Posts: 1274
Joined: Thu Dec 10, 2009 10:20 pm
Contact:

Post by Folknology »

Start with this, quickly knocked up (not tested!):

Code: Select all

#define PORT_I2S_DAC0		XS1_PORT_1D
#define PORT_I2S_DAC1  		XS1_PORT_1M
#define PORT_I2S_ADC0  		XS1_PORT_1I
#define PORT_I2S_ADC1		XS1_PORT_1L
#define PORT_I2S_LRCLK		XS1_PORT_1H
#define PORT_I2S_BCLK		XS1_PORT_1A
#define PORT_MCLK_IN		XS1_PORT_1E

#define PORT_GPIO			XS1_PORT_32A
#define PORT_I2C			XS1_PORT_4E
BTW I am basing this on info at some of those links (which appear to have some typos) so take them with a pinch of salt and double check!

regards
Al
User avatar
Folknology
XCore Legend
Posts: 1274
Joined: Thu Dec 10, 2009 10:20 pm
Contact:

Post by Folknology »

rklingler wrote:Hmm...think I'm getting there (o;

So the pin mapping is not defined by the development kit, but by the slice board and where it can be plugged in by means of the symbols...
I can't speak on behalf of Xmos regarding documentation of their Slice system, I will leave that for them, it started with four slice types but has since evolved with other kits introducing variations, it is rather confusing now, but originally I think you could just match the symbols....

regards
Al
rklingler
Junior Member
Posts: 7
Joined: Tue Jul 29, 2014 6:42 pm

Post by rklingler »

Those defines are something I would have figured as well...

Great support from you btw :-))

If only the forum site would work as expected...this is my third username I had to use (o;


Gonna try tomorrow morning some redefining and attach my LeCroy 9354AL and 9414...and if that doesn't help some logic analyzers...


Since you've seems to be the xCORE expert here....which device would you recommend for designing a small "stamp" like development board which could feature USB and ethernet?
User avatar
Folknology
XCore Legend
Posts: 1274
Joined: Thu Dec 10, 2009 10:20 pm
Contact:

Post by Folknology »

rklingler wrote:Since you've seems to be the xCORE expert here....which device would you recommend for designing a small "stamp" like development board which could feature USB and ethernet?
Not sure about expert but I certainly have some experience along with many others on XCore..

I would go for a dual tile Usb series XS1-U8A-128 (8 core) through to XS1-U16A-128 (16 core) they are pin compatible with each other just offering more threads. These provide built in USB phy and offer 128K this allows you to run TCP/IP or AVB with Ethernet on one tile and USB on the other tile, any spare cores across both can then be used for user apps (the more cores the better). It would be nice although difficult to cram both interfaces into a single tile with TCP/IP running in the other (user space) perhaps, but you may be pushed to find IO pins for the Ethernet on the USB tile (maybe just enough you need 4*1bit,2*4bit and a couple of other ports). That would leave maximum IO and user space cores on a single tile (64K) which would keep things simpler.

regards
Al
rklingler
Junior Member
Posts: 7
Joined: Tue Jul 29, 2014 6:42 pm

Post by rklingler »

I see that there are already a few 3rd party development boards available...but haven't seen them on Farnell though....just XMOS boards...

Would XMOS be interested in a new development board with USB/ethernet capabilities and two rows pin headers for plugging in into own applications or breadboard design?


Just asking as Farnell asked me to take over their private business exclusively for Switzerland (o;
And seems their product management is keen getting new devices (o;
Post Reply