weighing scale requirement

Discussion in 'General Electronics Chat' started by damilarem, Aug 12, 2017.

  1. damilarem

    Thread Starter Member

    Aug 5, 2017
    38
    1
    I AM USING A LOAD CELL OF MAX. 3K THE VOLT IS mV2± 10%.. AND PIC 16F877A.. I WANT TO BE ABLE TO MEASURE IN KG AND OTHER UNITS AND IF POSSIBLE I WILL INTERFACE IT WITH KEYPAD....
    I NEED HELP ON THIS THANKS ALL FOR YOUR QUICK AND SPEEDY RESPONSE
     
  2. dendad

    Active Member

    Feb 20, 2016
    626
    148
    Is this just a repeat of your other threads?
     
  3. damilarem

    Thread Starter Member

    Aug 5, 2017
    38
    1
    sir this is not a repeat it is a new thread sir... thanks for your response
     
  4. jayanthd

    Active Member

    Jul 4, 2015
    652
    60
    3 Kgs max is the weight your load cell measures. I got it.

    I didn't got the mV thing.

    Mention how much mV it gives per Kg that is what is the mV/Kg of the load cell.

    What kind of load cell it is that is half bridge or full bridge load cell ? Does the load cell has 3 wires or 4 wires ?

    What kind of keypad do you want to use ? 4x4 keypad ?

    Do you have a circuit or should I make the circuit ?

    Can you use HX711 module for the weighing scale ? HX711 is made specifically for load cell measurement.


    Use PIC18F46K22. I will give you a good code. PIC16F877A has very less RAM and I don't prefer to write code for 16F devices.

    Do you want password protection feature for weighing scale ? That is

    User has to enter 3 digit password and if the password is correct it allows the user to change the password or do calibration of the weighing scale.

    For doing calibration you have to press C button and then it enters calibration mode. Here if weighing scale is showing 0.125 Kgs then you can press # button to set it as 0 Kg and then you have to place a know weight of say 1 kg and then it shows some raw value like 834567 and you have to press # key and then enter value 1 and then press * key. This will calculate the scaling factor and converts 834567 into 1 kg and stores the scaling factor and zero factor in eeprom and then it comes out of the calibration mode.

    Now if you place any weight then it shows the exact weight on the LCD display.
     
    Last edited: Aug 14, 2017
  5. damilarem

    Thread Starter Member

    Aug 5, 2017
    38
    1
    i just look through the data sheet the rated output is 1.0±0.15mV/V

    it is a full bridge it has four wires
    keypad is 4x3...
    make me a circuit so it will have a good output
    yes i want to use it . u can add other amp..
    and put the password
    if u can help me with both also good , but i want the one u can write best with i mean the PIC.18f and 16f
    thanks jay
     
  6. jayanthd

    Active Member

    Jul 4, 2015
    652
    60

    Ok. I will write code for PIC18F46K22. I will post the code in 1 or 2 days.
     
  7. damilarem

    Thread Starter Member

    Aug 5, 2017
    38
    1
  8. damilarem

    Thread Starter Member

    Aug 5, 2017
    38
    1


    alright thanks
     
  9. jayanthd

    Active Member

    Jul 4, 2015
    652
    60
    1.0±0.15mV/V per Kg ?

    3.0 +/- 0.45 mV for 3 Kgs ?


    1.0±0.15mV/V = 1mV +/- 0.15 mV per excitation voltage ?

    HX711 module provides 5V excitation voltage and so

    it is

    5mV +/- 0.75 mV/5V excitation voltage

    5mV +/- 0.75 mV/5V excitation voltage per kg or for 3Kgs ?
     
    Last edited: Aug 14, 2017
  10. damilarem

    Thread Starter Member

    Aug 5, 2017
    38
    1
    that is for the maximum te exictation is for the 3kg
     
  11. jayanthd

    Active Member

    Jul 4, 2015
    652
    60
    You mean 1.0 +/- 0.15 mV?15 V excitation voltage for 3 Kgs ?
     
  12. ericgibbs

    AAC Fanatic!

    Jan 29, 2010
    3,327
    597
    hi jay,
    Please note the HX711 module has an onboard transistor that reduces the 5v supply to the load cell excitation, on the units I am using I see only approx 3v to 4v.
    Eric
     
    • A03.gif
      A03.gif
      File size:
      29 KB
      Views:
      9
  13. damilarem

    Thread Starter Member

    Aug 5, 2017
    38
    1
    the h7x11 maximum volts for the load cell exictation is 5v.. the exictation is maximum for the the loadcell
    5v excitation for 3kg
     
  14. jayanthd

    Active Member

    Jul 4, 2015
    652
    60
    @ericgibbs

    Thank you for explaining.

    I recently did a weighing scale using HX711 but did not worry about the excitation voltage because it was simply provided by it. I just adjusted the weighing scale reading to 0 and then measured a know weight and found out the scaling factor and completed the project. I really did not measure the E+ and E- voltages. As HX711 was powered from 5V I assumed it provides 5V excitation voltage.

    @damilarem

    Buy a HX711 module and connect the load cell to it. Power HX711. No need to connect DAT and CLK pins. Now measure the voltage and E+ and E- pins and also across A+ and A- pins and post the data here. It will be easier for implementing the code. Use a known weigh of say 1 Kg to get the measurement. You can use any known weigh but use a good quality multimeter with a new battery installed into it.


    If you can't do that above then I have another solution.

    I will quickly write a code for HX711 based weighing scale and post the .hex file here. You burn it and then setup the mechanical setup for the load cell. Then without any weight the LCD will display a 6 or 8 digit value. You post that value here and I will subtract that value from the raw adc reading and you will get 0 for no weight. Then you put a known weight like 100 gms or 200 gms and then send the reading it shows on the LCD and then I will find out the scaling factor and send you the 3rd .hex file.

    Then burn it and you have the weighing scale ready. it will show all weight accurately.
     
    Last edited: Aug 14, 2017
  15. jayanthd

    Active Member

    Jul 4, 2015
    652
    60
    Here is the .hex file.

    Use these connections for LCD and HX711.

    Code (Text):
    1.  
    2. // LCD module connections
    3. sbit LCD_RS at RB4_bit;
    4. sbit LCD_EN at RB5_bit;
    5. sbit LCD_D4 at RB0_bit;
    6. sbit LCD_D5 at RB1_bit;
    7. sbit LCD_D6 at RB2_bit;
    8. sbit LCD_D7 at RB3_bit;
    9.  
    10. sbit LCD_RS_Direction at TRISB4_bit;
    11. sbit LCD_EN_Direction at TRISB5_bit;
    12. sbit LCD_D4_Direction at TRISB0_bit;
    13. sbit LCD_D5_Direction at TRISB1_bit;
    14. sbit LCD_D6_Direction at TRISB2_bit;
    15. sbit LCD_D7_Direction at TRISB3_bit;
    16. // End LCD module connections
    17.  
    18. //HX711 Connections
    19. sbit HX711_SCLK at RE0_bit;
    20. sbit HX711_DOUT at RE1_bit;
    21.  
    22. sbit HX711_SCLK_Direction at TRISE0_bit;
    23. sbit HX711_DOUT_Direction at TRISE1_bit;
    24.  
    This is the config word

    Code (Text):
    1.  
    2. 0x2F41
    3.  
    Now hook up the circuit and send me raw no weight value which it shows.

    4 MHz Crystal is used.

    The readings should be positive else reverse the white and green wires.
     
    damilarem likes this.
  16. damilarem

    Thread Starter Member

    Aug 5, 2017
    38
    1

    you can do this to make the work faster
     
  17. jayanthd

    Active Member

    Jul 4, 2015
    652
    60
    I have already posted the .hex file in my previous post. Give the raw reading it shows on line 2 of LCD for no weight.

    It will show slightly fluctuating values. A delay is added so that you can read the values clearly. provide the least value it shows.
     
    Last edited: Aug 14, 2017
  18. damilarem

    Thread Starter Member

    Aug 5, 2017
    38
    1
    working on it now thanks
     
  19. jayanthd

    Active Member

    Jul 4, 2015
    652
    60
    After project completion make a video of the hardware working and upload it to mediafire.com (you need to create a free account) and then post the link here.

    I need the video for reference.
     
  20. damilarem

    Thread Starter Member

    Aug 5, 2017
    38
    1
    okay..... i have pic 16f877a right now
     
Loading...