student project

formatting link

John

Reply to
John Larkin
Loading thread data ...

Nice!

But...

"Because the length of these traces are much shorter (millimeters) in comparison to normal cable lengths (meters), TDR (Time Domain Reflectometry ) systems used to measure the impedance of cables cannot be used. In order to perform these measurements, a TDR system, which is usually part of a Vector Network Analyzer or a Digital Sampling Oscilloscope, must be used."

This is worded kinda poorly... you have to read the first sentence carefully to figure out that in the second sentence they mean, "a TDR system -- but not the kind used to measure the impedance of cables -- must be used." When people think "TDR" I don't think many immediately have a mental distinction between "TDR sytems used to measure cables" and "TDR systems used to measure circuit board traces." :-)

It'll be really cool if you guys get a functioning widget out of this! How long total do they have to do it in?

---Joel

Reply to
Joel Koltner

On a sunny day (Wed, 17 Nov 2010 08:36:28 -0800) it happened John Larkin wrote in :

Nice.

Reply to
Jan Panteltje

That looks like it could be fun. I have no experience with TDR systems. (Except in college we found this big spool of coax (~500 feet?) sent pulses down it and looked at the reflections as we changed the termination.)

Where is the step made?

BTW thanks for all the TDR data on resistors (different thread.)

George H.

Reply to
George Herold

Dang! Why can't I be a student again? ... ... Oh, now I remember.

--
Regards, Joerg

http://www.analogconsultants.com/

"gmail" domain blocked because of excessive spam.
Use another domain or send PM.
Reply to
Joerg

No reason you can't do it as a "hobby" project -- and I expect your "hobby" funds are rather larger (like, an order of magnitude larger!) than they were in college...

Reply to
Joel Koltner

Sure, but now the problem is that there is no time for this. Work, work, work during the week and then on weekends there's this ever-growing honey-do list.

Right now I'd rather be designing a TDR pod than what I am doing. Plowing through uC code that I haven't written, trying to find a hang-up condition. Hurumph.

--
Regards, Joerg

http://www.analogconsultants.com/

"gmail" domain blocked because of excessive spam.
Use another domain or send PM.
Reply to
Joerg

Yeah, understood. Maybe you can find someone on Craigslist for some of the the honey-do bit? :-)

I didn't realize you were willing to go through uC code... good to know!

---Joel

Reply to
Joel Koltner

I particularly liked their handdrawn approach illustrating the use FFTs (likely, not shown) to understand the system response so that constants could be developed to generate a better step response output.

That's a nice addition. A driven step goes through "some black box." The microcontroller's drive over time behavior (A) convolves with some analog BLACK BOX (B) to produce some actual drive over time (C). A*B=C. By analyzing samples of A and C, one can develop a static estimate of B=C/A (but as it is differentials, somewhat noisy.) Knowing B now, and a desired C, one can construct the required A to achieve C.

I like it.

Jon

Reply to
Jon Kirwan

But then when it's not done right in the eyes of the missus I'll have to do it again myself :-)

No, I am not an expert in code at all. But sometimes there are situations where the client is a small company and they go the code from some design house. Then I sometimes have to, to find hang-up causes and occasionally there stuff like a mishandled WDT, registers not set up, or unused pins asserted the wrong way.

--
Regards, Joerg

http://www.analogconsultants.com/

"gmail" domain blocked because of excessive spam.
Use another domain or send PM.
Reply to
Joerg

If you mean the sketch, I drew that!

I have a deconvolution algorith we plan to use to generate the FIR equalization filter, to beautify the step. But it's all time domain, no FFTs involved.

ftp://jjlarkin.lmi.net/TDR_Decon_demo.jpg

The purple trace is the impulse response of the FIR filter that turns the ugly step (yellow) into the final step (white). The algorithm evolves the filter from the input waveform and a target (ideal) waveform.

I've been wanting to do this for years but could never justify the effort. These guys needed a project, so shazam. They did have a hard time getting their instructor to approve it as a project, same problem I had with my senior project.

John

Reply to
John Larkin

How come this one didn't have any stains?

--
SCNR, Joerg

http://www.analogconsultants.com/

"gmail" domain blocked because of excessive spam.
Use another domain or send PM.
Reply to
Joerg

I did that last night, reading a lot of C code that's written like most C code: absurd variable names, no comments, insane logical constructs, ugly smushed-together syntax, matching brackets scattered over five pages, everything you need to know somewhere else in some other file. I actually found the bug

if (counter == 0)

{--counter} ;

or some such. It's supposed to be an error timeout down-counter.

C is a horrible language embedded in a horrible culture. I've been getting sample programs from intern applicants and it's scary. It's "code" for sure.

John

Reply to
John Larkin

In this code they are pretty clear. But not all of them are in English. Now I know that prueba is test and seg does not mean segment but segundo. Where's my margarita?

But what can you do? Everyone uses it, and the occasional inline assembler in there feels like a true refreshment. Even to a guy like me who does not program. Similar to getting back into your trusty stick-shift car after driving an automatic for days.

--
Regards, Joerg

http://www.analogconsultants.com/

"gmail" domain blocked because of excessive spam.
Use another domain or send PM.
Reply to
Joerg

On a sunny day (Wed, 17 Nov 2010 14:14:41 -0800) it happened John Larkin wrote in :

C is a beautiful language to those who understand it. It is close to the hardware, and pretty much free format.

For those who do not understand it is like Greek to the non-Greek. I have to admit that the way some people layout the files can be confusing to newbies. Usually if I use code from somebody else I reformat the whole thing in my own style. While doing that I go through the code, get a picture so to speak of what it does.

I have seen so much C code from others, because of open source, that I am used to ever different styles by now, just read it. At that point you can focus on what it does. You are still trying to learn to spell the words. Thats is a process involved with learning any language, computer related or real, like French and German, and Dutch, and English. It is not that one language is 'worse' than the other, it is just that you do not have enough experience using it.

Reply to
Jan Panteltje

Oh, most non-Greeks still know the important ones. Ouzo, Retsina, and so on. And more recently, pistotika (credit) :-)

newbies.

style.

does.

real,

IMHO there is only one way to learn, full immersion, not by learning individual words. Context is all. I learned Dutch that way and also electronics. After numerous explosions I finally figured out which brands of capacitors were better than others, and then why: ESR. At school they hadn't taught us that.

--
Regards, Joerg

http://www.analogconsultants.com/

"gmail" domain blocked because of excessive spam.
Use another domain or send PM.
Reply to
Joerg

newbies.

style.

does.

real,

The C culture avoids useful comments in favor of long variable and procedure names, which is stupid. It packs as much punctuation on one line as possible, which requires character-by-character analysis to find bugs. It scatters related stuff into different files, or even different linked modules. C programmers rarely note what a routine is for, who wrote it, when they wrote it, what version it is, or what changed from the last version. Explanations of algorithms, background math, or usage notes/warnings, are pretty much unheard of.

Lots of organizations have a standard comments header that has to be at the beginning of any serious piece of code. Hardly anybody bothers to fill them in.

Few C programmers read their own code unless forced to. If they get a clean compile, they, or someone else, tests it for bugs. When they get tired of that, or run out of time, they ship it.

You can usually look at the source file for a huge C program and get no idea of what the program is for, what it does, what it runs on, what compiler it's supposed to be built under, who wrote it when, or what's different about this version. It's just code.

John

Reply to
John Larkin

now

)

k,

up

ng to newbies.

y own style.

t it does.

m used

or real,

ou

That sounds strange. When I was last involved in a project with serious software content I didn't have anything to do with code, but people talked about walk-throughs - explaining your code to someone else - and keeping every function down to less than one page of code.

They wanted their code to be readable and intelligible in five years time, for a new team of programmers. And they had cat-fights about variable names, which were also supposed to be intelligible ...

-- Bill Sloman, Nijmegen

Reply to
Bill Sloman

now

)

k,

up

ng to newbies.

y own style.

t it does.

m used

or real,

ou

All your comments apply to any languages, by bad programmers. C allows programmers to write nice and clean codes as well as bad codes. Sometimes, even good programmers make bad judgments without understanding the compiler. I just fix one problem by the previous programmer:

typedef struct { struct_macro_entry entry[MAX_MACRO_SIZE]; } struct_macro;

by removing the MAX_MACRO_SIZE. The run-time ram space reduced from

3K to 500 bytes. The previous programmer forced the compiler to allocate extra unneeded space. Until I read his code, i kept wondering why we need a 4K SRAM uC for such a simple task.
Reply to
linnix

to newbies.

own style.

does.

used

real,

Oh, wait until the next generation comes. They will require that an RTOS is loaded first :-)

--
Regards, Joerg

http://www.analogconsultants.com/

"gmail" domain blocked because of excessive spam.
Use another domain or send PM.
Reply to
Joerg

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.