取消
显示结果 
搜索替代 
您的意思是: 

Multiplexer 4051 on Labview

Hi,

I have a project to measure the voltage of 20 cells of a battery. I use an arduino uno but it has only 6 analog inputs. So, i use two analog multiplexer 4051 to extend the analog inputs and i want to display the results on LabView. My problem is that i don't know how to use the 4051 on Labview to display the 20 values of the cells. Thank you.

0 项奖励
1 条消息(共 9 条)
5,087 次查看

Do you have the 4051 mux hardware operaing? 

 

Have you read this? Ardunio Playground Analog Multiplexer/Demultiplexer - 4051

 

You need to use three of the Arduio digital pins to address the 4051 and one pin to select direction (you could just tie this pin to +5 or Gnd as needed)

 

 

========================
=== Engineer Ambiguously ===
========================
0 项奖励
2 条消息(共 9 条)
5,076 次查看

Yes I read it. I simulated it with Proteus and I wrote the code on arduino and it works. Do I have to create a multiplexer on LabView ? Because I created one on Labview before but I didn't know how to connect the pin.

0 项奖励
3 条消息(共 9 条)
5,073 次查看

All you really need to do is address the 4051 with three digital pins and read the voltage passed through on an analog pin

 

Lets say you have the output 4051 (z) on analog pin 1 and are using D0,D1,D2 for addressing

 

If want to read the voltage on 4051 input y2

 

First write 0 to D0, 1 to D1 and 0 to D3

 

Then read the voltage on Analog pin1

 

I would create a typeDef and sub VI that would take care of all the addressing and read.

 

On closer inspection I see there is no direction pin on the 4051, the E pin is an enable low so just tie it to ground unless you need  to use more than one 4051 on the same analog pin of the Arduino

 

========================
=== Engineer Ambiguously ===
========================
0 项奖励
4 条消息(共 9 条)
5,059 次查看
How can I read 8 voltages ? analogRead of the arduino on LabView had only one output voltage. Do i have to modify the subVi of the analogRead.vi ?
0 项奖励
5 条消息(共 9 条)
5,042 次查看
You read 8 voltages by setting the mux for 8 different patterns and taking a read each time. This is done inside a loop and you save each read In an array. Or, write your sketch to generate the 8 patterns and the analog read and return the array to LabVIEW. Your choice.
0 项奖励
6 条消息(共 9 条)
5,035 次查看

It sounds as though your electronic skills may be limited. Are you sure that your voltages from the battery never exceed the input ratings of the 4051?  It is a nice device but is not very robust when it comes to overvoltage! You could also damage your Arduino if you are not careful!

 

Lynn

0 项奖励
7 条消息(共 9 条)
5,028 次查看
I use an amplifier and a voltage divider to reduce the voltage. Thank you very much for the help 🙂
0 项奖励
8 条消息(共 9 条)
5,022 次查看

 

@bigboss2582 wrote:
How can I read 8 voltages ? analogRead of the arduino on LabView had only one output voltage. Do i have to modify the subVi of the analogRead.vi ?

Do you understand what the 4051 chip is and does? Have you read the 4051 data sheet?

 

Think of it as an eight input  binary controled selector switch.

 

You select an input and measure that input with one analog pin.

 

========================
=== Engineer Ambiguously ===
========================
0 项奖励
9 条消息(共 9 条)
4,985 次查看