bgaultier/laclef-webapp

Add option for PIN Code

Opened this issue · 4 comments

Feature:

With a small POS style Terminal it would be usefull to accept payments only with PIN Code entered.
Scenario:

Swipe tag over reader - 'pop up' on terminal will be shown to enter PIN and accept payment.

Could be usefull in some cases ;)

Good idea, can you provide me a link to this kind of terminal ?
Cheers

There is no terminal for this usage. The idea was an rpi with an small 7" tochscreen with your webapp with a new part the login via pin - the username is the one behind the tag owner. Currently i dont know how to push a message to the web app to show the pin pop up...

Sure, we can use a Raspberry Pi with a touchscreen to generate a json message like so :

POST "http://api.yourpi.local/swipes/5"
{"uid":"5AE56B", "service":"0", "pin":"0963"}

@nibelungen I will work on this, do you have an pincode example for a Raspberry Pi touchscreen?

Why reinvent the wheel... I´ve found this one: http://keith-wood.name/keypad.html
looks good and the last releas just some days old.
Hmm but how do we query the post parameters??
Currently i write the swipe into a mysqldb and query the DB within the script:

var fast_update = setInterval(
        function(){
            $.get('queryDB.php', updateData);
                function updateData(data) {
                    $('#nfcid').html(data);
                        if(data){
                                                dosomestuffhere
                        }
                }
            },1000);    

But i get in trouble with the interval.... its too fast to enter the pin in this time, if the interval lasts longer the time to recognize the swipe will be too long...