Commit Graph

19 Commits

Author SHA1 Message Date
Michael Moon 0dc7d77885 Massive Doxygen documentation addition
'make doc' then point your browser at doc/html/

Needs plenty of cleanup and polishing, but the main bulk is here

even documents your configuration! ;)
2011-03-22 01:34:36 +11:00
Markus Hitter 851a91306a timer.c: don't reset next_step_time when doing a step.
Doing so adds most of the interrupt execution time to the
step time, see line 126 of the same file:

    if (next_step_time == 0) {
      // new move, take current time as start value
      step_start = TCNT1;
    }
2011-03-14 17:34:26 +01:00
Michael Moon d0601716e8 reorganise intercom to send packets from extruder main loop, also generalise protocol as discussed in forum 2011-03-05 13:38:12 +11:00
Markus Hitter 4ca9e470a5 Move timer macros from config.h.dist and derivates to timer.c.
This sould confuse users less and neither value is subject to change
per configuration. Reviewed also by Markus Amsler.
2011-02-23 12:37:15 +01:00
Michael Moon 3c5acd7ca7 disable interrupt if setTimer(0) is called 2011-02-11 11:53:27 +11:00
Michael Moon d91f30eda1 ensure step timer doesn't fire by itself after a period of inactivity 2011-02-10 19:57:16 +11:00
Markus Amsler 69f30f0691 timer: Use 2 comparator interrupts, one for the clock, the other for stepping.
The old implementation with an overflow interrupt for the clock and a comparator interrupt for stepping, had an unsolvable bug: If the comparator interrupt should happen very shortly after the overflow interrupt the comparator interrupt would miss. And with 2 comparators the implementation is more straightforward.
2011-02-10 19:53:58 +11:00
Markus Amsler d5033895b2 Fix timer for high speeds. 2011-02-08 21:57:58 +11:00
Michael Moon 00fc05a49b fix timer bug- if delay is smaller than TICK_TIME but counter has passed delay when timer is set, it will wait a whole TICK_TIME before firing instead of setting comparator to fire at correct time
check next_step_time instead of delay in comparison

Reported-by: Markus Amsler <markus.amsler@oribi.org>
2011-02-08 09:43:50 +11:00
Michael Moon 096d7dfdf3 Merge release-candidate-triffid branch 2011-01-07 23:09:13 +11:00
Michael Moon e3d0aa7b62 split delay functions into separate files 2010-10-11 10:12:35 +11:00
Markus Hitter 95939ecc22 Don't disable the stepper timer interrupt while stepping.
After lots of try and error the conclusion was, disabling this
interrupt makes the timer vulnerable to be messed up by
characters incoming over the serial line. So, now the
interrupt is enabled as a move starts and not disabled before
the move, and all subsequent moves are done.
2010-10-04 16:05:01 +02:00
Markus Hitter f98772ff25 timer.c: remove a few obsolete #includes. 2010-10-04 16:04:12 +02:00
Michael Moon e78381c56d Move configuration to config.h.dist 2010-09-27 09:20:07 +10:00
Markus Hitter 64683e6b6a Remove timer reset, as this doesn't play well. See
http://github.com/triffid/FiveD_on_Arduino/issues#issue/2/comment/428863 .
2010-09-25 12:08:23 +02:00
Michael Moon c1dbd869f5 minor fixes: comments, indenting, etc 2010-09-18 08:08:31 +10:00
Michael Moon 92eb4c97ca reset timer properly for more accurate timing 2010-09-16 21:42:24 +10:00
Michael Moon 48cf0e05d7 some code cleanup, added M114, wrapped M25[0..5] in ifdef DEBUG wrapper 2010-09-12 12:54:58 +10:00
Michael Moon 595b66a341 setting up new branch 2 2010-08-10 14:26:24 +10:00