Fixed line lengths; and ID keywords of merged sources.

This commit is contained in:
Florian Pose
2024-02-01 16:38:06 +01:00
parent ac50849bcc
commit df3954d8ec
8 changed files with 41 additions and 101 deletions

View File

@@ -1,4 +1,4 @@
/******************************************************************************
/*****************************************************************************
*
* Copyright (C) 2006-2023 Florian Pose, Ingenieurgemeinschaft IgH
*
@@ -17,22 +17,16 @@
* with the IgH EtherCAT Master; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*
* ---
*
* The license mentioned above concerns the source code only. Using the
* EtherCAT technology and brand is only permitted in compliance with the
* industrial property and similar rights of Beckhoff Automation GmbH.
*
* vim: noexpandtab
*
*****************************************************************************/
****************************************************************************/
/**
\file
EtherCAT driver for RTL8139-compatible NICs.
*/
/*****************************************************************************/
/****************************************************************************/
/*
Former documentation:

View File

@@ -1,4 +1,4 @@
/******************************************************************************
/*****************************************************************************
*
* Copyright (C) 2006-2023 Florian Pose, Ingenieurgemeinschaft IgH
*
@@ -17,22 +17,16 @@
* with the IgH EtherCAT Master; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*
* ---
*
* The license mentioned above concerns the source code only. Using the
* EtherCAT technology and brand is only permitted in compliance with the
* industrial property and similar rights of Beckhoff Automation GmbH.
*
* vim: noexpandtab
*
*****************************************************************************/
****************************************************************************/
/**
\file
EtherCAT driver for RTL8139-compatible NICs.
*/
/*****************************************************************************/
/****************************************************************************/
/*
Former documentation:

View File

@@ -1,6 +1,4 @@
/******************************************************************************
*
* $Id$
/*****************************************************************************
*
* Copyright (C) 2006-2014 Florian Pose, Ingenieurgemeinschaft IgH
*
@@ -19,19 +17,13 @@
* with the IgH EtherCAT Master; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*
* ---
*
* The license mentioned above concerns the source code only. Using the
* EtherCAT technology and brand is only permitted in compliance with the
* industrial property and similar rights of Beckhoff Automation GmbH.
*
*****************************************************************************/
****************************************************************************/
/** \file
* Ethernet-over-EtherCAT request functions.
*/
/*****************************************************************************/
/****************************************************************************/
#include <linux/module.h>
#include <linux/jiffies.h>
@@ -39,7 +31,7 @@
#include "eoe_request.h"
/*****************************************************************************/
/****************************************************************************/
/** EoE request constructor.
*/
@@ -68,4 +60,4 @@ void ec_eoe_request_init(
req->result = 0x0000;
}
/*****************************************************************************/
/****************************************************************************/

View File

@@ -1,6 +1,4 @@
/******************************************************************************
*
* $Id$
/*****************************************************************************
*
* Copyright (C) 2006-2014 Florian Pose, Ingenieurgemeinschaft IgH
*
@@ -19,20 +17,14 @@
* with the IgH EtherCAT Master; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*
* ---
*
* The license mentioned above concerns the source code only. Using the
* EtherCAT technology and brand is only permitted in compliance with the
* industrial property and similar rights of Beckhoff Automation GmbH.
*
*****************************************************************************/
****************************************************************************/
/**
\file
EtherCAT EoE request structure.
*/
/*****************************************************************************/
/****************************************************************************/
#ifndef __EC_EOE_REQUEST_H__
#define __EC_EOE_REQUEST_H__
@@ -42,7 +34,7 @@
#include "globals.h"
/*****************************************************************************/
/****************************************************************************/
/** Ethernet-over-EtherCAT set IP parameter request.
*/
@@ -68,10 +60,10 @@ typedef struct {
uint16_t result;
} ec_eoe_request_t;
/*****************************************************************************/
/****************************************************************************/
void ec_eoe_request_init(ec_eoe_request_t *);
/*****************************************************************************/
/****************************************************************************/
#endif

View File

@@ -1,6 +1,4 @@
/******************************************************************************
*
* $Id$
/*****************************************************************************
*
* Copyright (C) 2006-2014 Florian Pose, Ingenieurgemeinschaft IgH
*
@@ -19,33 +17,27 @@
* with the IgH EtherCAT Master; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*
* ---
*
* The license mentioned above concerns the source code only. Using the
* EtherCAT technology and brand is only permitted in compliance with the
* industrial property and similar rights of Beckhoff Automation GmbH.
*
*****************************************************************************/
****************************************************************************/
/**
\file
EtherCAT EoE state machines.
*/
/*****************************************************************************/
/****************************************************************************/
#include "globals.h"
#include "master.h"
#include "mailbox.h"
#include "fsm_eoe.h"
/*****************************************************************************/
/****************************************************************************/
/** Maximum time to wait for a set IP parameter response.
*/
#define EC_EOE_RESPONSE_TIMEOUT 3000 // [ms]
/*****************************************************************************/
/****************************************************************************/
void ec_fsm_eoe_set_ip_start(ec_fsm_eoe_t *, ec_datagram_t *);
void ec_fsm_eoe_set_ip_request(ec_fsm_eoe_t *, ec_datagram_t *);
@@ -55,7 +47,7 @@ void ec_fsm_eoe_set_ip_response(ec_fsm_eoe_t *, ec_datagram_t *);
void ec_fsm_eoe_end(ec_fsm_eoe_t *, ec_datagram_t *);
void ec_fsm_eoe_error(ec_fsm_eoe_t *, ec_datagram_t *);
/*****************************************************************************/
/****************************************************************************/
/** Constructor.
*/
@@ -71,7 +63,7 @@ void ec_fsm_eoe_init(
fsm->request = NULL;
}
/*****************************************************************************/
/****************************************************************************/
/** Destructor.
*/
@@ -81,7 +73,7 @@ void ec_fsm_eoe_clear(
{
}
/*****************************************************************************/
/****************************************************************************/
/** Starts to set the EoE IP partameters of a slave.
*/
@@ -96,7 +88,7 @@ void ec_fsm_eoe_set_ip_param(
fsm->state = ec_fsm_eoe_set_ip_start;
}
/*****************************************************************************/
/****************************************************************************/
/** Executes the current state of the state machine.
*
@@ -131,7 +123,7 @@ int ec_fsm_eoe_exec(
return datagram_used;
}
/*****************************************************************************/
/****************************************************************************/
/** Returns, if the state machine terminated with success.
*
@@ -142,9 +134,9 @@ int ec_fsm_eoe_success(const ec_fsm_eoe_t *fsm /**< Finite state machine */)
return fsm->state == ec_fsm_eoe_end;
}
/******************************************************************************
/*****************************************************************************
* EoE set IP parameter state machine
*****************************************************************************/
****************************************************************************/
/** Prepare a set IP parameters operation.
*
@@ -243,7 +235,7 @@ int ec_fsm_eoe_prepare_set(
return 0;
}
/*****************************************************************************/
/****************************************************************************/
/** EoE state: SET IP START.
*/
@@ -271,7 +263,7 @@ void ec_fsm_eoe_set_ip_start(
fsm->state = ec_fsm_eoe_set_ip_request;
}
/*****************************************************************************/
/****************************************************************************/
/** EoE state: SET IP REQUEST.
*/
@@ -323,7 +315,7 @@ void ec_fsm_eoe_set_ip_request(
fsm->state = ec_fsm_eoe_set_ip_check;
}
/*****************************************************************************/
/****************************************************************************/
/** EoE state: SET IP CHECK.
*/
@@ -376,7 +368,7 @@ void ec_fsm_eoe_set_ip_check(
fsm->state = ec_fsm_eoe_set_ip_response;
}
/*****************************************************************************/
/****************************************************************************/
/** EoE state: SET IP RESPONSE.
*/
@@ -457,7 +449,7 @@ void ec_fsm_eoe_set_ip_response(
}
}
/*****************************************************************************/
/****************************************************************************/
/** State: ERROR.
*/
@@ -468,7 +460,7 @@ void ec_fsm_eoe_error(
{
}
/*****************************************************************************/
/****************************************************************************/
/** State: END.
*/
@@ -479,4 +471,4 @@ void ec_fsm_eoe_end(
{
}
/*****************************************************************************/
/****************************************************************************/

View File

@@ -1,6 +1,4 @@
/*****************************************************************************
*
* $Id$
*
* Copyright (C) 2006-2014 Florian Pose, Ingenieurgemeinschaft IgH
*
@@ -19,12 +17,6 @@
* with the IgH EtherCAT Master; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*
* ---
*
* The license mentioned above concerns the source code only. Using the
* EtherCAT technology and brand is only permitted in compliance with the
* industrial property and similar rights of Beckhoff Automation GmbH.
*
****************************************************************************/
/**

View File

@@ -1,6 +1,4 @@
/*****************************************************************************
*
* $Id$
*
* Copyright (C) 2006-2014 Florian Pose, Ingenieurgemeinschaft IgH
*
@@ -19,12 +17,6 @@
* with the IgH EtherCAT Master; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*
* ---
*
* The license mentioned above concerns the source code only. Using the
* EtherCAT technology and brand is only permitted in compliance with the
* industrial property and similar rights of Beckhoff Automation GmbH.
*
* vim: expandtab
*
****************************************************************************/
@@ -40,14 +32,14 @@ using namespace std;
#include "CommandIp.h"
#include "MasterDevice.h"
/*****************************************************************************/
/****************************************************************************/
CommandIp::CommandIp():
Command("ip", "Set EoE IP parameters.")
{
}
/*****************************************************************************/
/****************************************************************************/
string CommandIp::helpString(const string &binaryBaseName) const
{
@@ -155,7 +147,7 @@ void CommandIp::execute(const StringVector &args)
}
}
/*****************************************************************************/
/****************************************************************************/
void CommandIp::parseMac(unsigned char mac[EC_ETH_ALEN], const string &str)
{
@@ -188,7 +180,7 @@ void CommandIp::parseMac(unsigned char mac[EC_ETH_ALEN], const string &str)
}
}
/*****************************************************************************/
/****************************************************************************/
void CommandIp::parseIpv4Prefix(ec_ioctl_slave_eoe_ip_t *io,
const string &str)
@@ -223,7 +215,7 @@ void CommandIp::parseIpv4Prefix(ec_ioctl_slave_eoe_ip_t *io,
resolveIpv4(&io->ip_address, host);
}
/*****************************************************************************/
/****************************************************************************/
void CommandIp::resolveIpv4(uint32_t *addr, const string &str)
{

View File

@@ -1,6 +1,4 @@
/*****************************************************************************
*
* $Id$
*
* Copyright (C) 2006-2014 Florian Pose, Ingenieurgemeinschaft IgH
*
@@ -19,12 +17,6 @@
* with the IgH EtherCAT Master; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*
* ---
*
* The license mentioned above concerns the source code only. Using the
* EtherCAT technology and brand is only permitted in compliance with the
* industrial property and similar rights of Beckhoff Automation GmbH.
*
****************************************************************************/
#ifndef __COMMANDIP_H__