Connect PIc to Pocket PC


Closed Thread
Results 1 to 8 of 8
  1. #1
    Keith's Avatar
    Keith Guest

    Default Connect PIc to Pocket PC

    Anyone have any experience in connecting a Pic to a mobile device such as the Pocket PC. I would assume most of the problems would be wireing the cable correctly??


    Thanks for any help....

  2. #2
    Join Date
    Mar 2005
    Location
    Iowa, USA
    Posts
    216


    Did you find this post helpful? Yes | No

    Default

    Don't forget a level translator (max232). I've been looking at using bluetooth instead of a serial cable. Sparkfun.com has bluetooth modules you can interface with a pic. Seems like manufactures are going away from serial cables and they're getting harder and more expensive to find. I use a Dell X50v.
    Last edited by rhino; - 12th July 2005 at 23:20.

  3. #3
    Keith's Avatar
    Keith Guest


    Did you find this post helpful? Yes | No

    Default Bluetooth Radio

    I checked out sparkfun... those bluetooth radio's are really slick! How would you connect one of them to a PIC to transmit to a base unit??

  4. #4
    Join Date
    Mar 2005
    Location
    Iowa, USA
    Posts
    216


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by Keith
    How would you connect one of them to a PIC to transmit to a base unit??
    They have a pretty good tutorial in their tutorials section. The only thing that has prevented me from getting one is I've been looking for a hyperterminal type application for PPC that can use bluetooth. If anyone knows of one (preferrably free) please PM me.

  5. #5
    Keith's Avatar
    Keith Guest


    Did you find this post helpful? Yes | No

    Default Bluetooth Radio

    They are transceiver's correct..???

  6. #6
    Join Date
    Mar 2005
    Location
    Iowa, USA
    Posts
    216


    Did you find this post helpful? Yes | No

    Default

    Correct.... they have a UART onboard. So you set up your pic for serial comms, just as with a pc, except without the level tranlsator in this case since they are 5V tolerant. Then you send your serial data from the pic to the module, and it spits it out over the air to another bluetooth enabled device... and vise-versa. They have a really straight forward data sheet. I couldn't attach it.... too large. Here's the link

    http://www.sparkfun.com/datasheets/RF/BlueSMiRF_v1.pdf

    Like I mentioned earlier, I haven't used these yet, but they seem to be fairly easy to integrate with. If you get one... let us know how well it works!

  7. #7
    Keith's Avatar
    Keith Guest


    Did you find this post helpful? Yes | No

    Default

    thanks... I just downloaded the doc. I will probably give one a try... in the next few weeks .. I'll let you know how it works...

  8. #8
    ccsparky's Avatar
    ccsparky Guest


    Did you find this post helpful? Yes | No

    Default Connect PIC to PocketPC

    With some help from members on the PICBasic and NSBasicCE lists I was able to put together the code listed below. Using a PIC 16f88 and a MAX232 I am able to send and receive data between a 16f88 w/ Max232 and my PocketPC HP h2215. As I am a beginner at this, you'll see that this is very simple.
    Hopefully this will help someone else!


    The cable I used can be found here http://www.gomadic.com/comipseradca.html
    The cost for the cable is $19.95 + s/h


    'PicBasic Pro
    '------------------------------------------------------
    N VAR BYTE
    Main:
    SERIN SERRX,T9600,["@"],N 'Waits here until @ and either a, b or c is received from h2215
    Pause 10
    if n = "a" then SEROUT SERTX,T9600,["Here's your a"] ' if N = a send this back to h2215
    if n = "b" then SEROUT SERTX,T9600,["Here's your b"] ' if N = b send this back to h2215
    if n = "c" then SEROUT SERTX,T9600,["Here's your c"] ' if N = c send this back to h2215
    Goto Main
    End


    'NSBasic-CE (Info on NSBasic http://www.nsbasic.com/ce/info/)
    '------------------------------------------------------
    Option Explicit
    AddObject "comm","comm",0,0,0,0
    Dim Instring

    AddObject "commandButton","Writea",8,65,70,20
    Writea.text="Write a"
    AddObject "commandButton","Writeb",8,85,70,20
    Writeb.text="Write b"
    AddObject "commandButton","Writec",8,105,70,20
    Writec.text="Write c"
    AddObject "textBox","textbox1",8,145,224,20
    TextBox1.borderstyle=1

    Sub Open()
    comm.Rthreshold = 1
    comm.InputMode = 0
    comm.handshaking=1
    comm.RTSEnable=False
    comm.DTREnable=False
    comm.PortOpen = True
    End Sub

    Sub form_close()
    Comm.PortOpen = 0
    End Sub

    Private Sub comm_OnComm()
    Dim InString
    InString = InString + comm.Input
    textbox1.text = InString
    End Sub

    Sub Writea_Click
    If comm.portopen = False Then Open
    comm.Output = "@a"
    End Sub

    Sub Writeb_Click
    If comm.portopen = False Then Open
    comm.Output = "@b"
    End Sub

    Sub Writec_Click
    If comm.portopen = False Then Open
    comm.Output = "@c"
    End Sub

Similar Threads

  1. Replies: 26
    Last Post: - 2nd October 2017, 11:35
  2. Send data PIC to PC
    By konter in forum Off Topic
    Replies: 6
    Last Post: - 25th December 2009, 22:04
  3. Replies: 67
    Last Post: - 8th December 2009, 02:27
  4. Free Project - 245 LED Display
    By T.Jackson in forum Code Examples
    Replies: 221
    Last Post: - 16th August 2009, 04:59
  5. HSERIN & Interupts (aka controlling PIC programs from a remote PC)
    By HankMcSpank in forum mel PIC BASIC Pro
    Replies: 16
    Last Post: - 17th June 2009, 14:46

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