CallumNunesVaz / DogBoneVFD

PIC16F1828 program code. For use with a custom board that acts as a wristwatch.
5 stars 1 forks source link

Timers and H-bridge #1

Open biomurph opened 7 years ago

biomurph commented 7 years ago

Hey, it's been a while since you touched this. I'm building my own VFD display using the same old/new nixie thing that you did. I have a question about your use of timers.

You used an internal hardware timer to drive the H bridges which you used to even the display brightness. I want to use an independent oscillator driven circuit to power the H bridges. It's a way to accomodate less pins, and also I like oscillators...

Are you using the H bridge timer interrupts to time the display multiplexing? I'm wondering because I think I can follow the relaxation oscillator that I have with an interrupt and time my muxer that way. Hope to hear feedback from you on my scheme.

Also, in your code line 71-73 you say you mux the digit display at 1Khz, but you are driving your H bridge at 250Hz. What's the logic behind that? My concern is that I will need to know when which element is 'lit' by the 2.5V to print my numbers. Does that make sense?

My current schematic and board layout can be found here https://github.com/biomurph/ILV2-7-5_VFD_Display

Great work, btw

CallumNunesVaz commented 7 years ago

Hi Joel,

I’m glad to see someone else doing one of these builds!

Yes its been a while since I put together the first prototype, but I do get fairly frequent emails from people asking questions or after the BOM so some stuff is still fresh in my mind.

I was using a timer to create delays between calls of the functions that drive the anodes via the MAX6920, and a separate timer (this one was tied to an interrupt) to drive the H-bridge. You could definitely use the same timer if your code that runs the anode drivers is small enough to reliably exist inside an interrupt service routine, but because mine was so long I wasn’t comfortable doing it that way and instead made use of the extra timers available.

In this “A Guide to Fundamental VFD Operation” (https://www.noritake-elec.com/technology/general-technical-information/vfd-operation), they specify timing values where the anode frequency is roughly double that of the cathode frequency, I reasoned that their usage of 50Hz and 60Hz was a simplification by driving the VFD filament via a step-down of mains AC, and that the filament should theoretically be able to go higher. Also I didn’t experience the flickering that they mentioned. Additionally, the code holds some legacy drivel, due to the fact that I was testing timing values about the time that I decided there were too many improvements that needed to be made to justify finishing the code, so that would be why the anode frequency is 4x the cathode frequency. As for your concern, the cathode filaments stretch across all four digits and the dots, so you don’t need to know which

I'm currently finishing up at uni and will be finalising my final year project over the summer (here in Australia), after which i will be finishing the second revision and hopefully be doing small batch orders of 'kits', since ordering single parts is so expensive. I mention this because I’ve identified a number of things I wanted to change in the new design…

Goodluck with your project! Let me know if you have any other questions.

Cheers,

Callum

From: Joel Murphy [mailto:notifications@github.com] Sent: Thursday, 16 November 2017 9:48 AM To: CallumNunesVaz/DogBoneVFD DogBoneVFD@noreply.github.com Cc: Subscribed subscribed@noreply.github.com Subject: [CallumNunesVaz/DogBoneVFD] Timers and H-bridge (#1)

Hey, it's been a while since you touched this. I'm building my own VFD display using the same old/new nixie thing that you did. I have a question about your use of timers.

You used an internal hardware timer to drive the H bridges which you used to even the display brightness. I want to use an independent oscillator driven circuit to power the H bridges. It's a way to accomodate less pins, and also I like oscillators...

Are you using the H bridge timer interrupts to time the display multiplexing? I'm wondering because I think I can follow the relaxation oscillator that I have with an interrupt and time my muxer that way. Hope to hear feedback from you on my scheme.

Also, in your codehttps://github.com/CallumNunesVaz/DogBoneVFD/blob/master/main.c line 71-73 you say you mux the digit display at 1Khz, but you are driving your H bridge at 250Hz. What's the logic behind that? My concern is that I will need to know when which element is 'lit' by the 2.5V to print my numbers. Does that make sense?

My current schematic and board layout can be found here https://github.com/biomurph/ILV2-7-5_VFD_Display

Great work, btw

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHubhttps://github.com/CallumNunesVaz/DogBoneVFD/issues/1, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AMMYMNdO8HPYBm24WOEhmlGCZ0fVi3byks5s23E8gaJpZM4QfuVP.

biomurph commented 7 years ago

Hi Callum,

Thanks for the timely and thorough response! And great link to the guide. I just want to ask again, since I'm new to VFD. I'm kind of doing this project on the side, since my neighbor gave me one of the ILV2-7/5. He wants to make and sell some clocks, and I'm helping out cause I like to learn stuff. Anyhow, here's what I think you're saying

Drive the CATHODE_AB and CATHODE_CD pins with alternating square wave of 2.5V at 1KHz. When CATHODE_AB is high, CATHODE_CD is low and vice versa.

Multiples the GRID anodes and the appropriate display segments at 250Hz. Basically print hours-tens, hours-ones, dots, minutes-tens, minutes-ones over and over again with 4mS between each digit.

Is that correct?

If I don't need to know which CATHODE is being hit with the 2.5V, then I will stick with my oscillator driver so I don't need to use the PIC. Not sure I have the pins to pull off a timer driven cathode anyway.

I like the idea of using -2.5V. I would have to look into how to make that work with my relaxation oscillator driver of the Hbridge.

Thanks again for your guidance!