Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Peripheral API #1

Open
hackrid opened this issue Apr 21, 2016 · 3 comments
Open

Peripheral API #1

hackrid opened this issue Apr 21, 2016 · 3 comments

Comments

@hackrid
Copy link

hackrid commented Apr 21, 2016

Hi,

what kind of peripheral API do you propose for your eco system?
what do you think about CMSIS-Driver? is this suitable ?

it provides the interface for some of the most popular peripherals:
https://github.com/ARM-software/CMSIS/tree/master/CMSIS/Driver/DriverTemplates

I have only found few implementations of this CMSIS-Drivers.
NXP:
https://github.com/ARM-software/NXP_LPC/tree/master/LPC4300/CMSIS/Driver
"Freescale Kinetis K60 Series Device Support and Examples" from https://www.keil.com/dd2/pack/

STM32:
"STMicroelectronics STM32F4 Series Device Support, Drivers and Examples" from https://www.keil.com/dd2/pack/

@oliviermartin
Copy link
Contributor

Hi @hackrid ,
my intention was actually to use CMSIS-Driver for the peripheral API instead of creating a new API.

At the moment, only the UART CMSIS driver has been implemented for most devices (eg: https://github.com/labapart/polymcu/blob/master/Device/NXP/Driver/uart_debug/Driver_USART.c).

I am doing some work with SPI for a polymcu based project. I have implemented the SPI CMSIS driver for NXP using NXP SDK (ARM tends to write again the CMSIS drivers from scratch).
I intend to push this support upstream.

As usual, any contribution are welcome :-)

@hackrid
Copy link
Author

hackrid commented Apr 25, 2016

Hi @oliviermartin,

thanks for your reply.

On page 31 in this document ARM states, that they will provide the CMSIS-Drivers for

  • NXP: Kinetis K64F, LPC1700, LPC1800, LPC4300
  • Silicon Labs EFM32 Giant Gecko
  • ST Microelectronics STM32F1, STM32F2, STM32F4, STM32F7

Other implementations are vendor driven (Infineon, Atmel)

For the NXP parts, except K64F, you can find the CMSIS-Driver implementation here:
https://github.com/ARM-software/NXP_LPC

It's very nice to see ARM moving their development towards github.
It is still a bit cluttered to look for software at many different places (different github repos, chip vendors, ARM website, keil.com/dd2/pack, sure more to find....)

best regards

@oliviermartin
Copy link
Contributor

It is still a bit cluttered to look for software at many different places (different github repos, chip vendors, ARM website, keil.com/dd2/pack, sure more to find....)

It is actually what I am trying to solve with PolyMCU:

  • taking advantage of Vendor SDKs
  • consolidate the Vendor specific SDK under a common framework (using CMSIS APIs)
  • enabling various libraries/RTOS/tools around this project

The idea is to combine the best of each project into a single location.

ARM implementation of CMSIS-Drivers is bypassing the Vendor SDK. So there is a duplication of work between Vendor SDK and ARM CMSIS Driver implementation.

If your own MCU project is taking advantage of ARM implementation of CMSIS-Driver and a Vendor SDK then there is a real risk of driver duplication (that implies bigger firmware binary) and conflicts (that implies some debugging time).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants