Re: Hm-trp
[QUOTE=zdravko;101637]

Originally Posted by
Ioannis
Did you set up the modules prior their use?
I think its not necessary. Default Settings is 9600bps, 8bit, No check, 1 bit stop.
I haven't used this particular device but I've become quite familiar with Hope's RFM22B. I think you might be a little optimistic in assuming the default serial settings cover everything you'll need. Given that it isn't working, following the guidance in the datasheet for configuring the chip might be a good step (after confirming that your PIC is working by blinking an LED or something).
Some very quick observations on your code:
-You define an ENAB pin but never explicitly set it low.
-You don't allow any warm up time. I think good practice is to give the PIC (and the module) a few hundred millisec to get their acts together. I usually add a PAUSE 500 after setting all the configuration bits.
-I don't see how you can even tell if it's working or not--how are you getting data out? At least for initial testing try having an LED blink (or something) each time a character is received.
Let us know how it goes. If you can't get it working give us some description of what it does and doesn't do--beyond "it doesn't work"--and how you're testing it. A schematic showing your hookup might also be useful.
Best Regards,
Paul
The way to avoid mistakes is to gain experience. The way to gain experience is to make mistakes.
Bookmarks