so this is a video you're going to show to the people before they go out to the breakout rooms or before they start doing this experiment number one and the idea here is let's understand how all the things are connected together this right here is the encoder and the job of the encoder is to get the angle which the disc has moved and relay that information to Arduino and Arduino's job is to okay this is the angle and based on how much voltage should I be giving to the motor and the Arduino does that in two stages. First, whatever voltage we have to give to the motor, it's encoded and sent to this guy, which is a digital-to-analog converter. And this digital-to-analog converter is going to take that information of the voltage and convert into the actual voltage.
And that goes on to this motor controller. And the motor controller's job is to provide the real voltage to the motor over here. And there's a power supply over here, which is going to...
volt power supply and based on the signal provided a fraction of that 24 voltage supply is going to go through the motor so let's understand the connection right from the sensor part so this is already in your diagram in the lab handout but there are two channels of this encoder and each of those channels send a tick of voltage whenever the disc moved by a particular angle so this is thousand counts per rotation I will this is thousand counts per rotation but otherwise you can check into the lab handout so every time the disc moves 1,000th of a rotation you'll send a volt these things this channel A and B over there will send a voltage check so they are slightly at a phase different from each other and these are two wires for channel A and B and they are connected to pin number two and pin number three of Arduino over there but to power that device to power that angle encoder you need to give it some voltage and that is five voltage and ground so the the ground wire of that is right here and that's connected to this one channel there's a whole channel which is a ground channel so the ground of this is connected to the ground channel and similarly the five volt is which is used to power this thing is connected over here but ultimately the five volt is coming from arduino so arduino has a five volt line over here that five load line is going going and that same 5 volt line coming from arduino is powering this guy and that 5 volt is also powering my digital to analog converter cool so arduino's 5 volt goes both to this and both there that signal is complete next step is let's see how arduino is going to give voltage to this digital to analog converter okay um there is there are two pins on arduino which are scl and sta those are the pins which we use to send data to the digital to analog converter and they stand for something for example scl stands for serial clock and sta is the data line so it needs a clock data clock signal to time with arduino and the data line is going to send the actual information so the arduino's job is to communicate how much voltage you need to send and that voltage is sent through the data channel so sta of arduino is connected to the sta pin over there and scl of arduino the senior serial clock is connected to the serial clock over here okay so that's good um and also once again to power this device you need to give it five volt which is ultimately coming from arduino and also along with the five volt it has to be ground so there's a ground pin over there and the ground is connected to the ground channel and the ground of arduino is also connected to this whole ground channel so everything is at the same ground now the only job left for us is to give information to the motor so this digital to analog converter is going to give there's a v out pin over here it's like v ou pin that's where it sends the signal to the motor controller and then once again the motor controller needs grounding along with that signal so that ground is that first channel and similarly there's another ground channel also so those are the wires the motor signal goes here from the v out and then the two grounds for the motor are connected with the ground channel over here on the motor controller we have these two wires over here the purple one in this case and the green one these are the wires coming from the 24 volt supply over here so these ones they are the input to the motor controller this is where all the voltage is coming from and this is where the signal is coming to the motor controller and based on that signal it decides what what fraction of that 24 volt should be given to the motor. And how is that voltage given to the motor? Through these two wires coming all the way here. And this fancy little thing is a power resistor. It's a resistor of really small value, 0.01 ohm, but it is super accurate.
We use this to measure the voltage. And we'll talk about that when the time comes. But this is where, this is 24 volt supply coming in.
And the output to the motor is coming through these two wires. And signal. which tells you what fraction is going to come from this tissue.
So those are all the wires. And if you guys have any questions, ask them. And we'll stop here.