EmbDev.net

Forum: µC & Digital Electronics 16 Bit plain serial data via SPI or logic&register


von Frank (Guest)


Rate this post
useful
not useful
Hi

I am working with a BB3210 and he requires 16Bit seriel data input 
"plain" just the data no start stop or parity bit.


My issue now is how to handle this in a clever way with a uC (proposed 
one is a PIC18) I came up with 3 basic solutions

1)use a uC output to generate the Serial code and send the data via bit 
shift bit for bit use 2 other uC out for the CS and CLK
unfortunately I like to use this for 16 channels so I need 8x 2310

2)write via 8 bit databus from the uC a shift register then clock the 
lsb bit to the 2310  and bit shift the complete data.

3)use the available SPI or UART where as far as I can know always one 
start stop or parity bit is generated
I am not so deep inside the PIC serial communication maybe there is also 
any other clever idea to use a shift register with some logic

Any beter solutions are welcome

von Jörg W. (dl8dtl) (Moderator)


Rate this post
useful
not useful
Frank wrote:

> I am working with a BB3210

Any reference?

> 3)use the available SPI or UART where as far as I can know always one
> start stop or parity bit is generated

SPI does not have start or stop pulses but uses a separate bit clock
provided by the master.  However, with 8-bit SPI hardware modules
(as typically found in microcontrollers), you cannot chain two 8-bit
transfers together without at least some minimal additional delay (to
setup the new SPI data register value) between both 8-bit (partial)
transfers.

von Frank (Guest)


Rate this post
useful
not useful
Sorry
to be more presice it is a BurrBrown now TI  PGA 2310 Stereo Audio 
Volume Control . This a high quality audio component that act very 
simular to a VCA´. I will use this (actual 8 of them) to build a high 
end pre amplifier

Data sheet here:
http://focus.ti.com/docs/prod/folders/print/pga2310.html

Issue is that both channels are controlled by a seriell dataword just 
the dataword no startstop bit or parity (like on page 8)


The main problem is now how to generate a plain 16 bit serial data word 
with the uC (8 bit serial data without any "disturbing" start stop or 
parity)

von Jörg W. (dl8dtl) (Moderator)


Rate this post
useful
not useful
This is a standard SPI protocol.  All you have to do is to initiate
two 8-bit transactions.

von Robert L. (manateemoo)


Attached files:

Rate this post
useful
not useful
If you uC's SPI interface is not able to send 16bit at ones, you can 
send the first eight bits then the next eight bits by holding CS active.
(see attached picture)

von Frank (Guest)


Rate this post
useful
not useful
Many thanks to all,

Also for me SPI seems to be the best solution I thought SPI has always a 
start and Stop bit as a definition, so I had to have a more detailed 
look at the uC specification ,- bye the way this will be a PIC18F8520 
deu to a useage for a touch screen and already available resources.

von Jörg W. (dl8dtl) (Moderator)


Rate this post
useful
not useful
Frank wrote:

> Also for me SPI seems to be the best solution I thought SPI has always a
> start and Stop bit as a definition

Nope, it doesn't.  SPI just has data bits, nothing else.

You're confusing the setup time for the slave select signal, but
there's no clock edge involved.

Please log in before posting. Registration is free and takes only a minute.
Existing account
Do you have a Google/GoogleMail account? No registration required!
Log in with Google account
No account? Register here.