Shop OBEX P1 Docs P2 Docs Learn Events
bs2px TTL Logic. — Parallax Forums

bs2px TTL Logic.

josecanalesjosecanales Posts: 1
edited 2006-10-14 03:56 in BASIC Stamp
Hi. I am new using the stamp modules.· Currently I am trying to use the Bs2px in one of my projects.· I have read that a voltage less than 1.4 is interpreted as a logic "0" and above as a "1".· Im usinng the configpin Threshold comand.· Anyone has a sample code for this controller.· All my inputs are analog so any help would be appreciated.

Comments

  • Mike GreenMike Green Posts: 23,101
    edited 2006-10-14 03:56
    The BS2px is like most of the Stamps and only has a few differences from earlier models. There are several manuals/tutorials in the Stamps in Class section of the Parallax website. Download at least "What's a Microcontroller?". It has many examples with diagrams of how to connect the parts and sample code. Another one "Basic Digital and Analog" should be useful.

    Even though the BS2px has some features that make using analog signals much easier, the Stamps are not specifically designed for directly handling analog signals. For example, the threshold (1.4V) is not that accurate and can be thrown off by noise on the power supply. The BS2px does have an analog comparator on pins 1 and 2 that can be used with the PWM statement and an appropriate resistor and capacitor, can be used to make a pretty accurate analog to digital converter. The RCTIME statement with the same parts can also be used to make a simple analog to digital converter. The PBasic manual and What's a Microcontroller? do discuss these.
Sign In or Register to comment.