We’re rewarding the question askers & reputations are being recalculated! Read more.

Questions tagged [spi]

Serial Peripheral Interface. Allows full-duplex serial communication from a master device to one or more slave devices arranged on a bus. Sometimes referred to as a 4-wire bus.

Filter by
Sorted by
Tagged with
0
votes
0answers
99 views

Unable to create a file on SD with Teensy 3.2 with FreeRTOS

I'm trying to log data to SD card using Teensy 3.2. I've taken the code from Arduino Examples SD > ReadWrite.ino and modified it slightly to run it with FreeRTOS - no changes in the header libraries ...
0
votes
1answer
77 views

Problem with SPI when using rf24 NRF24L01 transceiver with LED matrix MD_MAX72xx

I am currently using Arduino Mega to use a LED matrix and a NRF24L01 transceiver. for LED matrix, I use MD_MAX72xx library. While for the transceiver I use the RF24 library. I am already able to ...
0
votes
0answers
44 views

MOSI pin not turning low [duplicate]

I have the following code: #include <SPI.h> void initChips(){ SPI.begin(); SPI.beginTransaction(SPISettings(20000000, MSBFIRST, SPI_MODE0)); pinMode(SS, OUTPUT); ...
0
votes
2answers
177 views

Arduino SPI Multiplexer problems

I want to use the ADG731 32 ch multiplexer to read 32 potentiometers, I have wired everything and it works but it doesn't works as fast as I would want. The problem is that If I turn a potentiometer ...
0
votes
0answers
63 views

Need help with DAC to show more than one output with SPI (stuck and need help please)

I want to take 2 different outputs from my DAC from void setDacOutput function (and it should be switching with/like the timer for both outputs. One output of 2.9375V for 0.9ms from ISR if statement ...
0
votes
0answers
59 views

More than 3 SPI devices read by a single arduino

I've been working on a project that involves SSI Rotary Encoders from CUI. They are being read through the SPI interface, and I am bit-shifting appropriately to account for the differences between SSI ...
0
votes
1answer
98 views

Sending command through SPI on Arduino UNO

I am assuming the default pin configuration is pin 10(SS), 11(MOSI), 12(MISO), 13(CLK) from a default setup, SPI.begin(). The code compiles OK. Not sure about the int valuex and using the SPI.transfer(...
0
votes
1answer
43 views

NeoICSerial and SPI on the Uno - pin 10

The NeoICSerial documentation contains a table that states for the Uno: Transmit: 9 Receive: 8 PWM Unusable: 10 Pin 8 and 9 are used for the serial connection. Pin 10 is part of the pins for the SPI ...
1
vote
3answers
91 views

Is it possible to connect many (20+) SPI sensors to an Arduino Mega?

I am making a system for measuring whether or not there is vacuum present in big steel containers. They are located up to 100 meters from the control cabinet. The question is, how many SPI sensors ...
0
votes
1answer
368 views

Reading ADS1232 with Arduino

I'm a newbie and I'm trying to read an ADS1232 with an Arduino for a Weight Scale Project. I read data through the SPI interface, but i don't receive the result. #include <SPI.h> #define ...
3
votes
1answer
143 views

Cannot set MOSI pin low even after ending SPI

I'm building a battery operated device and must shutoff MOSI pin during sleep because it leaks current through the SD card if I don't (about 400 µA). Problem is, it won't stay off. I've looked at ...
0
votes
2answers
574 views

How to connect MPU9250 with NodeMCU using SPI or I2C Slave?

I want to connect 3 MPU9250 sensors, but since there is just one I2C bus, so there are another 2 sensors I want to connect through SPI. Library used - https://github.com/bolderflight/MPU9250/blob/...
0
votes
0answers
70 views

Adafruit Feather nRF52832 as a SPI slave

Like the title says, I am trying to configure the Adafruit Feather nRF52 as a SPI slave, who will receive information from a MSP430 microcontroller. I have found a few code examples that provide ...
1
vote
0answers
136 views

Is it possible to use I2C and SPI ons the same Clock line?

I'm trying to connect an I2C OLED display and an n RF24L01 WiFi module to an ATTiny85. But I only need 1 extra pin. Is it possible to use the same clock wire/pin for the I2C and SPI device? Maybe with ...
1
vote
3answers
228 views

SPI Wiring Confusion

I am currently trying to learn about SPI and how it works on the Arduino. I want to wire a MAX7219 chip to it to drive an 8x8 LED matrix with. Normally, I would assume the wiring from Arduino to ...
1
vote
0answers
208 views

Reading data from SPI on ESP32-WROOM-32

I'm newbie with Arduino and need to do a short task: read data from SPI (sent by another microcontroller) and send to WiFi (by ESP32-WROOM-32). I can't understand how to initialize and read data from ...
0
votes
0answers
188 views

WaveShare EPaper Display and Adafruit HUZZAH32 ESP32 Feather Board

I'm trying to understand how I could use WaveShare EPaper Display with Adafruit HUZZAH32 ESP32 Feather Board. With these connections SDI/SCK -> MOSI SCK/SCLK -> SCK CS -> 15 DC -> 33 RST/...
-1
votes
1answer
346 views

How to read Output data from SPI connector using Arduino Uno?

I am having main controller circuit board that give the data such as ("HAI", "HELLO") to 5 pin SPI Connector mounted on the same board. In that 5 pin SPI connector I could connect separate circuit ...
3
votes
1answer
173 views

SPI Connections to DAC [closed]

I'm hoping to construct a feedback loop for a laser using an Chipkit UC32 and an analog-digitial converter ( the one of I have is an AD5780 evaluation board). I've been reading through Digilint's SPI ...
0
votes
0answers
42 views

Arduino SPI ISR

Is there any way to trigger a ISR after a SPI transfer is complete? I am trying to send messages from one of three LORA radios and have the other two read the message. I am using the Radiohead (RF95) ...
0
votes
0answers
162 views

ESP32 MP3Decoding with VS1053/1003 not working

I want to build an webradio with my ESP32 and want to decode the mp3Stream with the Vs1053/1003. I´ve tried many libraries, but none of them worked, so I tried to understand the datasheet and I´ve ...
0
votes
3answers
186 views

Can Serial be safely used in an SPI interrupt routine

I have anecdotal experience that using Serial.print inside a slave's SPI interrupt routine (ISR) causes issues with transmission. It also seems that interrupts may be called more than once before the ...
0
votes
0answers
240 views

Arduino Mega and ADS1256 board

I found code for a Teensy board and now I added just digitalwriteFast library to code and changed port to SPI for Arduino Mega. And now I get just one number out: #include <SPI.h> #include <...
0
votes
1answer
51 views

Lines not pulsed fast enough (?))

Should this code pulse the PB3 and PB4 pins (MOSI and MISO of an Arduino Uno) at 2ms interval ? #include <avr/io.h> int main(void) { // for (byte i = 0; i < 32; i++) // pinMode(i, ...
0
votes
1answer
63 views

noisy output lines when waking up from a sleep

Using code similar to these examples from AVR https://www.microchip.com/webdoc/AVRLibcReferenceManual/group__avr__sleep.html my program causes my Adafruit Feather 32u4 to often sleep. When the ...
1
vote
2answers
570 views

Arduino NANO hardware SPI not working

I have an Arduino NANO clone and a 2.4" ILI9341 TFT display. The VCC and LCD pins of the display are connected to the 5V pin of the board. The GND to the GND. All the logic pins are connected to ...
-1
votes
1answer
488 views

Want to display an image from SD card to ILI9486 LCD display

I am completely new to Arduino. I have been given a side project to display a image from SD card to display. LCD used is ILI9486 which has a SD card slot at the back of the display module. I have ...
-1
votes
1answer
358 views

esp32 spi library, how read a mcp23s08 register

thanks for any help I need to read a gpio expander mcp23s08 set as 8 bits input. my code write correctly (I believe) the setup register using SPI library, with the enclosed example modified. But I do ...
2
votes
0answers
334 views

How to use SPI to set/ read registers for a sensor (Avoiding need for Github Lib)

Ok so as some readers might have seen, my current project involves using MPU's. The idea is sending data via CAN bus to a controlling MCU to then send to a raspberry pi to perform the calculations ...
0
votes
1answer
103 views

Using TFT with hardware SPI and speaker with tone()

I want to make a device with a TFT screen and a speaker that uses the builtin tone() function. However, according to the documentation, using tone() interferes with PWM on pins 3 and 11. On the ...
0
votes
1answer
140 views

Getting incorrect output from ADC over SPI in Arduino Uno

I am trying to read data from an ADC ADCS7476 (datasheet) using SPI on Arduino Uno. I am using the following code to read the data from the ADC and printing it on serial monitor. However, the code is ...
0
votes
1answer
345 views

Can SPI and serial.begin be used at the same time?

I have two modules where I want to control them through a single Arduino UNO. I guess Serial.begin(9600) uses serial port and UART. But Im not sure about SPI. Can I use SPI library hence the SPI ...
0
votes
1answer
412 views

Triggering an SPI transfer with an interrupt in Arduino Due

I have a DDS that is controlled by an Arduino DUE, loop() waits for Serial commands and based on them calls one or another function that sets the DDS's frequency, phase, amplitude etc via SPI. In ...
1
vote
0answers
339 views

Interfacing MAX6675 with Arduino Mega 2560

I'm trying to use a thermocouple k type and a MAX6675 IC. I bought the MAX6675 chip and made the circuit (just a 1 nf capacitor on +5 V and GND near the IC) with the help of the datasheet I used the ...
1
vote
1answer
241 views

Trouble configuring Arduino Due SPI to ADC

I am having trouble configuring Arduino Due SPI to an AD7490 ADC. Here is how I have the pins connected: +3.3V > 7490 pin 22 Vin +3.3V > 7490 Vref DUE CS (8) > 7490 pin 20 SS - slave select) DUE ...
0
votes
3answers
559 views

STM32 and NRF send & receive

This is my send and receive code in STM32 (blue board). But i can't send and receive data . why? I did use Enrf24.h . Enrf24 link: https://github.com/spirilis/Enrf24 send code is: #include <SPI.h&...
0
votes
1answer
44 views

Loops fail after ~5 minutes when making two API calls every 10 seconds using WiFi client

I am running into an issue with a loop call on an Arduino MKR1000. I have tried the solutions suggested in this question and it usually works for 5 minutes and then collapses. I am trying to make two ...
3
votes
1answer
147 views

Change operational mode of CAN transceiver

I have two MCP2515 stand-alone CAN controllers with SPI interface, two TJA1042 CAN transceivers and two Arduino Uno boards. As you may know TJA1042 have two operational modes: Sleep mode Normal mode. ...
0
votes
1answer
119 views

USART, SPI or Bit-Bang for the continuous transfer of bytes without inserted extra bits

I have heard that The SPI hardware introduces a 9th, HIGH bit between bytes USART still uses start and stop bits when in synchronous mode Are both these statements true? Can I modify the built-in ...
1
vote
1answer
245 views

16 bit SPI on Arduino Due

I'm trying to control AD7091-8 using Arduino Due. This IC calls for 16 bit SPI R/W. I'd read that I can change the transmit and receive bits of Arduino DUE by changing a register (bits 4-7 of SPI_CSR)...
2
votes
1answer
1k views

SPI.transfer(buffer, size) does not send data from buffer

I am having trouble getting SPI.transfer(buffer, size) to work as expected. Here is the code: // inslude the SPI library: #include <SPI.h> // set pin 10 as the slave select for the digital ...
0
votes
2answers
978 views

send more than one byte at a time SPI Arduino

I have recently been trying to send integers via SPI between two arduino Uno's. I am using the first example of Nick Gammons tutorial, and trying to modify it to get a basic understanding of how to ...
1
vote
1answer
101 views

Looking for a waterproof SPI temperature sensor

In my current project I'm using a DS18B20, which seems to be the only temperature sensor to show up when googling for waterproof temperature sensor for an arduino. The sensor itself is fine, however, ...
0
votes
2answers
2k views

SPI Digital Potentiometer not working on ESP32

I have an MCP4151 digital potentiometer chip. I have managed to get it to work using and Arduino Uno using the code below: #include <SPI.h> byte address = 0x00; int CS= 5; void setup() { ...
-3
votes
2answers
170 views

What's wrong with my code

I use a mega as a master and a nano as a slave. Both should convey texts. However, I get the master always only the answer that I send. The text from the slave does not arrive. Master: #include <...
0
votes
1answer
2k views

Interfacing with an SSI sensor?

I'm trying to interface with version RM08S of this rotary encoder using an Arduino Mega. The sensor supports a "Synchro serial interface (SSI), single ended" interface. I'm unfamiliar with this ...
3
votes
2answers
93 views

Stacking 3 of the same shields on top of each other and instructing them in sync

Context: I have an audio track separated into individual channels grouped by frequency and speaker location. I need to play all three of these channels simultaneously and perform instructions like ...
0
votes
1answer
79 views

Difference in pinout (types?) Uno/Mega

As a hands-on guy, I've started my first ever Arduino project 5 hours ago with no prior knowledge about Arduinos (I have coding experience tho. included this in case I am missing something obvious to ...
-1
votes
1answer
1k views

How to change the default Slave Select pin (Digital pin 10) on Arduino UNO R3 for SPI communication?

Currently I am working on an Arduino based project. My project require interfacing 6 servo motors and an SD card module to my Arduino UNO. The problem is that I need all the six PWM pins for six ...
1
vote
1answer
41 views

How do I include a file that is not a .h, .c or .cpp file?

I am using the ADF7030 on the breakout board (not motherboard) and I am trying to interface it with an Arduino Uno. I want to load the transceivers configuration file onto the chip using SPI. To do ...