Jump to content


  • Content Count

  • Joined

  • Last visited

Community Reputation

0 Neutral

About Kaplah

  • Rank
  1. Ok, I've gotten my senior project code written since my last post, and thanks to some email correspondance with jwinpenny I've figured out how to use his rs485 network code. The problem I am having now is when I try to compile the code I'm recieving the following errors. line 1: Illegal directive //this is #include line 4: Illegal directive // this is #include line 76: Illegal directive //this is a #seperate line 145: Illegal directive // this is a #seperate I'm not a programmer by nature, and I know just enough C to have coded the while and if loops I need for my main program. So troubleshooting this is a bit beyond me. Any assistance would be appreciated. I am willing to email my project code to you if you're willing to proofread it for me. Thanks for your time
  2. Thanks, but I have a hard time reading and making sense of examples. What I need is an explanation of some of the comands. Neither of the books I have on the PIC are very good at explaining these. TrisX (ie. trisb, trisa, yadda yadda) And portx (i.e. porta, portb, yadda yadda) The examples that I read through really didn't explain how these work either. How does the pic write data to a port, can I raise a single pin value, or does it write out data in binary numbers? What I'm trying to do is similar to having 8 LED's hooked up all to port b, and I only want one raised at a time for a period of 1 second.
  3. I'm working on my senior design project as an electrical engineer. I'm decently versed in C and C++, and I know the general layout of my program. The problem is I do not know how to read in information from the ports, and read out info to the ports. I have a couple of books and they have been little help. A quick explanation would be of more assistance than a 400 page manual. My situation is this. A hex switch will be hooked up to port A of a 16lf874A. I need to read in this info to store to a char. I also need to monitor port B for 14 DIP switches. These will be used for controls.
  • Create New...