View previous topic :: View next topic |
Author |
Message |
fuzzy
Joined: 26 Feb 2005 Posts: 64
|
Strange radio comunication problem. |
Posted: Sun May 27, 2007 3:37 pm |
|
|
HI,
I found out a curious problem yesterday and i still can't undertand it.
I programmed a transmitter and it's radioreceiver using pic16f88. I transmit data from RS232 Pin and i read bata in RS232PIn of another PIC.
I usually connect hem by radio modules. When I wrote firmware everithing worked OK. I produced 50 devices working perfectly.
Now i'm producing other 50 devices but i've got a big problem. I downloaded firmaware on them and they don't work as good as other
some(few) work good but others work very very bad. i would like to understand if it can be a PIC problem or a transmitter/receiver problem.
for example with previous production transmitter , new receiver don't work
while they can work with new production transmitter. and old production receiver works good with both production transmitter. I tryed calibrating internal 8mhz pic's clock and one of them worked better with calibration =-2.
topmorrow i'l try tranferring pic from a old production board to a new production one with same firmaware and maybe i'll understand better.
Anyone has a similar experience? |
|
![](templates/subSilver/images/spacer.gif) |
PCM programmer
Joined: 06 Sep 2003 Posts: 21708
|
|
Posted: Sun May 27, 2007 4:00 pm |
|
|
Call the radio manufacturer and ask them for a detailed list of changes
between the new version and the old version. This would include
signal timing, logic levels on i/o pins, performance over temperature
range, initialization sequences, commands, etc. -- All changes. |
|
![](templates/subSilver/images/spacer.gif) |
RossJ
Joined: 25 Aug 2004 Posts: 66
|
|
Posted: Sun May 27, 2007 8:34 pm |
|
|
It sounds like your first problem is to determine whether the problem is a radio one (module to module) or a serial one (module to/from PIC).
The way I usually go about detecting serial problems is to monitor the communication (passively) with a PC. An invaluable tool is a simple cable which connects the receive and transmit lines back to a PC's receive line on two COM ports. This allows you to monitor the data flow in both directions between the PIC and radio module. I use a program called Docklight (http://www.docklight.de/) on the PC to view the data. Note, if the voltage levels you are monitoring are TTL (i.e. a direct connection between PIC and module), you will need to add a MAX232 or similar level converter into the monitor cable.
If you do much with RS232 type serial comms, this is an invaluable tool.
A quick check you can make is to count the number of framing errors detected by the PIC. With a short direct wired connection, the number of errors should be extremely low.
Another thing to consider is voltage levels. The radio module I use is powered from 5 volts, but internally runs at 3.3 volts. The inputs are 5 volt tolerant, but the outputs are only 3.3 volts. On the 18 series PIC I am using, the USART pins have schmitt trigger inputs. The voltage thresholds are incompatible with 3.3 volt signals. Having said that, it usually works. But perhaps not always.
/Ross. |
|
![](templates/subSilver/images/spacer.gif) |
fuzzy
Joined: 26 Feb 2005 Posts: 64
|
|
Posted: Mon May 28, 2007 12:02 pm |
|
|
I made some experiments. I found out it's a pic problem.
I swapped pic between an old device and a new one and the not working new one begun working nice while the old one didn't work as well.
then i used a pic 16f87 i had for other purpose and device bean working perfectly.
I can see that the new 16f8 pic don't work in receiver but work in transimitter very well, i think i'm going to change all of them. I also found out that device works good witha pic16F88/ESS intead of 16F88/ISS
why does it happen in your opinion?? |
|
![](templates/subSilver/images/spacer.gif) |
Humberto
Joined: 08 Sep 2003 Posts: 1215 Location: Buenos Aires, La Reina del Plata
|
|
![](templates/subSilver/images/spacer.gif) |
|