Product Manual - Robotshop · 2010. 4. 21. · 1134_0_Product_Manual - March 29, 2010 8 Technical...

10
Product Manual 1134 - Switchable Voltage Divider

Transcript of Product Manual - Robotshop · 2010. 4. 21. · 1134_0_Product_Manual - March 29, 2010 8 Technical...

  • Product Manual1134 - Switchable Voltage Divider

  • Phidgets 1134 - Product Manual

    For Board Revision 0

    © Phidgets Inc. 2010

  • Contents

    4 Product Features

    4 Applications

    4 Connections

    4 Type of Measurement

    5 Getting Started

    5 Checking the Contents

    5 Connecting all the pieces

    5 Testing Using Windows 2000/XP/Vista

    7 Testing Using Mac OS X

    7 Programming a Phidget

    7 Code Samples

    7 Coding for your Sensor

    8 Technical Information

    8 Formulas

    8 ConfiguringtheVoltageDivider

    9 Variable resistance sensors

    9 OtherInterfacingAlternatives

    9 Analog Input Cable Connectors

    10 MechanicalDrawing

    10 DeviceSpecifications

    10 Product History

    10 Support

  • 41134_0_Product_Manual - March 29, 2010

    Designedtoconnecttoa:

    1018 - PhidgetInterfaceKit 8/8/8•

    1019 - PhidgetInterfaceKit 8/8/8 w/6 Port Hub•

    1070 - PhidgetSBC•

    1202-PhidgetTextLCD•

    Product FeaturesApplications

    Providesaninterfacetonon-Phidgetsvariableresistancesensorssuchas:ForceSensingResistors(FSR),light•sensors,thermistors(heatsensors),andbendsensors.

    Precisionresistorsonthe1134allowstheapplicationtopreciselycalculatetheresistanceoftheattachedsensor.•

    Possibletousemultipleresistorstoselectanequivalentresistanceforthe‘fixed’resistor•

    Theinterfacetothevariableresistancesensorisaconvenientterminalblock.•

    Connections

    Type of MeasurementThesensorusesratiometricmeasurement.

  • 51134_0_Product_Manual - March 29, 2010

    ConnecttheSwitchableVoltageDividertoanAnalogInput1.on the PhidgetInterfaceKit 8/8/8 board using the sensor cable.

    Connectthevariableresistancesensortotheterminal2.blockontheVoltageDivider.

    Select an appropriate measurement range for your 3.applicationbytogglingthedesiredDIPswitch.Wearetogglingthe27.4Kswitch.Whentheswitchisdown,theassociatedmeasuringresistorisselected.Itispossibletohavemorethanoneswitchtoggledandhavetheresistorsinparallel.Forourpurposeonlytoggleoneswitch.

    Connect the InterfaceKit board to your PC using the USB 4.cable.

    Getting StartedChecking the Contents

    In order to test your new Phidget you will also need:

    A PhidgetInterfaceKit 8/8/8•

    A USB Cable•

    Avariableresistancesensororanyresistor(weareusinga27K•resistor)

    You should have received:

    ASwitchableVoltageDividerboard•

    A Sensor Cable•

    Connecting all the pieces

    Testing Using Windows 2000/XP/VistaDownloading the Phidgets driversMakesurethatyouhavethecurrentversionofthePhidgetlibraryinstalledonyourPC.Ifyoudon’t,dothefollowing:

    Gotowww.phidgets.com>>Drivers

    DownloadandrunPhidget21Installer(32-bit,or64-bit,dependingonyourPC)

    You should see the iconontherighthandcorneroftheTaskBar.

    Running Phidgets Sample Program

    Doubleclickingonthe icon loads the Phidget Control Panel; we will use this program to make sure that your newPhidgetworksproperly.Sincethesensorisconnectedtoa1018,thecomputerwillseeonlythe1018.ThesensorisprovidingdatathroughtheAnaloginputitisconnectedto.

    The source code for the InterfaceKit-full sample program can be found under C# by clicking on www.phidgets.com >>Programming.

    1

    2

    3

    4

  • 61134_0_Product_Manual - March 29, 2010

    DoubleClickonthe icontoactivatethePhidget Control Panel and make sure that the Phidget InterfaceKit 8/8/8 is properly attachedtoyourPC.

    DoubleClickonPhidgetInterfaceKit1.8/8/8 in the Phidget Control Panel to bring up InterfaceKit-full and check that the box labelled Attached containsthewordTrue.

    MakesurethattheRatiometricbox2.isTicked.

    The Analog In box displays a number 3.correspondingtotheresistorvalue.

    Youcanadjusttheinputsensitivity4.bymovingthesliderpointer.

    Click on the Sensors button to bring 5.uptheAdvancedSensorForm.

    1

    2

    3

    4

    5

    IntheAdvancedSensorForm,selectthe1.1134-SwitchableVoltageDividerfromthedropdownmenu.

    Select the appropriate resistor from the 2.drop-down menu that has been selected withtheDIPswitchontheboard.

    The resistance measured by the sensor is 3.shownhere.

    Formulausedtoconverttheanaloginput4.SensorValueintoresistance.

    1

    23

    4

  • 71134_0_Product_Manual - March 29, 2010

    Testing Using Mac OS XClickonSystemPreferences>>Phidgets(underOther)toactivatethePreferencePane•

    MakesurethatthePhidgetInterfaceKit8/8/8isproperlyattached.•

    DoubleClickonPhidgetInterfaceKit8/8/8inthePhidgetPreferencePanetobringuptheInterfaceKit-Full•example.ThisexamplewillfunctioninasimilarwayastheWindowsversion,butnotethatitdoesnotincludeanAdvancedSensorDisplay.

    Programming a Phidget

    Phidgets’philosophyisthatyoudonothavetobeanelectricalengineerinordertodoprojectsthatusedeviceslikesensors,motors,motorcontrollers,andinterfaceboards.Allyouneedtoknowishowtoprogram.WehavedevelopedacompletesetofApplicationProgrammingInterfaces(API)thataresupportedforWindows,MacOSX,andLinux.Whenitcomestolanguages,wesupportVB6,VB.NET,C#.NET,C,C++,Flash9,Flex,Java,LabVIEW,Python,Max/MSP,andCocoa.

    Code SamplesWehavewrittensampleprogramstoillustratehowtheAPIsareused.

    Duetothelargenumberoflanguagesanddeviceswesupport,wecannotprovideexamplesineverylanguageforeveryPhidget.Someoftheexamplesareveryminimal,andotherexampleswillhaveafull-featuredGUIallowingallthefunctionalityofthedevicetobeexplored.Mostdevelopersstartbymodifyingexistingexamplesuntiltheyhaveanunderstandingofthearchitecture.

    Go to www.phidgets.com>>Programming toseeiftherearecodesampleswrittenforyourdevice.Findthelanguageyouwanttouseandclickonthemagnifyingglassbesides“CodeSample”.Youwillgetalistofallthedevicesforwhichwewrotecodesamplesinthatlanguage.

    IfthisisyourfirsttimewritingaprogramtocontrolaPhidget,youshouldreadtheGettingStartedGuideforthelanguageyouareplanningtouse.

    Coding for your SensorPhidgetanalogsensorsdonothavetheirownAPI,butinsteadtheiroutputisavoltagethatisconvertedtoadigitalvalueandaccessedthroughtheSensorValuepropertiesandeventsonaPhidgetInterfaceKit.ItisnotpossibletoprogrammaticallyidentifywhichsensorisattachedtotheAnalogInput.YourapplicationwillneedtoapplyanyformulasfromthismanualtotheSensorValuetotranslateitintousabledata.

    SeethePhidgetInterfaceKitproductmanualforanoverviewofitsAPIandadescriptionofourarchitecture.

  • 81134_0_Product_Manual - March 29, 2010

    Technical InformationThe1134SwitchableVoltageDividerisavoltagedividerwithswitches.Theswitchescanbeusedtocontrolwhichresistorsareusedinthevoltagedivider.Fromlefttoright,theresistancevalues(inOhms)are249,820,2.61K,8.45K,27.4K,91K,300Kand1M.Itispossibletohavemultipleswitchesflipped,puttingthecorrespondingresistorsinparallel.

    FormulasTheFormulatotranslateSensorValueintoresistanceis:

    Resistance(Ohms)=Req*(1000/SensorValue-1)

    WhereReqistheequivalentresistanceoftheswitchesthatareflippedoninOhms.

    TheSwitchableVoltageDividerhasaninternalbufferontheoutput.Thisallowstheoutputtobereadwithoutdistortioncausedbythedevicereadingthemeasurement,suchasthePhidgetInterfaceKit.

    Configuring the Voltage DividerTooptimizethevoltagedividertomeetyourneeds,youhavetoadjusttheswitchable resistance to match the characteristicsofyourchosenvariableresistor.First,adjusttheresistancefornostimulionyoursensor,thenapplymaximum stimuli and make sure that the Sensor Value stays within a range that givesyouanacceptableresolution.Theformula is most accurate at a SensorValue of500,withanerrorof0.4%.At100and900,theerrorincreasestoapproximately1.1%andat50and950,itincreasesto2.1%.

    Asageneralrule,iftheSensorValueisover900,alowerresistanceshouldbeswitchedin.IftheSensorValueisbelow100,ahigherswitchshouldbetoggled.Continue adjusting the switches until you findanacceptablerange.

    Warning:Itispossibleforthe1134toapplyupto5Vtothevariableresistor.Iftheresistorcannothandlethisvoltage,itcanbedamaged.

    The1134isaverysimplewayofmeasureresistance.Wheninterfacingtosensorswithsmallresistances(like100ohmRTDs,forinstance),largecurrentscanflow-upto30mA.Thislevelofcurrentmaycausesubstantialheatinginthevariableresistor,distortingthemeasurementorevenpossiblypermanentlydamagingit.

    OUTPUT+5V

    249

    820

    2.41

    K

    8.45

    K

    27.4K

    91K

    300K

    1M

  • 91134_0_Product_Manual - March 29, 2010

    Variable resistance sensorsHerearesomeinterestingvariableresistancesensorsthatcouldbeusedwiththeVoltageDivider.

    Sensor Type Manufacturer Example Digikey searchLight Sensors AdvancedPhotonics PDV-P9003-1 photocell

    Force Sensors CUIInc. IESP-12 force sensor

    Thermistors US Sensor 615-1037-ND thermistor radial

    Bend Sensors imagesco.com FLX-01 n/a

    Other Interfacing AlternativesIfyouwantmaximumaccuracy,youcanusetheRawSensorValueproperty.Tomodifytheformula,substitute(SensorValue)with(RawSensorValue/4.095)

    IfthesensorisbeinginterfacedtoyourownAnalogtoDigitalConverter(notaPhidgetdevice),ourformulascanbemodifiedbyreplacing(SensorValue)with(Vin*200).ItisimportanttoconsiderthevoltagereferenceandinputvoltagerangeofyourADCforfullaccuracyandrange.

    Analog Input Cable Connectors

    EachAnalogInputusesa3-pin,0.100inchpitchlockingconnector.Picturedhereisaplugwiththeconnectionslabeled.Theconnectorsarecommonlyavailable-refertotheTablebelowformanufacturerpartnumbers.

    Cable ConnectorsManufacturer Part Number Description

    Molex 50-57-9403 3 Position Cable Connector

    Molex 16-02-0102 Wire Crimp Insert for Cable Connector

    Molex 70543-0002 3 Position Vertical PCB Connector

    Molex 70553-0002 3PositionRight-AnglePCBConnector(Gold)

    Molex 70553-0037 3PositionRight-AnglePCBConnector(Tin)

    Molex 15-91-2035 3PositionRight-AnglePCBConnector-SurfaceMount

    Note:Mostoftheabovecomponentscanbeboughtatwww.digikey.com

  • 101134_0_Product_Manual - March 29, 2010

    Mechanical Drawing

    Device SpecificationsCharacteristic ValueMaximum Current Consumption 30 mA

    Supply Voltage 3.0to5.25VDC

    MaxSwitchableResistance 1M Ohms

    MinSwitchableResistance 172 Ohms

    VariableResistorRange Up to 50 MegaOhms

    ResolutionbetweenSensorValue100-900 Less than ±1%ofvariableresistorperSensorValue

    1:1scale

    Product History

    SupportCallthesupportdeskat1.403.282.73358:00AMto5:00PMMountainTime(US&Canada)-GMT-07:00

    or

    E-mailusat:[email protected]

    Date Board Revision CommentMarch 2010 0 ProductRelease