monkeyboard / Wiegand-Protocol-Library-for-Arduino

Wiegand 26 and Wiegand 34 Protocol Library for Arduino
323 stars 131 forks source link

What types of pins do I need to connect D0 and D1 to an ESP32 ? #43

Closed GeorgeFlorian closed 4 years ago

GeorgeFlorian commented 4 years ago

Hello !

Can I randomly choose two GPIO from the ESP32 pins or do they have to be specific pins, like UART pins ?

For example, if I want to use the Serial interface on the ESP32-EVB I will use GPIO 4 and GPI 36 specifically:

#define RX1 36
#define TX1 4

Do D0 and D1 have the same requirements ? Or I can choose whatever pins I have available ? Do they have to be input or output or both ?

Thank you.

jpliew commented 4 years ago

from ESP32's documentations, and GPIO will do.

GeorgeFlorian commented 4 years ago

from ESP32's documentations, and GPIO will do.

I am sorry, I didn't understand a thing from what you've written. Can you please be more eloquent ? Are you trying to tell me that any GPIO will do ? So that means that the pin has to be Input AND Output, correct ?

jpliew commented 4 years ago

Yes, any GPIO for ESP32 will be able to work. When you use the library, the initialisation will make the GPIO pin to be INPUT and with INTERRUPT.

3h50 commented 4 years ago

just tried the library with an esp32, seems to read a ton of items with no cards in front of it. Does it need pullup resistors?

jpliew commented 4 years ago

just tried the library with an esp32, seems to read a ton of items with no cards in front of it. Does it need pullup resistors?

Check with an oscilloscope first the D0 and D1 signal from the reader, also for ESP32 you need a voltage level converter to convert the voltage of D0 and D1 to the input level of ESP32.

Hope this helps.

3h50 commented 4 years ago

Awesome thanks. I bet the voltage is the issue I thought the mfr said it was 3v but who knows. I wonder of any are out there that work without a converter -.-

From: JP Liew notifications@github.com Reply-To: monkeyboard/Wiegand-Protocol-Library-for-Arduino reply@reply.github.com Date: Monday, February 24, 2020 at 2:18 PM To: monkeyboard/Wiegand-Protocol-Library-for-Arduino Wiegand-Protocol-Library-for-Arduino@noreply.github.com Cc: Taylor Fry taylor.fry@fryco.com, Comment comment@noreply.github.com Subject: Re: [External] [monkeyboard/Wiegand-Protocol-Library-for-Arduino] What types of pins do I need to connect D0 and D1 to an ESP32 ? (#43)

just tried the library with an esp32, seems to read a ton of items with no cards in front of it. Does it need pullup resistors?

Check with an oscilloscope first the D0 and D1 signal from the reader, also for ESP32 you need a voltage level converter to convert the voltage of D0 and D1 to the input level of ESP32.

Hope this helps.

— You are receiving this because you commented. Reply to this email directly, view it on GitHubhttps://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_monkeyboard_Wiegand-2DProtocol-2DLibrary-2Dfor-2DArduino_issues_43-3Femail-5Fsource-3Dnotifications-26email-5Ftoken-3DAGD3EYVBE2K6XIKAZ4K2WYDREQTQHA5CNFSM4JTT7OS2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEMZMBZI-23issuecomment-2D590528741&d=DwMCaQ&c=euGZstcaTDllvimEN8b7jXrwqOf-v5A_CdpgnVfiiMM&r=b79i46Xt-ToF3Zh-TwMXMn7PTFUJYqOu9J4wxem4ud8&m=3o9WSqqy_geEAKcJS1ShEAO88yHX0zpKImEg4Cf8lko&s=hDAc7jgL0Bndx0Gh6Xwp1Vl6MzcCaYh4anqQZyuQLG8&e=, or unsubscribehttps://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_notifications_unsubscribe-2Dauth_AGD3EYRUVFVOHLWMPHAPZKDREQTQHANCNFSM4JTT7OSQ&d=DwMCaQ&c=euGZstcaTDllvimEN8b7jXrwqOf-v5A_CdpgnVfiiMM&r=b79i46Xt-ToF3Zh-TwMXMn7PTFUJYqOu9J4wxem4ud8&m=3o9WSqqy_geEAKcJS1ShEAO88yHX0zpKImEg4Cf8lko&s=ILuf0NWU2zLTkIEd2RSu3TxVjDxph1CKS9dhHI7tAOM&e=.