Mar 07, 2021, 11:46 am

News:

New, New TardisBuilders!


Tardis light pulse circuit

Started by trackhappy, Dec 06, 2016, 04:19 am

Previous topic - Next topic

trackhappy

Dec 06, 2016, 04:19 am Last Edit: Dec 06, 2016, 04:22 am by trackhappy
In case it is useful to anybody, I made a small circuit using a Microchip PIC 10F322 to pulse a 12 volt bulb to imitate the Tardis light. It is a fade in and out, so if you want on/off without the fade, then you won't like this.



It is triggered by a 5 volt pulse to the trigger pin (a standard PIR puts out such a pulse, which is what triggers mine). For the more technical, it uses PWM to drive the FET, which switches the 12 volts to the bulb. The PWM controller is fed with a rough triangle waveform. I just used a 12 volt 23 watt car lamp, the characteristics of which look reasonable to my eye. Happy to supply the code or program a chip and pop it in the post for the cost of postage and blank chip.

I also put a Tardis takeoff sound into an ISD1760 module and used the PIC to trigger it at the same time. I timed the light fading in time with the sound just by trial and error. Looks ok to me, but it seems that purists don't think the light was ever timed with the sound anyway.

Enjoy.Tardis_light.JPG

galacticprobe

Dec 06, 2016, 05:52 am #1 Last Edit: Dec 06, 2016, 05:56 am by galacticprobe
Wow! That's an amazing circuit! I'm a retired electronics tech (military), not great on the design/engineering side, but I can build and fix things if I've got a diagram.

For this circuit, I've always envisioned using a 555 timer for the clock chip to get the "on" pulses, and a 2N3055, 55-watt power transistor to run the car lamp (and with the car lamp running at only 23 watts, the 3055 wouldn't need a heat sink). For me, simple, but it works.

As for this:
Quote from: trackhappy on Dec 06, 2016, 04:19 am
...but it seems that purists don't think the light was ever timed with the sound anyway.

When you go back to the beginning and watch the Classic Series from the first time we get to see the TARDIS lamp flash, to the last time we get to see it flash, there was never a time when the lamp was matched to the sound. Even in the early episodes of the New Series there was no matching of lamp flash to sound. It was only after a few series (possibly starting with Series 5?) that the lamp and sound were in sync, and that could be because from Series 5 on, the lamp never really went out; it was on all the time and the "flare" that's syncked with the sound is done with CGI.

So as for purists, it's not so much as that they don't think the light was ever timed with the sound; throughout all of the Classic Series and early episodes of the New Series, the visual evidence shows that it never was.

You still have a brilliant circuit designed there. It's certainly one to be proud of, and one I could never have designed.

Dino.
"What's wrong with being childish?! I like being childish." -3rd Doctor, "Terror of the Autons"

trackhappy

Thanks Dino. Not sure about amazing, it is very basic, courtesy of the PIC doing all the work. It makes it easy for somebody to cobble something together themselves if I supply a pre-programmed chip (you need a programmer to burn the code in there), and it can be built very tiny to fit unobtrusively into even a miniature Tardis. The FET can handle about 5 amps with just a little heatsink without a problem.

As for timing, I acquiesce to the likes of yourself of far greater knowledge than I in such matters. My logical brain just can't handle it not being in sync... ;)

Anyhow, its there if anybody wants it.

The ISD 1700 based module I used is freely available on a well known auction site for less than AU$20 and can handle the audio record and playback. There are other ones, but this one does up to 70 seconds. Add a class D amp (I like the TPA3116/3118 ones, but PAM8610 are cheap and work as well) and away you go.
All the best,
Glenn.

russellsuthern

Hey Glenn,

That circuit looks really cool!
Much better than my lash-up job!!

Now, are you going to build a TARDIS for it to go into?! ;)

Russell

bdhuey

I want one!  Going to build it. Thanks for sharing the info.

trackhappy

Looks like I can't attach the zip file containing the Microchip project, so if anybody wants it, feel free to PM me with an email address and I will send it, or postal address to send a chip. If there is sufficient interest, I could get some pcb's made and make complete modules available. Bare minimum would be 5 units and it costs around AU$65 to get 5 made and shipped to me. Looks like 10 up the 10F322 chips are down to less than $2 each. FET is about $6, voltage reg is about $1. Less than $20 components all up. Postage will be a killer of course, but if a few of you wanted them in one country then it would be cheaper.
Cheers,
Glenn.

trackhappy

Here is the full circuit with the ISD1760 chip added. Note that I haven't built this circuit as it sits. I have tested it but using the purchased 1700 board online, which has all the buttons and bits onboard. Note that the 1760 is designed to drive a speaker, so we just use one leg to output to the amplifier and we remove the onboard microphone and input direct to the mic in line via a cap.
This circuit is triggered by pin PIR-2, which is a PIR motion detector at present, the PIC starts the light pulsing and also triggers the sound playback by pulling RA2 low, which effectively presses the play button. I have tweaked the code to suit the recording currently in the 1760.

Enjoy.

galacticprobe

Dec 07, 2016, 07:44 am #7 Last Edit: Dec 07, 2016, 07:47 am by galacticprobe
Quote from: trackhappy on Dec 06, 2016, 10:56 pm
Looks like I can't attach the zip file containing the Microchip project,

Unfortunately, you're quite right, Glenn. The Forum only accepts photos/images for uploads, and only in JPG, GIF, or PNG formats. Any other file formats (PDF, WMV, MP3, ZIP, etc.) need to be uploaded to a file hosting site such as Dropbox or the like, and then you can post the URL (link) to that file. From there all members have to do is click on that link and they can go straight to the file and download it.

Quote from: trackhappy on Dec 06, 2016, 10:56 pm
so if anybody wants it, feel free to PM me with an email address and I will send it, or postal address to send a chip. If there is sufficient interest, I could get some pcb's made and make complete modules available.

This would definitely be best done via PM or e-mails as it's getting very close to what could be interpreted as a "group run". (Group runs aren't allowed on the Forum, and I wouldn't want to see anyone get in trouble with the Moderators.)

Dino.
"What's wrong with being childish?! I like being childish." -3rd Doctor, "Terror of the Autons"

trackhappy

Thanks Galacticprobe. I hadn't picked up on the "group run" restriction. Its a shame, I did a pcb design today. Not sure that a circuit to pulse a light can really be described as even close to violating a patent but I certainly defer to board rules and don't want any trouble.
As far as download sites, they tend to disappear, so not much point in using external sources.

At least I have supplied some options and potential resources for people. The source code is below for anybody with the skills.


#include <xc.h>
 
// CONFIG
#pragma config FOSC = INTOSC    // Oscillator Selection bits (INTOSC oscillator: CLKIN function disabled)
#pragma config BOREN = OFF      // Brown-out Reset Enable (Brown-out Reset disabled)
#pragma config WDTE = OFF       // Watchdog Timer Enable (WDT disabled)
#pragma config PWRTE = OFF      // Power-up Timer Enable bit (PWRT disabled)
#pragma config MCLRE = OFF      // MCLR Pin Function Select bit (MCLR pin function is digital input, MCLR internally tied to VDD)
#pragma config CP = OFF         // Code Protection bit (Program memory code protection is disabled)
#pragma config LVP = OFF        // Low-Voltage Programming Enable (High-voltage on MCLR/VPP must be used for programming)
#pragma config LPBOR = OFF      // Brown-out Reset Selection bits (BOR disabled)
#pragma config BORV = LO        // Brown-out Reset Voltage Selection (Brown-out Reset Voltage (Vbor), low trip point selected.)
#pragma config WRT = OFF        // Flash Memory Self-Write Protection (Write protection off)
 
/*------------------------------------------------------------------------*/
#define _XTAL_FREQ  (1000000)
#define triggerPin RA1
#define playPin RA2

char buttonState = 0;
//char lastButtonState = 0;

/*------------------------------------------------------------------------*/
void InitPWM (void);
void PulseLight(void);
/*------------------------------------------------------------------------*/
void main()

     /* TODO Initialize User Ports/Peripherals/Project here */
 
     OSCCON = 0b01100000;    //1MHz
     TRISA = 0b00001011;
     ANSELA = 0b00000000;
     LATA = 0;
     PORTA = 0b00001110;
     RA1=0;
     RA2=1;
     InitPWM();
   
     while (1){
         __delay_ms(20000);
         if(RA1==1) // If triggered by input pin 4 going high
         {
             //__delay_ms(750);
             RA2 = 0; // Play output low
             __delay_ms(500);
             RA2 = 1; // Play output high (default state)
             __delay_ms(1000);
             PulseLight(); // Run output routine to feed PWM register
         }
     }
}
   
/*------------------------------------------------------------------------*/
void PulseLight(void)
{
for ( int l = 0; l < 14; l++)
//for ( int l = 0; l < 2; l++)
   {   
        char x;

                for( x = 0; x < 0x65; x++)
                   {
                       PWM1DCH = x;
                       __delay_ms(80);
                   }

                for( x = 0x65; x > 0; x--)
                   {
                       PWM1DCH = x;
                       __delay_ms(64);
                   }
   }           
  }

void InitPWM(void)
{
     TRISAbits.TRISA0  = 1;      // Disable PWM output pin 
     PWM1CON = 0x00;             // Clear PWM1Con 
     PR2   = 0x65;               // Configure the Timer2 period
     PWM1DCH = 0x0; 
     PWM1DCL = 0x0;
     PIR1bits.TMR2IF = 0; 
     T2CON = 0b00000101;         // Prescaler = 4
     PWM1OE = 1;
     while (!PIR1bits.TMR2IF);    // Wait until the Timer overflows
     TRISAbits.TRISA0  = 0;        // Enable PWM output pin
     PWM1EN = 1;
 
}


All the best,
Glenn.

galacticprobe

Dec 08, 2016, 06:12 am #9 Last Edit: Dec 08, 2016, 06:26 am by galacticprobe
Quote from: trackhappy on Dec 07, 2016, 09:44 am
Thanks Galacticprobe. I hadn't picked up on the "group run" restriction.

No problem, Glenn. I just try my best to help people, and help them stay out of trouble. :)

Quote from: trackhappy on Dec 07, 2016, 09:44 am
Its a shame, I did a pcb design today. Not sure that a circuit to pulse a light can really be described as even close to violating a patent but I certainly defer to board rules and don't want any trouble.

The rule has been in place for probably as long as the Forum has been in existence, or at least shortly thereafter. It's sort of a safety thing. Unlike most other forums we seem to be more on the BBC's radar scope, possibly because of the amazing prop replicas our member turn out. And while it's true that a circuit board to flash a lamp isn't a patent or copyright thing - technically... if you've designed the board then you hold the copyright to it - but it's the possibility of someone using it in a 'Doctor Who' prop replica and then turning around and trying to sell that replica, which is something else we don't do. (See http://tardisbuilders.com/index.php?topic=2971, near the bottom.)

It's a case of better to err on the side of caution than to have the BBC Legal team issue a Cease and Desist Order and shut us down, which has happened to other sites that were selling unlicensed 'Who' replicas. We could lose too much priceless reference resources if that happened, so we stay careful.

Quote from: trackhappy on Dec 07, 2016, 09:44 am
As far as download sites, they tend to disappear, so not much point in using external sources.

Yes, they do, but ones like Dropbox are more reliable. We still have some PDF plans on there that have been there for years, so that one is relatively safe. And you can also post a notice letting everyone know the file is up, and how long you intend to keep it up before taking it down, either because you just want it up there for a limited amount of time, or to make room for another file.

Quote from: trackhappy on Dec 07, 2016, 09:44 am
At least I have supplied some options and potential resources for people. The source code is below for anybody with the skills.

And of course that's another way to do it, which will keep that code right here on the Forum for as long as our Forum exists. You can also type it in as part of the Comments, but it's nice to have that "code" tag to keep things in a scrollable window. I just scrolled through it and it made my brain hurt! I'm total rubbish with software. (I knew a little when I first started out in the electronics field, but that was back in 1981, and things have changed so much since then. I once took a Unix class because I thought it would help me out when working on our computerized radar - a Unix system running Windows-type software on a PowerPC (Mac) Processor! Talk about a mess. Even just sitting "idle" that processor was active 75 percent of the time. And that Unix class? I needed Bounty, the quicker-picker-upper, at the end of every day just to sop up my brain and squeeze it back into my skull! :P)

But now I'm digressing. At least we have people like you that understand this sort of thing to keep the planet running.

Dino.
"What's wrong with being childish?! I like being childish." -3rd Doctor, "Terror of the Autons"

bman

Jun 07, 2018, 09:55 am #10 Last Edit: Jun 20, 2018, 02:37 am by bman
Hi Bruce here from Geelong in Australia, can I have your email so I can ask you some questions about your Tardis light pulse circuit ? I think it is awesome and I would like one but my skills in making something like that is probably not existant.
I am building a Tardisreceived_2099609366720352.jpeg