Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
P-micro no digitalWrite pin #13
14-12-2015, 12:20 AM, (This post was last modified: 17-12-2015, 06:21 PM by jwzumwalt.)
#1
Photo  P-micro no digitalWrite pin #13
UPDATE
------------
This issue was caused by the compiler becoming buggy.
After a reboot, the problem disappeared.


However, I did find the definition for USERBUTTON was
wrong. It is set to 41, it should be 13.
------------
After struggling with IO problems using the Pinguino Micro Pic32, I soldered a LED board to see the I/O ouputs.
I found that the digitalRead( ) & digitalWrite( ) will not send a signal to pin #13. I have no knowledge of the Arduino and what may be necessary to attempt to make the PIC32 compatible but this seems to be a IDE bug since pins 10, 13, 20, and 28 also have multiple definitions.

It seems odd that the only way to write to this pin using digitalRead( ) & digitalWrite( ) is to use the pseudo pin #41 read/write. You can write/read normally using the connector P2_3 read/write.

Perhaps someone can explain the extra pin definitions for pin 13, 20, and 28.

(Now, I am off to decode the port commands. As I decipher this board I will be updating this diagram. )


[Image: pic32_pinguino-micro_io.png]
----------------
Thanks,
j
wzumwalt
 (\__/)
 (='.'=)
 (")_(")
Reply
14-12-2015, 11:34 AM, (This post was last modified: 14-12-2015, 04:18 PM by pingotg.)
#2
RE: P-micro no digitalWrite pin #13
I see from the schematic that port D bit 4 is tied to port D bit 0, so that is likely the underlying issue.

(It has consequences, such as potentially causing a short.) Maybe the pin was set by the digitalWrite but clashed with the pin it's shorted to? (You can damage the chip that way.)

I don't have that board but you have to be similarly aware on the OTG I have.

John
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)