Hi,
I purchased two breakout boards in attempt to increase a number of UARTs on my Arduino UNO.
Trouble is that I can not write to any register in SC16IS750.
Communication with SC16IS750 is through SPI.
SPI is set to ‘MSb first’, SPI_CLOCK_DIV128.
I am using logic analyzer to verify SPI waveforms. All waveforms are correct, measured at modules’ pins.
Here is what I read, no matter what I write to any register:
IER: 0 0
IIR: C1 11000001
LCR: 0 0
MCR: 0 0
LSR: E3 11100011
MSR: 0 0
SPR: 0 0
TCR: 0 0
TLR: 0 0
TXLVL: 0 0
RXLVL: 0 0
IODIR: 0 0
IOSTATE: FF 11111111
IOINTENA: 0 0
IOCONTROL: 0 0
EFCR: 0 0
DLL: 40 1000000
DLH: 0 0
EFR: C1 11000001
XON1: 0 0
XON2: 0 0
XOFF1: 0 0
XOFF2: 0 0
First number is HEX.
Did anyone encounter similar problem.
Thanks for reading
Hi
I see no response, so I belive my post was not clear enough.
So I will add more details.
I thought that working with SC16IS750 is a strightforward operaration.
I used libraries from various sources (WiFly, UART Bridge-master, Wim Huiskamp etc.
But:
- when I write to modules’ SPR, I get various results.
Sending 0x01, reading 0x00
Sending 0xFF reading 0xFF
Sending 0xFA reading0xF9
etc.
When I write to LCR
sending 0x03 to set uart, reading 0x02
- Similar thing happens with other registers
So I developed a program to R/W to the module using UNOs’ serial port.
It is attached.
It allowes an access to any register (by the book).
I used it to initiate this module in a various ways.
Yet, at no avail.
Details of hooking are in attachment.
As I wrote before, I used logic analyzer and oscilloscope to verify
signal vaweforms. They appear perfect (by the book).
So if someone has similar experiance, it will help because
I am stuck right now and have no idea what to do.
What am I doing wrong?
Any help is appreciated.
Examples:
Cmd received SPR W 0xFF
0xFF ('11111111) → 0x7
Cmd received SPR R 0XFF
SPR → 0xFF ('11111111)
Cmd received SPR W 0xFE
0xFE ('11111110) → 0x7
Cmd received SPR R 0XFF
SPR → 0xFE ('11111110)
Cmd received SPR W 0xFD
0xFD ('11111101) → 0x7
Cmd received SPR R 0XFF
SPR → 0xFD ('11111101)
Cmd received SPR W 0xFA
0xFA ('11111010) → 0x7
Cmd received SPR R 0XFF
SPR → 0xF9 ('11111001)