![]() ![]() ![]() ![]() ![]() ![]() |
||
![]() |
||
![]() ![]() ![]() ![]() This board is for PLC Related Q&A ONLY. Please DON'T use it for advertising, etc. |
||
![]() |
![]() |
#1 |
Member
![]() ![]() Join Date: Feb 2010
Location: Multan
Posts: 369
|
Data types
Hi friends;
i am confusing with GE funac. In rslogix we can define when create a tag style and data types. In ge i want to declare constants and i am unable to understand the registers. If i enter %r0001=11820 is it use only %R0001 or use %R0001 and R0002? is the data types define any where? or system it self choose the how many register occupy to see the value? If any one have example to use registers and documant about it in which explain with eaxples i am very thankful and pray for him. Regards |
![]() |
![]() |
#2 |
Lifetime Supporting Member
![]() ![]() Join Date: Mar 2008
Location: Kansas City
Posts: 245
|
|
![]() |
![]() |
#3 | |
Lifetime Supporting Member + Moderator
|
Unlike Rockwell, GE does not define separate areas of memory for Integers, Double Integers, Floats, Timers, or Counters. Instead GE defines %R memory for all numeric data.
A %R address defines a 16-bit memory location. When you need to do calculations in double integer or floating point, the PLC will automatically use two consecutive %R locations, the one you implicitly define when you assign an address to the variable plus the next higher %R address. When you define a variable as INT, that means the variable uses one %R address. When you define a variable as DINT or REAL, it uses two %R addresses. When you create a timer or counter, you automatically allocate three consecutive %R addresses. Quote:
|
|
![]() |
![]() |
#4 |
Member
![]() ![]() Join Date: Feb 2010
Location: Multan
Posts: 369
|
HI;
"When u define a variable as INT " How can i define it? Plz guide me. I know it is very basic but i do not know how to define in GE? Regards |
![]() |
![]() |
#5 |
Lifetime Supporting Member + Moderator
|
For an existing variable, look under properties for that variable. When you are creating a new variable you are given a choice. If you drop an instruction into ladder logic and then type in an address for which no variable already exists, the variable typr will be chosen based on the type of instruction you are applying it to. For example, if you are filling out a MUL_INT instruction, all new variables created for that instruction will automatically be INTs. If it a MUL_REAL instruction, all new variables will be REALs.
It is up to you as the programmer to be careful that you don't overlap register addresses when you create new varaibles. If there is already a DINT variable that uses %R101 and %R102, then don't create a new INT addressed to %R102. As I have previously, I suggest you experiment on your bench system to familiarize yourself with the way GE handles these things. Deliberatly overlap addresses on the bench system so you can observe the behavior and be able to recognize similar symptoms on an actual system. |
![]() |
![]() |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
Thread Tools | |
Display Modes | |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
initialize (or erase the data in) User-defined data types - RSLogix 5000 | ViperDaSnake | LIVE PLC Questions And Answers | 14 | October 17th, 2018 08:04 PM |
Vijeo Citect - Modicon M340 DDT (Derived Data Types) | majorv | LIVE PLC Questions And Answers | 2 | April 29th, 2009 06:34 PM |
FiFo data types | coopdegrace | LIVE PLC Questions And Answers | 1 | March 18th, 2009 04:21 AM |
S7 Data types | coopdegrace | LIVE PLC Questions And Answers | 3 | March 9th, 2009 04:37 AM |
Data types - which to use? | simple_mind | LIVE PLC Questions And Answers | 8 | September 6th, 2006 08:08 PM |