dizgah
Member level 5
hi every body
i need initialing mfrc522 rfid chips for my stm32f103 mcu,
i cant find a powerfull and fully commented library for that on keil,but i find a very good library with example for arduino and need to ported this library
its my first question :
what it this monster?
im familiar with constructor & know all of the code except :
its not like other constructor i saw ,what's meaning of :: ?,can any one descibe it ?
tnks
i need initialing mfrc522 rfid chips for my stm32f103 mcu,
i cant find a powerfull and fully commented library for that on keil,but i find a very good library with example for arduino and need to ported this library
its my first question :
what it this monster?
Code:
/**
* Constructor.
* Prepares the output pins.
*/
MFRC522::MFRC522( byte chipSelectPin, ///< Arduino pin connected to MFRC522's SPI slave select input (Pin 24, NSS, active low)
byte resetPowerDownPin ///< Arduino pin connected to MFRC522's reset and power down input (Pin 6, NRSTPD, active low)
) {
// Set the chipSelectPin as digital output, do not select the slave yet
_chipSelectPin = chipSelectPin;
pinMode(_chipSelectPin, OUTPUT);
digitalWrite(_chipSelectPin, HIGH);
// Set the resetPowerDownPin as digital output, do not reset or power down.
_resetPowerDownPin = resetPowerDownPin;
pinMode(_resetPowerDownPin, OUTPUT);
digitalWrite(_resetPowerDownPin, LOW);
// Set SPI bus to work with MFRC522 chip.
setSPIConfig();
} // End constructor
Code:
MFRC522[B]::[/B]MFRC522( byte chipSelectPin,byte resetPowerDownPin) {
tnks