SPI1 hardware NSS output ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2015-10-04 3:58 AM
Guys,
How can I control SPI1 hardware NSS output (PA4) ? I tried to give a signal to it, but nothing on my logic analyzer...#define Mp3SelectControl() { HAL_GPIO_WritePin(GPIOA, GPIO_PIN_4 , 0 ); }
#define Mp3DeselectControl() { HAL_GPIO_WritePin(GPIOA, GPIO_PIN_4 , 1 ); }
.
.
.
Mp3SelectControl();
HAL_Delay(10);
Mp3DeselectControl();
HAL_Delay(10);
Any clues ? thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2015-10-04 6:46 AM
The most obvious places to look would be how the pin is configured, and if there's anything externally that's impacting it.
Up vote any posts that you find helpful, it shows what's working..
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2015-10-04 7:35 AM
It worked after I was not using NSS as hardware, but use it as a GPIO....
Is it possible as CS pin with this configuration? thanks Logic analyzer capture :http://i129.photobucket.com/albums/p231/picture_77/logic%20analyzer%20VS1053%204_zps82ptkcm1.jpg
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2015-10-04 8:02 AM
Not sure I understand what the question is.
The HW NSS is problematic because it never quite does what the attached device wants.With GPIO you should be able to explicitly control it, just not very tightly to the SPI peripheral.Up vote any posts that you find helpful, it shows what's working..
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2015-10-05 7:35 AM
So better use PA4 as GPIO output for CS, don't you think ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2015-10-05 8:03 AM
I think it's the easiest route to get the waveform you want, doesn't have to be that specific GPIO
Up vote any posts that you find helpful, it shows what's working..
