Skip to content

Commit

Permalink
finalize fix/test for issue #250
Browse files Browse the repository at this point in the history
  • Loading branch information
gin66 committed Apr 28, 2024
1 parent f4cd8e6 commit 4ed8197
Show file tree
Hide file tree
Showing 10 changed files with 26 additions and 22 deletions.
5 changes: 4 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
TODO:
- Different behavior avr vs pc-based tests to be analyzed
- Different behavior avr vs pc-based testgis to be analyzed
- #include-file structure needs to be cleaned up
- setCurrentPosition() should adjust the maintained last position bits in queue. can be called a bug
- rename PoorManFloat to e.g. Log2Representation
Expand All @@ -8,6 +8,9 @@ TODO:

pre-0.30.12:
- esp32: fix deprecation warning for `rmt_memory_rw_rst()`
- simavr-tests:
- avr: Fix issue #250
- avr: In course of issue #250, interrupt blocks of 20us from application are tested.

0.30.11:
- esp32s3: add support for rmt from patch #225
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -500,4 +500,4 @@ As mentioned by kthod861 in [Issue #110](https://github.com/gin66/FastAccelStepp
- Thanks DaAwesomeP for the extension to ATmega 168/168P/328 (https://github.com/gin66/FastAccelStepper/pull/179)
- Thanks turley for the patch for missing `_stepper_cnt` initialization (https://github.com/gin66/FastAccelStepper/pull/204)
- Thanks GarmischWg for adding rmt-support to ESP32-S3 (https://github.com/gin66/FastAccelStepper/pull/225)

- THanks SHWotever for avr patch to fix missing direction pin toggle (https://github.com/gin66/FastAccelStepper/pull/252)
5 changes: 3 additions & 2 deletions examples/Issue250/Issue250.ino
Original file line number Diff line number Diff line change
Expand Up @@ -39,11 +39,12 @@ void setup() {

uint16_t loopcnt = 0;

// fails with blocking 30us
#ifndef BLOCK_INTERRUPT_US
#define BLOCK_INTERRUPT_US 30
#define BLOCK_INTERRUPT_US 20
#endif
#ifndef TOGGLE_DIRECTION
#define TOGGLE_DIRECTION false
#define TOGGLE_DIRECTION true
#endif
#ifndef USE_MOVETO
#define USE_MOVETO true
Expand Down
14 changes: 7 additions & 7 deletions extras/tests/simavr_based/test_sd_04_timing_2560/expect.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@
EnableA: 1*L->H, 1*H->L
EnableB: 2*L->H, 1*H->L
EnableC: 2*L->H, 1*H->L
StepA: 64000*L->H, 64000*H->L, Max High=29us Total High=380000us
StepB: 64000*L->H, 64000*H->L, Max High=34us Total High=507758us
StepC: 64000*L->H, 64000*H->L, Max High=40us Total High=629247us
StepA: 64000*L->H, 64000*H->L, Max High=25us Total High=396526us
StepB: 64000*L->H, 64000*H->L, Max High=35us Total High=418067us
StepC: 64000*L->H, 64000*H->L, Max High=41us Total High=635308us
Position[A]=64000

Position[B]=64000
Expand All @@ -19,11 +19,11 @@ Time in EnableB max=246080 us, total=246080 us

Time in EnableC max=254236 us, total=254236 us

Time in FillISR max=2849 us, total=2127254 us
Time in FillISR max=2866 us, total=2158540 us

Time in StepA max=29 us, total=380000 us
Time in StepA max=25 us, total=396526 us

Time in StepB max=34 us, total=507758 us
Time in StepB max=35 us, total=418067 us

Time in StepC max=40 us, total=629247 us
Time in StepC max=41 us, total=635308 us

14 changes: 7 additions & 7 deletions extras/tests/simavr_based/test_sd_04_timing_328p/expect.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,21 +2,21 @@
DirB: 1*L->H, 0*H->L
EnableA: 1*L->H, 1*H->L
EnableB: 2*L->H, 1*H->L
StepA: 1000*L->H, 1000*H->L, Max High=14us Total High=5335us
StepB: 1000*L->H, 1000*H->L, Max High=16us Total High=5809us
StepA: 1000*L->H, 1000*H->L, Max High=15us Total High=5588us
StepB: 1000*L->H, 1000*H->L, Max High=15us Total High=5832us
Position[A]=1000

Position[B]=1000

Time in EnableA max=225398 us, total=225398 us

Time in EnableB max=238116 us, total=238116 us
Time in EnableB max=238117 us, total=238117 us

Time in FillISR max=2642 us, total=47687 us
Time in FillISR max=2645 us, total=47801 us

Time in StepA max=14 us, total=5335 us
Time in StepA max=15 us, total=5588 us

Time in StepB max=16 us, total=5809 us
Time in StepB max=15 us, total=5832 us

Time in StepISR max=7 us, total=9300 us
Time in StepISR max=7 us, total=9366 us

Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@
DirB: 1*L->H, 0*H->L
EnableA: 1*L->H, 1*H->L
EnableB: 1*L->H, 0*H->L
StepA: 1000*L->H, 1000*H->L, Max High=10us Total High=5028us
StepA: 1000*L->H, 1000*H->L, Max High=10us Total High=5265us
StepB: 0*L->H, 0*H->L, Max High=0us Total High=0us
Position[A]=1000

Time in EnableA max=225399 us, total=225399 us

Time in FillISR max=2014 us, total=27533 us
Time in FillISR max=2015 us, total=27562 us

Time in StepA max=10 us, total=5028 us
Time in StepA max=10 us, total=5265 us

Time in StepISR max=7 us, total=4581 us
Time in StepISR max=7 us, total=4614 us

0 comments on commit 4ed8197

Please sign in to comment.