Would a Xmos controller be able to drive a device on the XY2 Topic is solved

If you have a simple question and just want an answer.
abeaupre
Newbie
Posts: 1
Joined: Mon May 26, 2014 3:17 am

Would a Xmos controller be able to drive a device on the XY2

Post by abeaupre »

I'm a beginner in regards to micro-controllers and I need advice on a project. I saw that some Xmos product can process up to 1000 MIPS and want to know if this is enough to realize my application on a Xmos programmed in high level C/C++.I need to drive a scan-head using XY2-100 protocol. To do so, the controller must be able to send 20 bits words on two different channels on a 2 MHz clock. The data would need no processing.I would also need to simultaneously drive a PWM output at a adjustable frequency.XY2-100 protocol datasheet :http://www.newson.be/files/TD_XY2-100_R0703.pdf


View Solution
User avatar
sethu_jangala
XCore Expert
Posts: 589
Joined: Wed Feb 29, 2012 10:03 am

Post by sethu_jangala »

This should be possible with XMOS devices. Have a look at the architecture and product brief documents to get you started with XMOS multicore microcontrollers.

Architecture Overview

Product Brief

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

Post by mon2 »

Hi. Not familiar with xy2-100 interface but reviewing your reference document, the interface appears to be a differential signal. For this reason, you will not be able to interface the xy2-100 signals (+ / -) directly with the XMOS device. Instead, you will require RS422 transceivers. Most RS422 transceivers can permit voltage swings from -12 to +12 volts on the RS422 pins as a norm. Exar has recently announced some RS422 devices that permit -18 to +18 volts.

For example, the following should be appropriate for your project:

XMOS_CLK (to be coded to generate 2 Mhz from 100 Mhz internal clock) @ CMOS levels (3.3 volts) -> RS422 driver -> CLK+ / CLK- -> to your external XY2-100 device (or you could consider to use an external 2 Mhz oscillator which will then feed the XMOS for clocking + use yet another RS422 driver to transmit the same clock to your external XY2-100 device). XMOS docs discuss how to use an external clock source as the CPU clock.

XMOS_SYNC @ CMOS levels (3.3 volts) -> RS422 driver -> SYNC+ / SYNC- -> to your external XY2-100 device

XMOS_CHANNEL_X @ CMOS levels (3.3 volts) -> RS422 driver -> CHANNELX+ / CHANNELX- -> to your external XY2-100 device

XMOS_CHANNEL_Y @ CMOS levels (3.3 volts) -> RS422 driver -> CHANNELY+ / CHANNELY- -> to your external XY2-100 device

XY2-100_STATUS (RS422) -> RS422 receiver to convert to STATUS_CMOS_LEVEL (3.3 volts) -> XMOS_STATUS

Ground

===============

Comments: RS422 is point to point so a typical setup will use a single RS422 master to slave configuration. This is because the RS422 drivers are always active and driving the bus where in RS485, the driver can be disabled on demand to allow other driver(s) to transmit on the same interface lines. If you are relatively local to the connected device then a non-isolated interface should be fine. If there is any doubt on the length of the cable where you may have a different ground potential between the local XMOS and the connected product, consider to design an isolated RS422 interface. A very modular approach is to review the Linear LT2881 or similar. This module is able to generate an onboard isolated power supply so that the grounds may be different between the mated pieces of equipment + offers an isolated RS422 transmitter and receiver. We have used these parts on numerous projects with success. To experiment, they do offer small PCBs with pre-mounted LT288x devices for immediate interfacing.

The controller portion of your project appears to be relatively straight forward for the XMOS device. We are performing similar bit bashing at about 6 Mhz (slowed down the traffic intentionally due to our fairly long and unshielded target device cables = noisy at high speeds !!) Likewise XMOS should be fine to handle the PWM extension - have a look at the PWM LED IP example in the XMOS tool chain and also the following from github.

https://github.com/xcore/sc_pwm

and

https://www.xmos.com/published/tutorial ... t?secure=1

 

Hope this helps.

Kumar