Oscilloscope is flatlining - need help setting it up

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

Hi,

 

I'm trying to debug some SPI signals with my oscilloscope but I seem to be unable to set things up right.

I have an ATUC256L4U, the SPI is sending data, however, I can't seem to get a reading of anything with my oscilloscope TEKTRONIX MSO 2014 everything is just a flat line.

https://ww1.microchip.com/downlo...

 

I'm powering the board at 3.3v, 60mA. 

Attachment(s): 

This topic has a solution.

1010001010111101110111

Last Edited: Thu. Jul 1, 2021 - 07:57 AM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Go back to basics. Just touch the probe alternately to Gnd and Vcc. Does it jump up and down? As a back up check the Vcc level with a DMM.

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

Your scope has a source of squarewaved at the bottom right, usually used to adjust the probes, but useful as a quick check. 

#1 Hardware Problem? https://www.avrfreaks.net/forum/...

#2 Hardware Problem? Read AVR042.

#3 All grounds are not created equal

#4 Have you proved your chip is running at xxMHz?

#5 "If you think you need floating point to solve the problem then you don't understand the problem. If you really do need floating point then you have a problem you do not understand."

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

The probe works fine, even the SPI seems to work fine. I need to test one bug but I can't seem to get anything to output on the oscilloscope. I can still send commands over the SPI to the target peripheral. 

1010001010111101110111

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

Brian Fairchild wrote:
f squarewaved at the botto

 

You mean the calibration pins? I've tested the probe with them - it seems to work. The only thing I can't get working is the digital SPI signal. I'm wondering if the thresholds are set wrong or something like that.

1010001010111101110111

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

make sure all scope channels are set to DC coupling...never use AC unless needed. DC shows the actual signal.

 

Make sure your gnd wire for each channel is really connected to gnd (verify your chosen gnd point is really a gnd point). You obviously can't measure a voltage reliably without a solid gnd.

Also, unless the scope is floating the gnd point must be at gnd or you can blow out the scope.....do not use a line voltage cheater cord.!!!

When in the dark remember-the future looks brighter than ever.   I look forward to being able to predict the future!

Last Edited: Tue. Jun 29, 2021 - 12:29 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

avrcandies wrote:

make sure all scope channels are set to DC coupling...never use AC unless needed. DC shows the actual signal.

 

Make sure your gnd wire for each channel is really connected to gnd (verify your chosen gnd point is really a gnd point). You obviously can't measure a voltage reliably without a solid gnd.

Also, unless the scope is floating the gnd point must be at gnd or you can blow out the scope.....do not use a line voltage cheater cord.!!!

 

I'm using the digital channel, it has 8 digital pins + ground. There is no AC setting for it. When using the regular probe to verify stuff it has always been in DC mode. As seen in the pictures, GSGAIN is the only signal that is high. The SPI signals themselves don't seem to do ANYTHING at all. I've tried different trigger settings too... Not sure with is going on.

 

Even the SCK line just shows a permanent HIGH signal.

1010001010111101110111

Last Edited: Tue. Jun 29, 2021 - 01:31 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Mithrandir_ wrote:
I'm using the digital channel, it has 8 digital pins + ground.

Use the "scope" part to see if there are signals changing on those lines, it may be the LA portion of your scope is correct, and there is nothing to see.

 

Jim

 

PS: west coast Jim may have better insight into your Tek issues, wait a couple more hours to see if he pops in after his morning joe.

 

 

 

FF = PI > S.E.T

 

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

ki0bk wrote:

Use the "scope" part to see if there are signals changing on those lines, it may be the LA portion of your scope is correct, and there is nothing to see.

 

Jim

 

Yes, I tried that. Every pin shows a permanent high signal. Especially confused by the fact that the clock seems to be showing a permanent high signal.

 

Quote:

PS: west coast Jim may have better insight into your Tek issues, wait a couple more hours to see if he pops in after his morning joe.

 

Alright, will do, thanks.

 

I'm trying to see what I should set as the threshold for the trigger in the data sheet - not quite sure tbh. I left it at the standard 1.40 V. It should trigger when SS is pulled low.

1010001010111101110111

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

Forget about spi...try blinking an led ...does the scope/logic show that?

I'm using the digital channel, it has 8 digital pins + ground.

Make sure every gnd lead is well-grounded to actual gnd

 

also, don't use trigger mode, use auto  mode...you should at least see some random pulses/blips on the screen.(assuming you are heavily working the pins)....If you do, then try triggering on things.

When in the dark remember-the future looks brighter than ever.   I look forward to being able to predict the future!

Last Edited: Tue. Jun 29, 2021 - 03:41 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Mithrandir_ wrote:
the SPI is sending data

Does it means that the SPI mode is Master, please.

So, you can produce a loop, one char sending each 10ms- it must be visible on the single channel scope, MOSI and SCK pins are important.

 

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

Ok, so I RTFM and I have a few questions.

 

If you ground the probe pins to the probe ground, do the levels change on the screen?

 

If they do not, press the button just to teh right of the PRINTER button under teh lower left corner of teh screen.  That turns teh Logic analyser inputs off and on.  Repeat the test of grounding teh leads....

 

East Side Jim

I would rather attempt something great and fail, than attempt nothing and succeed - Fortune Cookie

 

"The critical shortage here is not stuff, but time." - Johan Ekdahl

 

"Step N is required before you can do step N+1!" - ka7ehk

 

"If you want a career with a known path - become an undertaker. Dead people don't sue!" - Kartman

"Why is there a "Highway to Hell" and only a "Stairway to Heaven"? A prediction of the expected traffic load?"  - Lee "theusch"

 

Speak sweetly. It makes your words easier to digest when at a later date you have to eat them ;-)  - Source Unknown

Please Read: Code-of-Conduct

Atmel Studio6.2/AS7, DipTrace, Quartus, MPLAB, RSLogix user

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

grohote wrote:
Does it means that the SPI mode is Master,

OP needs to tell us what AVR he/she is using, as the atmega has a bad habit of switching from master to slave if the SS pin is left floating as an input!

 

Jim

 

 

FF = PI > S.E.T

 

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

My first SPI was Simulated Master- Real Slave on the same chip. The most tricky pin is /SS, you have to operate it yourself.

 

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

Almost no knowledge of Tek digital scopes. Will change shortly, though.

 

Since the scope calibrator seems to be shown on the screen, try connecting a probe to target Vcc, then target ground using auto-trigger on the scope. Does the trace shift vertically when you do this? If it does, then you are not configuring SPI properly. The SS pin causes lots of problems! Is the scope sweep speed appropriate for the SPI clock rate?

 

West Coast Jim

 

Until Black Lives Matter, we do not have "All Lives Matter"!

 

 

Last Edited: Tue. Jun 29, 2021 - 05:43 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

ka7ehk wrote:
no knowledge of Tek digital scopes

Why you/we should have any. I am proud owner of TEK-2235, with them no MOSI or SCK move may be unnoticed.

The OP does have the perfect chip, the perfect scope, yet, something does not.

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

Mithrandir_ wrote:
I have an ATUC256L4U

I missed this the first time I read the OP, thought it was the slave device, my bad!

So this is not an AVR!

 

Jim

 

 

FF = PI > S.E.T

 

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

ki0bk wrote:
So this is not an AVR

Why not, it is 32-bit Atmel AVR.

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

Folks ask me about Tek scopes because I used to work there in oscilloscope design. All with big cathode ray tubes, before modern digital scopes.

 

Jim

 

Until Black Lives Matter, we do not have "All Lives Matter"!

 

 

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

Can you get the scope to trigger at least on basic digital signals?  Just rapidly toggle some port pins---can you at least see those?  If not, you have bigger issues than spi configuration.  Maybe your scope digital probe is defective.

When in the dark remember-the future looks brighter than ever.   I look forward to being able to predict the future!

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

Take a step back and go back to the 'analog' world.

First make sure you get signals on the lines using the analog part, then you know what your timings need to be and confirm that your signal levels are OK.

Then switch back tot he 'digital' world and start by looking at 1 channel at a time and get that to show correctly. Then add channel after channel and see that things keep on working and showing as expected.

 

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

I had an MSO-2014 when I worked for a previous employer. It is a fine but phenomenally expensive scope.

 

Make sure the 16-Channel plug is securely clicked into place. I once had the same issue you have. The trouble was an improperly located digital input plug.

 

PS: Make sure you connect up the correct colour little spring clips to your chosen signals/channels. That's something else I've done wrong.

 

This reply has been marked as the solution. 
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 1

So it turns out that the issue was quite simple in the end. I used the analog probe to see what was going on when I sent information down the line. Somebody above here suggested that I use a falling edge with the analog probe as the trigger condition for the SS instead of the bus. When I did that I noticed that it was not getting triggered when I activated the peripheral that I was working on but rather another slave device. So the SS wires were crossed. Once I fixed that issue everything was working as intended. Thanks for all the help, it is much appreciated.

 

 

1010001010111101110111

Last Edited: Thu. Jul 1, 2021 - 07:57 AM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

N.Winterbottom wrote:
Make sure you connect up the correct colour little spring clips to your chosen signals/channels. That's something else I've done wrong.

 

I tripple checked all wires but this was still the problem =), the chip-select wires for the two devices controlled by the SPI were crossed.

1010001010111101110111

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

 

Mithrandir_ wrote:
Thanks for all the help

Apologies accepted.

 

 

 

 

 

 

 

Last Edited: Thu. Jul 1, 2021 - 08:17 AM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

So it turns out that the issue was quite simple in the end.

So why weren't you able to trigger on any of the lines when your were trying various settings & to get a response?  It doesn't matter what line is hooked to what, if you say trigger on channel 2, then it will trigger on channel 2---you should have pulses on all channels, so it should not flatline (be completely unresponsive)  regardless of which channel you use.

When in the dark remember-the future looks brighter than ever.   I look forward to being able to predict the future!