Shop OBEX P1 Docs P2 Docs Learn Events
Px and scale number — Parallax Forums

Px and scale number

TJHJTJHJ Posts: 243
edited 2008-07-17 17:39 in BASIC Stamp
So I am new to the basic stamp series, mainly plan on using it to check devices before attempting to use them on the Prop chip. So I purchased the Bs2Px chip. All of the examples have a scale number for each Bs2 clock speed, but so far none have one for the Px. Is there a common number I could use in the scale component of the demo code to make it compatible with the Px chip?

Thank you for your time,
TJ

Comments

  • stamptrolstamptrol Posts: 1,731
    edited 2008-07-17 14:05
    On the Parallax web store, you can compare the various Stamp modules.

    A quick check shows the standard BS2 to execute 4000 instructions per sec, the BS2sx about 10000
    and the BS2px about 19000. Since the examples give scale numbers for the other Stamps,you should be able to make a good estimate of what scale number to use with the Propellor to approximate the BS2px.

    Cheers,

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Tom Sisk

    http://www.siskconsult.com
    ·
  • TJHJTJHJ Posts: 243
    edited 2008-07-17 17:04
    I guess I explained that wrong, I am sorry Tom, but thank you for your time.

    So under the Memsic 2125 Dual-axis Accelerometer BS2 sample code it contains the following to account for the timing/clock speed difference of each chip.

    #SELECT $STAMP
      #CASE BS2, BS2E
        Scale       CON     $200                    ' 2.0 us per unit
      #CASE BS2SX
        Scale       CON     $0CC                    ' 0.8 us per unit
      #CASE BS2P
        Scale       CON     $0C0                    ' 0.75 us per unit
      #CASE BS2PE
        Scale       CON     $1E1                    ' 1.88 us per unit
    #ENDSELECT
    
    
    
    



    but the P has a different speed than the Px. There are a few example codes that use similar control to account for the different clock speeds.

    Does anyone know what the approiate scale would be for the Px chip?

    Thank you.
  • Mike GreenMike Green Posts: 23,101
    edited 2008-07-17 17:39
    The BS2px Brief (www.parallax.com/Portals/0/Downloads/docs/prod/stamps/BASICStamp2px.pdf) gives the timing information for the various statements in Stamp Basic. This link is from the BS2px product page in the Parallax web store.
Sign In or Register to comment.