Code Monkey home page Code Monkey logo

matedealer's Introduction

Hi there ๐Ÿ‘‹ I'm bouni

Visits Badge GitHub User's stars GitHub followers Twitter Badge Mastodon Badge

Top projects ๐Ÿคฉ

My stats ๐Ÿš€

Bouni's GitHub Stats

Bouni's Most used languages

Support me โ˜•

matedealer's People

Contributors

asiniy avatar bouni avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

matedealer's Issues

How to upload MateDealer to arduino?

Hello,

I'm testing mdb to arduino interaction and want to use your code.

First of all, I ran

sudo apt-get install gcc-avr binutils-avr gdb-avr avr-libc avrdude

Secondly, I ran

cd MateDealer && make all

What should I doing next?

SETUP command 111H with Sub-command 010H

Hello, thank you for make it code and your blog very good !

I have problem. i read your blog at http://blog.bouni.de/2012/the-mdb-protocol-part-3.html, the setup command (111H) will has 2 sub command : 000H and 0001H

I have VMC board. and i try send 100H (ACK) when Reset command and then send 000H 100H when PULL command and then VMC send it

+V: 0x111
+V: 0x010
+V: 0x111
+V: 0x010
+V: 0x117
+V: 0x117

Are you know about sub command 010H in SETUP command ?

Thanks !

This my code (Arduino) without UART file

extern void MDB_write(int data) ;
extern int MDB_read() ;
extern int MDB_available() ;
extern void MDB_setup() ;

void setup() {
  MDB_setup();

  Serial.begin(9600);
  Serial.println("Start !");

}

#define WAIT_DATA_1_Byte() { while (!(UCSR1A & (1 << RXC0))); }
#define READ_DATA_1_Byte() (((UCSR1B & 0x2) << 7) | UDR1)

int isReset = true;

void loop() {
  WAIT_DATA_1_Byte();
  int b = READ_DATA_1_Byte();
  if (b == 0x110) {
    WAIT_DATA_1_Byte();

    if (READ_DATA_1_Byte() == 0x010) {
      MDB_write(0x100);
      isReset = true;
      //Serial.println("Respont RESET command");
    }
  } else if (b == 0x112) {
    WAIT_DATA_1_Byte();

    if (READ_DATA_1_Byte() == 0x012) {
      if (isReset) {
        MDB_write(0x000);
        MDB_write(0x100);
        //Serial.println("Send Just reset");
        isReset = false;
      } else {
        MDB_write(0x100);
        //Serial.println("Send ACK");
      }
    }
  } else if ((b&0xF8) == 0x10) {
    Serial.print("+V: 0x");
    Serial.print(b >> 8, HEX);
    if ((b & 0xFF) < 0x10) Serial.print("0");
    Serial.print(b & 0xFF, HEX);
    Serial.println();
  }
}

Machine send reset before cashless enable

I am currently trying to couple a Nespresso dispenser with your MateDealer system.

I have the first part of the process established, with the RESET, the POLL of the machine, the SETUP stage 1, the SETUP stage 2. Then the machine waits a few seconds and sends the RESET command and starts the cycle again.

Has anyone ever tried to configure one of these distributors? Could you help me find what's wrong with the system.

thank you so much

Answer on session complete

First of all, great project and very well documented on your blog. Thanks alot!

About the issue:
When the VMC sends Vend-Session complete (113h 004h 017h) the mate dealer should answer with end session (N07h) and not with ACK (100h). I don't know if 'N' should be logic 1 or 0.

It's only small detail, maybe they changed the speccs in the meantime....?

If you accept the issue, please also update it on your blog for consistency or make a remark.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.