Very interesting AT90CAN128 error...

Go To Last Post
3 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hello all!

 

I was doing some basic testing with my at90can128 today. By basic I mean turning on and off pins (controlling a relay board (fully isolated with optocouplers)), and sending PWM signals to servos (the servos were on a different powersupply, so no high current draw from the main board)). 

 

It was all going well until I realized the signaling LED's on PORTG started to randomly flash, the relays started to randomly turn on and off... for first I thought it was the code, but it wasn't...

Throught 1 hour of debugging, I've tried simple code like turning just the PORTG on and off, tried another powersupply, erased the flash, ext.

 

 

 

What could have cause for my microcontroller to "freak out" like that? Maybe the boards powersupply, crystal? 

 

 

 

Thanks!

Code is everything, code is life :D
 

Last Edited: Thu. Jan 26, 2017 - 10:40 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

It could be resetting due to watchdog timeout. It could also be stack over-running variable space. Pretty sure there are other situations that lead to the appear of "software freakout" but which really are not.

 

Jim

Jim Wagner Oregon Research Electronics, Consulting Div. Tangent, OR, USA http://www.orelectronics.net

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

There is no watchdog set and I've tried a simple PORTG LED on and off and same situation

Code is everything, code is life :D