cancel
Showing results for 
Search instead for 
Did you mean: 
SOLVED

Analog value change in the PLC only every 4ms instead of 2ms

Analog value change in the PLC only every 4ms instead of 2ms

V_A
Established Member

Hello,

I am executing a task in the PLC on the CtrlX7. This runs cyclically with 1ms. In the task, an analog sensor is used. The problem is that I only get a value change in my trace every 4ms. The task is actually executed every 1ms. The EtherCat has a cycle time of 2ms. Therefore I would expect a value change at least every 2ms. I have this behavior with two sensors, so I exclude the sensors and the PLC task. How is the data written to the data layer? Is there a delay here? Why is it exactly twice the cycle time of EtherCat?

6 REPLIES 6

cc2go
Occasional Contributor

Hello, which kind / type/ brand of analoge IO are you using? Is it a Bosch Rexroth IO, then plase share the type plate / firmware version from CoE data.

Normally, based on the IO refresh time and if its a free running (2 cycles) or sync module (1 cycle/ every cycle) you can expect.

V_A
Established Member

I am using an analog input card XI312204 from Boschrexroth.

What exactly do you mean by the modules and can that be adjusted?

I have attached pictures of the settings in IO engineering

cc2go
Occasional Contributor

I don't see the online view of the CoE, you shared offline data, I assume you have v1.0.2, in the ctrlX IO we did some optimizations, please see our download section for latest firmware. It's 1.2.x please update and check timing again. You can do via FoE download.

Timing depend on hardware internal processing time, this cannot be adjusted, hardware dependend

V_A
Established Member

When I look at the Ethercatmaster information, it seems to be the current version. Here are the online data.

cc2go
Occasional Contributor

you see in the CoE software version 1.0.0, the old one, please update to 1.2.0

cc2go
Occasional Contributor

@V_A one additional info, when you use in the PLC task the TASK_EXTERNAL_EVENT, the external event need to be added in the scheduler as well, than you will get each EtherCAT cycle a new value. But keep in mind the PLC task is now coupled to the external event, when this doesn't run, the PLC task doesn't run too.

What to do is explained in the following How-To

https://developer.community.boschrexroth.com/t5/Store-and-How-to/CODESYS-Softmotion-How-to-configure...

Icon--AD-black-48x48Icon--address-consumer-data-black-48x48Icon--appointment-black-48x48Icon--back-left-black-48x48Icon--calendar-black-48x48Icon--center-alignedIcon--Checkbox-checkIcon--clock-black-48x48Icon--close-black-48x48Icon--compare-black-48x48Icon--confirmation-black-48x48Icon--dealer-details-black-48x48Icon--delete-black-48x48Icon--delivery-black-48x48Icon--down-black-48x48Icon--download-black-48x48Ic-OverlayAlertIcon--externallink-black-48x48Icon-Filledforward-right_adjustedIcon--grid-view-black-48x48IC_gd_Check-Circle170821_Icons_Community170823_Bosch_Icons170823_Bosch_Icons170821_Icons_CommunityIC-logout170821_Icons_Community170825_Bosch_Icons170821_Icons_CommunityIC-shopping-cart2170821_Icons_CommunityIC-upIC_UserIcon--imageIcon--info-i-black-48x48Icon--left-alignedIcon--Less-minimize-black-48x48Icon-FilledIcon--List-Check-grennIcon--List-Check-blackIcon--List-Cross-blackIcon--list-view-mobile-black-48x48Icon--list-view-black-48x48Icon--More-Maximize-black-48x48Icon--my-product-black-48x48Icon--newsletter-black-48x48Icon--payment-black-48x48Icon--print-black-48x48Icon--promotion-black-48x48Icon--registration-black-48x48Icon--Reset-black-48x48Icon--right-alignedshare-circle1Icon--share-black-48x48Icon--shopping-bag-black-48x48Icon-shopping-cartIcon--start-play-black-48x48Icon--store-locator-black-48x48Ic-OverlayAlertIcon--summary-black-48x48tumblrIcon-FilledvineIc-OverlayAlertwhishlist