External system' Square pulse timing benchmark

Hi,

I'm working on a RPi+Python3 project to run as smoothly as possible, as many as possible stepper motors with a single RPi GitHub - juanmf/StepperMotors: Python stepper motor library with customizable acceleration strategies and responsive, interruptible motor operations.,

Despite I know the limitations of PC and Python (lack of native support for simultaneous threads execution + OS swapping out processes) I stressed working around these limitations as much as possible. I'm happy with results so far but someone brought out a checklist with interesting items a serious tool of this kind should cover, for hard real time scenarios, in this reply:

  • one processor/core dedicated to each input/output device,
  • no caches (they improve the mean timings but make the worst case even worse),
  • no interrupts (unpredictable timing, priority inheritance etc),
  • non-realtime processing executing on different processors/cores,
  • language operations that allow the application to specify output occurring on a specific clock cycle and capturing the clock cycle at which input occurred
  • language where multicore/multithread isn't merely a bolt-on afterthought
  • a development environment that is capable of specifying the worst case timing, after compilation, but before execution

I have already addressed most but in the bolded one, I can't rely on the RPi for measurements, as it'd overload the already stressed CPU.

Questions:
I was wondering if I can measure accurately the HIGHs and LOWs from RPi GPIO pins using a spare Arduino Mega 2560 Controller Board I have. And how one would go about setting up an integration test of this kind.

Also would like to know if there is already a standard way and hardware to assess this type of system's SLA.



Manually I can use a scope and a signal generator for comparison, but it'd be impracticable to determine percentiles of accuracy.

Polling can not provide very accurate times. A timer Input Catch may work better.

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.