-->
Page 1 of 1

HSPI SLAVE MODE AND COHESIXTENCE WITH OTHER SPI SLAVE

PostPosted: Wed Sep 19, 2018 7:54 am
by princemoga
Hi everyone,

I'm working with an ESP8266 in HSPI slave mode connected with an Atmel Atmega 328p in master mode. Communication works fine until I try to share the SPI interface with another device as a slave. Obviously, I have two different chip select (one for esp and one for the other device). Every time I send a message to the other device (with esp's CS set HIGH) the next communications with esp fail. ;)
Has anyone ever faced a similar issue? Is it possible to use esp as a slave with other devices connected?
I'm using the Arduino Core 2.4.0 on the esp with SPISlave library and the classical Arduino SPI library on 328p.

Thanks

Re: HSPI SLAVE MODE AND COHESIXTENCE WITH OTHER SPI SLAVE

PostPosted: Tue Dec 04, 2018 9:13 pm
by kpwashere
Sounds like some registers need adjustment. u must have command bits, address bits, and optionally databits along with interrups and overall 'transaction' defined. if you are just using library, they dont have it right. I looked to docs for ESP32 ... much better written!! and almost same for esp8266. Cant use actual register numbers in that doc but u can googoogle the macro names and find better written and more complete header files with register values etc.