Omron floating Data Format

Soggy Canuck

Lifetime Supporting Member
Join Date
Jan 2008
Location
Vancouver
Posts
229
I'm banging my head on a wall here, and I suspect this is going to involve a "how could I have missed that" when I find the solution.

To my problem: Omron CJ1M with a MAD42 module. Using a 0-10V signal from the machine main drive to generate two separate follower signals. Each of the followers has a separate adjustment from two potentiometers feeding additional analog input channels of the MAD module. I worked out some basic math to use the potentiometer inputs to generate a percentage of the main drive analog signal and feed this into the 2 analog output channels.
The math worked like a charm but the output was not suitable to the machine requirements.

Enter the APR instruction. I set up a pair of these to reshape the 0-10V main drive signal to suit the follower equipment requirements.

Here's where it went sideways on me.

The output of the APR instruction was dropped into a DM set to Channel(HEX). Monitoring this it shows up as a hex value, but when looking at the DM as it enters the basic math section its showing up as a Signed Decimal Value.

How do I force the value to stay in hex? It enters a FLT instruction as a "+XXXX" value) and the instruction will not process.
 
It does not matter if you choose HEX or not - that is basically a monitoring function for that instruction. If the instruction puts out signed decimal that is what it is although you can monitor it in HEX. Why do you need to use FLT? just moved the signed decimal to the output channel but make sure the numbers are within the range of the output module eg. 0-6000 decimal. The APR function is a beauty and many PLCs do not have an equivalent.
 
I'm converting the APR O/P to Float so I am able to still incorporate the potentiometer signal as an external adjuster. This is on a coldset newspaper press where the ink and water feeds will vary with time of day, length of run, and paper type making setting precise values into the APR problematic at best.
 
If it is an integer it is all good - FLT D2000(INT) D3000(FLT) works. I use it all the time.
 

Similar Topics

Gents, We had to replace an CJ1G cpu for an CJ2M to get an Ethernet port on a machine. I uploaded the PLC program including memory area, and...
Replies
18
Views
5,131
Hi all, I'm not able to multiply decimal values in OMRON PLC CP1E-N20 I would like multiply one constant (+0.125)(multiplier) and one variable...
Replies
5
Views
4,828
I am trying to display a floating point number on an NT631c. PLC is a CJ1M. I have allocated the floating point number to D112 and set the screen...
Replies
4
Views
2,470
I would like to move a floating point value to a Data Memory area in an Omron CP1H. One might ask why? Because I can not enter a value directly...
Replies
7
Views
6,444
Dear All, I’m looking for ways to convert floating point value to BCD for OMRON C200HG CPU43 PLC. From instruction reference of CX-Programmer...
Replies
5
Views
8,877
Back
Top Bottom