|Help with hitechnic superpro prototype sensor
|Page 1 of 1|
|Author:||logan_en [ Sun Mar 23, 2014 1:17 pm ]|
|Post subject:||Help with hitechnic superpro prototype sensor|
How do I read from digital inputs correctly? I tried to extend the code from example7 in Xander's drivers and was not able to get any decent results.
Here is my code: http://pastebin.com/LKGm9EPX
I get a lot of very odd readings. Is there anything wrong with my code that I should be doing differently? Sorry if it is something very simple, I am new to programming robots / with robot-c and managing I/O.
|Author:||mightor [ Mon Mar 24, 2014 2:26 am ]|
|Post subject:||Re: Help with hitechnic superpro prototype sensor|
You'll need a call to HTSPBsetupIO() to configure the pins as either input or output, I am not seeing that in your code. You are also not really saying what you're trying to read or write. Be as precise as you can.
Another word of advice, remove any comments from the file that are NOT pertinent to the experiment you're trying to do, it's confusing. Make comments that are relevant to the task at hand.
|Page 1 of 1||All times are UTC - 5 hours [ DST ]|
|Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group