RF Modules


Closed Thread
Results 1 to 40 of 45

Thread: RF Modules

Hybrid View

  1. #1


    Did you find this post helpful? Yes | No

    Default

    Hi Joe,

    I've placed 0.1uF caps on each transceiver VDD and GND pins.

    Also placed a resistor on the receiver side as a pullup for the RX pin.

    Still i get intermittent and incomplete data

  2. #2
    Join Date
    Aug 2006
    Location
    Look, behind you.
    Posts
    2,818


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by ruijc View Post
    Hi Joe,

    I've placed 0.1uF caps on each transceiver VDD and GND pins.

    Also placed a resistor on the receiver side as a pullup for the RX pin.

    Still i get intermittent and incomplete data
    OK, so then you are getting, some data. That's good. Does the receiver still fail to boot sometimes? If so, have you swapped the Tx/Rx modules to see if they both react that way? (SURE Electronics ) Seem like pretty easy to deal with vendors. Just in case there is hardware problems. If all of the above is TRUE, then I think you will need to reevaluate how you are sending data. You may need to add some character pacing scheme and or send data X # of times to insure reception.
    Are you using Tony's code exactly as published here? If not may we see what you ARE using?
    EDIT: I just loaded Tony's code . . . the half that he posted into MCS for examination . . . I hope you ARE using more than that, on account of there is no place in this where data gets loaded or stored . . . so let us see your code, please.
    Last edited by Archangel; - 18th June 2009 at 20:21.
    If you do not believe in MAGIC, Consider how currency has value simply by printing it, and is then traded for real assets.
    .
    Gold is the money of kings, silver is the money of gentlemen, barter is the money of peasants - but debt is the money of slaves
    .
    There simply is no "Happy Spam" If you do it you will disappear from this forum.

  3. #3


    Did you find this post helpful? Yes | No

    Default

    Hi Joe,

    Does the receiver still fail to boot sometimes?
    No, so far so good

    You may need to add some character pacing scheme and or send data X # of times to insure reception.
    Did that...well...sort of...

    Here's the RX code
    Code:
    '****************************************************************
    '*  Name    : RXDemo.BAS                                        *
    '*  Author  : [select VIEW...EDITOR OPTIONS]                    *
    '*  Notice  : Copyright (c) 2008 [select VIEW...EDITOR OPTIONS] *
    '*          : All Rights Reserved                               *
    '*  Date    : 01-06-2009                                        *
    '*  Version : 1.0                                               *
    '*  Notes   : Demo for SureElectronics RF modules               *
    '*          : 16F88                                             *
    '****************************************************************
    
        CCP1CON = %00000000         ' Disable CCP
        SSPCON.5 = 0                ' Disable SSP Module
        ANSEL = %00000000           ' Set analog ports to digital mode
        CMCON = %00000111           ' Turn off comparator  
    
    
    TRISA=%00100000
    TRISB=%00000100
       
    '*****************************************************************************
    'DEFINEs
    '*****************************************************************************
    
    DEFINE OSC 4
    
    @ DEVICE PROTECT_OFF
    @ DEVICE CCPMX_OFF
    @ DEVICE DEBUG_OFF
    @ DEVICE WRT_OFF
    @ DEVICE CPD_OFF
    @ DEVICE LVP_OFF
    @ DEVICE BOD_OFF
    @ DEVICE MCLR_OFF
    @ DEVICE PWRT_ON
    @ DEVICE WDT_ON
    @ DEVICE XT_OSC
         
    '*****************************************************************************
    ' DEFINE LCD pins
    
    DEFINE  LCD_DREG        PORTA
    DEFINE  LCD_DBIT            0
    
    DEFINE  LCD_RSREG       PORTB
    DEFINE  LCD_RSBIT           1
    
    DEFINE  LCD_EREG        PORTB
    DEFINE  LCD_EBIT            0
    
    DEFINE  LCD_BITS            4
    
    DEFINE LCD_LINES 4              ' # of Lines on LCD,  1 or 2 (Note: use 2 for 4 lines)
    DEFINE LCD_COMMANDUS 2000       'lcd delay us
    DEFINE LCD_DATAUS 50            ' Data delay time in us
    
    '*****************************************************************************
    'debug defines
    
    INCLUDE "modedefs.bas" 
    DEFINE DEBUG_REG PORTB  
    DEFINE DEBUG_BIT 3
    DEFINE DEBUG_BAUD 19200
    DEFINE DEBUG_MODE 1
    define DEBUGIN_REG PORTB
    define DEBUGIN_BIT 2
    define DEBUGIN_BAUD 19200
    define DEBUGIN_MODE 1
    DEFINE DEBUG_PACING 10000
    
    '*****************************************************************************
    'PINS
     
    adc     var          PORTA.0  '
    a1      var          PORTA.1  '
    lcd1    var          porta.2  '
    lcd2    var          porta.3  '
    freq    var          porta.4  'pin8 of transceiver
    BUT1    var          porta.5  'Button1
    xtal1   var          porta.6  '
    xtal2   var          porta.7  '
    B0      var          portb.0  '
    B1      var          portb.1  '
    RX      var 	     PORTB.2  ' out
    TX      var 	     PORTB.3  ' in
    lcd4    var          portb.4  'Data pin for LCD         
    lcd5    var          portb.5  'Data pin for LCD
    lcd6    var          portb.6  'Data pin for LCD  
    lcd7    var          portb.7  'Data pin for LCD  
    
    '*****************************************************************************
    'variables
    
    maximo   var        WORD	'maximum value detected
    minimo   var        WORD	'minimum value detected
    media    var        WORD	'average
    mediac   var        WORD	'total of records received - average count
    km       var        WORD	'PowerOn counter
    MA       var        WORD	'
    MI       var        WORD	'
    ps4      var        WORD	'
    value    var        WORD	'value received
    medres   var        WORD	'value sum for avg math
    ADDR     var        word
    ra       var        word
    time     var        word
    timex    var        word
    MYDATA   var        word
    
    'contants
    Row1  CON 128 'constant for LCD line1
    Row2  CON 192 'constant for LCD line2
    Row3  CON 148 'comstant for LCD line3
    Row4  CON 212 'constant for LCD line4
    cl    con 254 'constant for LCD clear line
    
    
    clear
    '*****************************************************************************
    
    INCLUDE "lcdbarIN.bas" 
    DEFINE  LCD4X20  1
     
    '***********************************************************
    INIT:
    high tx
    high rx
    pause 400
    lcdout $fe,1,"  RX demo " 
    lcdout $fe,$c0,"     ...        "
    pause 1500
    if but1=1 then
    goto chann
    endif
    
    man:
    lcdout cl,row1," adc ", dec value 
    lcdout cl,row2," media  ", dec media
    
    rec:
    debugin [wait ("ok"),dec MYDATA]     
    lcdout cl,row4, "received - ",dec MYDATA,"   "
    
    goto REC
    
    chann:
    low freq
    pause 50
    while but1=1
    debug $af, $20
    wend
    goto man
    
    '
    end
    and the TX code
    Code:
    '****************************************************************
    '*  Name    : TXDemo.BAS                                        *
    '*  Author  : [select VIEW...EDITOR OPTIONS]                    *
    '*  Notice  : Copyright (c) 2008 [select VIEW...EDITOR OPTIONS] *
    '*          : All Rights Reserved                               *
    '*  Date    : 01-06-2009                                        *
    '*  Version : 1.0                                               *
    '*  Notes   : Demo for SureElectronics RF modules               *
    '*          : 16F88                                             *
    '****************************************************************
    
        CCP1CON = %00000000         ' Disable CCP
        SSPCON.5 = 0                ' Disable SSP Module
        CMCON = %00000111           ' Turn off comparator 
    
    TRISA=%00100001
    TRISB=%00000100
       
    '*****************************************************************************
    'DEFINEs
    '*****************************************************************************
     
    @ DEVICE PIC16F88, HS_OSC
    @ DEVICE PIC16F88, MCLR_OFF
    @ DEVICE PIC16F88, PROTECT_OFF
    
    DEFINE OSC 10
    
    @ DEVICE PIC16F88, CPD_OFF
    @ DEVICE PIC16F88, LVP_OFF
    @ DEVICE PIC16F88, BOD_OFF
    @ DEVICE PIC16F88, PWRT_OFF
    @ DEVICE PIC16F88, WDT_OFF
    @ DEVICE PIC16F88, CCPMX_OFF
    
    '*****************************************************************************
    'ADC
    
    DEFINE ADC_BITS 10 ' Set number of bits in result ( 8 or 10 bits )
    DEFINE ADC_CLOCK 3 ' Set clock source (3=rc)
    DEFINE ADC_SAMPLEUS 50 ' Set sampling time in uS
    
    '*****************************************************************************
    
    ANSEL=%00000001 
    ADCON1=%10000000 'no Vref - Right Justify 
    ADCON0=%11000001  
         
    '*****************************************************************************
    ' DEFINE LCD pins
    
    DEFINE  LCD_DREG        PORTB
    DEFINE  LCD_DBIT            4
    
    DEFINE  LCD_RSREG       PORTA
    DEFINE  LCD_RSBIT           3
    
    DEFINE  LCD_EREG        PORTA
    DEFINE  LCD_EBIT            2
    
    DEFINE  LCD_BITS            4
    
    DEFINE LCD_LINES 4              ' # of Lines on LCD,  1 or 2 (Note: use 2 for 4 lines)
    DEFINE LCD_COMMANDUS 2000       'lcd delay us
    DEFINE LCD_DATAUS 50            ' Data delay time in us
    '*****************************************************************************
    'debug defines
    
    INCLUDE "modedefs.bas" 
    DEFINE DEBUG_REG PORTB  
    DEFINE DEBUG_BIT 3
    DEFINE DEBUG_BAUD 19200
    DEFINE DEBUG_MODE 1
    DEFINE DEBUGIN_REG PORTB
    DEFINE DEBUGIN_BIT 2
    DEFINE DEBUGIN_BAUD 19200
    DEFINE DEBUGIN_MODE 1
    DEFINE DEBUG_PACING 10000
    
    '*****************************************************************************
    'PINS
     
    adc     var          PORTA.0  'analog input
    A1      var          PORTA.1  '
    lcd1    var          porta.2  '
    lcd2    var          porta.3  '
    freq    var          porta.4  'pin8 from transceiver
    BUT1    var          porta.5  'But1
    Xtal1   var          porta.6  'Xtal
    Xtal2   var          porta.7  'Xtal
    B0      var          portb.0  '
    B1      var          portb.1  '
    RX      var 	     PORTB.2  ' in
    TX      var 	     PORTB.3  ' out
    lcd3    var          portb.4  'Data pin for LCD         
    lcd4    var          portb.5  'Data pin for LCD
    lcd5    var          portb.6  'Data pin for LCD 
    lcd6    var          portb.7  'Data pin for LCD  
    
    '*****************************************************************************
    'variables
    
    maximo   var        WORD	'maximum value detected
    minimo   var        WORD	'minimum value detected
    media    var        WORD	'average
    mediac   var        WORD	'total of records received - average count
    km       var        WORD	'PowerOn counter
    MA       var        WORD	'
    MI       var        WORD	'
    ME       var        WORD	'
    ps4      var        WORD	'
    value    var        WORD	'value received
    medres   var        WORD	'value sum for avg math
    ADDR     var        word
    ra       var        word
    time     var        word
    timex    var        word
    MYDATA   var        word
    
    'contants
    p1a             con   $10     
    p1b             con   $e20
    ctw             CON   $A0 
    Row1  CON 128 'constant for LCD line1
    Row2  CON 192 'constant for LCD line2
    Row3  CON 148 'comstant for LCD line3
    Row4  CON 212 'constant for LCD line4
    cl    con 254 'constant for LCD clear line
    
    
    clear
    '*****************************************************************************
    
    INCLUDE "lcdbarIN.bas" 
    DEFINE  LCD4X20  1
     
    '***********************************************************
    INIT:
    high rx
    high tx
    pause 400
    lcdout $fe,1,"  TX demo " 
    lcdout $fe,$c0,"     ...        "
    pause 1500
    debug $55
    if but1=1 then
    goto chann
    endif
    
    man:
    high freq        
    me=0
    for ra=0 to 15
    adcin adc,value
    pause 50
    me=me+value
    next ra
    me=me/16
    media=me
    media=(media*/5000)>>2
    lcdout cl,row1," adc ", dec value 
    lcdout cl,row2," media  ", dec media
    
    
    transmit:
    lcdout cl,row4,"transmiting - ",dec value ,"   "
    debug $55,"ok", dec value dig 3, dec value dig 2, dec value dig 1, dec value dig 0
    
    goto man
    
    chann:
    low freq
    pause 50
    while but1=1
    debug $af, $20
    wend
    goto man
    
    end

  4. #4


    Did you find this post helpful? Yes | No

    Default

    Thanks to Joe the problem has been solved.

    The problem was related with the Mode ( debug defines ) settings.

    I changed from MODE 1 to MODE 0 and it started to receive all data 100%.

    Thanks Joe.

  5. #5
    idrenth's Avatar
    idrenth Guest


    Did you find this post helpful? Yes | No

    Default

    Hello

    can maybe sombody give a circuit so I can test it.

    I have the CY2196R module but I didn't get it running also.

    I hope for respons.

    regards idrenth

  6. #6
    JulianDichiara's Avatar
    JulianDichiara Guest


    Did you find this post helpful? Yes | No

    Default Answer

    I was looking for things to do with my GP-GC010. I came across this forum.
    I got my GP-GC010 working well. At first I was having the same problems as
    ruijc was having. I got mine to work with a debug window and an example
    program displaying this string "On The Air!". I'm using a 3.3 volt regulator.
    I reset it and it started working (I don't really know why!).
    Last edited by JulianDichiara; - 16th March 2010 at 01:10.

  7. #7
    Join Date
    Jan 2008
    Location
    Dublin, Ireland
    Posts
    33


    Did you find this post helpful? Yes | No

    Default

    Ah, call it the joy of electronics!

  8. #8
    Join Date
    Mar 2007
    Posts
    9


    Did you find this post helpful? Yes | No

    Default

    Firstly, apologies for dragging up this post yet again!

    I too am having trouble with this module. I've tried everything I can think of, but I can't get anything to be received. Is anyone who has got this working prepared to help me out? There are so many contradictions and instances of vague language in the 'data sheet' that it seems amazing anyone has got this working!

    I am using a PIC16F88 USART to transmit to one module and I'm reading the other with an arduino. When I send serial data to either module, the busy LED lights. Everything looks good. Pins 7 and 8 are pulled high, 5 and 2 are grounded and everything is running on 3.3V. I'm definitely running at 19200 baud rate and I'm using true rs232 (i.e. normaly high, when data sent goes low). However, I've been trying for almost a solid day now and the busy LED of the other module has never flashed in response to receiving transmission from another module.

    I've tried setting the transmission frequency but the data sheet is so vague that frankly I could have been doing anything.

    Any ideas? Thanks!

Similar Threads

  1. RF Modules (Zigbee)
    By Chris Barron in forum mel PIC BASIC Pro
    Replies: 10
    Last Post: - 4th March 2010, 18:28
  2. Low latency Wireless RF transceiver modules?
    By mark155 in forum General
    Replies: 0
    Last Post: - 4th March 2010, 05:20
  3. RF Transceiver modules help
    By davewanna in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 16th May 2008, 14:54
  4. Help with CC1100 RF Modules.
    By charudatt in forum mel PIC BASIC Pro
    Replies: 13
    Last Post: - 27th November 2006, 20:58
  5. RF Modules at 433.92MHz
    By Ioannis in forum Adverts
    Replies: 2
    Last Post: - 17th October 2006, 12:36

Members who have read this thread : 1

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts