Skip to content
  • MySensors
  • OpenHardware.io
  • Categories
  • Recent
  • Tags
  • Popular
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Brand Logo
  1. Home
  2. Hardware
  3. Ceech board upgrade

Ceech board upgrade

Scheduled Pinned Locked Moved Hardware
4 Posts 2 Posters 1.8k Views 3 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • C Offline
    C Offline
    ceech
    Hardware Contributor
    wrote on last edited by
    #1

    The board will receive a new design with TP4056 battery charger.
    0_1468676002946_IoT_Pro_01_V3.png
    Charge current and battery voltage will be reported on ADC6 and ADC7.
    Mosfet will be available for external load regulation. It is connected to D3.
    There are three sockets for:
    bluetooth
    NRF24l01+ and
    I2C modules.

    1 Reply Last reply
    5
    • ? Offline
      ? Offline
      A Former User
      wrote on last edited by
      #2

      Are we able to use the Rfm69 module with nrf24l01 adapter? Is the IRQ PIN connected to D2?

      C 1 Reply Last reply
      0
      • ? A Former User

        Are we able to use the Rfm69 module with nrf24l01 adapter? Is the IRQ PIN connected to D2?

        C Offline
        C Offline
        ceech
        Hardware Contributor
        wrote on last edited by
        #3

        @kenci It can be used with Rfm69. And yes, IRQ pin is connected to D2.

        1 Reply Last reply
        0
        • C Offline
          C Offline
          ceech
          Hardware Contributor
          wrote on last edited by ceech
          #4

          New boards are ready and are being tested. Here is one connected to a Bluetooth module charging a battery:

          0_1469517433501_IMG_0051_mala.jpg

          This is the code used in battery voltage and charge current monitoring:

          float readVcc() 
          {
            signed long resultVcc;
            float resultVccFloat;
            // Read 1.1V reference against AVcc
            ADMUX = _BV(REFS0) | _BV(MUX3) | _BV(MUX2) | _BV(MUX1);
            delay(10);                           // Wait for Vref to settle
            ADCSRA |= _BV(ADSC);                 // Convert
            while (bit_is_set(ADCSRA,ADSC));
            resultVcc = ADCL;
            resultVcc |= ADCH<<8;
            resultVcc = 1126400L / resultVcc;    // Back-calculate AVcc in mV
            resultVccFloat = (float) resultVcc / 1000.0; // Convert to Float
          
            return resultVccFloat;
          }
          
          const int current = A6;
          const int lipo = A7;
          
          
          float vout = 0.0;
          float vin = 0.0;
          int value = 0;
          
          void setup() 
          {
            Serial.begin(9600);
          }
          
          void loop() 
          {
            float napetost = readVcc();
          
            float tok = ((analogRead(current) * napetost / 1024 ) * 1200) / 3; // convert the ADC value of charge current to miliamps
            float baterija = ( analogRead(lipo) * napetost / 1024 ) * 2; // measuring battery voltage
            
            Serial.print("Vcc = ");
            Serial.print(napetost);
            Serial.println("V");
            delay(400);
            Serial.print("Charge current = ");
            Serial.print(tok);
            Serial.println("mA");
            delay(400);
            Serial.print("Battery voltage = ");
            Serial.print(baterija);
            Serial.println("V");
            delay(400);
            Serial.println("----------------------------");
            delay(2000);
          }
          /*
          Improving accuracy:
          To do so, simply measure your Vcc with a voltmeter and with our readVcc() function. Then, replace the constant 1107035L with a new constant:
          scale_constant = internal1.1Ref * 1024 * 1000
          where
          internal1.1Ref = 1,1 * Vcc1 (per voltmeter) / Vcc2 (per readVcc() function)
          Example:
          For instance, I measure 3,43V from my FTDI, the calculated value of Vref is 1,081V.
          So (1,081 x 1000 x 1024) = 1107034,95 or 1107035L rounded up.
          
          Use smoothing example from IDE to smooth the data from ADC.
          */
          

          Charge current is limited to 400mA and can be easily changed to another value by changing just one resistor.

          1 Reply Last reply
          2
          Reply
          • Reply as topic
          Log in to reply
          • Oldest to Newest
          • Newest to Oldest
          • Most Votes


          19

          Online

          11.7k

          Users

          11.2k

          Topics

          113.1k

          Posts


          Copyright 2025 TBD   |   Forum Guidelines   |   Privacy Policy   |   Terms of Service
          • Login

          • Don't have an account? Register

          • Login or register to search.
          • First post
            Last post
          0
          • MySensors
          • OpenHardware.io
          • Categories
          • Recent
          • Tags
          • Popular