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 library (plib.h) not included in pic32mx #3

Open
GaussSeidel opened this issue Aug 29, 2016 · 3 comments
Open

Peripheral library (plib.h) not included in pic32mx #3

GaussSeidel opened this issue Aug 29, 2016 · 3 comments
Labels

Comments

@GaussSeidel
Copy link

GaussSeidel commented Aug 29, 2016

Hi,

The peripheral library which is no longer supported by chipkit-core (Arduino add-on) and MPLab X is missing in platformIO.

The plib files (plib.h and the file peripherals) can be found in the last version (abandoned) of MPIDE available here :

http://chipkit.net/wiki/index.php?title=MPIDE

following the path : \mpide-0150\hardware\pic32\compiler\pic32-tools\pic32mx\include

You need to add plib.h and the file peripherals in the pic32mx file of platformIO (which is located here : .platformio\packages\toolchain-microchippic32\pic32mx\include) to make it work.

Using this library you can deal with the pic32 funtions such as :

  • adc10
  • timers
  • spi
  • i2C
  • ...

Could be fun to have it directly in platformIO.

Pay attention that you can have some redundancy with some libraries that are added directly in the lib file of a project (I think there is a another timer.h library for arduino).

Regards,

Byran

--- Want to back this issue? **[Post a bounty on it!](https://www.bountysource.com/issues/37369820-peripheral-library-plib-h-not-included-in-pic32mx?utm_campaign=plugin&utm_content=tracker%2F38217658&utm_medium=issues&utm_source=github)** We accept bounties via [Bountysource](https://www.bountysource.com/?utm_campaign=plugin&utm_content=tracker%2F38217658&utm_medium=issues&utm_source=github).
@EmbeddedMan
Copy link

Bryan - just a slight caution about plib.h : the only reason we removed it from chipKIT in the first place was that Microchip was not willing change the license on it to be an open source license. So if you are including it somewhere, be careful that you're OK with the language of Microchip's license.

We ended up rewriting all uses of plib in chipKIT-core so that we didn't need it anymore.

*Brian

@GaussSeidel
Copy link
Author

Many thanks for that information !

What are the libraries that replaces plib in chipkit-core ?

I'm currently working with DNETcK libraries to communicate with the chipkit through Ethernet but this library requires plib... I'm also using I2C, timers, output compare ports for PWM etc and I couldn't find any library that efficiently deals with those requirements.

@EmbeddedMan
Copy link

Bryan,

Unfortunately, we don't have a complete set of plib replacement libraries.
99% of the use of plib in chipKIT-core was very simple to replace with a
handful of equivalently named macros (for doing pin I/O mainly) which we've
put into our header files. But there are tons of plib library calls that
code could use that we don't have replacements for. Much of the older
Digilent library code uses plib calls that chipKIT-core doesn't currently
support.

The good news is that the majority of plib calls' implementation is very
simple - normally just some register writes/reads using macros or nicely
named constants, which makes things pretty simple to replace in your own
code. But still a bit of work.

*Brian

On Tue, Oct 11, 2016 at 9:23 AM, ByranByran [email protected]
wrote:

Many thanks for that information !

What are the libraries that replaces plib in chipkit-core ?

I'm currently working with DNETcK libraries to communicate with the
chipkit through Ethernet but this library requires plib... I'm also using
I2C, timers, output compare ports for PWM etc and I couldn't find any
library that efficiently deals with those requirements.


You are receiving this because you commented.
Reply to this email directly, view it on GitHub
#3 (comment),
or mute the thread
https://github.com/notifications/unsubscribe-auth/AAbeCN5CUGzVEQQ5Fr1Sm7PnqdoEye2vks5qy5vegaJpZM4JvQfY
.

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

No branches or pull requests

3 participants