rocketscream / TinyReflowController

An all-in-one Arduino compatible reflow controller powered by ATtiny1634R
121 stars 64 forks source link

Multiple Profiles and Temp Holding (wip) #10

Open sschueller opened 3 years ago

sschueller commented 3 years ago

Please do not merge this yet. I still need to test it as my oven is not quite finished yet (waiting for parts). However I wanted to make you and others aware of my changes in case someone wants to also help or give input.

Changes:

TODO:

geekbozu commented 3 years ago

I am looking for these features in my oven, Can you put together some quick better documentation on the setting up of profiles. I mostly am looking to add a "bake" profile of sorts but am confused as to how your configuring steps and similar Thanks!

sschueller commented 3 years ago

I have some docs at https://github.com/sschueller/TinyReflowController. Do you have a specific question regarding the configuration?

For each profile you need to add a line as such:

const char profilename_4[] PROGMEM = "Bake";

Then you need to add it to profileNames

const char *const profileNames[] PROGMEM = {profilename_0, profilename_1, profilename_2, profilename_3,profilename_4};

Then you need to add an additional column to each line in the stages following. So for example pre-heat

// preheat temp
const float profilePreHeatTemps[] PROGMEM = {Profile 0, Profile 1, Profile 2, Profile 3, Profile 4 .... etc.};

So like this:

// pre-heat
const float profilePreHeatTemps[] PROGMEM = {150, 150, 63, 177, 200};
const uint32_t profilePreHeatMTime[] PROGMEM = {0, 0, 120000, 120000, 0};
const int profilePreHeatTStep[] PROGMEM = {120, 120, 1, 1, 120};
const uint32_t profilePreHeatHoldTime[] PROGMEM = {0, 0, 0, 0, 0};
const float profilePreHeatKP[] PROGMEM = {100, 100, 100, 100, 100};
const float profilePreHeatKI[] PROGMEM = {0.025, 0.025, 0.025, 0.025, 0.025};
const float profilePreHeatKD[] PROGMEM = {20, 20, 20, 20, 20};

Do this for all Stages.

Bake would be similar to "Annealing" but without the set time on how slow/fast it should heat up to the "Bake" temp or cooldown.

geekbozu commented 3 years ago

My question pertains to how to setup the steps and timing and better definitions of the values in the stage arrays, Like you have some explanations of what each step/Profile line item is but I am failing to link the difference between hold steps etc. Like MTim is 0 step is 120 but you flip that for the Annealing ones? I'm sure its plenty logical I just am missing the connection :(

sschueller commented 3 years ago

Looking at it myself after months it's confusing me as well :)

Let me try to explain:

When we want to cooldown slowly the profilePreHeatTStep is negative since I want to remove degrees from the current set point to reach the profilePreHeatTemps which is lower than the last stage. So I'm at 200C and I want to go to 50C with steps of -1C every profilePreHeatMTime

I may make a small JavaScript script to calculate these values so you can specify total time you want instead having the manually figure out the temp step and mtime.

How exactly would you want your bake profile to look?

geekbozu commented 3 years ago

That java-script thing would be super nice actually That makes way more sense. Thank you a ton for the explanation. I'm looking at implementing a pretty standard part bake 125C for 6-12 hours depending on a few factors. I work in a production environment where we need to make sure we don't have our parts popcorn during assembly.

As for the PID stuff I know that is oven dependent...really need to spend the time to tune those heh....I wonder if this could eventually get an auto tuner like a lot of 3d printers lately.