GithubHelp home page GithubHelp logo

rancilio-pid / clevercoffee Goto Github PK

View Code? Open in Web Editor NEW
268.0 25.0 138.0 131.46 MB

Do-It-Yourself PID für Espressomaschinen

Home Page: https://clevercoffee.de

License: GNU General Public License v2.0

C++ 60.50% C 28.15% HTML 5.49% JavaScript 5.12% Python 0.74%

clevercoffee's Introduction

CleverCoffee

(formerly Rancilio PID)


Buy Me a Coffee at ko-fi.com

About

This project implements a PID controller for stable and accurate temperature control, originally for Rancilio Silvia espresso machines but also includes support for Gaggia and Quickmill machines. Others can easily be added or are already compatible.

Additional features include:

  • shot timer
  • pre-infusion (wip: reduced initial pressure using a dimmer for the pump)
  • brew by weight (using weight cells, no support for external scales yet)
  • brew by time
  • pressure monitoring

The hardware has a small footprint and can easily fit into most smaller espresso machines. The original wiring of the machine (mostly) remains and is only extended. The machine can be easily reversed to the original state after the conversion.

The project has been in active development and supported for 4 years with continuous improvements. Hundreds of machines have been converted to PID control already.

You can find our project website here: Clever Coffee Website.

This software is Open Source: free of charge for you and customizable to your personal needs.

We recommend you have a look at the manual before starting a build, you can find the german one here. It is currently being reworked to include all the latest features. The english one is sadly still very outdated but will also be updated soon.

Chat and Support

You will find more information, discussions, and support on our Discord server. If you want to be part of the project and help with development of hardware, software and documentation you will also find the right channels there. Please keep in mind that we only can give support for our own pcbs. We will not help with any hardware solutions that are not based on our own pcbs. Please do not offer any kind of pcb derivatives of our design or own developments without contacting us before. This can cause a ban on our discord server.

Video tutorial on how to flash the firmware (a little outdated but mostly still valid):
https://youtu.be/KZPjisOEcQ4

Version

With Version 3.3.0 we bring the last major release with support for ESP8266 and ESP32. There will only be bug fix releases for ESP8266 from there on. Further development, with new features, will only be done for ESP32. "master" branch contains the current development only for esp32. "master-esp8266" branch contains last version for ESP8266 and ESP32.

What is possible after installation into your espresso machine?

  • Control of the brew temperature with an accuracy of up to +/- 0,1°.
  • Reaches the target temperature within 5 to 10 minutes after switching on (you should, however, wait a bit longer, e.g. 20 min depending on the machine to heat up the group head etc.)
  • Set PID parameters and monitor current temperature and heater output on a web page hosted on the ESP controller
  • Separate PID for steam mode with own parameters and target temperature (can be enabled in the web interface/MQTT or using the steam switch)
  • Automatically brew by set time (including pre-infusion with additional dimmer for the pump).
  • Automatically brew by weight when scale components are built in.
  • Possible to change brew and steam switches to push buttons. Brew push button then has two actions: short press for brew, long press to flush.
  • Allows brew switch detection (e.g. for the shot timer) by using an optocoupler module when deciding not to control the pump from the ESP (details).
  • MQTT (IoT) support to monitor and manipulate all important parameters.
  • Extended data monitoring via Influxdb/Grafana.
  • Choose from multiple designs for the display (including vertical), possibility to integrate custom designs
  • Over-The-Air updates of the firmware (WiFi)

User feedback and suggestions for further development of the software are most welcome. You are welcome to help us in our mission to make better espresso. :)

Thanks to every single supporter!

clevercoffee's People

Contributors

alcoinus avatar andreas301-sketch avatar blinkingjoe avatar btotherunner avatar christian-hellwig avatar cottec avatar dafes avatar danieltwagner avatar emreakca avatar endym avatar fabiansperrle avatar fiendie avatar genkigenki avatar gomezalberto avatar jomeie avatar kjyv avatar loque90 avatar mar0ni avatar miau09 avatar mikulcak avatar murmeltier08 avatar nilaik avatar nils-werner avatar pbehr avatar piontec avatar rfmae avatar simoncbell avatar simonspa avatar tml89 avatar user-na 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  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  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

clevercoffee's Issues

Brew switch

Abfangen, wenn der Brühschalter geschaltet mit der Maschine startet und/oder Anzeige er solle zurück gestellt werden.

Temperaturprüfung

Pürfung der Temperatur kleiner 0 Grad ergänzen mit Prüfung, ob die Temperatur um mehr als X springt in einer gewissen Zeit, um fehler in der Brüherkennung zu erkennen. Keine Beispiel werte im Moment vorhanden.

unnötiger Impuls bei Outout=isrCounter

`void ICACHE_RAM_ATTR onTimer1ISR() {
timer1_write(50000); // set interrupt time to 10ms

if (Output != isrCounter) { // führt dazu, dass der PWR immer sicher an oder aus ist (kein unnötiger Impuls bei Output=isrCounter)
if (Output < isrCounter) {
digitalWrite(pinRelayHeater, relayOFF);
//DEBUG_println("Power off!");
} else {
digitalWrite(pinRelayHeater, relayON);
//DEBUG_println("Power on!");
}
}
isrCounter += 10; // += 10 because one tick = 10ms
//set PID output as relais commands
if (isrCounter > windowSize) {
isrCounter = 0;
}`

QM Logo

Add logo QM-Logo_84x46_V1

multilingual support

Enable translated string in the display, so that the user can select the language via the userConfig.h file

esp32 support? k-type thermistors?

hi there

im superhappy that i found this distro!

i've planed since a long time to add PID to my Quickmill 3035.

my aim is to keep the Machine as close as possible to stock, so everything hidden and maybe only an exposing antenna to configure and monitor the temp.

is this distro also working with the ESP32? i just found the esp32 branch.. 👍

and how hard is it to add K-Type Thermistors? with MAX6675 or MAX31855 ?

cheers

Minor Code Issues

  • Do not use magic numbers, use #defines, i.e.:
    bezugsZeit > 35*1000 -> 35 -> #define SHOT_MAX_TIME_SEC (35*1000)
    machinestate = 40 -> is hard to read the code -> machinestate = STATE_DAMPF or machinstate=STATE_STEAM would be better
  • Make shot timer available for Blynk
  • Do not use header files for code.

How you mange this repo, shall I create a branch and make a pull request?

Display ausgabe ohne PID

Ein per Config auswählbare Anzeige nur mit Temperatur, Status anzeige oben und blinkenden Thermometer wenn Zieltemperatur erreicht.

PID Optimierung

Senden von Blynk bei günstigen Momenten des Ablaufes ohne PiD zu stören

To-Dos

  • Wifi Manager nur wenn kein Wlan geht? -> branch gibt es
  • Steam PID: erledigt 2.8.0

heating stopped - schriftgröße

Ich hab eben auf 2.7.3 geupdated und mir gefällt das neue Displaydesign richtig gut! Allerdings zerschießt es sich, sobald ich beim Dampfen 120grad überschreite. Ist das bei euch auch so oder liegt der Fehler bei mir?
50896E30-500B-427A-8AD3-DBF346FD8844

Fehler in moving average 1. readIndex++ in else-Zweig gelegt 2. if geaendert von numReadings - 1 auf 0

`void movAvg() {
if (firstreading == 1) {
for (int thisReading = 0; thisReading < numReadings; thisReading++) {
readingstemp[thisReading] = Input;
readingstime[thisReading] = 0;
readingchangerate[thisReading] = 0;
}
firstreading = 0 ;
}

readingstime[readIndex] = millis() ;
readingstemp[readIndex] = Input ;

if (readIndex == 0) { // geaendert numReadings - 1 auf 0
changerate = (readingstemp[0] - readingstemp[numReadings - 1]) / (readingstime[0] - readingstime[numReadings - 1]) * 10000;
} else {
changerate = (readingstemp[readIndex] - readingstemp[readIndex - 1]) / (readingstime[readIndex] - readingstime[readIndex - 1]) * 10000;
}

readingchangerate[readIndex] = changerate ;
total = 0 ;
for (i = 0; i < numReadings; i++)
{
total += readingchangerate[i];
}

heatrateaverage = total / numReadings * 100 ;
if (heatrateaveragemin > abs(heatrateaverage)) {
heatrateaveragemin = abs(heatrateaverage) ;
}

if (readIndex >= numReadings - 1) {
// ...wrap around to the beginning:
readIndex = 0;
}
else{
readIndex++;
}
}
`

PID

Umstellung von Ki Kd kn auf kp Tv und Tn
Prüfung von P_on_m

Blynk Superchart

Hallo an alle! In der Blynk App ist bei der Superchart für den Setpoint V3 vordefiniert, sollte eigentlich V7 sein. Ich weiß nicht, ob das nur bei mir so ist, dachte mal ich schreibs hier mal rein;)

OFFLINE MODE

offlinemode, dann kein OTA oder wificheck usw

Compiling problems using platform.io on Linux

I was trying to compile this software using platform.io core on my Arch Linux machine and was stumbling over several issues:

I was using a platformio.ini file

[platformio]
lib_dir = rancilio-pid/libraries/
src_dir = rancilio-pid/

[env:nodemcuv2]
platform = espressif8266
board = nodemcuv2
framework = arduino

Firstly, platform.io does not like the lib directory to be inside the src directory, and runs into a lot of file not found errors. To fix it I had to move rancilio-pid/libraries/ into the root project dir.

After this change I was running into several warnings and errors:

Several redefines, like

In file included from /home/nils/Projekte/pid/ranciliopid/rancilio-pid/rancilio-pid.ino:10:0:
rancilio-pid/userConfig.h:12:0: warning: "DISPLAY" redefined [enabled by default]
 #define DISPLAY 2            // 0 = deactivated, 1 = SH1106 (e.g. 1.3 "128x64), 2 = SSD1306 (e.g. 0.96" 128x64)
 ^
In file included from /tmp/tmpzs65wggn:1:0:
/home/nils/.platformio/packages/framework-arduinoespressif8266/cores/esp8266/Arduino.h:71:0: note: this is the location of the previous definition
 #define DISPLAY 0x1
 ^

and, more importantly, errors like

In file included from /home/nils/Projekte/pid/ranciliopid/rancilio-pid/rancilio-pid.ino:8:0:
libraries/ArduinoOTA/src/ArduinoOTA.h:100:22: error: 'WiFiServer' was not declared in this scope
 ArduinoOTAMdnsClass <WiFiServer, WiFiClient, WiFiUDP> ArduinoOTA;
                      ^
libraries/ArduinoOTA/src/ArduinoOTA.h:100:34: error: 'WiFiClient' was not declared in this scope
 ArduinoOTAMdnsClass <WiFiServer, WiFiClient, WiFiUDP> ArduinoOTA;
                                  ^
libraries/ArduinoOTA/src/ArduinoOTA.h:100:53: error: template argument 1 is invalid
 ArduinoOTAMdnsClass <WiFiServer, WiFiClient, WiFiUDP> ArduinoOTA;
                                                     ^
libraries/ArduinoOTA/src/ArduinoOTA.h:100:53: error: template argument 2 is invalid
libraries/ArduinoOTA/src/ArduinoOTA.h:100:65: error: invalid type in declaration before ';' token
 ArduinoOTAMdnsClass <WiFiServer, WiFiClient, WiFiUDP> ArduinoOTA;

Can someone point me in the right direction on how to fix these issues? It seems to me that the configuration classes WiFiServer, WiFiClient, WiFiUDP should be configured in my patch before importing ArduinoOTA.h, but I can't see them configured anywhere...

ShotTimer

Wäre es möglich einen ShoTimer zu integrieren?

Damit auf dem Display auch bei der Brüherkennung der Shottimer startet und die Sekunden "Groß" angezeigt werden.

Ist Temp überschreibt Pfeil im Minimal Displ. Template

Problembeschreibung:

Das Problem tritt beim Minimal Template Displaydesign auf. Beim Dampfbezug (sprich über 100° C) überschreibt die "Ist-Temp" den Pfeil zur Soll-Temp, da die Ist-Temp mehr Platz als im "Normalfall" einnimmt.

Lösungsvorschlag:

Es dürfte mehrere Optionen geben:

  1. Ab 100° werden keine Nachkommestellen mehr angezeigt
  2. Ab 100° wird kein Pfeil und keine Solltemperatur mehr dargestellt (die passt ja sowieso nicht zum Dampfbezug)

Temperature Template

Temperature Template


/********************************************************
    send data to display
******************************************************/
void printScreen() 
{
  unsigned long currentMillisDisplay = millis();
  if (currentMillisDisplay - previousMillisDisplay >= intervalDisplay) {
    previousMillisDisplay = currentMillisDisplay;
    if (!sensorError) {
      u8g2.clearBuffer();
      //draw outline frame
      //u8g2.drawFrame(0, 0, 128, 64);
     

      //draw (blinking) temp
    if (fabs(Input - setPoint) < 0.3) {
    if (isrCounter < 500) {
      if (Input < 99.999) {
        u8g2.setCursor(13, 12);
        u8g2.setFont(u8g2_font_fub35_tf);
        u8g2.print(Input);
      }
      else {
        u8g2.setCursor(-1, 12);
        u8g2.setFont(u8g2_font_fub35_tf);
        u8g2.print(Input);
      }
    }
  } else {
    if (Input < 99.999) {
      u8g2.setCursor(13, 12);
      u8g2.setFont(u8g2_font_fub35_tf);
      u8g2.print(Input, 1);
    }
    else {
      u8g2.setCursor(-1, 12);
      u8g2.setFont(u8g2_font_fub35_tf);
      u8g2.print(Input, 1);
    }
  }
}

      // Für Statusinfos
      if (Offlinemodus == 0) {
        getSignalStrength();
        if (WiFi.status() != WL_CONNECTED) {
          u8g2.drawFrame(116, 28, 12, 12);
          u8g2.drawXBMP(118, 30, 8, 8, antenna_NOK_u8g2);
        } else {
          if (!Blynk.connected()) {
            u8g2.drawFrame(116, 28, 12, 12);
            u8g2.drawXBMP(118, 30, 8, 8, blynk_NOK_u8g2);
          }
        }
      } else {
        u8g2.drawFrame(116, 28, 12, 12);
        u8g2.setCursor(120, 30);
        u8g2.print("O");
      }
      u8g2.sendBuffer();
    }
  }

Update ZACwire Library

In the last weeks I developed and tested a new version of the ZACwire Library for the TSic temperature sensor. The changes are the following:

  • works also on an ESP32 or other µC
  • checks with every .getTemp(), if the sensor is still connected and sending
  • scattered reading errors have been eliminated
  • ISR is faster

Please update the library files to the 1.3.0:
https://github.com/lebuni/ZACwire-Library

Offlineanzeige, TOF

„Offlinemodus“ kollidiert aktuell mit der füllstandsanzeige, vllt etwas nach links rücken oder durch „offline“ ersetzen.
image

Bug Display

wenn der PID aus ist und man einen Bezug macht, dass der Shottimer und das "Aus"-Logo hin und her flackern

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.