Mountain Bike Reviews Forum banner
1 - 20 of 48 Posts

·
Registered
Joined
·
63 Posts
Discussion Starter · #1 · (Edited)
Hello. I've been following this group for a while. I fancy the Citizen Kane's Hammond light DIY and decided to do a mod. I will share some mechanical and electronic drawings with you. Keep in mind this is my first time using a 3D CAD software (Google Sketchup). There's alot of experienced mechanics in here for sure! Please tell me what you think. I'll provide many images of the 3D model with text in them (don't worry, they are small sized files for fast loading). I'm not english speeking person also, please excuse my english. Ok enough excuses..
Wow. This has been a steep learning curve. Watching youtube videos on how to draw 3D with Sketchup has helped designing alot. Its much easier to see how things fit together now. A 3D model of the Hammond box is available for download at hammonds website. I've used a plugin for Sketchup to convert from "iges"- to "skp"-files. I notice that "iges" 3D model files are the ones mostly available (for example at molex.com and hammond mfg among many). The STAR LED model was downloaded from Google 3D warehouse. A big thanks to the designer of this model. Maybe you are at this forum aswell.

Features
The features that makes this DIY a bit different than the others are:
- Integrated battery.
- Thermostat with dual tresholds (one for warning led, and the other for cutting the current at overheating).
- Pot-meter, sealed with pass-through rubber grommet on the pots axel. (see images).
- On/Off switch in pot-meter.
- Optional 8pin/8bit flash-based Microcontroller + mode-button. (create pcb footprint for soldering a microcontroller to the pcb for future firmware project).

Images of 3D Model
Front


Rear
The LED is for high-temp warning. The design may need a charging connector, or maybe ill just unscrew the cover to charge it.


External Contents


Internal Contents (Side View)
For the 4 SSC P4 i'm thinking a 4S1P 2600mAh Li-ion pack would do giving plenty of runtime (3h+) and enough voltage. A flat arangement of the four sels fit neatly inside the enclosure together with the leds. Battery mount-plate not yet designed.
I've been researching the forum for waterproof potentiometer, and such a part is not available. A rubber grommet with 6mm inner dia that match the
pot's axel diameter will hopefully keep water out of the case and the same time make rotation possible. Has anyone tested this?
So why the @£!# do one need a thermostat in this. Usually one just design for an operating temperature range, one would do alot of testing to ensure the light performance in that range. 1st of all, its just for safety and for variety (=funn). The LM56 is quite clever. It does all the analoge noise sensitive operations on its die and producing a digital cmos (open collector) output about the state of the thermostats. It has two thermostats that give four states. In other words its possible to monitor two thresholds. That gives many application uses. For this application i want the first threshold to be the point where a warning led is switched on (lets say at 50C), and the second threshold where the power is cut to protect the battery pack and LEDs (lets say at 60C). The thresholds are configured using three resistors (see datasheet for details).
(EDIT: image replaced. Previous image noted 4P1S which was wrong)


Thermostat Assy
This is the LM56 device with R0603 resistors mounted on it. Values will be calculated later. The datasheet note that the temperatyre is measured at the package-pins. To electrically insulate it from the L-profile-LED-mount (see image above), and conduct heat to it, it will be dunked in thermal glue and then glued to the rear of the profile, close to one of the LEDS.


PCB Assy as seen from top
The PCB is slided into the Hammond box's PCB-groves. The box is for 100mm wide PCBs and upto 2mm thick. Neat! The PCB connects battery pack, LEDs, driver, Pot, switch, and thermostat. The datasheet for the LM56 thermostat has loads of application notes. The same goes for the 3021E. More on that later when i post electronic schematics.
For the thermostats digital cmos output, signalling high and low will override the pot-meter outputs to the Ref input of the 3021E Buckpuck (datasheet). Can be somehow be interfaced with the led driver by connecting it to a pnp transistor that has been connected in parallel with the thermostat.
The mechanical drawing showing hole positions etc will be generated using sketchup. There will be a challenge to get all the mounting holes and component placement aligned with the pcb-layout. I'm currently using Eagle. How do you do this transition from 3D cad to pcb-layout?


Rear view again, without rear bezel


Thanks for reading and for future comments. I really love it.
 

·
Registered
Joined
·
63 Posts
Discussion Starter · #4 ·
Itess:
I started with 4-LED design to be able to use a combination narrow and wide optics, and I didn't find a BuckPuck with 2000mAh available here in norway. No good explanation for it really. I'm planning to replace the leds later after gathering some experience with thermals etc. The design will be easily modified by replacing the L-bracket. Ofcourze the driver must be replaced too.

Madmusk:
Thanks. The charger plug was left out because I've not found a good round DC-socket. I've had bad experience with those. There are some nice panel-mount DC-sockets used by others in this forum that I might consider. (yes there will be a charger plug).
It took some time to get used to 3D design, and yes its alot of details, but drawing 3D takes less time than one might think if one is new to it. Especially if you can find the components for download. Its also easy to experiment with different casings to see how things fit before buying :) This is especially true if you include a custom PCB in the design. It makes it tidyer and things stay more secure to the casing.
 

·
Registered
Joined
·
171 Posts
sergio_pt said:
nice projecting, looking good and organized. I always liked the idea of the rotating pot with on off switch.
And yes I would only change the LEDs to XP-G R5.
good work
Hey where is a good place for XP-G's? I've looked at DX but they don't have them there. Thanks
 

·
Registered
Joined
·
171 Posts
sergio_pt said:
nice projecting, looking good and organized. I always liked the idea of the rotating pot with on off switch.
And yes I would only change the LEDs to XP-G R5.
good work
Hey where is a good place for XP-G's? I've looked at DX but they don't have them there. Thanks
 

·
Lets RIDE!
Joined
·
1,548 Posts
Nice....we don't see many self-contained (batteries in the housing) lights here, I don't think ever one based on the Hammond boxes. Looking forward to seeing the finished light :thumbsup:

What Itess was asking is why use the SSC leds now that the brighter and more efficient Cree XP-G leds are available?

Will 5 batteries fit in there? That would be a better match with the Buckpuck and 4 leds.....the BuckPuck needs 2v over the Vf of the led series. And your batteries should be in series, not parallel. (or go 2s2p with a boost driver?)

@PSpuza: Cutter is the only good source for XP-G right now.

JZ
 

·
Registered
Joined
·
190 Posts
bwack said:
The design may need a charging connector, or maybe ill just unscrew the cover to charge it.
I wouldn't rely on screwing/unscrewing the back plate every time you want to charge the battery. The back plate on Hammond case is screwed on with self-tapering screws, so after a couple of screw/unscrew cycles those taps in relatively soft aluminum will be damaged.
 

·
Registered
Joined
·
25 Posts
I've also been looking at 4*18650 battery built-in version of Hammond light. Couldn't find any box that fits the battery dimensions.. and to give som feedback on your light I think it's kind of big and will occupy quite some space on the handlebar.

4pcs battery is approx 75 wide, feels like to much dead area to use 103 wide box. Also thickness wise there's 8-10mm air above the batteries.

I think your idea is great but I would try to find a box/extrusion that better fits the batteries.

For example, 45*45mm * 2 thickness extrusion with inside dimension 41*41 would fit 4 batteries in square configuration, have less air inside and occupy much smaller space on the bar*.

(edit* I assumed it's a bar light since It will be quite heavy to have on the helmet.)
 

·
Registered
Joined
·
63 Posts
Discussion Starter · #12 ·
Jim Z in VT (and Ola):
Thank you, yes indeed! I need 5 cells indeed to satisfy the 2V margin of the Buck Puck.
The previous image noted 4P1S but was supposed to say 4S1P.
Yes, 5cells will fit with ~1.5mm clearing on the sides. Here is an image of it.

I've looked at this battery pack. With the clearing noted above, there should be some room for the wires exiting the batteries on the sides. Not optimal, but it should be ok. May need to plaster it to secure it from the sharp edges of the Hammond box.

Regarding R5. I've now read the datasheet. I was thinking they where 2A devices, but they are 1A. The lumen/watt ratio is really impressive compared to the SSC P4. If can get 20mm STAR version, is my Carclo optics and holders compatible? have allready bought this holder and some various Carclo (4 narrow and two wide).

(edit: Yes, Ola, it is a bar mounted light.)
 

·
Registered
Joined
·
63 Posts
Discussion Starter · #13 · (Edited)
ortelius said:
I wouldn't rely on screwing/unscrewing the back plate every time you want to charge the battery. The back plate on Hammond case is screwed on with self-tapering screws, so after a couple of screw/unscrew cycles those taps in relatively soft aluminum will be damaged.
Good point! I will look into this!
 

·
Registered
Joined
·
25 Posts
Ok, 5 batteries will fill up the box much better.

Regarding optics, I've tried xpg's with carclo 20mm and it did not impress me. Found it quite bad actually.

Since you have the space, the ledil 21.6 square optics (lxp or cxp, always mix them up) are much better than carclo 20mm. I buy ledil from bram at candlepowerforums. Search on "bram groupbuy cpf" and you should find him.
 

·
Registered
Joined
·
425 Posts
ortelius said:
I wouldn't rely on screwing/unscrewing the back plate every time you want to charge the battery. The back plate on Hammond case is screwed on with self-tapering screws, so after a couple of screw/unscrew cycles those taps in relatively soft aluminum will be damaged.
I created a very similar design to this some time ago but abandoned the idea. The solution that I came up with for fixing the back plate was to use some threaded rod which screwed into the aluminium case where the self-tapping screws go. You could fix it in place with some epoxy like J-B Weld. Then if it protruded through the back plate by about 5mm you could use two knurled nuts to secure the back plate. That way you wouldn't be continually screwing in and out of the soft aluminium case every time you wanted to remove the back plate.

Nice design by the way bwack, it should make a great light. I'm into CAD myself for my light designs but prefer 2-D - it's the way I was brought up. You need to spend less time drawing though mate and more time building!! :D
 

·
Registered
Joined
·
63 Posts
Discussion Starter · #16 ·
I've been busy this weekend on this project.
This is the electronic design. I have ordered the PCB from BatchPCB.com. See the schematics below. The PCB interfaces the BuckPuck 3021E with CTRL input LED driver. The driver is controlled by a pot, thermostat and microcontroller. The POT (PC1) also has an internal switch rated for 1A. Charger connector (J1) switches off the driver when charging. That switch is not rated so that can be interesting... If it fails I'll have to short that switch. Electrolytic Capacitors C3 and C4 is supposed to compensate for inductance in long battery wiring. Since the wiring is short, C3 and C4 will probably not connected. (as i recall, switchmode devices like this driver doesnt like inductance from the power supply (can some one correct me on this?)).

The microcontroller can be left out of the board, and the board should still perform well.

The CTRL input.
The Potmeter PC1 set a voltage level on the CTRL input, and the driver converts that into a constant current value for the LEDs. This is done using information from the datasheet's application notes section. R1, R2 and T1 provides a CMOS-compatible CTRL-input. The thermostat and microcontrollers output is connected here (CUTOFF_N). Open-collector-like outputs are required if more than one device is connected to CUTOFF_N.

Thermostat Assembly
The thermostat Assembly
The thermostat LM56 is attached to the PCB via cables. Three resistors configures the two thermostat trip-values. I've selected 50C and 60C using R1=15k2, R2=1k4, and R3=10k4 (see the datasheet on how-to calculate R1, R2 and R3). A small 100nF capacitor filter some noise on the powersupply lines. A dab of Arctic Silver thermal glue is applied before attaching it to the back of the L-profile LED mount. I don't know if the glue will change the resistance. I'll have to test it.

Schematics


Layout


3D view


Ok thats it. The pcb is ordered and components are on its way!! Will switch to R5's also! Thanks for all help. And of course when the stash is in house, I'll show some build photos :) I'll definetly not discarde this project in a long while, so a firmware is also be programmed. What mode's do you like ? I was thinking of a fast way of dimming the lights in passing to a user-programable preset. And if the button was to be hold for 2s, a blinking mode was selected/unselected.

Can't wait start the building :)
 

·
mtbr member
Joined
·
890 Posts
Hi, this looks really cool, I like the integrated setup with the battery.

Can you explain how the pin 5 of the IC is going to work? I am not an electronics expert and am probably being dense, but I am thinking that it may interfere with the operation of the PNP if it is an input, however I don't see how it will provide anything as an output.

When running the blink mode, it looks like it would need to have the pot turned down low if blinking was to be seen - is this correct? I think that would be a plus since on my blink modes I have the low part of the blink set so it is not off, but just slightly less bright than the peak of the blink mode, helps to see stuff while it is blinking (no strobe effect).

Just a thought on another way to control this - you could use the pot to control an ADC input on the IC and then have the IC control the control pin on the buck with a PWM out. That would basically put the IC in control and give some more flexibility. You could use the IC to control the temp and voltage triggers too. That is kind'a how I have mine set up, though I use a button for control of modes.
 

·
Registered
Joined
·
63 Posts
Discussion Starter · #18 · (Edited)
Hi, thanks for the ideas. I'll explain the pin #5 at IC1 microcontroller (MCU), and how the CTRL pin is (or can be) interfaced.
But first, here is a newer revision (2.3) of the Buck Puck datasheet that takes out some factual errors in Rev 2.1. For clarity, if the CTRL pin is pulled towards 5V REF, the LEDs are dimmed. (CTRL voltage vs current output is inverse). For those interrested, here is the ATTiny13 datasheet

The direction of the pin5 on IC1 must be programmed. It can be an input (High-Z), or input with an internal pull-up, or an output pulling or sourcing current. I'm (almost) certain that the pin can be switched between active low output (pull-current) and a input (High-Z) in real time. In this way pin5 will function like the thermostats open collector output and pin5 will only be able to pull current through the pnp and never source current to the thermostat (that is fatal to the semiconductors!).

But your questions are 1. if pin5 will interfere with the pnp-operation, and 2. if pin5, as an output, will it serve any purpose?

1. If current is pulled through the pnp's diode, either by IC1 pin5 set to low or the thermostats open-collector output, the pnp "closes", overrides the pot, and switching off the LEDs. After pin5 or thermostat output is finnished switching the LEDs OFF, they must return to an High-Z state (as an input). If the pin5 is an input, in other words, does not pull anything through the pnp,I don't see how that will interefere with the operation of the pnp. R2 will keep the pnp "open" when no current is running through R2 (thats the case when pin5 is an input and the thermostat output is inactive).
I agree, using the pot with the MCU's ADC input would make the MCU more in control, but the concept is that the pcb can be used with or without MCU. Therefor the pot must not require a MCU on the PCB. .. Its a good idea actually... When thinking of it, the pots output could have been connected to both CTRL and MCU separeted by optional 0 Ohm resistor so that the pcb could be reconfigured at a later time (without having to order a new prototype). Lets call that Rev 1.1 of the board :)

After reading my own explaination you may think its confusing, am I using pin5 as an output or input .The answer is: Both i think.. I think it would be nice to control the LEDs with pin5 as an output, but at also be able to read CUTOFF_N from the thermostat when pin5 is an input.

2. Pin 5 as an output will serve as a purpose. The output will be able to pull current through the pnp and override the pot. I was thinking of PWM to dim down the LEDs. The pot will then work as a "master volume control".

Blinking with more than 0% output so that it is possible to see at the same time as blinking is a good idea. Should be fairly easy with a PWM output of the IC.
EDIT: I just realized that you have allready made light-build with a similar electronic setup and allready know stuff about microcontrollers !! Btw i like it!
I also forgot to answer if the pot needs to be turned low if blinking was to be seen. Its the other way, the pot must be turned up to see the blink. The CUTOFF_N signal can only cut the current to the LEDs, it can't turn on the LEDs.
 

·
mtbr member
Joined
·
890 Posts
Sorry to raise a concern, and thanks for the explanation, I think I get how it should work now. Thanks for sharing the schematic too, although my mind was a bit haywire it got me thinking about a project I had on hold for a while which I need to get back to.

I had some beginners luck with my light, I used the PICAXE which is designed with students in mind so it is super simple to get going - so I am still a novice with PIC's.

I noticed you have some other unused pins on your PIC, any plans for those yet? Maybe a low battery indicator?
 
1 - 20 of 48 Posts
This is an older thread, you may not receive a response, and could be reviving an old thread. Please consider creating a new thread.
Top