JoelMurphy
- 9th March 2008, 00:37
hello fellows,
i've got a general question and comment that i hope generates some discussion. how the heck do you make sure that you don't miss a serial signal when you are using UART? sure, each application is specific, and if you're looking for a signal, you're likely able to control each end of the transmission [any snoopers out there?] so the suit fits as well as the tailor is good. but what i'm after is examples of what did and didn't work in your experience with certain situations.
here's mine.
i'm developing a wireless doo-hickey. i want it to be 'universal' in the sense that the way it functions should be useful in most situations. my user will have all the details about how my device works, and they will tailor their transmission/reception to my protocol. [for advanced users, there will be an ICSP connection to load their own firmware].
the doo-hickey will mostly be handling transmissions, so the PIC on it will act like a buffer. i've had some luck with a short MAIN loop and putting the SERIN2 command in a subroutine that gets called once a loop. in that situation i use the timeout/label option. i've had some slightly glitchy results and tweeking the timeout value does and doesn't work.
another option that i'm going to try is just to check the state of the RX pin and see if it's low. that would mean there's some data there, but i'm wondering about the timing of that query. has anyone tried other options besides the old 'initialize the serial input and wait to see if there's readable data there'?
thanks, joel
definitely, definitely, smarter than yesterday.
altho' i did smack my thumb with a hammer before lunch...
i've got a general question and comment that i hope generates some discussion. how the heck do you make sure that you don't miss a serial signal when you are using UART? sure, each application is specific, and if you're looking for a signal, you're likely able to control each end of the transmission [any snoopers out there?] so the suit fits as well as the tailor is good. but what i'm after is examples of what did and didn't work in your experience with certain situations.
here's mine.
i'm developing a wireless doo-hickey. i want it to be 'universal' in the sense that the way it functions should be useful in most situations. my user will have all the details about how my device works, and they will tailor their transmission/reception to my protocol. [for advanced users, there will be an ICSP connection to load their own firmware].
the doo-hickey will mostly be handling transmissions, so the PIC on it will act like a buffer. i've had some luck with a short MAIN loop and putting the SERIN2 command in a subroutine that gets called once a loop. in that situation i use the timeout/label option. i've had some slightly glitchy results and tweeking the timeout value does and doesn't work.
another option that i'm going to try is just to check the state of the RX pin and see if it's low. that would mean there's some data there, but i'm wondering about the timing of that query. has anyone tried other options besides the old 'initialize the serial input and wait to see if there's readable data there'?
thanks, joel
definitely, definitely, smarter than yesterday.
altho' i did smack my thumb with a hammer before lunch...