SOEM/oshw/macosx/oshw.h
Marc Butler 812403783c Add port to macOS (#286)
* Port to macOS

This port to macOS is an amalgam of the existing Linux and Win32
ports. Consequently code is duplicated from each in this port:
primarily from win32 in oshw, and Linux is osal.

Synthesizing a shared common posix port, did not seem warranted given
the modest amount of code, and stable api.

This port uses the default pcap interface provided in the development
libraries shipped with XCode.

Limited testing on os releases: 10.13 and 10.14.

* fix possible race condition as for win32

See aed0f81724

* fix spelling as for linux / win32

See 7beba91c62
2019-05-15 07:35:31 +02:00

32 lines
557 B
C

/*
* Licensed under the GNU General Public License version 2 with exceptions. See
* LICENSE file in the project root for full license information
*/
/** \file
* \brief
* Headerfile for ethercatbase.c
*/
#ifndef _oshw_
#define _oshw_
#ifdef __cplusplus
extern "C" {
#endif
#include "ethercattype.h"
#include "nicdrv.h"
#include "ethercatmain.h"
uint16 oshw_htons(uint16 hostshort);
uint16 oshw_ntohs(uint16 networkshort);
ec_adaptert * oshw_find_adapters(void);
void oshw_free_adapters(ec_adaptert * adapter);
#ifdef __cplusplus
}
#endif
#endif