Skip to main content

Show Posts

This section allows you to view all Show Posts made by this member. Note that you can only see Show Posts made in areas you currently have access to.

Messages - alank2

1
Bus Pirate Support / Re: Buspirate v3 VS v4
So is the v4 a dead project at this point?  It is the only BP I have and it works fine for most things I've tried on it.  What does not work on it/is there a bug list for it?  Sometimes I'm tempted to get a v3 BP just so I've got the more stable version to work with...
3
Bus Pirate Support / Re: BPv4 1 wire not working for me
Well....it turns out that the temp/humidity sensor is NOT a 1wire device, and hence, that is the reason it does not work.

I put a couple of DS18B20's on with it and it works perfectly.
4
Bus Pirate Support / BPv4 1 wire not working for me
Hi Everyone,

I started out by updating to the latest bp package 6.1 firmware.

I've got a temp/humidity sensor from seedstudio (SEN51035P) that I was going to try to connect to.

I connected the 5V/GND/MOSI pins from the BP4 to it.  I enabled the power supply.  I enabled the pullups.  I used the e command to connect the pullup pin.  I went into the 1wire mode.  I tried to send a reset.  I've got it hooked to my scope so I can see what it does.

Sure enough it does send a 480us low pulse.  If I have the data line disconnected from the thermometer it works as expected.  I see the RESET and nothing else.

Here is where it goes wrong - if I hook the data line back up I can properly see the "Answer to Reset" from the device, but the BP doesn't see it.  It complains about "Warning: *Short or no pull-up”.

I can see a lot more traffic after this.  I issued a { 0x33 r:8 and the bytes read would change between executions even though the data on the scope looked the same.

Any ideas?

Thanks,

Alan
5
Project development, ideas, and suggestions / Re: Input for my frequency counter questions...
Hi Mick,

[quote author="MickM"]I would try to copy an oscilloscope input circuit.
Or even better rip one out of an old scope, or get a plug-in module for a TEK (7000 series?)
http://www.barrytech.com/tektronix/tek7 ... copes.html
[/quote]

I am hoping to use standard available parts and yet keep the part list down as well, but for a one off I can't see anything better than using a scope input stage type module!  I haven't looked at scope input circuits too much yet, but I may start.

I've been playing around with this input stage:

http://www.piclist.com/techref/piclist/ ... ircuit.htm

It has a lot of things I like, but yet still falls short in some areas.  My initial problem was that I wanted to support an input signal as small as 50 mV rms and it didn't haven enough gain.  The circuit is designed for 9V operation although I'm using it with 5V.  I changed R4 to 50 ohms last night and R5 to 1K which gave me enough gain and I was feeling pretty good about it until I started testing various speed oscillators that I have.  If anyone has comments on these value changes please let me know, I figured I could probably drop to 50 ohms since my voltage is lower on R4, but truly I don't fully understand the circuit.  I've tried reading the Art of Electronics and other books on it but it hasn't come to me!  To try to understand it better, I tried the PNP without the JFET present making the assumption that the JFET was either open or closed and that also didn't work as I could adjust the pot from range to range without seeing the output move to the middle.  I must assume that the JFET provides a range of resistances for the input signal fluctuating between -.6 and +.6.  I noticed that the range of adjustment was greatly diminished when moving R5 to 1K, but it did give me the gain I wanted.

I noticed that slower (10MHz and lower) did ok, but that the clamping diodes made a mess of the signal around 25 MHz.  I disconnected the jfet gate and was just looking at the signal up to that point where it is clamped by the diodes.




At 80 MHz it didn't seem all that bad however. 




The diodes I am using are the 1N4148's called for by the schematic and their reverse recovery time is 4ns which I would think is fast enough, but it seems to be these diodes that are causing the 26MHz signal to look so bad.  Do I need to look at faster diodes?

Other traces I did:

5Mhz:


24Mhz:


All comments welcome!  I was feeling pretty hopeful last night with it until I saw the signal being changed so much when I tested it at different frequencies...

Thanks,

Alan
6
Project development, ideas, and suggestions / Re: Input for my frequency counter questions...
Hi,

[quote author="foxit"]Would you write a list of components for device?[/quote]

This list is preliminary, but:

1 main cap

(2) quad cc led 7 segment displays

3 buttons
4 leds
4 led current limiting resistors

max7219
bypass cap
1 resistor for max7219 current setting

atmega168
(2) bypass cap
reset pullup resistor 10k

mc74ac4040n prescaler
bypass cap

mc74ac132n nand
bypass cap

16.3676 MHz TCXO 3V
bypass cap

3V linear voltage regulator
bypass cap

I'll be adding one more button and one more LED for the low/high/average mode I plan to add which when enabled (led lit to indicate enabled), it will keep track of the lowest, highest, average, count, and last measurement and the user can press the button to toggle between them.

Thanks,

Alan
7
Project development, ideas, and suggestions / Re: Input for my frequency counter questions...
Hi,

foxit:  The input stage is the last thing I need to finish on this.  Once it is done, I'm going to design a pcb and do the documentation.  When I'm done (hopefully in the next month or so), I'll post the entire project with source code and gerber files for anyone who wants to build one.

arakis:  It is a reciprocal frequency counter so I am measuring the period of a signal (or multiple signals) against the internal uc clock.  I have a timer clocked 1:1 with the uc clock and am using an input capture unit to get a count of cpu cycles for a count of signal cycles.  I am still using a gate time although it merely sets the minimum time to wait and a final trigger is taken after the gate time to get both a (1) count of signal cycles and a (2) count of uc cycles.  Once I have both of those I just do the math to calculate the frequency.  I am using a prescaler that is switched on or off automatically depending on the input signal, and as long as the prescaler doesn't change, successive measurements are taken back to back with no signals ignored.  Whether measuring 10 Hz or 80 MHz, you will get the same precision which is log10(uc clock).  I am currently using a 16.7636 Mhz TCXO because it was reasonably cheap and is very stable, but you can feed it a clock between 10MHz-20MHz from any reliable source.  It has a button to change the gate time, to hold the display, and one to enhance the precision which bumps the number of digits up by 1 if there is room on the display.  Values on the display are rounded and automatically scaled between Hz, kHz, and MHz.  Edit: It also does not require the uC clock to be tuned (or tunable) specifically to a frequency, you can specify the actual frequency and it is stored in eeprom.  It also has a calibration mode where you provide a 10MHz reference clock and it will figure out its internal frequency.

joushou:  It isn't that I really want to measure mains so much as I'd like the input stage to tolerate it.  I was thinking US mains voltages, 400V max.  One of the input stages I've tested (not with mains, but is designed to tolerate it) has a 1.5uF capacitor feeding a 100K/1M divider that is then clamped by a couple of diodes.  It then feeds a jfet/pnp combination.  It isn't bad and I may end up going with it if I can't find something better, but it doesn't give enough amplification for smaller signals such as 50mV rms.  Even though the breadboard picture above looks pretty big, I plan squashing it as small as possible while still sticking with PTH components so it is easy to solder for beginners, so I'm not looking for a 30 part input stage so much as I'd like a durable input stage that can handle decently small input signals in as few parts as possible...

Thanks,

Alan
8
Project development, ideas, and suggestions / Re: Input for my frequency counter questions...
Hi,

[quote author="sqkybeaver"]the maxim part is very nice for <100 MHz
the op amp could be any rail to rail, its only function would be to set trigger level. you would want a nice clean reference voltage too.[/quote]

Would you mind posting a schematic of something like this?  I am very weak in analog but want to learn!

I've tried using a voltage divider with some diodes to clamp feeding a jfet and then a transistor based on some schematics I've found on the web, but it wasn't as sensitive as I was hoping.

Thanks,

Alan
9
Project development, ideas, and suggestions / Re: Input for my frequency counter questions...
Hi,

What about something like this:

http://pdfserv.maxim-ic.com/en/ds/MAX961-MAX999.pdf

I have some of these on hand I was going to play around with:

http://www.ti.com/lit/ds/symlink/tlv2470a.pdf

You don't think they will be able to handle faster speeds?

I know measuring mains is dangerous, and I'm not planning on it, but I would like to design if possible an input stage that tolerates it...

Thanks for the help!!

Alan
10
Project development, ideas, and suggestions / Input for my frequency counter questions...
Hi Everyone,

I've been working on a reciprocal frequency counter and all the digital work is done.  Here is a breadboard picture showing 80 Mhz (or near it!)  The top led to the right is the "MHz" indicator.



It is AVR based and automatically enables or disables a prescaler to handle frequencies from 0.5 Hz to 100 MHz.  It can give the same precision whether the signal is fast or slow unlike my old BK counter I've been using.

The question is about the front end.  I've tried various input circuits, I've tried biasing inverters, schottky inverters, etc.  I want the input to support even measuring mains voltages if possible.  The problem with the circuits I've tried is that they don't amplify enough to get down to 50mV signals.  I was thinking about trying an opamp or a very fast comparator next, but I don't see opamps/comparators usually mentioned in the searching I've done for frequency counter input stages.  What advice do you guys have?

Thanks,

Alan
11
Client software / Re: Trigger question...
Hi jawi,

Where is your local repository?  Are you saying I could download a newer component that would fix this?  I can wait for the next version/beta too so no big deal if you truly mean your "local" repository!

Thanks,

Alan
12
Client software / Re: Trigger question...
[quote author="jawi"]By any chance I can get a datafile of your 200MHz capture? I'm collecting those for regression testing...[/quote]

Sure, I've attached it.  I saved the 200MHz as an OLP and a 50MHz as an OLS, what is the difference?

Thanks,

Alan
13
Bus Pirate Support / Re: My first time with the BusPirate (v4)!
[quote author="BrentBXR"]:D SEEED doesnt sell a v4 probe cable yet :3 v4 is still newish. [/quote]

Found that out the hard way! :)

[quote author="BrentBXR"]Have you updated it yet? if not I suggest you do. but if you used SPI then im guessing you have.[/quote]

First thing I did was download the latest package and flash it.

Thanks,

Alan
14
Client software / Re: Trigger question...
Hi,

[quote author="ian"]As far as I know, the 200MHz mode in FPGA is working correctly.[/quote]

It worked better for me tonight, but the timing is wrong.  I measured the same signal using cursors and:

200MHz      3.585 us
100MHz      7.020 us
50MHz      7.020 us

This may be a known bug in the client; I am not sure.

Thanks,

Alan
15
Bus Pirate Support / My first time with the BusPirate (v4)!
Hi,

It sure beats my old method of writing code, compiling, flashing, checking the results, and repeating!!

I used it with a max7219 seven segment display driver and it worked great (SPI).

Really cool piece of hardware.

The SEEEDstudio buspirate probe grabber cable doesn't fit it because of the different header size though! :(

Thanks,

Alan

( ! ) Fatal error: Uncaught exception 'Elk_Exception' with message 'Please try again. If you come back to this error screen, report the error to an administrator.' in /var/www/dangerousprototypes/forum/sources/database/Db-mysql.class.php on line 696
( ! ) Elk_Exception: Please try again. If you come back to this error screen, report the error to an administrator. in /var/www/dangerousprototypes/forum/sources/database/Db-mysql.class.php on line 696
Call Stack
#TimeMemoryFunctionLocation
10.01632454152session_write_close ( )...(null):0
20.01662585728ElkArte\sources\subs\SessionHandler\DatabaseHandler->write( )...(null):0
30.01662586504Database_MySQL->query( ).../DatabaseHandler.php:119
40.06522725224Database_MySQL->error( ).../Db-mysql.class.php:273