GPIO question on XU208

New to XMOS and XCore? Get started here.
User avatar
Wavelength
Experienced Member
Posts: 76
Joined: Mon Sep 24, 2018 9:56 pm

GPIO question on XU208

Post by Wavelength »

All,
So I am using X0D16-19 as XS1_PORT_4D on my audio board to control the master clock selection, dac reset and active stuff as general io.

I am of course using 1M, 1N, 1O, 1P as single bit for I2S stuff.

I was wondering if it is possible to use X0D40-43 as output as well to control other stuff?

If so do I declare that like this?
out port p_gpo2 = on tile[0] : XS1_PORT_8D;
...and just use bits 4-7? or does this screw with the single bit entries I am using for the I2S stuff?

Thanks,
Gordon


Wavelength Audio, ltd.
User avatar
mon2
XCore Legend
Posts: 1913
Joined: Thu Jun 10, 2010 11:43 am

Post by mon2 »

I was wondering if it is possible to use X0D40-43 as output as well to control other stuff?

Yes.

[quote]If so do I declare that like this?
out port p_gpo2 = on tile[0] : XS1_PORT_8D;
...and just use bits 4-7?[/quote]

Yes.

[quote]or does this screw with the single bit entries I am using for the I2S stuff?[/quote]

No. Due to the single bit ports being also used in your code, like a "wax strip" - those port pins have been ripped away from the larger 8B port.

So now continue to make use of the remains of the 8B port, specifically do as you wish to 8D4..8D7. You will be shooting blanks if you attempt to use 8D0..8D3 due to the above reason that the lower density ports (ie. LEFT side of the port width table have higher priority in the mappings).
User avatar
Wavelength
Experienced Member
Posts: 76
Joined: Mon Sep 24, 2018 9:56 pm

Post by Wavelength »

Thanks!
Gordon
Wavelength Audio, ltd.