CurrentValue()

Support for the Milan Intelligent interface, sold by Money Controls as the Paylink USB unit and for the earlier PCI card version.

Moderators: aardvark, davebush, Admin

Post Reply
Vii
Posts: 3
Joined: Mon Oct 05, 2015 11:21 am

CurrentValue()

Post by Vii »

Hello,

I have read the programmers manual which states:
The value returned by this call is never reset, but increments for the life of the interface card.
Since this is a 32 bit integer, the card can accept £21,474,836.47 of credit before it runs into
any rollover problems. This value is expected to exceed the life of the unit.
I have several questions:

1. Why is this number signed?
2. A am currently working with Hungarian Forints, so 2147483647 HUF / 100 =~ 69 000 EUR which is less likely to exceed the life of the unit.
So my question is: can anybody give me a certain behavior what will happen when the number overflows, will i have to work with negative numbers? I am asking this, because i can't replicate this kind of scenario.
3. Is there some kind of way to reset this counter?
4. Is there some kind of way to change the lowest denomination of the currency. I will not have any acceptors that accept coins smaller than 10 HUF, but i could settle with 1 HUF base unit

I have the same problem with CurrentPaid()

Thank you,
davebush
Posts: 482
Joined: Fri Oct 22, 2004 12:20 pm

Re: CurrentValue()

Post by davebush »

Hi,

I'm afraid that the basic design of the Paylink is 10 years old and was done for the UK Market. We do have plans to eventually implement system wide scaling - but that won't be in time to help you.

The best solution for you is to periodically call E2PromReset to reset the values before they overflow.

E2PromReset
Synopsis
The E2PromReset call is made by the application to clear all the internal E2PROM memory on the card. This is the are where the Paylink system keeps the value in / value out counters, the configuration information, etc.
void E2PromReset(int LockE2Prom);
Parameters
1. LockE2Prom
This is a flag. If zero, then the E2PROM may be reset again later.
If non zero, then all future calls to this function will have no effect on the card.
Aardvark software developer. Please put all communication on the problem through the board for the benefit of others.
Vii
Posts: 3
Joined: Mon Oct 05, 2015 11:21 am

Re: CurrentValue()

Post by Vii »

OK, thank you for your reply.

I initially thought that E2PromReset function resets only the user-accessible e2prom.

Can you specify a bit more details about what data am i wiping with E2PromReset and how can i restore previous values, if possible?

If not, what is the data that is stored in the internal eeprom, so i can keep track of that data.

Thanks,
davebush
Posts: 482
Joined: Fri Oct 22, 2004 12:20 pm

Re: CurrentValue()

Post by davebush »

No, user accessible data is not touched by erase.

The erase clears CurrentValue, CurrentPaid and the PathCount field for all acceptor coins.
Aardvark software developer. Please put all communication on the problem through the board for the benefit of others.
Post Reply