How to carve out 3 1-bit ports from a 4-bit port?

Technical questions regarding the XTC tools and programming with XMOS.
User avatar
segher
XCore Expert
Posts: 844
Joined: Sun Jul 11, 2010 1:31 am
Contact:

Post by segher »

Folknology wrote:Yes but you can switch between Input and output, albeit all bits at once
That's right; but you should make sure it is okay with the device connected to the other
if you drive a pin that it can drive as well; and the other way around, make sure it is
okay to float a pin that the other side uses for input.
making some protocols possible, like perhaps slave I2C?
For IIC, you need to do both input and output anyway: output when you are sending
a 0, and input when you are sending a 1 (or receiving).


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

Post by Folknology »

For IIC, you need to do both input and output anyway
Sure.
output when you are sending
a 0, and input when you are sending a 1 (or receiving).
Love that ruthless reduction of open collector operation of IIC.

regards
Al
Last edited by Folknology on Mon Feb 28, 2011 1:59 pm, edited 1 time in total.
User avatar
landon
Experienced Member
Posts: 71
Joined: Mon Sep 06, 2010 4:05 pm
Contact:

Post by landon »

Thanks for the discussion, everyone.

This lack of 1-bit ports is forcing me off the XK-1 sooner than I expected.

Al, I agree with your assessment on the architecture improvements. It would be splendid to treat any pin as a one-bit port even if there was a fixed number of them less than the total port/pin count.

My only other huge wish on XMOS improvements is more RAM. One of my 1-bit needs because of lack of RAM is to talk to a 4-wire F-RAM and an SD for archival.

Despite various limitations, still loving learning about and using XMOS,

Landon
User avatar
landon
Experienced Member
Posts: 71
Joined: Mon Sep 06, 2010 4:05 pm
Contact:

Post by landon »

BTW - I think my strategy, were I to stay on XK-1 would be:

reserve all the 1-bit ports that are broken out for things like clock, MISO, and MOSI. Then put all the chip select lines bit one of each of the 4 bit ports...that would cover 2-3 SPI devices depending upon whether it's a MISO and MOSI requirement.

This way I could use all the nice XMOS clocked ports, and clocked i/o on one-bit ports and leave the simpler select parts for gpio on 4-bit ports. This approach will stretch the 1-bit ports further before having to move off XK-1.

Landon
User avatar
bsmithyman
Experienced Member
Posts: 126
Joined: Fri Feb 12, 2010 10:31 pm
Contact:

Post by bsmithyman »

I think a lot of problems would be solved if the SPI lines used for the flash were broken out somewhere on the XK-1. They're already set up for SPI anyway, so it just requires one additional pin per device for the CS signal.
landon wrote:My only other huge wish on XMOS improvements is more RAM. One of my 1-bit needs because of lack of RAM is to talk to a 4-wire F-RAM and an SD for archival.
By any chance are you using one of the Ramtron F-RAM chips in SO-8 package? They're pretty speedy, and non-volatile as well; not much pricier than an SPI RAM anyway, and they run up to 40 MHz. I actually wondered if they could be used in place of the SPI flash, but I think the lack of a Page Program instruction would make it difficult.
User avatar
landon
Experienced Member
Posts: 71
Joined: Mon Sep 06, 2010 4:05 pm
Contact:

Post by landon »

Yes re: Ramtron F-RAM - SOIC-8:

Mouser Part #: 877-FM25V10-G
Manufacturer Part #: FM25V10-G

I see Mouser is out of them and they're quoting a 14-week lead-time. I bought 4 of them at the time, so hopefully, that'll get me through prototyping. Where are some other good places to source the Ramtron devices?

I am actually fine with the XK-1 not breaking out its SPI Flash lines....I would prefer to keep my peripheral SPI bus(es) separate from my firmware.

I also thought I'd experiment with a serial SRAM but the SRAM sizes are not that large...I have a 256Kb On Semi SRAM (Mouser #: 863-N25S830HAS22I Mfr. #: N25S830HAS22I). I would love to find a larger than 256Kb serial SRAM device. If you know of one, definitely point it out to me.

Mouser is terrible about distinguishing between a KB and a Kb. Boggles me. The On Semi SRAM for example is titled 256KB but is a 256Kb device.

Landon
User avatar
bsmithyman
Experienced Member
Posts: 126
Joined: Fri Feb 12, 2010 10:31 pm
Contact:

Post by bsmithyman »

I sampled a couple of the 2 Mbit chips from Ramtron (FM25H20), but they're pretty pricey (i.e. $20/ea). Not that it's necessarily unreasonable, it's just what FRAM costs. Also, they draw more than 3 times the current of the FM25V* chips, if that's a factor. I usually buy from Digikey, and I find they're pretty good about the bit/byte sizes, but they don't seem to have Ramtron parts at all. The nice thing about the FRAM is that they're fast and they've got a preposterously long lifetime for non-volatile chips (like 10 years at 100% I/O load). For some reason I feel like I saw a product bulletin that they're working on 4 Mbit and 8 Mbit chips, but that they aren't in full production yet.
Looks like Future Electronics also stocks Ramtron parts, but they're mostly at zero quantity at the moment.
Edit: Maybe http://www.alliedelec.com/?
Post Reply