Help with bluetooth...


Results 1 to 25 of 25

Threaded View

  1. #1
    Join Date
    Oct 2008
    Posts
    65

    Unhappy Help with bluetooth...

    Hi everyone, I got an EGBC-04 bluetooth module. When I powered the EGBC-04 my pc detects it(Bluetooth discovery). But I'm having problem communicating with it(sending data only). I place leds to test the communication setup from PC to EGBC04 to PIC16F877A but no luck. Kindly check my setup and codes in the pic....I appreciate any help.

    Code:
    CLEAR		;read and write hardware USART
    B1	VAR     BYTE	;initialize USART
    
        TRISB = %00000000
        PortB = %00000000
    	TRISC = %10111111	;set TX (PORTC.6) to out, rest in
    	SPBRG = 25	;set baud rate to 2400
    	RCSTA = %10010000	;enable serial port and continuous receive
    				
    LOOP:		
    GOSUB CHARIN	;get a character from serial input, if any
    	IF B1 = 0 THEN LOOP 	;no character yet
    	GOTO LOOP	;do it forever
    			;subroutine to get a character 
    			;from usart receiver
    CHARIN: 
    B1 = 0			;preset to no character received
    	IF PIR1.5 = 1 THEN	;if receive flag then...
    		B1 = RCREG	;get received character to b1
    
    	   IF B1 = 65 then  
    	       If PortB.0 = 0 then
    	          High PortB.0 
               else
                  Low PortB.0
               Endif 	           
    	   ENdif
           
       ENdif            
    goto loop
    Thanks in advance,
    mbox
    Attached Images Attached Images  

Similar Threads

  1. Bluetooth problme with the 16F877A
    By slimpeng in forum Bluetooth
    Replies: 6
    Last Post: - 27th June 2009, 12:06
  2. interaction between Bluetooth and PIC MCU
    By veenadari in forum Bluetooth
    Replies: 1
    Last Post: - 23rd June 2009, 15:03
  3. help my bluetooth and PIC 16F877A?
    By slimpeng in forum mel PIC BASIC Pro
    Replies: 1
    Last Post: - 18th March 2008, 06:52
  4. Bluetooth GPS and PBP interfacing
    By RFsolution in forum Bluetooth
    Replies: 0
    Last Post: - 5th January 2006, 11:17
  5. Bluetooth wireless with PIC / HSERIN / DAC
    By rpatel in forum mel PIC BASIC Pro
    Replies: 1
    Last Post: - 20th December 2004, 22:13

Members who have read this thread : 2

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