Go Down

Topic: Klingon Proton Collector (Read 19429 times) previous topic - next topic

jameskirk


fungus

Looks easy enough from the electronics side...

But...what's inside it? Does it have LEDs? Battery compartment? What?? How much space is there?


No, I don't answer questions sent in private messages (but I do accept thank-you notes...)

jameskirk

I have not seen the actual insides of the original but you can see thru the holes in the back in this pic from the original...

It has LEDs...
Thanks
Michael

fungus


I have not seen the actual insides of the original but you can see thru the holes in the back in this pic from the original...


We need to know about the one you've actually got, not the original.

No, I don't answer questions sent in private messages (but I do accept thank-you notes...)

jameskirk

#4
Aug 12, 2014, 01:32 am Last Edit: Aug 12, 2014, 01:37 am by jameskirk Reason: 1
Sorry here is some pic's of my Prop...







You can pull the handle off to put the battery pack in...



Thanks
Michael

Simpson_Jr

#5
Aug 12, 2014, 01:09 pm Last Edit: Aug 12, 2014, 01:11 pm by Simpson_Jr Reason: 1
It's hard to tell how much space you've got, about two 9v batteries would be nice.
Looking at the pictures it seems... enough for at least a few coincells, 6 leds, 6 resistors and a Mini, Pro Mini, Micro or Nano.

The first two boards are the smallest, but need an external USB-breakout board to program them.
Unfortunately the product pages of these boards don't specify size, each pin on a connector is placed 0.1 inch from the next though.


Next part, how would you like to control/configure your leech ?
You could for example use a power switch to start the (standard programmed) routine, which requires access to a pc when you want to change settings. Looking at the original leech, you may also be able to include some switches/potentiometers to adjust settings without the need of a PC.

Most of the functions needed are described in the first two sections of the built-in tutorial of Arduinos IDE by the way, it shouldn't be too difficult to get a working proto(n)-type ;-)

fungus


It's hard to tell how much space you've got, about two 9v batteries would be nice.
Looking at the pictures it seems... enough for at least a few coincells, 6 leds, 6 resistors and a Mini, Pro Mini, Micro or Nano.


If this is your first Arduino project you could do far worse than get a "protosnap":

http://www.ebay.com/sch/i.html?_nkw=protosnap

This has a small Arduino, a programmer and some other stuff all connected together for learning. You can build the circuit and get it working then break the pieces apart and put just the bits you need inside the leech.

For power you can use 2xAAA batteries (or 2xAA, or 3xAAA, whatever) plus a 5V voltage booster.

After that all you need is a few LEDs and some matching resistors.
No, I don't answer questions sent in private messages (but I do accept thank-you notes...)

PaulRB

#7
Aug 12, 2014, 11:54 pm Last Edit: Aug 13, 2014, 12:49 am by PaulRB Reason: 1
If you can squeeze in 3 x AAA, you won't need to boost the voltage to 5V, it will almost certainly work fine with just the cells.

http://www.ebay.co.uk/itm/1-2-3-4-6-8-x-AA-AAA-23A-9V-Battery-Holder-Snap-On-Connector-Enclosed-Box-Switch-/180814661762?pt=UK_BOI_Electrical_Components_Supplies_ET&var=&hash=item2a1964c882

I guess you will also need a piezo sounder. These are small and flat, so won't take up much space at all.

http://www.ebay.co.uk/itm/Piezo-Element-Sounder-Sensor-Trigger-Drum-Disc-Transducer-Various-Sizes-amount-/111180207482?pt=LH_DefaultDomain_3&var=&hash=item19e2db557a

Once you have the sketch working on your Uno, you can upload it into an attiny85

http://www.ebay.co.uk/itm/1-2-5-10-PCS-Original-ATMEL-DIP-8-ATTINY85-20PU-Tiny85-20PU-IC-Chip-NEW-/191092048934?pt=UK_BOI_Electrical_Components_Supplies_ET&var=&hash=item2c7df94426

Paul

jameskirk

Paul
What would I need a piezo sounder for???
Also you put the wrong link in for it...



I guess you will also need a piezo sounder. These are small and flat, so won't take up much space at all.

http://www.ebay.co.uk/itm/1-2-3-4-6-8-x-AA-AAA-23A-9V-Battery-Holder-Snap-On-Connector-Enclosed-Box-Switch-/180814661762?pt=UK_BOI_Electrical_Components_Supplies_ET&var=&hash=item2a1964c882


Thanks
Michael

PaulRB

Yes, sorry, I have corrected the link.

The sounder is to make beep noises like in the movie!

jameskirk

OK I have a Nano V3.0 ATmega 328, ATTiny 85... I can get a UNO if need be...
Can you help me out with the code I need to make it do what it needs to do???
Thanks
Michael

PaulRB

Yes I will help. But I will not do all the work for you.

You will not need an Uno. I just assumed that would be what you already had. Nano 3 will be fine. You will not need the tiny85 until later. Use the Nano to get the sketch and circuit working on breadboard first.

Do you have the Arduino ide installed and working? Do you have the "blink" sketch uploaded and running?

dave-in-nj

list every output. 

the X pattern could be 2 pins, if they are always lighting in pairs.

the lights under the cutouts near the handle.  are they multi color or just one color.  do they change as the proton storage chambers fill ?

the yellowish one furthest from the handle does appear to get brighter as the chambers fill.

but that looks like 4 total pins out plus the noise of the unit

the photo of the back of the original unit appears to have a switch and three pots.

start with whatever arduino you are most comfortable programming with.

look at blink without delay
add in the sketch to

Code: [Select]

// set the LED with the ledState of the variable:
    digitalWrite(ledPin1, ledState);
    digitalWrite(ledPin2, -ledState);


this should have one of the X sides light and the other to be off, and they will forever be opposite

you have to declare ledPin1 and ledPin2 in the sketch


dave-in-nj


Yes I will help. But I will not do all the work for you.



PaulBR, 

For the 4 LED's of the X in series.  one could put them in series, and have a pin connected to the center point between the 2 pairs.  then change the pin from input (light the pair of LED's connected to the 5V and then change the pin to an output (light the LED pair connected to the ground.

that would save a pin on the '85.

what do you think ?

would need to have the other two LEDs on a shared pin, using analogout to fade-up the leds.
one pin for the sound and one for the on/off switch... or do we still have room on the '85





PaulRB


For the 4 LED's of the X in series.  one could put them in series, and have a pin connected to the center point between the 2 pairs.  then change the pin from input (light the pair of LED's connected to the 5V and then change the pin to an output (light the LED pair connected to the ground. that would save a pin on the '85.


Not quite. You are probably correct in saying they can be in series. As long as they are red, their forward voltage will probably be less than 2V. Two (low value, e.g. 68R) series resistors will be needed. But if the Arduino pin is set to Input, the leds will glow very dimly or probably not at all. However, if the pin it set as output and high, one pair of leds will light and if output and low, the other pair will light.


would need to have the other two LEDs on a shared pin, using analogout to fade-up the leds.
one pin for the sound and one for the on/off switch... or do we still have room on the '85


The tiny85 has 5 usable pins. Up to three can be analog inputs. Up to 2 can be analog (PWM) outputs. I don't see a need to use a pin for on/off - just have a switch cut power to the chip.

Pins usage:
1 digital output for "X" leds
1 PWM output for "filling/full" led
1 digital output for piezo sounder
1 analog input for "fill level" control

Michael has not said how he wants to control the "fill level" of the device. Options could be:

1. The collector builds up to "full" after a fixed timed interval after switch-on.
2. a hidden pot could be adjusted by slight-of-hand
3. a thermistor could be used so that if he device is placed on a central heating radiator, or a stone wall hot from the sun, the device would act like it is filling as the temperature rises.


Go Up