Touch Sensor


Results 1 to 3 of 3

Thread: Touch Sensor

Threaded View

  1. #1

    Default Capacitive Touch Sensor

    Hi,

    I have found a very good Device B6TS-04LT,is a 4 Ch Sensor from OMRON.

    http://docs-europe.electrocomponents...6b8095df92.pdf

    I dont' know how I can put Photos on this Thread :-)

    I Build the Sensor Device with a PIC 16F870 all Work Fine,my only Problem is that when I Read something for Example the Device ID (Work just in Setup Mode),sometime i Receive the Right ID sometime just FFFF and so on,I can not Read any other Value I try all Mode and Routines.

    I use for Write this:

    Include "modedefs.bas" ' Mode definitions for Serout

    Define OSC 4

    DEFINE HSER_RCSTA 90h
    DEFINE HSER_TXSTA 24h
    DEFINE HSER_SPBRG 25 ' 9600 Bauds
    DEFINE HSER_CLROERR 1

    ..........
    ........


    ' PortB.4 is Data (Duplex)
    ' PortB.3 is Clock
    'SCS is Chip select

    '''''''''''''''''''''''''''''''''''''''''''''''''' '''''''''''Write to Register'''''''''''''''''''''''''''''''''''''''''' '''''''''
    Low PortB.2 ' SCS
    pauseus 10
    Shiftout PortB.4,PortB.3,5,[Command.highbyte,Dummy,DatenTX.highbyte,DatenTX.lo wbyte] 'Toggle
    pauseus 10
    High PortB.2
    Sound Summer ,[124,10]
    Pause 1000
    '''''''''''''''''''''''''''''''''''''''''''''''''' ''''''''''Write to EEPROM'''''''''''''''''''''''''''''''''''''''''''' ''''''
    Command.highbyte = %10111111 'Write EEPROM
    Command.lowbyte = %00000000
    DatenTX.highbyte = %01010011
    DatenTX.lowbyte = %01010100
    Dummy = $FF
    Low PortB.2
    pauseus 10
    Shiftout PortB.4,PortB.3,5,[Command.highbyte,Dummy,DatenTX.highbyte,DatenTX.lo wbyte]
    pauseus 10
    High PortB.2
    Sound Summer ,[124,10]
    Pause 1000


    This Work fine !

    '''''''''''''''''''''''''''''''''''''''''''''''''' ''''''Read ID'''''''''''''''''''''''''''''''''''''''''''''''' '''''''''''''''''''''
    Command.highbyte = %00000000
    Command.lowbyte = %00000000
    DatenRX.highbyte = $00
    DatenRX.lowbyte = $00
    Dummy = $FF
    Low PortB.2 'SCS
    pauseus 10
    Shiftin PortB.4,PortB.3,6,[Command.highbyte,Dummy,DatenRx.Highbyte,DatenRx.Lo wbyte]
    pauseus 10
    High PortB.2 ' SCS

    This Code dont' Work all the Time,when I use any other Command I Receive just the ID und not the right Value what I need.

    My second question :-) is why I need SCS what is SCS(Chip select).

    I try Hours and Hours to find the way but no Result.

    Thank you for any answer !

    Regards Pesti.
    Last edited by Pesticida; - 24th September 2007 at 14:58.

Similar Threads

  1. Need a cheap touch sensor idea.. here it is
    By mister_e in forum Code Examples
    Replies: 20
    Last Post: - 16th April 2016, 22:42
  2. Any Ideas for a cheap touch sensor??????
    By rsocor01 in forum mel PIC BASIC Pro
    Replies: 17
    Last Post: - 19th October 2013, 00:33
  3. PICBASIC PRO-coding for wireless sensor node
    By syazila in forum mel PIC BASIC Pro
    Replies: 2
    Last Post: - 10th February 2009, 00:05
  4. LED Touch Sensor
    By ngeronikolos in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 3rd April 2008, 01:15
  5. Replies: 6
    Last Post: - 18th January 2008, 08:17

Members who have read this thread : 0

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