Author Topic: Problem with my Syren Controller?  (Read 3223 times)

0 Members and 1 Guest are viewing this topic.

Offline silo_xtremeTopic starter

  • Robot Overlord
  • ****
  • Posts: 173
  • Helpful? 0
  • I really love robots, they keep me awake at night.
Problem with my Syren Controller?
« on: May 20, 2009, 12:32:17 PM »
I have a Syren25 and when the S1 wire is not connected to the Syren the motor is off.

When the Syren25 has a S1 wire connected to it, and the other end of the S1 wire is not connected to anything , the motor runs.

It's also not responsive to any commands.

I have it in Simple Serial mode.  I'm thinking my Syren has a short in it ..... would this be a correct thought? ???


Offline Admin

  • Administrator
  • Supreme Robot
  • *****
  • Posts: 11,703
  • Helpful? 173
    • Society of Robots
Re: Problem with my Syren Controller?
« Reply #1 on: May 23, 2009, 10:35:30 PM »
lol sounds like the wire is somehow acting as an antenna . . . check to make sure your grounds are common, and that your other wiring is correct.

Offline silo_xtremeTopic starter

  • Robot Overlord
  • ****
  • Posts: 173
  • Helpful? 0
  • I really love robots, they keep me awake at night.
Re: Problem with my Syren Controller?
« Reply #2 on: May 24, 2009, 09:08:25 AM »
LoL, I know it's an interesting problem. 

My 5V source and 24V source are separate power sources, isolated from each other.  I had another interesting problem when I tried to use the 5V output on the Syren ... I ended up with 33V as an input into the Syren.

I think there's something wrong with my Syren's ... but I need a sanity check.

Offline Admin

  • Administrator
  • Supreme Robot
  • *****
  • Posts: 11,703
  • Helpful? 173
    • Society of Robots
Re: Problem with my Syren Controller?
« Reply #3 on: May 24, 2009, 09:52:16 AM »
Quote
My 5V source and 24V source are separate power sources, isolated from each other.
As I suspected, you need to keep grounds common. :P

Offline silo_xtremeTopic starter

  • Robot Overlord
  • ****
  • Posts: 173
  • Helpful? 0
  • I really love robots, they keep me awake at night.
Re: Problem with my Syren Controller?
« Reply #4 on: May 24, 2009, 10:09:27 AM »
 Haha, That looks like it fixed the noise problem!  Thanks!!!  ;D

Now how come my code won't turn it off after it starts?

Code: [Select]
// USART2 initialization
// Communication Parameters: 8 Data, 1 Stop, No Parity
// USART2 Receiver: Off
// USART2 Transmitter: On
// USART2 Mode: Asynchronous
// USART2 Baud Rate: 38400
UCSR2A=0x00;
UCSR2B=0x08;
UCSR2C=0x06;
UBRR2H=0x00;
UBRR2L=0x19;


                UDR2=190;
                delay_ms(1000);                     
            UDR2=127;

while(1);


I'm a bit confused on that one.

Offline Admin

  • Administrator
  • Supreme Robot
  • *****
  • Posts: 11,703
  • Helpful? 173
    • Society of Robots
Re: Problem with my Syren Controller?
« Reply #5 on: May 24, 2009, 10:13:21 AM »
What mcu you using? :P

Offline silo_xtremeTopic starter

  • Robot Overlord
  • ****
  • Posts: 173
  • Helpful? 0
  • I really love robots, they keep me awake at night.
Re: Problem with my Syren Controller?
« Reply #6 on: May 24, 2009, 10:14:30 AM »
Heh, Sorry.

ATMEGA 1280

I don't get any response or change in direction either  ... I can just turn it on with a signal.  It's weird.

Offline Admin

  • Administrator
  • Supreme Robot
  • *****
  • Posts: 11,703
  • Helpful? 173
    • Society of Robots
Re: Problem with my Syren Controller?
« Reply #7 on: May 24, 2009, 10:19:11 AM »
Reverse the 190 and 127 . . . that'll offer a clue to what isn't working.

Offline silo_xtremeTopic starter

  • Robot Overlord
  • ****
  • Posts: 173
  • Helpful? 0
  • I really love robots, they keep me awake at night.
Re: Problem with my Syren Controller?
« Reply #8 on: May 24, 2009, 10:22:45 AM »
The motor turns on as soon as I hit the program chip button.

In order for me to get the motor to stop, I erase the chip and cycle the power to both the chip and Syren.

 ???

Offline Admin

  • Administrator
  • Supreme Robot
  • *****
  • Posts: 11,703
  • Helpful? 173
    • Society of Robots
Re: Problem with my Syren Controller?
« Reply #9 on: May 24, 2009, 10:24:12 AM »
This means either your wiring still isn't correct, or your UART isn't working as you thought.

Got an oscope?

Also, attach your uart to hyperterminal to see the actual output.

Offline silo_xtremeTopic starter

  • Robot Overlord
  • ****
  • Posts: 173
  • Helpful? 0
  • I really love robots, they keep me awake at night.
Re: Problem with my Syren Controller?
« Reply #10 on: May 24, 2009, 10:28:53 AM »
No Oscope, suppose I should buy one.

Will try to get the USART to hypertem soon.

I've been trying to do everything on the JTAG interface ,....  I can debug the chip..

Offline silo_xtremeTopic starter

  • Robot Overlord
  • ****
  • Posts: 173
  • Helpful? 0
  • I really love robots, they keep me awake at night.
Re: Problem with my Syren Controller?
« Reply #11 on: May 24, 2009, 10:45:27 AM »
What should I look for with an Oscope or USART to Hyperterm?

Offline Admin

  • Administrator
  • Supreme Robot
  • *****
  • Posts: 11,703
  • Helpful? 173
    • Society of Robots
Re: Problem with my Syren Controller?
« Reply #12 on: May 24, 2009, 11:19:20 AM »
What should I look for with an Oscope or USART to Hyperterm?
If its hyperterminal, you should see numbers representing what you sent to serial of your Syren.

If an oscope, you'll see a TTL binary of the number (square wave, high for 1, low for 0). Just use the trigger setting to capture it.

Offline sonictj

  • Supreme Robot
  • *****
  • Posts: 416
  • Helpful? 11
    • Tim's Workshop
Re: Problem with my Syren Controller?
« Reply #13 on: May 24, 2009, 02:58:15 PM »
Quote
If its hyperterminal, you should see numbers representing what you sent to serial of your Syren.

you should see the equivalent ascii character not number. you will have to convert to see the equivalent number.

Offline silo_xtremeTopic starter

  • Robot Overlord
  • ****
  • Posts: 173
  • Helpful? 0
  • I really love robots, they keep me awake at night.
Re: Problem with my Syren Controller?
« Reply #14 on: May 25, 2009, 10:26:26 AM »
Just thinking.

I could try packetized serial mode with address 128.

Would this be the correct code to send 1 packet and test this concept?

Code: [Select]
UDR2=128;
                UDR2=127;
                UDR2=64;
                UDR2=((128 + 127 + 64) & 0b01111111);

Offline Admin

  • Administrator
  • Supreme Robot
  • *****
  • Posts: 11,703
  • Helpful? 173
    • Society of Robots
Re: Problem with my Syren Controller?
« Reply #15 on: May 25, 2009, 05:45:42 PM »
I personally recommend just using AVRlib. Its code that you know works, and its user friendly.

 


Get Your Ad Here