Reusing Vacuum Fluorescent Displays (MSM9202-01)

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
hi guys so today I want to focus on these vacuum fluorescent displays or VFDs for short and these have a nice vintage or retro look to them which makes them very appealing however you just don't find these commonly anymore in modern equipment LCDs and LED displays are replacing these very frequently however in older equipment these are pretty common and it would be nice to know how to connect to them or how to reverse engineer them right and that's what I'm gonna be talking about in this video I'm just going to focus on a practical approach on how to both talk to the display but also talk to maybe the chip that's also on the board when you take these out of equipment you frequently find a chip right next to the display that's you know purposely built to drive the display and in it's often much easier to drive the chip than to drive the display directly with your own built interface and we'll see why it's easier to do that in a second but I'll be focusing on both of those things in this video so I think will be beneficial to quickly go over how a vacuum fluorescent display works and it pretty much works exactly like a triode vacuum tube and so you have what you would expect a filament where the electrons start off a grid which either allows the electrons to pass or doesn't allow it to pass and an anode where the electrons ultimately want to get to and they want to get to our segments so our segments are covered in a phosphor and so when the electrons hit our segments they glow now in order to make sure our electrons get to our anode or our segments we have to make sure that our grid and our anode are positively charged and that's how we attract the electrons from here from the filament through the grid and to our segments and allow our segments to glow so even before we get to talking about the display itself and the chip that drives it we have to talk about the voltages that are required to power the display and so the display requires you to power its filament and also to drive its segment and digit pins so what that requires is an AC voltage here to drive the filament and I'm using four volts as you can see four volts AC to drive the filament but that drops to a little bit below three volts and what I usually do is when I apply the voltage to the filament I see if the filament glows red and if it does I add a resistor to make sure that it doesn't burn out you don't want that filament burning out so here we have a DC voltage source and as you can see I have 40 volts on that line but I also added a resistor divider so I could use 20 volts and so I have the option between 20 and 40 but really it all depends on the display because that is if the display is physically bigger then it will require obviously a larger filament voltage in a larger driver voltage for the segments and the digits but it all depends you have to check for yourself and see what works or consult the datasheet if you find it so generally speaking the range for the AC voltage to power the filament is like 2 to 5 volts usually for these types of displays and the DC range for the other supply to power the segments and the digit pins is usually 10 to 60 volts so I'm going to be talking about this display first and this is just to show you how to identify pin outs on the bare display and so usually what you start with is powering up the filament and the filaments are very thin wires that stretch across the entire display like this and you can see them you can just barely make them out and because they're stretched along the display like this lengthwise you'll notice that there's two two sets of pins here on either end that are well you know different from the rest of the center pins there they're kind of spaced apart and these of course are very easy to identify as the filament pins and the two pins are connected together so it's just one giant lead so now I have my four volts AC connected over to those pins driving the filament and if I turn off the lights we can try to see if the filament is glowing now normally if you see the filament glowing that's a bad sign but I'm gonna do it purposely here just to show you that we are powering the filament that that's one way at least to indicate that you're powering the filament is to see a glowing so what I'm gonna do is instead of using the resistor I'm going to kind of put more voltage on the filament then it was designed for and you can see that red come up the the filament is glowing red just slightly and now I'm gonna stop and put it on the resistor and you're not gonna see it glowing so now we have the filament powered great so we have electrons coming from the filament now we have to direct those electrons to the the segments to light them up on the segments are phosphors and when electrons hit those phosphors we we basically see the segment light up and that's how the display works but to direct those electrons there we have to make sure that the grid right above the segments and the segment itself is positively charged because electrons are attracted to something positively charged so how do we do that well first of all we need to reference the filament over to the negative side of the second supply so we literally we can choose any lead any side of the filament that we want and we just reference it over to the negative side but I'm not using 40 volts I'm using 20 volts so I'm going to reference it here in the center that's going to be our negative and so now with the positive side of our twenty volts which is here what do we what do we do with this positive side of our 20 volts well we actually split this connection into two more connections so I literally just took another alligator clip and I connected it over to here and now we have two two points where we can test from remember what we're doing with these two contact points is we're probing the pins of the display to search for segment pins and grid pins and if the grid and the underlying segments of that grid are both positive the appropriate segments should light up because the electrons would be attracted to that area all right so here we go so we're just gonna randomly probe the pins oh and there we go look at that so on the left here I found a grid pin and on the right are the corresponding segments underneath that grid and they light up as a result because both the grid and the appropriate segments underneath that grid are both positive so there you go and if I hold a specific segment and I move the grid pin you can see that same segment moving across multiple grids so from here it should be pretty simple to reverse the pin out of this display just probe all the pins find the segment pins and the grid pins and Mark that down and you got the entire pin out of the display now from here it's up to you how you want to drive the segment pins in the the grid pins now one example of that would be via a transistor or a MOSFET so if you were to build your own interface with discrete components like transistors or MOSFETs to control the segments on this display this is how it would look like this is just one example of how you could go about building that interface I'm using an N channel MOSFET here and I'm using a dummy load 6.6 K ohm resistor my case but you could probably use a 1 to 10 K ohm resistor and this dummy load serves two purposes first of all it makes sure that our segment line here gets switched on and off properly but it also makes sure that this supply when when this MOSFET is conducting does not short itself out and that's because you you just have to look at the lines and and you can tell that because the positive line here is connected to the drain and then the source of this MOSFET is connected to the negative side so if this MOSFET were to conduct without the resistor then this supply would short itself however now that we have the dummy resistor here we connect our segment line from our display over here after the resistor because in the perspective of this connection when the MOSFET is conducting then this connection will short-circuit immediately to the source which is connected to the negative side now when the segment line is negative it will repel electrons and nothing will be displayed now on the other hand when the MOSFET is not conducting so it's off in the perspective of this connection it can't short-circuit to source so it would go all the way over to the positive end it would go to the positive side of this supply through the resistor and of course when this segment line is positive it will attract those electrons and we will see something displayed now as for the grid or grids you should probably connect all of them to the positive side and have them stay positive because the only real thing you're controlling is the segments but I mean you can do what you want this is how I would do it this is how I would connect it I'm not sure if this is the standard way of connecting it but really you got to keep in mind the only thing we are truly switching on and off is the segment pins and that's all we care about right we don't care to select or control the grid pins at all we can really just tie them to the positive line and and that's it that's all there is to it so this is the circuit that I was talking about in action I built the circuit with the MOSFET and here we are we're controlling a single segment and turning it on and off you can also see if I change the segment it will blink a new or a different segment so yeah there you go so I also connected an LED over to the MOSFETs gate and so when Arduino is turning on and off the MOSFET it's also turning on and off the LED but you can see when the LED is on the segment on the display goes off so now that you have a general understanding of what these bare displays need in order to operate let's take a closer look at the chip that is usually found on the same board as them so in this case this particular chip is a MSM 92o - - oh one and this chip is actually taken from a Sony CD player with the model number C X - 20 so I obviously found the datasheet for this chip but what if you weren't so lucky what if the chip was not known or you just couldn't find datasheet for it well in that case if you still really wanted to use the the chip then you would have to figure out the protocol that it's using and you would have to figure out the correct pin out for that protocol because most likely your chip will use either I squared C or SPI to communicate and I squared C only needs two wires and SPI needs at least three wires and so from that you would have to deduce like what pins to connect to and then you would have to set up something to read the the data that's being sent over to this chip because this chip is only the driver for the display and it needs to receive a certain type or amount of data before it starts to display something and so you would have to watch the communication line between this chip and another microcontroller on the unit you have to power up the whole unit and sniff the communication line between this chip and another microcontroller with something like a logic analyzer something like this this in particular is $80 so you really don't need something as fancy as this you could even go for something like the bus pirate that will set you back maybe thirty or forty dollars another thing worth mentioning is that surprisingly there exists code freely available code for the Arduino and for the stm32 in order to turn these microcontrollers into logic analyzers and so if you really want a cheap option in order to sniff the the SPI or I squared C communication protocol between this chip and another chip then you can do so with a microcontroller that might be probably the cheapest way of doing that if you want to go there however a word of caution here because with microcontroller based logic analyzers you might have trouble actually reading spi traffic I squared C should be just fine because I squared C actually operates at a much lower frequency than SPI SPI operates at a much higher frequency usually and it operates as I understand at a factor of the clock frequency and so I guess if you're having trouble reading or sniffing the SPI protocol or communication traffic between this chip and another then what you might consider doing is desoldering the crystal that the chip uses and re soldering a lower frequency crystal and that might actually help you read the SPI traffic however I have never tried to do such a thing so I don't know if it would actually work like you would expect so yeah reading traffic with microcontrollers is possible but it is not the best option and surely is the cheapest but it will be very limited in its applications but if you just want to read some you know communication traffic then you could get away with a microcontroller based logic analyzer but if I was in the situation where I didn't know the chip and I just couldn't figure out how to communicate with it properly then I just wouldn't spend my time and waste my time with trying to figure out and sniff sniff the protocol it is a good exercise a good learning exercise if you really want to do that but if you just want to drive a vacuum fluorescent display then really it is more worth going online and finding a dedicated driver chip with a known datasheet so here's the full schematic of how I connected everything and here are the relevant Arduino pins that I connected over to the chip pins now because I'm doing this in software and not hardware I can choose whatever pins on the Arduino I want in order to control the data clock and chip select lines if you were to do this in hardware then you have to use the dedicated pins that are connected to the SPI Hardware on the Arduino Nano here we have a CD player and we found its service manual so if we go down and look at the circuit schematic section you will see BAM the display board and as you can see this is the chip that we saw on the board and its name is clearly printed out for us as well as all the connections that are relevant around it so this is really useful in order to just figure out what the connections on the printed circuit board are all the connections that we saw on the circuit board were labeled for convenience on the silkscreen right but sometimes it's not like that and you would have to consult the service manual of the product in order to actually know what all the connections do or where they go so this is very helpful in order to figure out which connection goes to which pin on on the chip and especially a good example of this is pin number six as you can see it's labeled FLT now this doesn't strike any resemblance to a pin that we may be familiar with however if we do follow this line down here all the way back to the chip we will see that that FLT pin corresponds to the chip select pin I would have never guessed that and if you can imagine spending a lot of time trying to reverse-engineer these pin outs you would never have guessed that something as arbitrary as you know a mislabeled pin could set you back but it can and if you didn't know that this was the chip select pin then you would think this might be an I squared C communication line because if you didn't know that the FLT pin up here was in fact the chip select pin then you would only see data and clock and you would think huh maybe this is I squared C instead of you know SPI and actually that is that is what I thought when I first saw this so now we're looking at the datasheet of the chip and if we go down to this section the command list you'll see that this is how the data is structured and how we're supposed to send it over to the chip in order to display something so when you want to display a character on screen you have to choose first a ram to use now the most common way of displaying a character is to just choose DC Ram DC Ram stands for data control Ram you first have to choose the first four bits of an address and so this actually corresponds to the grid that we want to use so com1 would a correspond to the leftmost grid that we see on the display so it's the first grid right so we just choose the first grid to display our character on and so that's 0 0 0 0 and then we fill in the rest of the bits and after our second bite is just full of character data this is data that you would find in an ASCII table now one thing I did find a little bit weird is that an ASCII table is provided at the bottom of this datasheet but the chip doesn't seem to be flashed with this information on it because I tried using the specific bits that are labeled here to display a specific character but it just didn't work like that like you would expect it to and when I tried a different ASCII table that I found online that worked for some reason so maybe you know this is a discontinued product so I'm not too surprised about that but it's something you have to keep in mind when you're working with older hardware because it'll definitely throw you off anyway another thing to keep in mind is that addresses are internally incremented automatically so what that means for your data is once you send out your command and the specific grid you want to use and you send out your first piece of data which corresponds to a character you can keep sending data without any interruptions you can keep sending data and the chip will automatically increment the address the grid address another extremely important thing you have to keep in mind is the least significant bit and the most significant bit now these correspond to the leftmost or the rightmost bits in a stream of eight bits or a byte and you have to keep in mind which side of this byte is coming into the chip first and what I mean by that is in this datasheet it specifies that the chip needs to have this data this byte coming into it with the least significant bit first and in this case it shows that the least significant bit is on the leftmost side of this data right but that is not the case in Arduino and basically if you mess up the order that these bits go into the chip then you're going to mess up the character is going to be displayed or you're not gonna get anything displayed at all alright so this is the most basic simplest code that we have to set up in order to start talking to the chip and I'll explain all of this so up here we have our basic defines for our pins we have our clock pin data pin slave select pin or chip select pin and we have our bit order this can be most significant bit first or this can be least significant bit first all pretty much all of these parameters up here are used by the shift out function what's important here is to focus on the bit order and the data that we're sending out so first of all let's talk about the bit order because this can be two things the least significant bit first or the most significant bit first and why this is important so this is important because the way you see the data displayed in the data sheet of the chip is the least significant bit is on on the left hand side and most significant bit is on the right hand side in Arduino this is actually reversed so you'll find the most significant bit on the left and least significant bit on the right and that's why if we want to basically make our coding life easier and type in the data exactly how we see it in the datasheet then what we have to do is instead of choosing least significant bit first up here we have to do most significant bit first because we're actually reversing the bit order and that is actually going to make our life much more easier because we can now type in the data that we want to send out the bits that we want to send out in the order that we see them in the datasheet exactly how we see them in the datasheet instead of reversing the bits to make it work with the least significant bit first in the Arduino IDE alright so next we have to make sure that all of our pins are set as outputs to make sure that our shift out function works properly and then we can start sending data so obviously we have here a function that we it ourselves called send data and we're sending some relevant data but let's review that function over here so it's very very simple so before we start shifting out data to the chip we have to make sure that the slave select or chip select pin is set low the chip will interpret that as oh I'm getting a command sent to me and after we are done shifting out that command over to the chip then we can set the slave selector chip select pin high and that will end the data stream and so this is just a very simplistic function to make our code a little bit neater it would be very tedious to do this manually every time that we want to send a byte out so with this byte we are specifically setting our ports on the chip to low because we're not using this feature this is just to control other input/output devices and like LEDs so we really really don't care about this so we're just setting that low with this byte we are configuring the number of grids on the display like I said every displays different and so this will differ for you but on my display I have 15 grids that I can use to display individual characters so I set it up that way with this byte we are setting the displays duty cycle for contrast and with the last byte we are setting the display into normal mode now this is very important because this byte actually makes sure that you can display characters on the display if you don't send this byte over to the chip to set it into normal mode then the chip will not allow you to display any characters on the display and after that it's just a matter of sending out the correct command over here and the following data that we want to send out I mean as simple as that and so in this case this byte represents the ASCII ASCII bits for the letter W the uppercase letter W now I'm not using the ASCII table that was in the datasheet I am not using that I'm using actually let me show you what I'm using it's this table this ASCII table that I found just randomly on mine so what you'll notice in the ASCII table here is is that the W is zero one zero one zero triple one and if we look back on our Arduino code you'll see that those bits are actually reversed here and that has to do with how these bits go into the chip right if the leftmost bit goes first or the rightmost bit goes first all right so let's just upload this and let's see if we get a W on the display all right so as you can see the first character the first grid here is displaying aw now so indeed we are sending the data correctly over to the display however you can see there's a bunch of other data on-screen that we do not want so we have to get rid of it somehow so we saw the W on screen but we also saw a bunch of other data that we did not want on screen and so getting rid of that extra data on screen as as simple as overwriting it so here I have the W but I also have 14 spaces in ASCII and this should basically overwrite any extra data on screen other than the W and in total we will be shifting out 15 bytes in order to display you know one W and 14 spaces and there you go we have a blank screen with just one W exactly how we want it so now you know how to display a character on screen and how to clear the screen so you can actually do this manually and letter-by-letter construct your own words or anything else you want to display on screen but that is very tedious and that's why we make functions so you'll find print string and a bunch of other code that I've included in the description available for download and you can check out good examples of just doing this manually shifting out characters manually and good examples of me using the print string function to display something and yeah if you have the same chip or if you have an identical chip and just want to see if this code works for you know some identical chip then go ahead this is freely available to hack and modify so I hope you enjoyed and I hope you learned something and I hope you get to repurpose and reuse these displays these are very nice displays and you know them using I squared C or SPI makes them pretty easy to interface with
Info
Channel: SciCynical Inventing
Views: 8,566
Rating: 4.9722223 out of 5
Keywords: scicynical inventing, sir spunk, reusing vacuum fluorescent displays, msm9202, vfd, VFD, scicynical
Id: W5G1gR7aGh0
Channel Id: undefined
Length: 29min 49sec (1789 seconds)
Published: Tue Feb 11 2020
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.