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

... not so much a pull request, but more a test request #132

Open
wants to merge 37 commits into
base: master
Choose a base branch
from

Commits on Feb 26, 2018

  1. create config.h for site specific configuration

    .. this should help to configure non-auto-detectable features.
    
    Signed-off-by: Helmut Raiger <[email protected]>
    taliesin committed Feb 26, 2018
    Configuration menu
    Copy the full SHA
    7ee1fca View commit details
    Browse the repository at this point in the history
  2. add configuration option for FET drivers

      for heater and fan. They are non-inverted now,
    i.e. on if high. Change pin setup and reverse PWM.
    
    Signed-off-by: Helmut Raiger <[email protected]>
    taliesin committed Feb 26, 2018
    Configuration menu
    Copy the full SHA
    c77b208 View commit details
    Browse the repository at this point in the history
  3. add configuration option to swap 1-wire to P0.5

     ... this is in preparation for the secondary heater patch.
    If this is selected the 1-wire pin is moved from P0.7 to P0.5
    to allow access to PMW2 (P0.7).
    
    NOTE: the display code simply writes to P1 pins, this would disturb
      the 1-wire communication if one of the P1 pins would have been
      used. Safer to stay on port 0!
    taliesin committed Feb 26, 2018
    Configuration menu
    Copy the full SHA
    4e672d1 View commit details
    Browse the repository at this point in the history
  4. support secondary heater at P0.7 (PMW2)

      .. currently this is simply driven with the same values as
    the original heater, this needs further investigation.
    taliesin committed Feb 26, 2018
    Configuration menu
    Copy the full SHA
    e6f939e View commit details
    Browse the repository at this point in the history
  5. allow baudrate configuration for UART0

     ... just give it a standard baudrate and it'll work.
    This is mainly to support communication issues with 115200.
    As additional goody the serial interface now reports what it did
    not understand.
    taliesin committed Feb 26, 2018
    Configuration menu
    Copy the full SHA
    51ca75b View commit details
    Browse the repository at this point in the history
  6. dissect main.c to allow simplification and ...

      shell integration. Currently the serial command interpreter is
    disabled.
    taliesin committed Feb 26, 2018
    Configuration menu
    Copy the full SHA
    40d65d2 View commit details
    Browse the repository at this point in the history
  7. simplify LCD output, use printf style

      ... GUI should be just the same, but more wrapped up.
    taliesin committed Feb 26, 2018
    Configuration menu
    Copy the full SHA
    d9bdf9c View commit details
    Browse the repository at this point in the history
  8. cleanup static globals in main.c

      only one left which is shared between Edit_Profile_Mode and
    Select_Profile_Mode().
    taliesin committed Feb 26, 2018
    Configuration menu
    Copy the full SHA
    adb8c69 View commit details
    Browse the repository at this point in the history
  9. add the most simple logging system

     currently this is more or less like the printfs before, but the level
    may be changed at runtime and new formats may be implemented.
    Currently only the level is prepended.
    taliesin committed Feb 26, 2018
    Configuration menu
    Copy the full SHA
    553aa1a View commit details
    Browse the repository at this point in the history
  10. clean up GUI, mostly cosmetic ...

     but a few things were sacrificed for simplicity.
    The bake timer is now not settable to infinity anymore.
    If no coldjunction sensor is installed it simply vanishes instead
    of stating 'not present'.
    Bake mode controls don't vanish on value limits, but in setup
    this won't either.
    taliesin committed Feb 26, 2018
    Configuration menu
    Copy the full SHA
    0e38643 View commit details
    Browse the repository at this point in the history
  11. plug in SimpleCLI from ...

       https://github.com/matthiasb85/SimpleCLI
    Needs commands and better texts.
    Shows internal commands as internal and external?
    taliesin committed Feb 26, 2018
    Configuration menu
    Copy the full SHA
    1c9024c View commit details
    Browse the repository at this point in the history
  12. shell: implement some commands

     - implement non-mode-switching commands
     - improve user experience (prompt, version ...)
     - prepare main for mode switching
    
    Fix a bug in Makefile (used a wrong path for SimpleCLI includes).
    taliesin committed Feb 26, 2018
    Configuration menu
    Copy the full SHA
    e84eae1 View commit details
    Browse the repository at this point in the history
  13. shell: allow to set log levels ...

      set log_lvl 7 ... for verbose
      set reflow_log_lvl 7 ... for standby logging
      set reflow_log_lvl 0 ... for logging during bake and reflow
    taliesin committed Feb 26, 2018
    Configuration menu
    Copy the full SHA
    545d87a View commit details
    Browse the repository at this point in the history
  14. shell: finalize port to SimpleCLI

      ... implement reflow and bake. This is still a bit
    clumsy, it switches the display mode to keep the serial interface
    consistent with the GUI.
    The 'setting x y' was not implemented on purpose for now. Actually
    these values should not be set remotely (and most probably only
    once during first set-up).
    taliesin committed Feb 26, 2018
    Configuration menu
    Copy the full SHA
    6125284 View commit details
    Browse the repository at this point in the history
  15. change eeprom format and add save profile ...

     - completely change the EEPROM format, holds 4 custom profiles now
        change temperature encoding to byte (20 .. 275 deg C allowed).
     - allow a profile to be saved from the shell:
        like: save NEW_PROFILE 30,40,50,60,...
     - custom profiles may have names now (only from the shell)
     - they may still be edited via the keyboard
    
    Some things are gone, like non-volatile bake setpoint.
    taliesin committed Feb 26, 2018
    Configuration menu
    Copy the full SHA
    d81d3d9 View commit details
    Browse the repository at this point in the history

Commits on Mar 8, 2018

  1. simplify adc.c and USE_PRECISION_OPAMP

      adc.c used a buffer of 2 x 256 x 2 byte = 1024 bytes to
    calculate the sum over the last 256 values for oversampling.
    This is pretty useless in the first place as accuracy below 1K
    are not to be expected even with a precision opamp instead of the
    TLC27L2. The current implementation at least gets rid of the
    buffer completely by using a running average method.
    Along with the change the sampling is reduced to once per ms
    instead of ever 100us, which was an overkill, new values
    are delivered every 256ms now, which is good enough.
    
    USE_PRECISION_OPAMP switches the internal gain to 0.36845 as the
    pre-amplifier is supposed to have a gain of 222.2 (see adc.c).
    At 300 degree C it uses 834 LSBs instead of only 307.
    
    Using an OPA2333 or similiar and replacing the trim resistors
    by fixed (and accurate) resistors will do the trick.
    taliesin committed Mar 8, 2018
    Configuration menu
    Copy the full SHA
    17dd69b View commit details
    Browse the repository at this point in the history

Commits on Mar 9, 2018

  1. minor fixes and cosmetics, BUG with bake mode!

     .. there is still a bug when baking, this needs more than a
    few lines of code.
    taliesin committed Mar 9, 2018
    Configuration menu
    Copy the full SHA
    83d1ace View commit details
    Browse the repository at this point in the history

Commits on Mar 11, 2018

  1. reflow: major rewrite

     - simplify interface
     - make it an independent state machine (no external state switching).
     - move non-reflow stuff out to shell.c and main.c
     - get setpoint from profile using time (not index)
     - improve readability, lots of comments, lower complexity
    
    Compiles, but does not work yet.
    taliesin committed Mar 11, 2018
    Configuration menu
    Copy the full SHA
    0fa4ffe View commit details
    Browse the repository at this point in the history
  2. fix reflow.c ...

     - Reflow_GetSetpointAtTime()
     - add timing stuff
    
    standby fan control not yet working, switch out of reflow screen ...
    taliesin committed Mar 11, 2018
    Configuration menu
    Copy the full SHA
    fed6aa8 View commit details
    Browse the repository at this point in the history

Commits on Mar 12, 2018

  1. reflow.c: cosmetics and more ...

     - move plot profile to main.c, have profiles zero-terminated
     - make setpoint reporting independent of look-ahead drive
    taliesin committed Mar 12, 2018
    Configuration menu
    Copy the full SHA
    d57274b View commit details
    Browse the repository at this point in the history
  2. bake mode: split menu modes

     ... to visualize bake mode better.
    
    Still very buggy.
    taliesin committed Mar 12, 2018
    Configuration menu
    Copy the full SHA
    0b2a16e View commit details
    Browse the repository at this point in the history
  3. reflow: change abort state to cooling state

     .. don't use PID to cool down, go full speed and stop.
    taliesin committed Mar 12, 2018
    Configuration menu
    Copy the full SHA
    036fb37 View commit details
    Browse the repository at this point in the history
  4. bake mode: fix screen content

     .. fix last value interpolation in Reflow_GetSetpointAtTime()
    taliesin committed Mar 12, 2018
    Configuration menu
    Copy the full SHA
    5385131 View commit details
    Browse the repository at this point in the history

Commits on Mar 19, 2018

  1. reflow_profiles: move shell specifics to shell.c

     ... print and dump moved to shell.c.
    Show current profile in 'profiles'
    taliesin committed Mar 19, 2018
    Configuration menu
    Copy the full SHA
    30e9f5e View commit details
    Browse the repository at this point in the history
  2. Add cooling screen

      This is to visualize the forced cooling cycle after any bake
    or reflow (even if aborted). Only after cooling a new heating
    cycle can be started, this also fixes a few strange behaviours
    when started from the shell.
    taliesin committed Mar 19, 2018
    Configuration menu
    Copy the full SHA
    d88700a View commit details
    Browse the repository at this point in the history

Commits on Mar 21, 2018

  1. main.c: setup, fix fan control

     ... this was removed during the change of the reflow state machine
    and can now be done directly using Set_Fan().
    taliesin committed Mar 21, 2018
    Configuration menu
    Copy the full SHA
    745b6b1 View commit details
    Browse the repository at this point in the history

Commits on Mar 22, 2018

  1. fix format warnings and declaration of _write

      ... make gcc shut up.
    taliesin committed Mar 22, 2018
    Configuration menu
    Copy the full SHA
    749063c View commit details
    Browse the repository at this point in the history
  2. add -Wextra and fix the warnings, mostly cosmetic

     - lots of unsigned/signed comparision warnings, non of them critical
     - a few more unused argument warnings
    taliesin committed Mar 22, 2018
    1 Configuration menu
    Copy the full SHA
    02578c1 View commit details
    Browse the repository at this point in the history

Commits on Apr 2, 2018

  1. tried using -O2 instead of -Os

     ... as space is not critical use -O2 instead, BUT this fails
    completely! Won't start anymore, so the code is buggy at some
    point not allowing for this kind of optimization.
    
    So, onl make some of the time critical functions inlineable,
    i.e. put them in the headers and make them static inline.
    
    This is in preparation for the reduction of interrupt latencies
    in onewire.c, which block interrupts for quite some time (as
    identified and modified by radensb).
    taliesin committed Apr 2, 2018
    Configuration menu
    Copy the full SHA
    7090354 View commit details
    Browse the repository at this point in the history
  2. reduce interrupt latency in onewire.c

     .. block and unblock on byte boundaries instead of
    whole sequences. This follows a patch by radensb.
    taliesin committed Apr 2, 2018
    Configuration menu
    Copy the full SHA
    8d82026 View commit details
    Browse the repository at this point in the history

Commits on Apr 15, 2018

  1. serial.c: improve interrupt handling

     ... use the HW-FIFOs and ring buffer adequately.
    taliesin committed Apr 15, 2018
    Configuration menu
    Copy the full SHA
    977eeda View commit details
    Browse the repository at this point in the history
  2. cosmetic: rename TC_AVERAGE to TO_CONTROL

     ... in preparation of composing a control temperature
    which may be something else than a simple average.
    taliesin committed Apr 15, 2018
    Configuration menu
    Copy the full SHA
    963d7a3 View commit details
    Browse the repository at this point in the history
  3. fix bug in reflow.c concerning fan

      In standby mode the fan and heater were always turned off,
    so that in setup mode the fan was turned on and off all the time.
    Along with this fix the PWM control in io.c is simplified.
    taliesin committed Apr 15, 2018
    Configuration menu
    Copy the full SHA
    8526a71 View commit details
    Browse the repository at this point in the history

Commits on Apr 16, 2018

  1. sensor.c: let sensor be configured, remove auto-detect

    This is in preparation for the implementation of a new control strategy.
    Auto-detection of sensors may be neat, but has it's drawbacks
    if sensors disappear during operation. Currently this is not
    fixed with the change either, but it will allow such a change
    more easily.
    
    This also improves the performance of Sensor_DoConversion() as
    it will not check for the existance of sensors during the reflow process.
    taliesin committed Apr 16, 2018
    Configuration menu
    Copy the full SHA
    01973ae View commit details
    Browse the repository at this point in the history
  2. Add setup screen for the LR_WEIGHTED_AVERAGE control

     This allows the user to select the 'weight' of the PCB to be
    soldered. The value 0-100% goes from:
    
    'super light weight': nearly no components, thin PCB material
      next to no reflective zones on it (it picks up lots of radiated
      heat).
    'heavy weight': larger and heavier components (increased thermal
     capacity or lots of reflective zones (less radiation pickup).
    
    ... and everything in between.
    
    Note: this requires the termal couples to be patched, see wiki.
    taliesin committed Apr 16, 2018
    Configuration menu
    Copy the full SHA
    3677c20 View commit details
    Browse the repository at this point in the history

Commits on May 19, 2018

  1. add weight to LR_WEIGHTED_AVERAGE control in shell

     - left TC is light, right TC is heavy
     - change weight to be integer from 0 .. 100
     - add weight argument to reflow command in the shell
    taliesin committed May 19, 2018
    Configuration menu
    Copy the full SHA
    6ea2ab3 View commit details
    Browse the repository at this point in the history

Commits on Jun 15, 2018

  1. tweak cooling phase with LR_WEIGHTED_AVERAGE

    When simulating the PCB temperature the radiation pattern seems
    to overheat the PCB even with the lowest weight selected, if
    the PCB is placed on stand-offs in the drawer.
    
    But it works super stable having them placed on the drawer bottom
    directly! This spreads the heat on the board aswell!
    The drawback is the cooling is lagging a lot, even slower
    than the heavy thermo couple (which is more exposed to the
    air stream caused by the fan).
    
    The solution so far:
    - place the PCB directly on the drawer bottom
    - with pretty normal PCBs select a weight of about 20%
    - remove the cooling ramp from the profiles
      this makes the reflow state machine go to COOLING and fully
      ventilate the drawer.
    - tweak the control temperature so that it reflects something
      more likely to be the real PCB temperature (mostly informational
      anyway).
    - show the cooling phase on the display
    
    The best solution definitely would be to directly measure the
    PCB temperature, but ramp-up with the simulator is about +/-5K
    on the setpoint (the PID control still not fixed). The cooling
    process is very dependent on the position in the drawer, it's
    a lot more air on the left side!
    taliesin committed Jun 15, 2018
    Configuration menu
    Copy the full SHA
    00ba609 View commit details
    Browse the repository at this point in the history