![]() ![]() SPDR = myData //places 0x12, then 0x34īut I want to achieve something more basic, something he already did, to be able to send and receive info from the Slave, but I only want him to do that when SS enables it (how SPI generally works). SPI.attachInterrupt() //interrupt logic is enabled PinMode(SS, INPUT_PULLUP) // ensure SS stays high for now ![]() SPI.setClockDivider(SPI_CLOCK_DIV16) // SPI.setClockDivider(SPI_CLOCK_DIV16) //1 MBits/sĭigitalWrite(SS, LOW) //Slave is selected This is the screen shot (Fig-2) of the Serial Monitor of ESP8266-SPIMaster. Seriously, I would really appreciate it if you could help me, thanks!Ģ. ![]() Serial.println("Successful initialization") Īt no time is it seen that the code sets the SS pin high or something (I think that is done in the SD library), nor in the Esp8266 code, and I would need that to control two Slaves. It works well and there are no problems with it, but my problem comes when I want the Arduino (Slave) to send info to Esp8266, I DON'T KNOW HOW TO DO IT, I don't know why I can't find example codes about this (sorry if there are any, but I CAN'T FIND THEM), I tried to do it by myself with what little I knew, but it didn't work. There is almost no information about SPI on the internet, much less related to Esp8266, but I found these two codes that allow me to send info from Esp8266 (Master) to Arduino (Slave). I have an Arduino Uno and an Esp8266, both are connected via SPI, Esp8266 is the Master and the Arduino is the Slave. Hello again, I have a question, or maybe 2 questions, but first I will tell you what I have. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |