Shop OBEX P1 Docs P2 Docs Learn Events
Some Simple Questions From a Newb — Parallax Forums

Some Simple Questions From a Newb

willthiswork89willthiswork89 Posts: 359
edited 2006-06-19 16:23 in BASIC Stamp
H guys im new hopefully ill get a good welcome, my question is ive been reading the whats a miucrocontroller and i have a few questions that dont get answered in the book fully. the RCTIME wiring diagram doesnt connect with me, because is goes

································ Wire
P4->Resistor->104 .01 u|Potentiometer->··| ...... what i dont get is how does this work when the wire is just running to the place that the potentiometer is connected to anyways?

also

with the DIRH and OUTH how does it know whats what like... i have the Clock Display thingy like in alarm clocks and its connected by resistors through p15-p8 and my question is when i do

outh = %10101010 how does it know that it needs to use THOSE 8 ? ho does it know whats connected and how does it know in which order to complete this? like if i move these all down one (p14-p7) would it still work the same? thanks for the time guys!

Comments

  • PJAllenPJAllen Banned Posts: 5,065
    edited 2006-06-19 11:50
    · With DIRH/DIRL, you are telling it that the pin groups their direction, that they are inputs or outputs, but not the state of their input or output (HI or LO).

    · With OUTH/OUTL, you are setting the states of the outputs in question.

    · OUTH is always and only P8-P15 and OUTL is always and only P0-P7, those are internal hardware/firmware associations.

    · RCTIME works by going through, I believe, two periods during RCTIME execution: a charge time and a discharge time.

    · Post edit -- Of course, you don't have to deal with the OUTputs a byte at a time (as in OUTL/OUTH) as you can set each independently with the HIGH and LOW commands.· HIGH 7 makes output P7 HI and LOW 7 makes output P7 LO.

    Post Edited (PJ Allen) : 6/19/2006 12:54:32 PM GMT
  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2006-06-19 13:58
    In the Help File under Memory and Variables you can see the way that these commands (OUTH/OUTL) are organized, and which pins they affect.· The Help File may also clarify the RCTIME command for you.· You can get help on any command in the Help File by clicking on the words, "PBASIC Reference" and then clicking on the command.· I hope this helps you out.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Tech Support
    csavage@parallax.com
  • willthiswork89willthiswork89 Posts: 359
    edited 2006-06-19 16:16
    thanks guys that helps a ton i didnt know that it associates it with only p15 through p8 my other question is after i read this book where do i go from there... ive got alot of c++ experience and i got to that point where i didnt know where to go but i dunno about this one it may be an easierwuestion to answer lol
  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2006-06-19 16:23
    Once you've completed the "What's A Microcontroller?" tutorial you can always go through some of our other Stamps In Class materials.· The manuals are always available as free PDF downloads.

    http://www.parallax.com/html_pages/edu/curriculum/sic_curriculum.asp

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Tech Support
    csavage@parallax.com
Sign In or Register to comment.