Commit Graph

392 Commits

Author SHA1 Message Date
Florian Pose 7b40d5fc40 Added missing prototypes. 2024-05-22 12:36:16 +02:00
Bjarne von Horn 997c81b6fa use separate queue for external datagrams to avoid corrupting master::queue 2024-05-16 09:48:23 +02:00
Bjarne von Horn fe160f5c86 Use -ENOBUFS to indicate insufficient preallocated buffer 2024-04-03 10:34:17 +02:00
Bjarne von Horn 13e99008c3 use int as return type for ecrt_master_*
See #101
2024-04-03 10:34:17 +02:00
Bjarne von Horn d0f4aed39b Make ecrt_master_reset available in RT context
It takes the master_sem, so calling it from RT context is not an option.
The reset is done by a workqueue now, which is triggered in a NMI-safe way.

Fixes #103
2024-02-08 08:59:29 +01:00
Florian Pose 4ce4d08b7b Made some more pointer arguments const in API. 2024-02-02 10:56:09 +01:00
Florian Pose ee55c20e28 Fixed mail address; limited lines to 78 characters; removed $Id$. 2024-02-01 15:15:41 +01:00
Florian Pose 512bac72e2 Merge branch 'devel-1.6' into prepare-1.6 2024-02-01 13:26:12 +01:00
Florian Pose 2fdea4dd53 Merge branch '79-query-scan-progress-via-api-2' into 'devel-1.6'
Resolve "Query scan progress via API"

See merge request etherlab.org/ethercat!110
2024-02-01 10:27:07 +00:00
Bjarne von Horn 2e071ad680 Remove EtherCAT copyright notice. 2024-02-01 09:18:26 +01:00
Bjarne von Horn 9a2abde36c Remove 2.6 conditionals in master 2024-02-01 09:12:55 +01:00
Florian Pose 91fe3eb735 Added ecrt_master_scan_progress() method. 2024-01-31 16:52:18 +01:00
Bjarne von Horn a54fac3090 Make locking of ext_datagram_queue more selective 2024-01-15 11:20:25 +01:00
Bjarne von Horn 13e1e469e1 Use RT Mutex instead of semaphore for RT ioctl locking. 2024-01-15 11:20:25 +01:00
Bjarne von Horn c3826c7758 Remove EtherCAT copyright notice. 2024-01-15 11:20:25 +01:00
Bjarne von Horn 543dc87d88 Remove 2.6 conditionals in master 2024-01-15 11:20:25 +01:00
Florian Pose 1726abf0c3 Allow zero-sized SDO responses 2023-05-02 08:43:16 +00:00
Matthias Schoepfer e6d842cc8f master: added 'run_on_cpu' module parameter to bind kthreads to a cpu
When you use isolcpus to isolate a cpu for the realtime task, as well
as assiging all relevant interrupts to this cpu, it makes sense to
also bind the EtherCAT-OP / EtherCAT-IDLE task to this cpu to reduce
the cache misses and avoid data migration between cores. Therefore
a parameter 'run_on_cpu' is added, that takes the cpu number (same as
in isolcpus, not a smp_affinity mask). If unset, will bind to any cpu
and will be migratable.

The reason to put this into the kernel module is, that the thread is
created during runtime, i.e. when the userspace program is starting
the ethercat master. It would be rather hacky, to find the pid of the
EtherCAT-xx thread and migrate it at this point.

Signed-off-by: Matthias Schoepfer <m.schoepfer@rethinkrobotics.com>
2021-09-27 14:56:01 +02:00
Florian Pose 4e11a50670 Define set_normal_priority() inside #ifdef EC_EOE. Fixes #12. 2021-08-25 09:47:26 +02:00
Florian Pose cd0d17d6a5 Also changed license of gloabl headers to LGPL.
Moved definition of EC_SDO_INJECTION_TIMEOUT to master.c.
2021-07-23 13:33:54 +02:00
Nicola Fontana 2600c89390 Fix sched_setscheduler undefined on kernel 5.9
sched_setscheduler is no more exported:
    https://lkml.org/lkml/2020/4/22/1071
2021-03-05 15:16:15 +01:00
Florian Pose 21d0fb5176 Fixed missing include for struct sched_param. 2020-04-03 12:09:39 +02:00
Florian Pose f03f15a6fc Added ecrt_master_sync_reference_clock_to() method. 2018-11-26 17:41:27 +01:00
Florian Pose 083bd419b8 Renamed app_start_time to dc_ref_time; output via command-line tool. 2018-11-26 17:17:18 +01:00
Florian Pose 538c3d7c04 Improved buffer overflow messages. 2017-12-13 15:39:13 +01:00
Florian Pose a694e3055f Support scheduler parameters in kernels >= 4.11. 2017-12-06 10:09:50 +01:00
Florian Pose 39919cd96a Fixed statistics filter initialisation. 2017-10-12 13:22:06 +02:00
Florian Pose b6930dfa9b Fixed possible NULL pointer dereference; thanks to Matthieu Bec. 2014-05-05 13:49:45 +02:00
Florian Pose e385a9bb62 Added configure switch --disable-rt-syslog. 2013-10-21 19:27:50 +02:00
Florian Pose 605739d78a Introduced FORCE_OUTPUT_CORRUPTED. 2013-05-21 13:18:24 +02:00
Florian Pose b0eace9ef1 Implemented emergency register requests to analyze a broken bus. 2013-05-13 20:21:19 +02:00
Florian Pose f6f5460485 Updated Doxygen documentation. 2013-02-12 15:46:43 +01:00
Florian Pose 032acb3d85 Avoided io_sem locking from userspace/rtdm library. 2013-01-10 17:36:41 +01:00
Florian Pose 623c91c545 Fixed io_sem usage in queue_external_datagrams(). 2012-12-06 18:11:11 +01:00
Florian Pose 43202f7e32 Send sync datagrams only if reference clock is found. 2012-12-05 15:54:49 +01:00
Florian Pose 5f73e9c046 Using common waitqueue for requests. 2012-12-04 16:05:23 +01:00
Florian Pose 72b60d1c07 Removed unnecessary ec_master_soe_request_t type. 2012-12-04 14:49:23 +01:00
Florian Pose de0ce09db9 Removed unnecessary ec_master_sdo_request_t. 2012-12-04 13:28:38 +01:00
Florian Pose 6863b34ff1 Minor: Renamed slave_sdo_requests. 2012-12-04 12:59:15 +01:00
Florian Pose 1322a3b6a8 Removed unused method. 2012-12-04 12:22:38 +01:00
Florian Pose cf327f63c8 Mark processing SDO request as invalid if config is cleared. 2012-12-04 12:09:42 +01:00
Florian Pose e59b790583 Reset master state machine when going to orphaned phase. 2012-12-04 11:57:55 +01:00
Florian Pose 879a17fa56 Minor changes. 2012-12-04 11:54:13 +01:00
Florian Pose 3cb0b12899 Added configure option for redundancy (--with-devices). 2012-11-30 20:15:31 +01:00
Florian Pose becf05dbd6 Added interface to select the reference clock and to sync to it.
Added rtai_rtdm_dc example, thanks to Graeme Foot.
2012-11-20 14:35:53 +01:00
Florian Pose 4773e88bf6 Added interface to read/write register contents; re-worked register requests. 2012-11-14 22:12:57 +01:00
Florian Pose 88b99dcd07 Removed state-dependent skip messages. 2012-11-14 22:00:11 +01:00
Florian Pose ef68a4bff1 Added ecrt_sdo_request_index() method to change index and subindex. 2012-10-04 10:07:52 +02:00
Florian Pose 9faaa83212 Re-worked and seamlessly integrated RTDM interface. 2012-09-20 15:28:25 +02:00
Florian Pose b0b7e6fde4 Removed trailing spaces. 2012-09-06 20:22:24 +02:00