uint32 Ibytes;
/** input pointer in IOmap buffer */
uint8 *inputs;
- /** has DC capabillity */
+ /** has DC capability */
boolean hasdc;
/** next DC slave */
uint16 DCnext;
dowkccheck = 0;
if (ctx.slavelist[0].hasdc && (wkc > 0))
{
- /* calulate toff to get linux time and DC synced */
+ /* calculate toff to get linux time and DC synced */
ec_sync(ctx.DCtime, cycletime, &toff);
}
ecx_mbxhandler(&ctx, 0, 4);
{
if (inOP && ((dowkccheck > 2) || ctx.grouplist[currentgroup].docheckstate))
{
- /* one ore more slaves are not responding */
+ /* one or more slaves are not responding */
ctx.grouplist[currentgroup].docheckstate = FALSE;
ecx_readstate(&ctx);
for (slaveix = 1; slaveix <= ctx.slavecount; slaveix++)
needlf = FALSE;
printf("\n");
}
- /* one ore more slaves are not responding */
+ /* one or more slaves are not responding */
ctx.grouplist[currentgroup].docheckstate = FALSE;
ecx_readstate(&ctx);
for (slaveix = 1; slaveix <= ctx.slavecount; slaveix++)
/* Set the HOOK */
ecx_EOEdefinehook(context, eoe_hook);
- /* Create a asyncronous EoE reader */
+ /* Create an asynchronous EoE reader */
osal_thread_create(&thread2, 128000, &mailbox_writer, context);
}
needlf = FALSE;
printf("\n");
}
- /* one ore more slaves are not responding */
+ /* one or more slaves are not responding */
ctx.grouplist[currentgroup].docheckstate = FALSE;
ecx_readstate(&ctx);
for (slaveix = 1; slaveix <= ctx.slavecount; slaveix++)
if (ctx.slavelist[0].hasdc)
{
- /* calulate toff to get linux time and DC synced */
+ /* calculate toff to get linux time and DC synced */
ec_sync(ctx.DCtime, cycletime, &toff);
}
ecx_send_processdata(&ctx);
needlf = FALSE;
printf("\n");
}
- /* one ore more slaves are not responding */
+ /* one or more slaves are not responding */
ctx.grouplist[currentgroup].docheckstate = FALSE;
ecx_readstate(&ctx);
for (slaveix = 1; slaveix <= ctx.slavecount; slaveix++)
grp->Obytes, grp->Ibytes, grp->nsegments);
if (grp->nsegments > 1)
{
- /* Show how slaves are distrubuted */
+ /* Show how slaves are distributed */
for (i = 0; i < grp->nsegments; ++i)
{
printf("%s%d", i == 0 ? " (" : "+", grp->IOsegment[i]);
needlf = FALSE;
printf("\n");
}
- /* one ore more slaves are not responding */
+ /* one or more slaves are not responding */
ctx.grouplist[currentgroup].docheckstate = FALSE;
ecx_readstate(&ctx);
for (slaveix = 1; slaveix <= ctx.slavecount; slaveix++)
* @param[in] ADO = Address Offset
* @param[in] length = length of datagram excluding EtherCAT header
* @param[in] data = databuffer to be copied in datagram
- * @return Offset to data in rx frame, usefull to retrieve data after RX.
+ * @return Offset to data in rx frame, useful to retrieve data after RX.
*/
uint16 ecx_adddatagram(ecx_portt *port, void *frame, uint8 com, uint8 idx, boolean more, uint16 ADP, uint16 ADO, uint16 length, void *data)
{
pODlist->Entries = 0;
MbxIn = NULL;
MbxOut = NULL;
- /* Empty slave out mailbox if something is in. Timout set to 0 */
+ /* Empty slave out mailbox if something is in. Timeout set to 0 */
wkc = ecx_mbxreceive(context, Slave, &MbxIn, 0);
if (MbxIn) ecx_dropmbx(context, MbxIn);
MbxOut = ecx_getmbx(context);
pODlist->Name[Item][0] = 0;
MbxIn = NULL;
MbxOut = NULL;
- /* Empty slave out mailbox if something is in. Timout set to 0 */
+ /* Empty slave out mailbox if something is in. Timeout set to 0 */
wkc = ecx_mbxreceive(context, Slave, &MbxIn, 0);
if (MbxIn) ecx_dropmbx(context, MbxIn);
MbxOut = ecx_getmbx(context);
Index = pODlist->Index[Item];
MbxIn = NULL;
MbxOut = NULL;
- /* Empty slave out mailbox if something is in. Timout set to 0 */
+ /* Empty slave out mailbox if something is in. Timeout set to 0 */
wkc = ecx_mbxreceive(context, Slave, &MbxIn, 0);
if (MbxIn) ecx_dropmbx(context, MbxIn);
MbxOut = ecx_getmbx(context);
MbxIn = NULL;
MbxOut = NULL;
- /* Empty slave out mailbox if something is in. Timout set to 0 */
+ /* Empty slave out mailbox if something is in. Timeout set to 0 */
wkc = ecx_mbxreceive(context, slave, &MbxIn, 0);
MbxOut = ecx_getmbx(context);
ec_clearmbx(MbxOut);
* @param[in] context = Context struct
* @param[in] slave = Slave number
* @param[in] port = Port number on slave if applicable
- * @param[out] ipparam = IP parameter data retrived from slave
+ * @param[out] ipparam = IP parameter data retrieved from slave
* @param[in] timeout = Timeout in us, standard is EC_TIMEOUTRXM
* @return Workcounter from last slave response or returned result code
*/
MbxIn = NULL;
MbxOut = NULL;
- /* Empty slave out mailbox if something is in. Timout set to 0 */
+ /* Empty slave out mailbox if something is in. Timeout set to 0 */
wkc = ecx_mbxreceive(context, slave, &MbxIn, 0);
MbxOut = ecx_getmbx(context);
ec_clearmbx(MbxOut);
frameinfo1 = etohs(aEOEp->frameinfo1);
frameinfo2 = etohs(aEOEp->frameinfo2);
- /* Retrive fragment number, is it what we expect? */
+ /* Retrieve fragment number, is it what we expect? */
if (*rxfragmentno != EOE_HDR_FRAG_NO_GET(frameinfo2))
{
/* If expected fragment number is not 0, reset working variables */
buffersize = *psize;
MbxIn = NULL;
MbxOut = NULL;
- /* Empty slave out mailbox if something is in. Timout set to 0 */
+ /* Empty slave out mailbox if something is in. Timeout set to 0 */
wkc = ecx_mbxreceive(context, slave, &MbxIn, 0);
MbxOut = ecx_getmbx(context);
ec_clearmbx(MbxOut);
MbxIn = NULL;
MbxOut = NULL;
- /* Empty slave out mailbox if something is in. Timout set to 0 */
+ /* Empty slave out mailbox if something is in. Timeout set to 0 */
wkc = ecx_mbxreceive(context, slave, &MbxIn, 0);
MbxOut = ecx_getmbx(context);
ec_clearmbx(MbxOut);
/** Read OUT mailbox from slave.
* Supports Mailbox Link Layer with repeat requests.
* Mailbox is fetched from pool, caller is owner after return
- * and therefore should drop it back to the pool whe finished.
+ * and therefore should drop it back to the pool when finished.
* @param[in] context = context struct
* @param[in] slave = Slave number
* @param[out] mbx = Double pointer to mailbox data
MbxIn = NULL;
MbxOut = NULL;
- /* Empty slave out mailbox if something is in. Timout set to 0 */
+ /* Empty slave out mailbox if something is in. Timeout set to 0 */
wkc = ecx_mbxreceive(context, slave, &MbxIn, 0);
MbxOut = ecx_getmbx(context);
ec_clearmbx(MbxOut);
MbxIn = NULL;
MbxOut = NULL;
- /* Empty slave out mailbox if something is in. Timout set to 0 */
+ /* Empty slave out mailbox if something is in. Timeout set to 0 */
wkc = ecx_mbxreceive(context, slave, &MbxIn, 0);
hp = p;
maxdata = context->slavelist[slave].mbx_l - sizeof(ec_SoEt);