Giter Site home page Giter Site logo

msvsdcsc's Introduction

msvsdcsc

CRACK SENSING CIRCUIT

The Idea


Any crack in a structure changes the strain profile of the material underneath. In situations like a boiler or a jet engine this can be critical. This strain can be detected using a strain gauge i.e. a device which changes its electrical resistance which change in strain. So if such a variable resistor is placed in a voltage divider/wheatstone bridge we can get different voltage levels for different strains detected. This change in voltage can be sensed by a Mixed signal SoC as discussed in this design.

Screenshot from 2023-02-27 11-52-27

INDEX:

The Implementation Overview


This circuit is implemented using the following 5 stages:-

  1. The voltage divider (for the sake of this simulation, the voltage is directly taken)
  2. 3-bit Flash type ADC to convert that voltage level into digital output
  3. A 8x3 priority encoder to convert the ADC output to binary code
  4. A PIPO to send data from the encoder to lcd every clock cycle
  5. LCD interfacing circuit to display the data on a LCD

FLASH ADC and PRIORITY ENCODER

Also called the parallel A/D converter, this circuit is the simplest to understand. It is formed of a series of comparators, each one comparing the input signal to a unique reference voltage. The comparator outputs connect to the inputs of a priority encoder circuit, which then produces a binary output. The following figure shows a 3-bit flash ADC circuit:

flashadc

Vref is a stable reference voltage provided by a precision voltage regulator as part of the converter circuit, not shown in the schematic. As the analog input voltage exceeds the reference voltage at each comparator, the comparator outputs will sequentially saturate to a high state. The priority encoder generates a binary number based on the highest-order active input, ignoring all other active inputs.

The calculation for eg. an input of 0.8 V with Vref = 1.1 V:

The input lies in the range (these voltages can be found by voltage divider calculations) 5/8 * Vref and 6/8 * Vref which would make the output of the 5th comparator high which would give the corresponding input to priority encoder which would give the output 101 (5).

FLASH ADC Circuit and its parts

avsdcmp IP in cadence (Schematic)

comparator circuit compares two voltages and outputs either a 1 (the voltage at the plus side) or a 0 (the voltage at the negative side) to indicate which is larger. Comparators are often used, for example, to check whether an input has reached some predetermined value.

vsdcamp

FLASH ADC Circuit

Flash analog to digital converter is the fastest type of ADC among all the other ADCs. It is also known as a parallel analog to digital converter. It comprises high-speed comparators, resistive voltage divider circuits along with a priority encoder.

An N-bit flash ADC consists of 2 powered N-1 comparators and contains 2 powered N number of matched resistors.

flash ADC

flash ADC1

Output Graphs

Screenshot from 2023-02-20 14-36-41

For comparator

Screenshot from 2023-02-17 02-51-50

PIPO (parallel in parallel out)

Parallel In Parallel Out (PIPO) shift registers are the type of storage devices in which both data loading as well as data retrieval processes occur in parallel mode. A shift register is one type of sequential logic circuit where its output mainly depends on its input & previous output. This register includes a set of Flip Flops where these are connected within cascade which means, one FF output is simply connected to the input of another FF. This register is used to store as well as shift the group of binary data. The number of FFs available within the shift register mainly depends on the no. of binary bits stored within the register. Here we are implementing a 3 bit PIPO.

pipo The LCD interfacing circuit is a circuit designed in verilog to transfer the input on its terminal to a LCD (16x2 as shown in the figure) on every register select operation.

D flipflop Schematic

Screenshot from 2023-02-16 14-11-13

PIPO Schematic

Screenshot from 2023-02-16 14-09-33

Output for 1 D Flip FLop

A D (or Delay) Flip Flop (Figure 1) is a digital electronic circuit used to delay the change of state of its output signal (Q) until the next rising edge of a clock timing input signal occurs. Since the output remains constant unless deliberately changed by altering the state of the D input followed by a rising clock signal.

Screenshot from 2023-02-16 12-01-59

Priority Encoder

A priority encoder is a circuit or algorithm that compresses multiple binary inputs into a smaller number of outputs. The output of a priority encoder is the binary representation of the index of the most significant activated line, starting from zero. They are often used to control interrupt requests by acting on the highest priority interrupt input.

priority Encoder

logic

Q0 output bit Schematic for 8:3 Priority Encoder

Screenshot from 2023-02-22 14-37-02

Complete Circuit Schematic for priority Encoder

Screenshot from 2023-02-22 15-21-34

Output(for input I5,I4,I3,I2,I1 = 1 )

Screenshot from 2023-02-22 15-21-11

Priority Encoder simulation using verilog code and testbench

priority encoder output

Verilog codes for designing digital blocks

1)Priority Encoder

module krunal_priority(i,d);
  // declare
input [7:0] i;
  // store and declare output values
  output [2:0] d;
  reg [2:0] y;
  always @(i)
  begin
   
        // priority encoder
        // if condition to chose 
        // output based on priority. 
        if(i[7]==1) y=3'b111;
        else if(i[6]==1) y=3'b110;
        else if(i[5]==1) y=3'b101;
        else if(i[4]==1) y=3'b100;
        else if(i[3]==1) y=3'b011;
        else if(i[2]==1) y=3'b010;
        else if(i[1]==1) y=3'b001;
        else
        y=3'b000;
     
   
  end
assign d = y;
endmodule
  1. PIPO register
module krunal_pipo(clk,a,q);
input clk;
input[2:0]a;
output[2:0]q;
reg[2:0]q;
always@(posedge clk)
begin
q<=a;
end
endmodule
  1. LCD interfacing circuit
module lcd_2(
    clk,
  din,din1,din2,
  output reg rs, rw,
  output reg dout
    );

input reg clk;
input din;
input din1;
input din2; 

integer  i = 0;
 
reg [2:0] data = 0 ;



always@(posedge clk)
begin
data[0]  <= din; 
data[1] <= din1; 
data[2] <= din2; 
   
   if(i <= 2)
   begin
    rs   <= 1'b1;
    rw   <= 1'b0; 
    dout <= data[i];
    i <= i + 1; 
   end
 	else
   begin
   i <= 0;
   rs    <= 1'b0;
   rw    <= 1'b0;
   dout  <= 1'b0;
   end
	
end
 

endmodule

Complete crack sensing Circuit and Simulation results

Black Box for CSC (7-I/O pins except Vdd & gnd)

Screenshot from 2023-02-27 11-52-27

Integrated CSC Schematic

This circuit consists of FLASH ADC, made through comparators and resistors, including a 8:3 priority encoder and a PIPO circuit(made using 3 D flip-flops).

Screenshot from 2023-02-27 11-30-39

Output Graphs (Giving the desired 101 output)

Screenshot from 2023-03-01 04-55-19

Graph of all I/O pins

Screenshot from 2023-03-01 04-50-15

Layout of the CSC Circuit

LAYOUT_W3 (1)

LAYOUT_W2_zoomed2

LAYOUT_W2_zoomed1

Area of Layout

This area is in µm^2.

layout area

Future Work

  • Post Layout Simulations needs to be performed.
  • Output Waveforms of Post Layout Simulation with Post Schematic Waveforms needs to be match.

Acknowledgments

  • Kunal Ghosh, Director, VSD Corp. Pvt. Ltd.
  • Madhav Rao, Associate Professor, IIIT Bangalore
  • Kavya Agarwal, Mtech ECE student, International Institute of Information Technology, Bangalore
# Contact Information

- Ritesh Lalwani, Mtech ECE student, International Institute of Information Technology, Bangalore  [email protected]
- Kunal Ghosh, Director, VSD Corp. Pvt. Ltd. [email protected]

References

msvsdcsc's People

Contributors

riteshlalwani avatar

Watchers

 avatar

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.