Multiplexer #3 - Digital and Analog Inputs

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
okay now imagine that here I need to add buttons so the multiplexer can read both digital and analog pins the same multiplexer okay I'm going to remove a module here replace it here okay we need to just check that we are correctly installing our module the positive and negative pins are these two and they will go there okay as you can see they are correctly installed you let's put screws on it okay connect it in Z okay this program already has the moves from the previous program on pin enable 17 the data pins are 9 10 11 and 12 and instead of initializing the multiplexer on the setup function we won't use this here and we will use it before cycling the multiplexer addresses ok the first addresses are analog and that is because we are using these common here to declare that from now on we will read analog signals the next addresses are digital ok and here we don't need to use the analog and instead of a 1 let's put the digital pin number it's the 16 and starts 4 and if it's less than 8 and for the rest the rest we will come back to analog and starts in eight and if it's less than 16 as you can see we are going through each one of the multiplexer address from 0 to 3 it's analog printed from 4 to 8 they are digital and then they are analog again okay nothing is happening oh the buttons are there but not the potentiometers and that is because in 1716 zero otherwise okay it's the a2 and not the a1 a2 applaud it and on the first four addresses we have four analog inputs then we have the button inputs and all the others are analog inputs again as you can see it's quite easy to work with and again this is the same for the Arduino we are using tin Z but Arduino users this is the same if you prefer to use an Arduino ok guys hope this video was useful if you have any questions just drop us a line in the comments below see you next time
Info
Channel: Making Stuff by Guilherme Martins
Views: 2,601
Rating: undefined out of 5
Keywords: multiplexer, arduino, teensy, 74HC4067, inputs, sensors, buttons, digital, analog, make, maker, diy, module, modular, electronics, interface, lesson, beginner, howto
Id: JwD_pATeySc
Channel Id: undefined
Length: 5min 19sec (319 seconds)
Published: Sat Jan 18 2020
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.