Jump to content

Entrada digital (1 ó 0) convertirla a un grafico de nivel


Recommended Posts

Hola a todos, necesitaría que me dijeran cómo hago para que una entrada física digital de (1 ó 0) en un vision 350 pueda representarla en un gráfico de barra de nivel. Los gráficos de barra de nivel son MI donde el mínimo es 0 y el máximo es 1. Yo quiero que cuando la entrada digital sea 1 aparezca el gráfico lleno y cuando la entrada digital sea 0 el gráfico aparezca vacío.

esto sé hacerlo con entrada analógica pero con entrada digital no.

quisiera saber cómo se linealiza una entrada digital (I8) y representarla como máximo 1 y mínimo 0 en gráfico de barra de nivel

 

 

Link to comment
Share on other sites

  • MVP 2023

Translate...

Hello everyone, I would need you to tell me how I can represent a digital physical input of (1 or 0) in a vision 350 in a level bar graph. The level bar graphs are MI where the minimum is 0 and the maximum is 1. I want that when the digital input is 1 the graph appears full and when the digital input is 0 the graph appears empty. I know how to do this with analog input but not with digital input. I would like to know how a digital input (I8) is linearized and represent it as a maximum of 1 and a minimum of 0 in a level bar graph

Link to comment
Share on other sites

Gracias Kramle, pero al final lo he hecho con un pulsador detransición positiva y un bloque de incremento, luego reseteo con un contacto normalmente cerrado de I8 a reset numérico de MI del bloque de incremento

dime qué opción cojo o te parece mejor????

Link to comment
Share on other sites

  • MVP 2023

In general, both options are equivalent, but if you use a pulse signal for incrementing, you should note that the number of these pulse signals in the program is limited (less than 255).

I can offer you another option

36.jpg.3987fb33303b3b555705bef0fecb6295.jpg

but I always lean towards a solution that uses fewer lines of code

Link to comment
Share on other sites

Al final me decanto por la opción que me dijistes al principio, convierto bit a numérico, me funciona bastante bien, por eso que me dices de los pulsos positivos (hasta 255).

esta última opción de almacenar es muy simplificada está genial pero me aconsejas no utilizar más lineas de codigo.

Al final convierto bit a numérico, todo perfecto, gracias.

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...