Categories

[AmpeRose] GUI Skeleton

Hello AmpeRose fans,

This post is a bit overdue… Well a lot overdue, I was supposed to write it last week :p

So, that week, in addition to working on the calibration schema, I created the class diagram for our graphic interface, which I ordered into three well wrapped levels:

  • Back-end
  • Data View
  • Graphic interface

BackEnd

The Back-end handles communications with AmpeRose, which includes

  • Reading Data sent by AmpeRose
  • Decoding data using a specific configuration (Translation)
  • Sending commands to AmpeRose
  • Performing special operations with the data (save to file, backup, send to database…)

N.B: Just yesterday, we decided that we might add another class that would handle error correction, using correction info sent forth by AmpeRose. (Benefits of being late :p)

 

DataView

The Data View does not handle the data per Se, but it handles how this data will be viewed.

For instance, it is here that we can choose to view the data as a simple continuous stream, or as lapses that obey to a certain trigger. It is also here that we can calculate the FFT of our data points, to allow the user to see the frequency spectrum of his device. The data container of the Data View will act as a moving window for the measurements, i.e. it will contain a fixed number of points (10^7 to 10^8), and as new data pours in, values will be replaced.

 

The graphic interface

This part of the pc software is what the user will see and use directly. It will view the data in a useful manner, and will allow for control over AmpeRose, as well as the other components of the software.

 

That’s all for tonight folks,

But stay tuned for the way more interesting post about the updates on our calibration circuit this week!

P.S: Some titles are links to images of the class diagrams.

[AmpeROSE] Initial Calibration

Good evening everyone!

In this long overdue post I will talk a little bit about one of the two main subjects I have worked on these past two weeks: The calibration method.

In a perfect world the whole initial calibration method would not be needed, but we live in the real world, so here goes…

 

We have gone to great lengths to get the components most suitable for our purposes. That said, the components of our measurement circuits are far from perfect: they present a number of errors we have to tend to.

 

These are the most important errors that must be corrected if we are to obtain meaningful results from AmpeROSE:

  1. Shunt errors:
    1. Precision error on Shunt resistor values
    2. Added resistance of the switch transistor with each Shunt resistor
    3. Leakage current of said transistors when blocking
    4. Input bias current of the buffers after the Shunt stage
  2. Amplification errors:
    1. Gain error of the operational amplifier in use
    2. Offset voltage of said amplifier

 

1.4. AKA the input bias current of the buffers is negligible. Note that we added the buffers to reduce this leak current, which was before that of the Op Amp.

 

Now for the calibration method. Our calibration will run as iterations of a 2-step process:

  1. Consider the Shunts perfect and calibrate the Amplification stage
  2. Consider the Amplification stage perfect and calibrate the Shunts

For step 1, we will apply a zero voltage difference on the input of the Op Amp, but we will get a non-zero output. this is a static error, the amplified input offset voltage of the Op Amp. We will measure this value, using our ADC, and save it. We will the apply very specific non-zero inputs to the amplification stage. From each output we get, we subtract the static error. in the end, we approximate the slope of the output line. (Of course we will take care not to saturate the Op Amp.) Now, also through software, we can correct values we get from the amplifier.

Now for step 2, we will use a current sink (discussed in a different post) to force a very specific, and well known current to pass through each Shunt branch. And… You guessed it… We will not measure the value we’re supposed to measure, due to the errors discussed above. Then we use these values to shift our measurement scales, in the software.

We will repeat these steps until we reach a fixed point. This calibration may also be performed when AmpeROSE heats up, because component characteristics change with heat. Also, non-linear errors are a nuisance we will have to endure.

So, to wrap this up, you might have noticed that we’re gonna need some extra components to be able to accomplish these calibrations. Thankfully those will not affect the measures themselves… We’re going to add a current sink to our circuit, as well as switches to cut it clean from the Supply of the DUT.

[AmpeRose] Protocol Definition

Good evening, everyone,
This is Michel from team AmpeRose, and this week, I had the task of defining the communication protocol between our device, AmpeRose, and the graphic interface meant to display the measurements.

We had already defined (last week) our main data structure as a 32-bit word. We had also announced that we will be using an Ethernet connection. So we have agreed on using a simple protocol defined as follows:

AmpeRose to PC:

AmpeRose will send 32-bit words to the software, using the Ethernet connection. The MSB (Most significant bit) of these words defines them as data words (0) or control words (1):

 

  • Data word: In the case of a data word, the bits [30:8] will be the measured value, bits [7:2] will be the context pins, and the bits [1:0] will define the caliber. This type of words will be way more common than control.

 

  • Control word: If the word is a control word, its value will indicate if it is an ACK, a NAK, or an error. ACK means AmpeRose has executed a command, NAK means that it has refused. There may be multiple NAK and error words, depending on the level of information we wish to have from this message.

 

PC -> AmpeRose:

The computer will send command words to AmpeRose, over the Ethernet connection. Each value of the 32-bit word will correspond to a specific command. There will be start and stop commands, frequency calibration commands (preset values), as well as commands to choose whether to read from the SD card or do live measures.

Note that some commands, such as switching from direct measures to SD card may only be sent while AmpeRose is in a stopped state, and will solicit a NAK response otherwise. The software may consider a command executed only after receiving an ACK response. Commands sent in a certain order will receive ACK responses in the same order.

Here is a small list of possible commands:

  • Start
  • Stop
  • SetFreq50
  • SetFreq100
  • ReadFromSD
  • Measure

This list is far from exhaustive, and is subject to change at any time. But it should give the reader an idea about how the computer will pilot AmpeRose.

 

Having accomplished my task for the week, I spent some time studying a few examples of measurement circuits, to catch up with my teammates who had the task of defining our own circuit, and try to assist them in this critical task. The results of this endeavor, however, are the subject of a different upcoming post!

[AmpeRose] Computer interface design and functionalities

Hello everyone!
Today, as we conclude our second week of working on the AmpeRose, we would like to show you a rough view of the interface of the computer software that will be communicating with AmpeRose.

I’ve had the pleasure of helping in designing this interface, along with Abdelhadi, and this is the end result:

Note that the main focus was on the ergonomics and how to include the functionalities, rather than choosing nice shapes on so on. These aesthetic details are easily changeable and need not be determined this early in the development of the project.

Our interface will show a continuously updated graph of the current, and will boast an auto-adjusting scale.It will also show the maximum value for the current in the window, as well as the activation and disactivation instants of the GPIO pins.

On the left side, you can notice a few statistics values, as well as buttons to control the viewing mode (Trigger or Normal mode, FFT mode), and to control AmpeRose itself(Frequency, Start, Stop, etc…).

Moreover, the user has the possibility of reading live data from the Ethernet connection with AmpeRose, or data stored on its SD card.

And finally, the user will be able to change the names of the GPIO pins, from the edit tab. These pins, connected from the DUT to AmpeRose, will provide the user with the ability to customize the pin names when performing tests.

This interface may still be changed of course (hopefully to include more functionalities). We sincerely hope you liked the interface, and welcome any suggestions!

AmpeRose: Plans for week 2

Hello world!

We are the AmpeRose Team, and we’re excited to tell you that today we embark on our noble quest of creating an affordable high precision Micro-Ammeter!

This week our work will be divided between two crucial tasks:

1-We are going to conduct an extensive research on current measurement techniques and state of the art tools to perform them. This task will be supervised by Ian.

2-Meanwhile, under Michel’s lead falls the task of specifying the architecture of our embedded system, as well as its interface with the IoT device.

In both of the aforementioned tasks, we will first focus on the functionalities, and once we have a clear image, we will choose specific components that fit our specifications.

We will be setting the overall specs and performance requirements for our project very soon, so feel free to comment with your notes, suggestions or remarks!

Keeping you posted,
M.H.