Search found 24 matches

by mrguen
Mon May 10, 2021 8:52 am
Forum: General discussion
Topic: SPI partly working when using hardware, library or code CS management
Replies: 11
Views: 8041

Re: SPI partly working when using hardware, library or code CS management

moustachedbird Yes I did succeed in configuring the MCP3561 and reading data on IRQ . I don' t remember exactly what was the keypoint for solving this issue. But here are the important code parts: In a header file: ... // Parameters of the Master Clock Output pin #define MCO1_GPIO_PORT GPIOA #defin...
by mrguen
Mon May 10, 2021 8:31 am
Forum: General discussion
Topic: Question about PB_10 configuration on STM32F405RG probably related to USB_OTG_HS
Replies: 4
Views: 1964

Question about PB_10 configuration on STM32F405RG probably related to USB_OTG_HS

Hello, I am using a custom board implementing the STM32F405RG. Arduino Core STM32: 1.9.0 Arduino IDE 1.8.13 I can't have the LED attached to PB_10 work with the blink sketch. Another pin like PA_14 works. I can see that PinNamesVar.h assigns PB_10 as USB_OTG_HS_ULPI_D3. #ifdef USBCON USB_OTG_FS_SOF ...
by mrguen
Wed Sep 02, 2020 12:28 pm
Forum: General discussion
Topic: SPI partly working when using hardware, library or code CS management
Replies: 11
Views: 8041

Re: SPI partly working when using hardware, library or code CS management

The command was not correct. I can have it work when managing the CS pin in the code. I did not tested more the other two methods.
by mrguen
Mon Aug 31, 2020 3:20 pm
Forum: General discussion
Topic: SPI partly working when using hardware, library or code CS management
Replies: 11
Views: 8041

Re: SPI partly working when using hardware, library or code CS management

@fpiSTM Yes this is a recent component (2019). So there is hardly any info available. I guess I have to analyze the signals. I will do some more test and let you know.
by mrguen
Mon Aug 31, 2020 10:00 am
Forum: General discussion
Topic: SPI partly working when using hardware, library or code CS management
Replies: 11
Views: 8041

Re: SPI partly working when using hardware, library or code CS management

@fpiSTM Yes I did read the WIKI and use SPI_CONTINUE in example 2, but maybe not correctly?
by mrguen
Sun Aug 30, 2020 4:12 pm
Forum: General discussion
Topic: SPI partly working when using hardware, library or code CS management
Replies: 11
Views: 8041

SPI partly working when using hardware, library or code CS management

Hello, Maybe some of you know well the SPI? I am trying to communicate between STM32F401RCT6 and an ADC module MCP3561. The expected com on SPI is attached at the end of the message. The SPI used is SPI2 with alternate pins const byte SPI_MOSI = PC3; const byte SPI_MISO = PC2; const byte SPI_SCK = P...
by mrguen
Mon Aug 17, 2020 3:36 pm
Forum: General discussion
Topic: How to use SPI2
Replies: 17
Views: 33038

Re: How to use SPI2

@fpiSTM
About __HAL_RCC_I2C1_CLK_DISABLE(); I saw that there was an incompatibility on some boards with I2C1 so I tried in case it would solve the problem.

Yes, uncommenting PB_3 and PB_5 affectation to SPI1 worked.

So the question might be: why it was commented?

Thanks
by mrguen
Mon Aug 17, 2020 1:11 pm
Forum: General discussion
Topic: How to use SPI2
Replies: 17
Views: 33038

Re: How to use SPI2

I a m sorry but I can't make SPI work with alternate pins to drive a TFT. It works with default pins (PA5,PA7) but not when using SPI.setMOSI(PB_5); SPI.setSCLK(PB_3); SPI.begin(); // even when adding this in any case __HAL_RCC_I2C1_CLK_DISABLE(); ON STM32F401RCT6 other pins are defined as #define T...
by mrguen
Wed Jul 15, 2020 11:34 am
Forum: General discussion
Topic: How to use SPI2
Replies: 17
Views: 33038

Re: How to use SPI2

Hello, Thanks for the code example.

1) I get the error
'AFIO_DEBUG_SW_ONLY' was not declared in this scope

on STM32F401RCT6 (CoreBoard) / STM32 Cores 1.9.0

2) Is it possible to use the remapped SPI2 (SCK: PB13, MOSI: PC3, MISO: PC2)?
by mrguen
Wed Mar 11, 2020 5:10 pm
Forum: Custom design boards
Topic: Other USB_CONNECT pin on STM32F4xx
Replies: 5
Views: 7435

Re: Other USB_CONNECT pin on STM32F4xx

Thanks. I will try with another pin.

Go to advanced search