PDA

View Full Version : does this jive?



stbrnrd
05-26-2006, 10:07 AM
on a bs2sx would the comand :
IF Pin1 = 1 THEN Pin2 = 1
ELSEIF Pin1 = 0 THEN
FREQOUT Pin3, 1, 20
ENDIF

would this translate to if pin 1 is on, then pin 2 also on; and if pin 1 is not on, send 20KHz out of pin 3 ??

Chris Savage
05-26-2006, 10:11 AM
It would if you had the proper PIN declarations for those names (Pin1, Pin2, etc.)


▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Chris Savage
Parallax Tech Support
csavage@parallax.com (mailto:csavage@parallax.com)

stbrnrd
05-26-2006, 12:12 PM
do you mean like :

Pin1 pin 1 'monitor
Pin2 pin 2 'out if valid
Pin3 pin 3 'out if invalid

the problem is this... I need some guidance...hope you could help

a small portion of my dilemma is this...
on a bs2sx would the comand :
IF Pin1 = 1 THEN Pin2 = 1
ELSEIF Pin1 = 0 THEN
FREQOUT Pin3, 1, 20
ENDIF

would this translate to if pin 1 is on, then pin 2 also on; and if pin 1 is not on, send 20KHz out of pin 3 ??

i need to monitor pin 1 for a 20 - 80 KHz constant signal... if it is present then pin 2 will signal an optocoupler to allow same signal to go on, and if the signal is not within range, to then send a 20KHz (constant) signal out of pin 3.

but i don't know how to do this...

Chris Savage
05-26-2006, 01:39 PM
Actually I answered your question the first time...I said it would work if the pins were defined to those aliases...However you've since then brought a different signal into the mix...Now you're talking about a high-speed frequency...And that would not be the way to go about this.ˇ But since you didn't have all the details in the first post I should make sure you have them all now.ˇ What exactly is the signal?ˇ You won't get a constant 20 KHz signal out of P3 either way so...I thought you were trying to play a tone.ˇ That will play a very short duration tone.

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Chris Savage
Parallax Tech Support
csavage@parallax.com (mailto:csavage@parallax.com)

stbrnrd
05-28-2006, 11:04 AM
wow...i now see that being surgically precise helps in getting questions answered... LOL http://forums.parallax.com/images/smilies/smile.gif makes sense though .

how would i be able to make the stamp put out an uninterrupted 20KHz signal (for 3-6 hours or more preffered, or a loop)?
in the same token...how could i have it monitor a 20KHz signal so that if it is within range...one action happens...and if it isn't...another action happens?
what kind of hardware conditioning would i have to provide the stamp with ...555 timer ciecuit, crystal, resonator, oscillator, etc. (wikepedia has been good http://forums.parallax.com/images/smilies/smile.gif ) help would be apreciated.

Chris Savage
05-28-2006, 12:44 PM
I'm not sure what your signal is, but you might want to simply implement the proper circuit to detect it.ˇ That circuit will output a high or low to the BASIC Stamp which could easily be read.ˇ You could build a missing pulse detector I guess...But again, I don't know what your signal is...Square wave, audio signal?

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Chris Savage
Parallax Tech Support
csavage@parallax.com (mailto:csavage@parallax.com)

stbrnrd
05-28-2006, 01:02 PM
Ohhh I'm very sory, i know see the erros in my questioning...
...thanks Chris -

it is 20-80KHz TTL square-wave signal used in a communication identifier. and Austrian made Ir hub that allows up to 4 different comm stations to share and send data signals (hence the 20-80KHz) but the tasking in the project was to build an interface that would allow my station (20KHz) to not fall bellow range, so that info sent by me could not get mistakingly logged as another or ignored due to false identifier. i hope this didn't make it worse, but it's as technical as the manual is translated. thanks again for your help.
did you mean like a transistor connected to the signal that would be detected by the stamp as a "missing pulse" in pwm? - or a 555 timer that could be set to the propper signal and driven by the stamp at a much safer modulation?
your input is appreciated.

Chris Savage
05-29-2006, 03:22 AM
I would Google missing pulse detector.ˇ Is it just a constant signal or is it a serial data stream?ˇ If it's missing what sort of signal would be seen?ˇ If it's riding on a carrier like a radio signal it seems like you'd need to strip that information from the signal.

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Chris Savage
Parallax Tech Support
csavage@parallax.com (mailto:csavage@parallax.com)

Gadgetman
05-29-2006, 03:42 AM
Let me get this straight...

You have an incoming signal of 20 to 80KHz, which IF detected is to be shunted straight through using an optocoupler, and if it isn't detected, you want your circuit to send its own 20KHz signal?
(No other parameters, like a specified delay time before switching over?)

Unless the signal carries some sort of DATA that the BS2 is to decode, what exactly do you need the BS2 for?

The detection-circuit for the 20KHz signal already gives you a logic signal, right?
Can't that logic output be used to control the optocoupler?
And if so can't it also be used to control another optocoupler to connect the locally generated 20KHz to the output?

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Don't visit my new website...

stbrnrd
05-29-2006, 06:20 AM
well gadgetman i was already using the bs2 for other functions within the same system, and the frequency signal is one that i could not get right, so that's why i was wondering if the stamp could do it. the signal itself allows a port to be 'opened' where the transmission of serial data happens from another source not dealing with the stamp...it's sort of a key that allows one station to be different from the other. i don't know why they used such a high and specific frequency, and why it is used to diferentiate between others, but that's just what i have to go on.
as far as the signal being shunted to an optocoupler, i thought that would be the best way to isolate it from the receiving end. i do not have the circuitry to monitor or generate the signal, that was the point of asking for help...because i sure need it. http://forums.parallax.com/images/smilies/smile.gif

Amaral
05-29-2006, 08:36 AM
Try using an LM 567 Tone DETECTOR , seems pretty apropriate for your need.
Just another thing , if youˇˇ - FREQOUT Pin,Period,20ˇ-ˇˇˇ ˇ at the BS2sx you will be sending a 50 Hz false sine wave out, if you want to send an 20KHz out I think you shoud useˇˇ - FREQOUT Pin,Period,8000 -ˇ ( this is just a guess I'm not familiar to the BS2sx , just BS2 ).

Hope it Helps

Amaral


(PS . I tryed to Attach the datasheet but it's giving me an error (runtime ) , look for it at www.alldatasheet.com (http://www.alldatasheet.com) )

ˇ

Amaral
05-29-2006, 08:39 AM
Just a fast question What does jive means ? (for me its jazz but makes no sense )

for the record ... I'm Brazilian


Amaral.

Chris Savage
05-29-2006, 08:52 AM
Gadgetman said...(trimmed)
Let me get this straight...
You have an incoming signal of 20 to 80KHz, which IF detected is to be shunted straight through using an optocoupler, and if it isn't detected, you want your circuit to send its own 20KHz signal?
Something you said here got my attention...You're suggesting he is trying to replace the missing data in the signal...I didn't think of that.ˇ Again, not enough information.ˇ I thought he was trying to sound some sort of alarm signal if the other one was missing...

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Chris Savage
Parallax Tech Support
csavage@parallax.com (mailto:csavage@parallax.com)

Franklin
05-29-2006, 12:50 PM
Amaral, the term "does this jive" means "does this match up with" as in "I like working with parallax products because they are easy, how does this jive with your experience?"

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
- Stephen

Bruce Bates
05-29-2006, 01:01 PM
Amaral -

As is often the case with the crazy English language, jive has more than one connotative meaning, and numerous denotative meanings. Indeed it can mean "jazz" as you said. Jive can also implyL 1) equivalence with, equality to, or 2) making sense with something else, as in thes example sentences:

Do these instructions jive with the procedures you actaully used to assemble this toy wagom, or do we need to correct them?

or

If the new information proposed for the updated instruction manual jives with the old instruction manual, then there is really no sense in re-writing, and re-printing it.

- - -

In speech, jive is sometimes confused with gibe, which has an entirely different meaning.

Denotatively, jive is actually described as "the language of hipsters" although that is a slightly dated meaning, and not used very often. This is really a good example of a word whose connotative (common use) meaning is often more popular and current, than its rather outdated, denotative (dictionary) meaning.

Regards,

Bruce Bates

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
<!--StartFragment -->

stbrnrd
05-29-2006, 03:08 PM
Gadgetman

"You have an incoming signal of 20 to 80KHz, which IF detected is to be shunted straight through using an optocoupler, and if it isn't detected, you want your circuit to send its own 20KHz signal?
(No other parameters, like a specified delay time before switching over?)

Unless the signal carries some sort of DATA that the BS2 is to decode, what exactly do you need the BS2 for?----to calculate the signal to ensure that it is a 20000Hz signal----

The detection-circuit for the 20KHz signal already gives you a logic signal, right?----I have no 'detection ckt' asides from the BS2SX----
Can't that logic output be used to control the optocoupler?-----Once the stamp calculated the signal to be within range, another pin would control the optocoupler----
And if so can't it also be used to control another optocoupler to connect the locally generated 20KHz to the output?----there wouln'dt be a need for a secondary optocoupler, the stamp would be the generator of this signal----



Amaral

Try using an LM 567 Tone DETECTOR , seems pretty apropriate for your need.----i'm looking at them now thanks----
Just another thing , if you - FREQOUT Pin,Period,20 - at the BS2sx you will be sending a 50 Hz false sine wave out, if you want to send an 20KHz out I think you shoud use - FREQOUT Pin,Period,8000 - ( this is just a guess I'm not familiar to the BS2sx , just BS2 ).----I was under the impression that it would be out of (pin#), for 1 milisecond (.001), the freq of 20Hz, i thought this would equate a 20000Hz constant signal out of the pin...bu it obviously doesn't---

and yes, 'jive'... make sense


Chris...if you wouldn't mind telling me what kind of information do you need, you keep reffering to 'not enough information' but it actually has been offered.

apreciate the help fellas, even yours Chris.

Chris Savage
05-30-2006, 12:29 AM
I am still trying to figure out whether you're trying to replace the missing signal or just generate an alert if it's missing.

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Chris Savage
Parallax Tech Support
csavage@parallax.com (mailto:csavage@parallax.com)

PJ Allen
05-30-2006, 12:42 AM
OK, "lookit", the word is jibe and not jive.

http://forums.parallax.com/attachment.php?attachmentid=73618

Post Edited (PJ Allen) : 5/29/2006 5:51:19 PM GMT

PAR
05-30-2006, 01:14 AM
PJ Allen said...
OK, "lookit", the word is jibe and not jive.

http://forums.parallax.com/attachment.php?attachmentid=73619

Off Topic

It's even more complicated (confusing?) than that...

http://www.randomhouse.com/wotd/index.pperl?date=20000711

PAR

stbrnrd
05-30-2006, 02:10 AM
Chris...I'm looking to Monitor the signal...if it is within range, then signal an optocoupler and allow the signal to continue to it's destination; if it is not wthin range....to then replace the signal with a constant 20KHz signal (not a tone specifically because it would not 'play' through a speaker...)
i looked at the 555 for freq generation, but how do i make the stamp generate the signal the 555 needs?

PJ Allen
05-30-2006, 02:29 AM
Let this (schematic attached) melt into your mind --

Chris Savage
05-30-2006, 03:07 AM
That's what I suspected...So something else needs to generate the signal, which I see PJ has already provided.ˇ With your FREQOUT command earlier I suspected you were trying to do this from the BASIC Stamp, which wasn't going to happen like you wanted.

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Chris Savage
Parallax Tech Support
csavage@parallax.com (mailto:csavage@parallax.com)

stbrnrd
05-30-2006, 04:57 AM
thanks JP, this is what i had in mind up until chris said it couldn't be done by the stamp alone, so the quest to find an oscillator to do the generating of the frequency begins, but al least i was able to see the way it would need to be connected...thanks a lot fellas for your input and patience.

PJ Allen
05-30-2006, 05:14 AM
I'd suggest aˇ7555, configured as a free-running, or astable, oscillator.ˇ The relationship of RAˇand RBˇdetermines the mark-space ratio (duty cycle.)ˇ As you may know, the output of a 7555 (555) can be tailored for pulses, square-waves, and anything in between.