Skip to content

Commit

Permalink
Fix #190
Browse files Browse the repository at this point in the history
The default `RST pin` of MFRC522 is 9, which overlaps with I2C pins used by LCD blocks. Since reset is not commonly used, we pass `UINT8_MAX` instead., which supresses the `RST pin` feature of MFRC522.
  • Loading branch information
pablosun committed Jun 25, 2018
1 parent 9c94f0f commit 78e49b7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion edit/generators/mfrc522.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ Blockly.Arduino.mfrc522_read = function() {

Blockly.Arduino.definitions_['define_spi_include'] = '#include <SPI.h>\n';
Blockly.Arduino.definitions_['define_mfrc522_include'] = '#include <MFRC522.h>\n';
Blockly.Arduino.definitions_['define_mfrc522_inst'] = 'MFRC522 rfid(/*SS_PIN*/ 10, /*RST_PIN*/ 9);\n';
Blockly.Arduino.definitions_['define_mfrc522_inst'] = 'MFRC522 rfid(/*SS_PIN*/ 10, /*RST_PIN*/ UINT8_MAX);\n';
Blockly.Arduino.definitions_['define_mfrc522_readid'] = `
String mfrc522_readID()
{
Expand Down

0 comments on commit 78e49b7

Please sign in to comment.