Discussions on Python software that powers the ChipWhisperer system
#2086 by br1234
Mon Aug 27, 2018 9:46 am
I am using a CW1173_ChipWhisperer-Lite and trying to trigger a glitch based on the Target IO4 pin's falling edge. I see no glitches in the ClockXOR or ClockOR outputs.

I did the operations/settings below

1.Switch the ADC Clock Source as being CLKGEN x4.
2. Press Reset ADC DCM, confirm the frequency is 29.5 MHz as expected.
3. Switch the Trigger Setup --> Mode to be Falling Edge
4. Switch the Trigger Setup --> Total Samples to be 1000

I tried experimenting with different gain settings (both low and high) and it didn't make any difference. I don't fully understand how to change this based on different targets. I would appreciate any inputs on this. I have verified that the input on Target IO4 line works as expected with an oscilloscope

Other info:
I am able to setup and verify that manual clock glitching works
The Enable only signal from Glitch module is just noise.
My target is a development board SPC564A-disp
#2102 by Alex_Dewar
Wed Sep 05, 2018 1:09 pm
Hi br1234,

Just to confirm, you're at the Automatically Triggering Glitch section of Tutorial A2, right? The part you're referring to is basically just making sure you can capture power traces. The list a little afterwards, where you change the Glitch Trigger to "Ext Trigger:Single Shot" is what actually changes glitching to being trigger based.
#2118 by br1234
Tue Sep 11, 2018 2:33 pm
Thank you for your response. Yes you are right I don't need to change those settings for triggering a glitch. I went back and changed just the Glitch Trigget to Ext Trigger:Single and Ext Trigger:Continous and I still dont see any glitches in the output. My Trigger to CW is connected to pin 16 FPGA-TARG4. The trigger is active low reset signal from the target device I intend to hack.

Below are the rest of my settings
[Scope Settings]
[[ChipWhisperer/OpenADC]]
Connection = NewAE USB (CWLite/CW1200)
Auto-Refresh DCM Status = True
[[[NewAE USB (CWLite/CW1200)]]]
[[[[ChipWisperer-Lite USB]]]]
[[ChipWhisperer/OpenADC]]
[[[Serial Port (LX9)]]]
Selected Port =
[[ChipWhisperer/OpenADC]]
[[[OpenADC]]]
[[[[HW Information]]]]
[[[OpenADC]]]
[[[[Gain Setting]]]]
Mode = low
Setting = 0
[[[OpenADC]]]
[[[[Trigger Setup]]]]
Mode = low
Timeout (secs) = 2
Offset = 0
Pre-Trigger Samples = 0
Total Samples = 24400
Downsample Factor = 1
[[[OpenADC]]]
[[[[Clock Setup]]]]
[[[[[ADC Clock]]]]]
Source = CLKGEN x1 via DCM
Phase Adjust = 0
[[[[Clock Setup]]]]
Freq Counter Src = EXTCLK Input
[[[[[CLKGEN Settings]]]]]
Input Source = system
Input Frequency = 10000000.0
Multiply = 2
Divide = 16
Desired Frequency = 12000000
[[ChipWhisperer/OpenADC]]
[[[CW Extra]]]
[[[[CW Extra Settings]]]]
[[[[[Trigger Pins]]]]]
Target IO1 (Serial TXD) = False
Target IO2 (Serial RXD) = False
Target IO3 (SmartCard Serial) = False
Target IO4 (Trigger Line) = True
Collection Mode = OR
[[[[CW Extra Settings]]]]
Trigger Module = Basic (Edge/Level)
Clock Source = Target IO-IN
Target HS IO-Out = Glitch Module
HS-Glitch Out Enable (High Power) = False
HS-Glitch Out Enable (Low Power) = False
[[[[[Target IOn Pins]]]]]
Target IO1 = Serial TXD
Target IO2 = Serial RXD
Target IO3 = High-Z
Target IO4 = High-Z
[[[[CW Extra Settings]]]]
[[[[[Target IOn GPIO Mode]]]]]
Target IO1: GPIO = Disabled
Target IO2: GPIO = Disabled
Target IO3: GPIO = Disabled
Target IO4: GPIO = Disabled
nRST: GPIO = Default
PDID: GPIO = Default
PDIC: GPIO = Default
[[[[CW Extra Settings]]]]
Target Power State = True
[[[CW Extra]]]
[[[[Glitch Module]]]]
Clock Source = CLKGEN
Glitch Width (as % of period) = 39.84375
Glitch Width (fine adjust) = 0
Glitch Offset (as % of period) = 10.15625
Glitch Offset (fine adjust) = 0
Glitch Trigger = Ext Trigger:Continous
Single-Shot Arm = After Scope Arm
Ext Trigger Offset = 0
Repeat = 50
Output Mode = Clock XORd
#2119 by Alex_Dewar
Tue Sep 11, 2018 3:59 pm
I don't see anything wrong with your settings at first glance. Are you arming the ChipWhisperer by capturing a trace (the green triangle in the top left part of CW Capture)? That needs to be done before the glitch module is active. That will also tell you if the ChipWhisperer is picking up the trigger event, since you'll get a trace.

Alex
#2121 by br1234
Wed Sep 12, 2018 10:57 am
I clicked on the green triangle to capture a trace as you suggested. I see a power trace view window but I actually want to view the voltage at the Target IO4 pin. How do I connect the trigger connected to pin 16 of CW Lite board to OpenADC channel 1 on CW?
I have set the target module as 'Simple Serial' under 'Generic Settings'. Do I need CW305 (Artix-7 board) in order to see if the Chipwhisperer is picking up the trace?
Note: I do have a PicoScope 3000 Series hooked up and I can see that the trigger to the CW on pin16 works.
#2122 by Alex_Dewar
Wed Sep 12, 2018 12:03 pm
That the ChipWhisperer captured the trace (unless you got a timeout) tells you that it's triggering correctly. Did you see a glitch when you hit the capture button?

If you want to see in real time whether the trigger is being picked up, you can check "Trigger Active Count". If it's steadily climbing, the ChipWhisper is being triggered. You also probably don't want to hook the OpenADC up to your trigger pin, as it's looking for small changes in voltage happening over small periods of time.

Alex
#2125 by br1234
Wed Sep 12, 2018 3:37 pm
I didn't see a glitch when I hit the capture button. I see that the Trigger Active Count increases even when there isn't a signal connected to pin16. I'm not sure what I am missing here.
This is my physical setup:
CW has GND from the target board connected to Pin2, the output from the glitch module (Clock XORd) is connected to the XTAL of the target device and Pin 16 is connected to the active low reset signal from the target board.
I am using a Glitch Width and Glitch offset of 10.2% each.

I am talking to the Chipwhisperer using the VMware release "Chipwhisperer 4.0.1 Lubuntu 64-bit".
#2127 by Alex_Dewar
Thu Sep 13, 2018 10:51 am
What does your actual clock setup look like? If you're using an external clock, the ChipWhisperer needs to be between the clock source and the target by taking the clock source as an input on HS1. It then needs to output to the device's clock input. If you're using the ChipWhisperer's clock to drive the device, you'll need to switch your clock source back to being "System".

Additionally, you can also try hitting the "Reset DCM" button in the glitch module.

Alex

Who is online

Users browsing this forum: No registered users and 2 guests