equal
deleted
inserted
replaced
184 UNS8 offset; |
184 UNS8 offset; |
185 UNS8 status; |
185 UNS8 status; |
186 UNS32 objDict; |
186 UNS32 objDict; |
187 UNS16 offsetObjdict; |
187 UNS16 offsetObjdict; |
188 UNS16 lastIndex; |
188 UNS16 lastIndex; |
|
189 TIMEVAL EventTimerDuration = 0; |
189 |
190 |
190 status = state2; |
191 status = state2; |
191 |
192 |
192 MSG_WAR (0x3935, "proceedPDO, cobID : ", (UNS16_LE(m->cob_id) & 0x7ff)); |
193 MSG_WAR (0x3935, "proceedPDO, cobID : ", (UNS16_LE(m->cob_id) & 0x7ff)); |
193 offset = 0x00; |
194 offset = 0x00; |
218 */ |
219 */ |
219 if (*pwCobId == UNS16_LE(m->cob_id)) |
220 if (*pwCobId == UNS16_LE(m->cob_id)) |
220 { |
221 { |
221 /* The cobId is recognized */ |
222 /* The cobId is recognized */ |
222 status = state4; |
223 status = state4; |
|
224 EventTimerDuration = *(UNS16 *)d->objdict[offsetObjdict].pSubindex[5].pObject; |
223 MSG_WAR (0x3936, "cobId found at index ", |
225 MSG_WAR (0x3936, "cobId found at index ", |
224 0x1400 + numPdo); |
226 0x1400 + numPdo); |
225 break; |
227 break; |
226 } |
228 } |
227 else |
229 else |
301 ((*pMappingParameter) >> 8) & 0xFF); |
303 ((*pMappingParameter) >> 8) & 0xFF); |
302 offset += Size; |
304 offset += Size; |
303 } |
305 } |
304 numMap++; |
306 numMap++; |
305 } /* end loop while on mapped variables */ |
307 } /* end loop while on mapped variables */ |
306 |
308 if (EventTimerDuration && d->RxPDO_EventTimers) |
|
309 { |
|
310 DelAlarm (d->RxPDO_EventTimers[numPdo]); |
|
311 d->RxPDO_EventTimers[numPdo] = SetAlarm (d, numPdo, d->RxPDO_EventTimers_Handler, |
|
312 MS_TO_TIMEVAL (EventTimerDuration), 0); |
|
313 } |
307 return 0; |
314 return 0; |
308 |
315 |
309 } /* end switch status */ |
316 } /* end switch status */ |
310 } /* end while */ |
317 } /* end while */ |
311 } /* end if Donnees */ |
318 } /* end if Donnees */ |
600 /* This is needed to avoid deletion of re-attribuated timer */ |
607 /* This is needed to avoid deletion of re-attribuated timer */ |
601 d->PDO_status[pdoNum].inhibit_timer = TIMER_NONE; |
608 d->PDO_status[pdoNum].inhibit_timer = TIMER_NONE; |
602 /* Remove inhibit flag */ |
609 /* Remove inhibit flag */ |
603 d->PDO_status[pdoNum].transmit_type_parameter &= ~PDO_INHIBITED; |
610 d->PDO_status[pdoNum].transmit_type_parameter &= ~PDO_INHIBITED; |
604 sendOnePDOevent (d, (UNS8) pdoNum); |
611 sendOnePDOevent (d, (UNS8) pdoNum); |
|
612 } |
|
613 |
|
614 void |
|
615 _RxPDO_EventTimers_Handler(CO_Data *d, UNS32 pdoNum) |
|
616 { |
605 } |
617 } |
606 |
618 |
607 /*! |
619 /*! |
608 ** |
620 ** |
609 ** |
621 ** |