EmbeddedNim / picostdlib

Nim wrapper for the raspberry pi stdlib
MIT License
70 stars 11 forks source link

Update picostdlib examples #35

Closed casey-SK closed 2 years ago

casey-SK commented 2 years ago

Purpose:

My intent here is to create a better structure for the examples included in the picostdlib. I have arranged the examples as follows:

Note that so far, I have only completed 6 examples in the manor described, hope to finish the rest soon. I have tested them all to ensure that they run correctly.

I deleted the redundant examples that covered the same concepts, and left the examples the I have not yet look at. I also changed the import statements for the remaining hello_ programs.

I am curious to know how many examples you guys think we should have? did you have a limit in mind?

beef331 commented 2 years ago

I am curious to know how many examples you guys think we should have? did you have a limit in mind?

As many as you want, ideally these work as tests that the API atleast compiles and works, but the down side is hard to test.

casey-SK commented 2 years ago

haha, I haven't closed (#3) yet. I would like to at the very least test that they build without error. I watched a video about debugging, and it takes a lot of steps haha

beef331 commented 2 years ago

Yea properly testing this stuff works is very much in the category of having a bunch of breakout boards that could be dropped on to test X module/feature.

beef331 commented 2 years ago

For one the example PR should be separate to the piconim link changes. Though secondly i dont know how i feel with the solution for link libraries. Iterating every C file searching for a string seems ugh. Need to think about it more.

casey-SK commented 2 years ago

dang, sorry for being an amateur with git. I am going to close this PR and try again.

beef331 commented 2 years ago

All you need to do is git rebase -i HEAD~2 and drop the last commit(after making another branch), then push over this, then in the other branch drop everything but the latest commit doing git rebase -i #commitBeforeWorkAdded then dropping all between then and now.

casey-SK commented 2 years ago

Oh okay, once I try that, I will reopen this. Sorry for testing your patience like this haha