-
A few months later...
06/17/2016 at 13:50 • 0 commentsSo i've not really done any work on this since I assembled a couple of test units. I've been using one daily for the last few months and it's been incredibly handy. Quick and easy to use, does the one thing it's meant to do well - perfect.
Sometimes I feel products can be overcomplicated. Do one thing and do it well.
-
Initial Testing
03/29/2016 at 14:56 • 0 commentsQuickly hand soldered one together - SMD parts on pads not designed for hand soldering is fun... It's not pretty but it works!
Had some issues with the 100nF capacitor on the reset pin (I should really look up what value it should be...) so I just removed it, otherwise the programmer wouldn't detect it. It seems to work fine without the cap so I'll just leave it out. Same with C1 and C3 which are loading caps for the clock crystal. The MSP430 has built in configurable capacitance which is enough for the crystal I'm using.
Currently running it at 1sec = 1min accelerated speed so it can run through the full 3 day cycle in a matter of hours for testing.
It will be interesting to see how long the battery lasts in normal usage. I used 230ohm resistors to limit the current to under 5mA. WIll properly measure the current at some point, and tweak values to get an even brightness from each LED.
-
PCB & Plexi Case Arrival
03/29/2016 at 12:17 • 0 commentsI initially paid for EMS shipping for my order from Elecrow, but for some reason, customs/EMS Post rejected the package and sent it back to elecrow after a week. Elecrow were very helpful after I contacted them, and had it re-shipped via DHL. The package arrived within a couple of days, so from now on I'll spend the little bit extra for DHL over EMS.
I quickly tapped M3 threads into one of the back pieces, and did a dry fit of all the pieces. I quickly realised the holes on the front piece were not aligned properly. Turns out I'd misplaced them 1mm too high on my cad design / DXF file... oh well. I want to make the back piece much closer to the battery holder (now I actually have the physical holders I can confirm dimensions - the joy of buying random things from Aliexpress without part numbers or datasheets).
My idea to use pogo-pins for programming through some well placed holes in the case turned out well. Elecrow's laser cutting service has no issues cutting such tiny holes (approx 1.8mm if I remember correctly).
-
Launchpad Dev Platform & Current Measurements
02/29/2016 at 14:27 • 0 commentsWhen I started this project, I knew I needed a low cost and low power microcontroller. All it really needed was a timer, some basic IO (5 pins), and the ability to use a watch crystal. Looking around my lab/study, I found some old MSP-EXP430G2 Launchpads. The kit includes an MSP430G2211 which is close enough to what I will be using (it's in the same family, and has analog comparator functions that the G2201 doesn't have, otherwise the same chip). The pin headers connecting the debugger section to the target section came in handy for taking power measurements.
Using my trusty Dave Jones uCurrent Gold, and a Keithley 2000 DMM, I was able to take measurements in various states.
Running the core off the internal oscillator (DCO), which runs at approximately 1 MHz, with a /8 divider, results in a core clock frequency of 125kHz. Running current is 100uA at this frequency.
Running the core off the external watch crystal, 32.768kHz, with a /8 divider, results in a core clock frequency of 4.1kHz. Running current is 6uA at this frequency. However, I had some issues where it would boot up and run off the DCO, because the LFXCLK wasn't ready yet. There's an interrupt that occurs when LFXCLK fails, which I could use to then kick it back into low frequency mode. However, the device only runs in full power mode for a few seconds at a time, so I didn't bother. DCO it is.
In Low Power Mode 3, with the internal timer running off the 32.768kHz external clock, with interrupts enabled for the button, current consumption was a measly 600nA.
I have yet to decide on resistor values for the LEDs, but will be looking to keep the LED current around 2mA or less to reduce battery power consumption. A quick calculation shows I should get 6-12months of runtime easily with the occasional manual viewing of status.
FYI: If you are using Code Composer Studio, and haven't tried out GRACE yet, do it. It's super easy to setup chip peripherals using a GUI. I had the timer, IO pins, clock sources, etc all configured in no time using GRACE.