Custom Search

Tag Archives: Hardware

430 work shop links and source code

0
Filed under electronics, Hardware, MSP430
Tagged as , ,

source code zip of all the projects that were demoed at workshop 88 http://www.workshop88.com/
demos
(the code is in mspgcc format and may need alterations to compile for CCS & IAR)

Sources code for Shift register demo
original code here

servo demo
original source

Music demo
Original source here

The RGB demo was not there
source http://justinstech.org/projects/msp430-rgb-flower-pot/

upcomming small projects

0
Filed under electronics, Hardware
Tagged as , , ,

Upcoming project and circuit

  • Motor Driver for Helicopter
  • Servo power supply for helicopter
  • interface board to hook up mbed, gyro and accelerometer

Im hoping to get most of these done in the next week and a half

pics of my work in progress to come :)

edit Pics :)

TTL/MOS timer experiments

0
Filed under electronics, General, Hardware
Tagged as , ,

I have this dual 556 timer that i have wanted to use, just because it can take 15V and work with out an issue and as low as 3V. (thanks TI) So i was thinking that this had some potential to be used for RF or a fixed PWM signal. (personally i would like to pick up a few digital POTs and a digital cap to to create a DCO of some sort)
So far i have played with it and found some interesting things out.

TLC556 Dual Cmos Timer Data Sheet

My first goal was to get a 50% duty cycle from the chip, this was pretty easy just choosing the correct values for Ra and Rb, but you will have to do some math and you should use the equation out of the data sheet for your chip. My equati0n Period = tH + tL ~= CT (RA + 2RB) In 2, but if you need values closer to what is measured, you will have to break out the TI 8x and plug in tH = Ct (Ra + Rb) ln [ 3 - exp(-t PHL / Ct (Rb + Ron) ) ] + t PHL and Tl = Ct (Rb + Ron) ln [ 3 - exp(- t PHL/ CT(Ra + Rb)) ] + tPLH.  I know these equations look difficult but as long as you plug in your values you will get close to what you measure on your oscilloscope. but i did this the fun way, use the first equation to get close to what you need then tweak the rest of the values until you get something close to what you want.

The values that i chose first were the Ra and Rb, I chose Ra =  220 ohms and Rb =  100 ohms and Ct = .0047 uF.  Rl and Cl i did not choose a value nor did i hook up those components, i will have to look into the reason they are there, but i’m sure they are there for good reason. This first Test was just to make sure i can get a good square wave and be able to shape it.

the new values that i used are – will update later, but frequency is near 1 Mhz

My second goal was to try and make a sine wave or shape the square wave to be better for RF transmission. I added a Pi Network to the out put to shape the wave and below is what i got for half of the pi network, i will have better pics of the final wave form once my circuit is a little more complete.

another pic

and another

If all goes well and i can create a pretty stable transmitter i will be hooking up a small modem chip to the circuit and create a cheap digital modem . Another thing that would be nice would be a pair or transmitters and receivers so i can send and receive at the same time.

update-

R1 100 ohms

R2 220 ohms

C1 .0047uF

MSP430 RGB V0.1

2
Filed under electronics, Hardware, MSP430, programing, software
Tagged as , , , ,

A different take on how to create a PWM signal. I decided to go the interrupt route using the WDT+ peripheral. I did this by setting it to the interval timer and putting all my counters and logic within the interrupt. The funny thing is  i have read that you shouldn’t put too much code into your interrupt, or something bad will happen.

the resistors on the left, are 100 ohm resistors and the one on the right is a 470 ohm resistor to limit current for the RGB LED. connections on the uC that are used are pins 1.3, 1.4, 1.5 i have not decided which pins are what color, i will decide that on my final build.

The test code will be improved this is just the compile and see if it works.- The best part , the code works lol .

so let me know what you think on creating PWM with the interval timer instead of timer A.

#include <msp430x20x2.h>
#include <signal.h> //add for interrupt
#define UP 0x00
#define DOWN 0x01
volatile  int millsecs = 0;
volatile  int counter2 = 0;
volatile  int led_red = 0;
volatile  int led_green = 199;
volatile  int led_blue = 199;
volatile  int dir = UP;
void main(void)
{
WDTCTL = WDT_MDLY_0_064;
P1DIR |= BIT5 + BIT4 + BIT3;
P1OUT |= BIT5 + BIT4 + BIT3;
IE1 |= WDTIE;
eint();
}//end main
interrupt(WDT_VECTOR) watchdog_timer(void)
{
++millsecs;
if (millsecs == 200) { millsecs= 0; P1OUT |= BIT0 + BIT6; ++counter2; }
if (millsecs == led_red ) { P1OUT ^= BIT3; }
if (millsecs == led_green) { P1OUT ^= BIT4; }
if (millsecs == led_blue ) { P1OUT ^= BIT5; }
if (counter2 == 25 ) { counter2 =0;
switch (dir){
case UP: ++led_red; --led_green; --led_blue;
if (led_red == 199) {dir = DOWN;}
break;
case DOWN: --led_red; ++led_green; ++led_blue;
if (led_red == 0) {dir = UP;}
break;
}//end switch
}//end if
}//end interrupt

To change the Period length – change the 200 value to the period you want, you can also change it by setting the WDT interval to different intervals to change the period.
to change the Duty cycle, change the led_[color] variable to anything between 0 and period length

I am still working on trying to get it to cycle through all colors, and fade better when led_[color] is close to 0
by far this project is not done, the board will be soldered up and pics will be presented. The end result should be code for WDT PWM, which could be used for servos, LEDs, or possibly communication, and i will have my flower pot back!

Samples are coming from Zilog

0
Filed under electronics, General, Hardware
Tagged as , , , ,

Z16C3516VSG IC 16MHZ Z8500 CMOS ISCC 68-PLCC 1
Z86E0812SEG1903 IC Z8 2K OTP 12MHZ RC OSC 18SOIC 1
Z8F0423SB005EG IC ENCORE MCU FLASH 4K 8SOIC 2
Z8F0830SJ020EG IC ENCORE XP MCU FLASH 8K 28SOIC 2

cant wait to figure out how to program ….well i can wait