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

Add basic support for Particle targets #77

Merged
merged 2 commits into from Oct 2, 2019

Conversation

@Dan-Kouba
Copy link
Contributor

commented Sep 24, 2019

Added basic support for using LibHydrogen on Particle targets. I have implemented the entropy seed using the Particle HAL and added a makefile for structuring the library the way Particle expects it.

Notes:

  • The main hydrogen.c file must be a .cpp file for the Particle build system to accept it. Since it only has #include code in it, I just rename it during the make process
  • Particle libraries require versioning to be done using the Semantic Versioning standard, so have added an additional digit.

This is just basic support - I am happy to make or accept any modifications to improve my PR!

@jedisct1

This comment has been minimized.

Copy link
Owner

commented Sep 24, 2019

Thank you Dan!

Is the delay(10) between calls to the HWRNG actually needed for that platform?

@Dan-Kouba

This comment has been minimized.

Copy link
Contributor Author

commented Sep 25, 2019

It shouldn't be but I am double checking with our RNG implementation code to make sure we have an implementation that waits for a new number to be generated before returning. I'll modify once I confirm!

Unnecessary as all HAL implementations for supported Particle platforms are blocking until sufficient random data is available to fulfill the request.
@Dan-Kouba

This comment has been minimized.

Copy link
Contributor Author

commented Sep 26, 2019

I have verified that the HAL implementations for the RNG function I used are blocking and won't return until new random numbers are available. Therefore I have removed the delay from the code.

@jedisct1 jedisct1 merged commit f1f061d into jedisct1:master Oct 2, 2019
1 check passed
1 check passed
continuous-integration/travis-ci/pr The Travis CI build passed
Details
@Dan-Kouba Dan-Kouba deleted the Dan-Kouba:particle_support branch Oct 2, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.