{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": 453,
   "id": "dbf9a4d2-5193-472c-9ffe-b69a837ac783",
   "metadata": {},
   "outputs": [],
   "source": [
    "scope.dis()\n",
    "target.dis()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 1,
   "id": "eee0ea42-9f95-4a95-80f2-18b5f2f54037",
   "metadata": {},
   "outputs": [],
   "source": [
    "PLATFORM = 'CWLITEARM'\n",
    "CRYPTO_TARGET = 'NONE'\n",
    "SS_VER = 'SS_VER_1_1'"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 300,
   "id": "7168327b-ed9c-4f9c-8e17-443368f37f61",
   "metadata": {
    "scrolled": true
   },
   "outputs": [
    {
     "ename": "KeyboardInterrupt",
     "evalue": "",
     "output_type": "error",
     "traceback": [
      "\u001b[0;31m---------------------------------------------------------------------------\u001b[0m",
      "\u001b[0;31mKeyboardInterrupt\u001b[0m                         Traceback (most recent call last)",
      "Cell \u001b[0;32mIn[300], line 15\u001b[0m\n\u001b[1;32m     13\u001b[0m target\u001b[38;5;241m.\u001b[39msimpleserial_write(CMD_TEST_3,textin_array[i])\n\u001b[1;32m     14\u001b[0m scope\u001b[38;5;241m.\u001b[39mcapture()\n\u001b[0;32m---> 15\u001b[0m res \u001b[38;5;241m=\u001b[39m \u001b[43mtarget\u001b[49m\u001b[38;5;241;43m.\u001b[39;49m\u001b[43msimpleserial_read\u001b[49m\u001b[43m(\u001b[49m\u001b[38;5;124;43m'\u001b[39;49m\u001b[38;5;124;43mr\u001b[39;49m\u001b[38;5;124;43m'\u001b[39;49m\u001b[43m,\u001b[49m\u001b[43m \u001b[49m\u001b[38;5;241;43m190\u001b[39;49m\u001b[43m,\u001b[49m\u001b[43mtimeout\u001b[49m\u001b[38;5;241;43m=\u001b[39;49m\u001b[38;5;241;43m0\u001b[39;49m\u001b[43m)\u001b[49m\n\u001b[1;32m     16\u001b[0m \u001b[38;5;28mprint\u001b[39m(res)\n",
      "File \u001b[0;32m~/chipwhisperer/software/chipwhisperer/capture/targets/SimpleSerial.py:441\u001b[0m, in \u001b[0;36mSimpleSerial.simpleserial_read\u001b[0;34m(self, cmd, pay_len, end, timeout, ack)\u001b[0m\n\u001b[1;32m    439\u001b[0m ascii_len \u001b[38;5;241m=\u001b[39m pay_len \u001b[38;5;241m*\u001b[39m \u001b[38;5;241m2\u001b[39m\n\u001b[1;32m    440\u001b[0m recv_len \u001b[38;5;241m=\u001b[39m cmd_len \u001b[38;5;241m+\u001b[39m ascii_len \u001b[38;5;241m+\u001b[39m \u001b[38;5;28mlen\u001b[39m(end)\n\u001b[0;32m--> 441\u001b[0m response \u001b[38;5;241m=\u001b[39m \u001b[38;5;28;43mself\u001b[39;49m\u001b[38;5;241;43m.\u001b[39;49m\u001b[43mread\u001b[49m\u001b[43m(\u001b[49m\u001b[43mrecv_len\u001b[49m\u001b[43m,\u001b[49m\u001b[43m \u001b[49m\u001b[43mtimeout\u001b[49m\u001b[38;5;241;43m=\u001b[39;49m\u001b[43mtimeout\u001b[49m\u001b[43m)\u001b[49m\n\u001b[1;32m    442\u001b[0m \u001b[38;5;28mself\u001b[39m\u001b[38;5;241m.\u001b[39m_simpleserial_last_read \u001b[38;5;241m=\u001b[39m response\n\u001b[1;32m    444\u001b[0m payload \u001b[38;5;241m=\u001b[39m \u001b[38;5;28mbytearray\u001b[39m(pay_len)\n",
      "File \u001b[0;32m~/chipwhisperer/software/chipwhisperer/capture/targets/SimpleSerial.py:323\u001b[0m, in \u001b[0;36mSimpleSerial.read\u001b[0;34m(self, num_char, timeout)\u001b[0m\n\u001b[1;32m    321\u001b[0m     \u001b[38;5;28;01mif\u001b[39;00m num_char \u001b[38;5;241m==\u001b[39m \u001b[38;5;241m0\u001b[39m:\n\u001b[1;32m    322\u001b[0m         num_char \u001b[38;5;241m=\u001b[39m \u001b[38;5;28mself\u001b[39m\u001b[38;5;241m.\u001b[39mser\u001b[38;5;241m.\u001b[39minWaiting()\n\u001b[0;32m--> 323\u001b[0m     \u001b[38;5;28;01mreturn\u001b[39;00m \u001b[38;5;28;43mself\u001b[39;49m\u001b[38;5;241;43m.\u001b[39;49m\u001b[43mser\u001b[49m\u001b[38;5;241;43m.\u001b[39;49m\u001b[43mread\u001b[49m\u001b[43m(\u001b[49m\u001b[43mnum_char\u001b[49m\u001b[43m,\u001b[49m\u001b[43m \u001b[49m\u001b[43mtimeout\u001b[49m\u001b[43m)\u001b[49m\n\u001b[1;32m    324\u001b[0m \u001b[38;5;28;01mexcept\u001b[39;00m \u001b[38;5;167;01mException\u001b[39;00m \u001b[38;5;28;01mas\u001b[39;00m e:\n\u001b[1;32m    325\u001b[0m     \u001b[38;5;28mself\u001b[39m\u001b[38;5;241m.\u001b[39mdis()\n",
      "File \u001b[0;32m~/chipwhisperer/software/chipwhisperer/capture/targets/simpleserial_readers/_base.py:146\u001b[0m, in \u001b[0;36mSimpleSerialTemplate.read\u001b[0;34m(self, num, timeout)\u001b[0m\n\u001b[1;32m    143\u001b[0m     \u001b[38;5;28;01mreturn\u001b[39;00m ret\u001b[38;5;241m.\u001b[39mdecode(\u001b[38;5;124m'\u001b[39m\u001b[38;5;124mlatin-1\u001b[39m\u001b[38;5;124m'\u001b[39m)\n\u001b[1;32m    145\u001b[0m \u001b[38;5;66;03m# If we didn't get enough data, try to read more from the hardware\u001b[39;00m\n\u001b[0;32m--> 146\u001b[0m data \u001b[38;5;241m=\u001b[39m \u001b[38;5;28mbytearray\u001b[39m(\u001b[38;5;28;43mself\u001b[39;49m\u001b[38;5;241;43m.\u001b[39;49m\u001b[43mhardware_read\u001b[49m\u001b[43m(\u001b[49m\u001b[43mnum\u001b[49m\u001b[43m,\u001b[49m\u001b[43m \u001b[49m\u001b[43mtimeout\u001b[49m\u001b[38;5;241;43m=\u001b[39;49m\u001b[43mtimeout\u001b[49m\u001b[43m)\u001b[49m)\u001b[38;5;241m.\u001b[39mdecode(\u001b[38;5;124m'\u001b[39m\u001b[38;5;124mlatin-1\u001b[39m\u001b[38;5;124m'\u001b[39m)\n\u001b[1;32m    147\u001b[0m \u001b[38;5;28;01mfor\u001b[39;00m c \u001b[38;5;129;01min\u001b[39;00m data:\n\u001b[1;32m    148\u001b[0m     \u001b[38;5;28mself\u001b[39m\u001b[38;5;241m.\u001b[39mterminal_queue\u001b[38;5;241m.\u001b[39mappend([\u001b[38;5;124m'\u001b[39m\u001b[38;5;124min\u001b[39m\u001b[38;5;124m'\u001b[39m, c])\n",
      "File \u001b[0;32m~/chipwhisperer/software/chipwhisperer/capture/targets/simpleserial_readers/cwlite.py:109\u001b[0m, in \u001b[0;36mSimpleSerial_ChipWhispererLite.hardware_read\u001b[0;34m(self, num, timeout)\u001b[0m\n\u001b[1;32m    108\u001b[0m \u001b[38;5;28;01mdef\u001b[39;00m\u001b[38;5;250m \u001b[39m\u001b[38;5;21mhardware_read\u001b[39m(\u001b[38;5;28mself\u001b[39m, num, timeout\u001b[38;5;241m=\u001b[39m\u001b[38;5;241m250\u001b[39m):\n\u001b[0;32m--> 109\u001b[0m     \u001b[38;5;28;01mreturn\u001b[39;00m \u001b[38;5;28;43mself\u001b[39;49m\u001b[38;5;241;43m.\u001b[39;49m\u001b[43mcwlite_usart\u001b[49m\u001b[38;5;241;43m.\u001b[39;49m\u001b[43mread\u001b[49m\u001b[43m(\u001b[49m\u001b[43mnum\u001b[49m\u001b[43m,\u001b[49m\u001b[43m \u001b[49m\u001b[43mtimeout\u001b[49m\u001b[43m)\u001b[49m\n",
      "File \u001b[0;32m~/chipwhisperer/software/chipwhisperer/hardware/naeusb/serial.py:243\u001b[0m, in \u001b[0;36mUSART.read\u001b[0;34m(self, dlen, timeout)\u001b[0m\n\u001b[1;32m    241\u001b[0m     \u001b[38;5;66;03m# time.sleep(0.001)\u001b[39;00m\n\u001b[1;32m    242\u001b[0m     \u001b[38;5;28;01mif\u001b[39;00m (timeout \u001b[38;5;241m%\u001b[39m \u001b[38;5;241m10\u001b[39m) \u001b[38;5;241m==\u001b[39m \u001b[38;5;241m0\u001b[39m:\n\u001b[0;32m--> 243\u001b[0m         \u001b[43mtime\u001b[49m\u001b[38;5;241;43m.\u001b[39;49m\u001b[43msleep\u001b[49m\u001b[43m(\u001b[49m\u001b[38;5;241;43m0.01\u001b[39;49m\u001b[43m)\u001b[49m\n\u001b[1;32m    245\u001b[0m     waiting \u001b[38;5;241m=\u001b[39m \u001b[38;5;28mself\u001b[39m\u001b[38;5;241m.\u001b[39minWaiting()\n\u001b[1;32m    247\u001b[0m \u001b[38;5;66;03m# print(\"read: \" + str(resp))\u001b[39;00m\n",
      "\u001b[0;31mKeyboardInterrupt\u001b[0m: "
     ]
    }
   ],
   "source": [
    "from tqdm import tqdm\n",
    "\n",
    "CMD_TEST_3 = 'b'\n",
    "scope.adc.samples = 24400\n",
    "scope.adc.decimate = 15\n",
    "scope.clock.adc_src = 'clkgen_x1'\n",
    "scope.gain.db = 30\n",
    "#scope.adc.offset = 1000\n",
    "#scope.adc.timeout = 50\n",
    "for i in range(15):\n",
    "    target.flush()\n",
    "    scope.arm()\n",
    "    target.simpleserial_write(CMD_TEST_3,textin_array[i])\n",
    "    scope.capture()\n",
    "    res = target.simpleserial_read('r', 190,timeout=0)\n",
    "    print(res)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "id": "a0ab60db-0aee-4712-852a-901f8e3eb54b",
   "metadata": {},
   "outputs": [],
   "source": [
    "from tqdm import tqdm\n",
    "\n",
    "CMD_TEST_3 = 'a'\n",
    "scope.adc.samples = 24400\n",
    "scope.adc.decimate = 15\n",
    "scope.clock.adc_src = 'clkgen_x1'\n",
    "scope.gain.db = 30\n",
    "#scope.adc.offset = 1000\n",
    "#scope.adc.timeout = 50\n",
    "for i in range(15):\n",
    "    target.flush()\n",
    "    scope.arm()\n",
    "    target.simpleserial_write(CMD_TEST_3,textin_array[i])\n",
    "    scope.capture()\n",
    "    res = target.simpleserial_read('r', 190,timeout=0)\n",
    "    print(res)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 269,
   "id": "0b46e097-c35d-44eb-9803-42ca763a499f",
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "INFO: Found ChipWhisperer😍\n",
      "scope.gain.mode                          changed from low                       to high                     \n",
      "scope.gain.gain                          changed from 0                         to 30                       \n",
      "scope.gain.db                            changed from 5.5                       to 24.8359375               \n",
      "scope.adc.basic_mode                     changed from low                       to rising_edge              \n",
      "scope.adc.samples                        changed from 24400                     to 5000                     \n",
      "scope.adc.trig_count                     changed from 6066950                   to 27944586                 \n",
      "scope.clock.adc_src                      changed from clkgen_x1                 to clkgen_x4                \n",
      "scope.clock.adc_freq                     changed from 0                         to 29538459                 \n",
      "scope.clock.adc_rate                     changed from 0.0                       to 29538459.0               \n",
      "scope.clock.clkgen_div                   changed from 1                         to 26                       \n",
      "scope.clock.clkgen_freq                  changed from 192000000.0               to 7384615.384615385        \n",
      "scope.io.tio1                            changed from serial_tx                 to serial_rx                \n",
      "scope.io.tio2                            changed from serial_rx                 to serial_tx                \n",
      "scope.io.hs2                             changed from None                      to clkgen                   \n",
      "scope.io.cdc_settings                    changed from bytearray(b'\\x01\\x00\\x00\\x00') to bytearray(b'\\x00\\x00\\x00\\x00')\n"
     ]
    }
   ],
   "source": [
    "import time\n",
    "import chipwhisperer as cw\n",
    "\n",
    "scope = cw.scope()\n",
    "\n",
    "target_type = cw.targets.SimpleSerial\n",
    "try:\n",
    "    target = cw.target(scope, target_type)\n",
    "except:\n",
    "    print(\"INFO: Caught exception on reconnecting to target - attempting to reconnect to scope first.\")\n",
    "    print(\"INFO: This is a work-around when USB has died without Python knowing. Ignore errors above this line.\")\n",
    "    scope = cw.scope()\n",
    "    target = cw.target(scope, target_type)\n",
    "\n",
    "print(\"INFO: Found ChipWhisperer😍\")\n",
    "\n",
    "prog = cw.programmers.STM32FProgrammer\n",
    "\n",
    "time.sleep(0.05)\n",
    "scope.default_setup()\n",
    "def reset_target(scope):\n",
    "    scope.io.nrst = 'low'\n",
    "    time.sleep(0.05)\n",
    "    scope.io.nrst = 'high_z'\n",
    "    time.sleep(0.05)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 270,
   "id": "1d3309bc-0e7c-415b-bd77-200c1ee81897",
   "metadata": {
    "scrolled": true
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Building for platform CWLITEARM with CRYPTO_TARGET=NONE\n",
      "SS_VER set to SS_VER_1_1\n",
      "SS_VER set to SS_VER_1_1\n",
      "mkdir -p .dep\n",
      ".\n",
      "Welcome to another exciting ChipWhisperer target build!!\n",
      "arm-none-eabi-gcc (Arch Repository) 14.2.0\n",
      "Copyright (C) 2024 Free Software Foundation, Inc.\n",
      "This is free software; see the source for copying conditions.  There is NO\n",
      "warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.\n",
      "\n",
      "mkdir -p objdir-CWLITEARM \n",
      ".\n",
      "Compiling C: main.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/main.lst -MMD -MP -MF .dep/main.o.d main.c -o objdir-CWLITEARM/main.o\n"
     ]
    },
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "main.c: In function 'scarsa_test_grp2':\n",
      "main.c:1422:13: warning: variable 'ret' set but not used [-Wunused-but-set-variable]\n",
      " 1422 |         int ret = -1;\n",
      "      |             ^~~\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      ".\n",
      "Compiling C: src/int/i31_add.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/i31_add.lst -MMD -MP -MF .dep/i31_add.o.d src/int/i31_add.c -o objdir-CWLITEARM/src/int/i31_add.o\n",
      ".\n",
      "Compiling C: src/int/i31_bitlen.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/i31_bitlen.lst -MMD -MP -MF .dep/i31_bitlen.o.d src/int/i31_bitlen.c -o objdir-CWLITEARM/src/int/i31_bitlen.o\n",
      ".\n",
      "Compiling C: src/int/i31_decmod.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/i31_decmod.lst -MMD -MP -MF .dep/i31_decmod.o.d src/int/i31_decmod.c -o objdir-CWLITEARM/src/int/i31_decmod.o\n",
      ".\n",
      "Compiling C: src/int/i31_decode.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/i31_decode.lst -MMD -MP -MF .dep/i31_decode.o.d src/int/i31_decode.c -o objdir-CWLITEARM/src/int/i31_decode.o\n",
      ".\n",
      "Compiling C: src/int/i31_decred.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/i31_decred.lst -MMD -MP -MF .dep/i31_decred.o.d src/int/i31_decred.c -o objdir-CWLITEARM/src/int/i31_decred.o\n",
      ".\n",
      "Compiling C: src/int/i31_encode.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/i31_encode.lst -MMD -MP -MF .dep/i31_encode.o.d src/int/i31_encode.c -o objdir-CWLITEARM/src/int/i31_encode.o\n",
      ".\n",
      "Compiling C: src/int/i31_fmont.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/i31_fmont.lst -MMD -MP -MF .dep/i31_fmont.o.d src/int/i31_fmont.c -o objdir-CWLITEARM/src/int/i31_fmont.o\n",
      ".\n",
      "Compiling C: src/int/i31_iszero.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/i31_iszero.lst -MMD -MP -MF .dep/i31_iszero.o.d src/int/i31_iszero.c -o objdir-CWLITEARM/src/int/i31_iszero.o\n",
      ".\n",
      "Compiling C: src/int/i31_moddiv.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/i31_moddiv.lst -MMD -MP -MF .dep/i31_moddiv.o.d src/int/i31_moddiv.c -o objdir-CWLITEARM/src/int/i31_moddiv.o\n",
      ".\n",
      "Compiling C: src/int/i31_modpow2.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/i31_modpow2.lst -MMD -MP -MF .dep/i31_modpow2.o.d src/int/i31_modpow2.c -o objdir-CWLITEARM/src/int/i31_modpow2.o\n",
      ".\n",
      "Compiling C: src/int/i31_modpow.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/i31_modpow.lst -MMD -MP -MF .dep/i31_modpow.o.d src/int/i31_modpow.c -o objdir-CWLITEARM/src/int/i31_modpow.o\n",
      ".\n",
      "Compiling C: src/int/i31_montmul.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/i31_montmul.lst -MMD -MP -MF .dep/i31_montmul.o.d src/int/i31_montmul.c -o objdir-CWLITEARM/src/int/i31_montmul.o\n",
      ".\n",
      "Compiling C: src/int/i31_mulacc.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/i31_mulacc.lst -MMD -MP -MF .dep/i31_mulacc.o.d src/int/i31_mulacc.c -o objdir-CWLITEARM/src/int/i31_mulacc.o\n",
      ".\n",
      "Compiling C: src/int/i31_muladd.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/i31_muladd.lst -MMD -MP -MF .dep/i31_muladd.o.d src/int/i31_muladd.c -o objdir-CWLITEARM/src/int/i31_muladd.o\n",
      ".\n",
      "Compiling C: src/int/i31_ninv31.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/i31_ninv31.lst -MMD -MP -MF .dep/i31_ninv31.o.d src/int/i31_ninv31.c -o objdir-CWLITEARM/src/int/i31_ninv31.o\n",
      ".\n",
      "Compiling C: src/int/i31_reduce.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/i31_reduce.lst -MMD -MP -MF .dep/i31_reduce.o.d src/int/i31_reduce.c -o objdir-CWLITEARM/src/int/i31_reduce.o\n",
      ".\n",
      "Compiling C: src/int/i31_rshift.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/i31_rshift.lst -MMD -MP -MF .dep/i31_rshift.o.d src/int/i31_rshift.c -o objdir-CWLITEARM/src/int/i31_rshift.o\n",
      ".\n",
      "Compiling C: src/int/i31_sub.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/i31_sub.lst -MMD -MP -MF .dep/i31_sub.o.d src/int/i31_sub.c -o objdir-CWLITEARM/src/int/i31_sub.o\n",
      ".\n",
      "Compiling C: src/int/i31_tmont.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/i31_tmont.lst -MMD -MP -MF .dep/i31_tmont.o.d src/int/i31_tmont.c -o objdir-CWLITEARM/src/int/i31_tmont.o\n",
      ".\n",
      "Compiling C: src/int/i32_div32.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/i32_div32.lst -MMD -MP -MF .dep/i32_div32.o.d src/int/i32_div32.c -o objdir-CWLITEARM/src/int/i32_div32.o\n",
      ".\n",
      "Compiling C: src/int/mod_rand_pow.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/mod_rand_pow.lst -MMD -MP -MF .dep/mod_rand_pow.o.d src/int/mod_rand_pow.c -o objdir-CWLITEARM/src/int/mod_rand_pow.o\n",
      ".\n",
      "Compiling C: src/rsa/FI-countermeasure.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/FI-countermeasure.lst -MMD -MP -MF .dep/FI-countermeasure.o.d src/rsa/FI-countermeasure.c -o objdir-CWLITEARM/src/rsa/FI-countermeasure.o\n"
     ]
    },
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "src/rsa/FI-countermeasure.c: In function 'br_rsa_i31_private_FI':\n",
      "src/rsa/FI-countermeasure.c:337:39: warning: suggest parentheses around '+' inside '>>' [-Wparentheses]\n",
      "  337 |         memcpy(t2 + 1, t1 + 1, (t1[0] + 7 >> 3));\n",
      "      |                                 ~~~~~~^~~\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      ".\n",
      "Compiling C: src/rsa/message_and_exp_blind.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/message_and_exp_blind.lst -MMD -MP -MF .dep/message_and_exp_blind.o.d src/rsa/message_and_exp_blind.c -o objdir-CWLITEARM/src/rsa/message_and_exp_blind.o\n",
      ".\n",
      "Compiling C: src/rsa/modulus_randomization.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/modulus_randomization.lst -MMD -MP -MF .dep/modulus_randomization.o.d src/rsa/modulus_randomization.c -o objdir-CWLITEARM/src/rsa/modulus_randomization.o\n",
      ".\n",
      "Compiling C: src/rsa/pre_randomization.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/pre_randomization.lst -MMD -MP -MF .dep/pre_randomization.o.d src/rsa/pre_randomization.c -o objdir-CWLITEARM/src/rsa/pre_randomization.o\n",
      ".\n",
      "Compiling C: src/rsa/rsa_i31_priv.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/rsa_i31_priv.lst -MMD -MP -MF .dep/rsa_i31_priv.o.d src/rsa/rsa_i31_priv.c -o objdir-CWLITEARM/src/rsa/rsa_i31_priv.o\n",
      ".\n",
      "Compiling C: src/rsa/rsa_i31_pub.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/rsa_i31_pub.lst -MMD -MP -MF .dep/rsa_i31_pub.o.d src/rsa/rsa_i31_pub.c -o objdir-CWLITEARM/src/rsa/rsa_i31_pub.o\n",
      ".\n",
      "Compiling C: src/rsa/rsa_i31_randkey.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/rsa_i31_randkey.lst -MMD -MP -MF .dep/rsa_i31_randkey.o.d src/rsa/rsa_i31_randkey.c -o objdir-CWLITEARM/src/rsa/rsa_i31_randkey.o\n",
      ".\n",
      "Compiling C: src/codec/ccopy.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/ccopy.lst -MMD -MP -MF .dep/ccopy.o.d src/codec/ccopy.c -o objdir-CWLITEARM/src/codec/ccopy.o\n",
      ".\n",
      "Compiling C: src/codec/dec16be.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/dec16be.lst -MMD -MP -MF .dep/dec16be.o.d src/codec/dec16be.c -o objdir-CWLITEARM/src/codec/dec16be.o\n",
      ".\n",
      "Compiling C: src/codec/dec16le.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/dec16le.lst -MMD -MP -MF .dep/dec16le.o.d src/codec/dec16le.c -o objdir-CWLITEARM/src/codec/dec16le.o\n",
      ".\n",
      "Compiling C: src/codec/dec32be.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/dec32be.lst -MMD -MP -MF .dep/dec32be.o.d src/codec/dec32be.c -o objdir-CWLITEARM/src/codec/dec32be.o\n",
      ".\n",
      "Compiling C: src/codec/dec32le.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/dec32le.lst -MMD -MP -MF .dep/dec32le.o.d src/codec/dec32le.c -o objdir-CWLITEARM/src/codec/dec32le.o\n",
      ".\n",
      "Compiling C: src/codec/dec64be.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/dec64be.lst -MMD -MP -MF .dep/dec64be.o.d src/codec/dec64be.c -o objdir-CWLITEARM/src/codec/dec64be.o\n",
      ".\n",
      "Compiling C: src/codec/dec64le.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/dec64le.lst -MMD -MP -MF .dep/dec64le.o.d src/codec/dec64le.c -o objdir-CWLITEARM/src/codec/dec64le.o\n",
      ".\n",
      "Compiling C: src/codec/enc16be.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/enc16be.lst -MMD -MP -MF .dep/enc16be.o.d src/codec/enc16be.c -o objdir-CWLITEARM/src/codec/enc16be.o\n",
      ".\n",
      "Compiling C: src/codec/enc16le.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/enc16le.lst -MMD -MP -MF .dep/enc16le.o.d src/codec/enc16le.c -o objdir-CWLITEARM/src/codec/enc16le.o\n",
      ".\n",
      "Compiling C: src/codec/enc32be.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/enc32be.lst -MMD -MP -MF .dep/enc32be.o.d src/codec/enc32be.c -o objdir-CWLITEARM/src/codec/enc32be.o\n",
      ".\n",
      "Compiling C: src/codec/enc32le.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/enc32le.lst -MMD -MP -MF .dep/enc32le.o.d src/codec/enc32le.c -o objdir-CWLITEARM/src/codec/enc32le.o\n",
      ".\n",
      "Compiling C: src/codec/enc64be.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/enc64be.lst -MMD -MP -MF .dep/enc64be.o.d src/codec/enc64be.c -o objdir-CWLITEARM/src/codec/enc64be.o\n",
      ".\n",
      "Compiling C: src/codec/enc64le.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/enc64le.lst -MMD -MP -MF .dep/enc64le.o.d src/codec/enc64le.c -o objdir-CWLITEARM/src/codec/enc64le.o\n",
      ".\n",
      "Compiling C: src/rand/rand/aesctr_drbg.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/aesctr_drbg.lst -MMD -MP -MF .dep/aesctr_drbg.o.d src/rand/rand/aesctr_drbg.c -o objdir-CWLITEARM/src/rand/rand/aesctr_drbg.o\n",
      ".\n",
      "Compiling C: src/rand/rand/hmac_drbg.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/hmac_drbg.lst -MMD -MP -MF .dep/hmac_drbg.o.d src/rand/rand/hmac_drbg.c -o objdir-CWLITEARM/src/rand/rand/hmac_drbg.o\n",
      ".\n",
      "Compiling C: src/rand/mac/hmac.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/hmac.lst -MMD -MP -MF .dep/hmac.o.d src/rand/mac/hmac.c -o objdir-CWLITEARM/src/rand/mac/hmac.o\n",
      ".\n",
      "Compiling C: src/rand/mac/hmac_ct.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/hmac_ct.lst -MMD -MP -MF .dep/hmac_ct.o.d src/rand/mac/hmac_ct.c -o objdir-CWLITEARM/src/rand/mac/hmac_ct.o\n",
      ".\n",
      "Compiling C: src/rand/hash/dig_oid.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/dig_oid.lst -MMD -MP -MF .dep/dig_oid.o.d src/rand/hash/dig_oid.c -o objdir-CWLITEARM/src/rand/hash/dig_oid.o\n",
      ".\n",
      "Compiling C: src/rand/hash/dig_size.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/dig_size.lst -MMD -MP -MF .dep/dig_size.o.d src/rand/hash/dig_size.c -o objdir-CWLITEARM/src/rand/hash/dig_size.o\n",
      ".\n",
      "Compiling C: src/rand/hash/ghash_ctmul32.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/ghash_ctmul32.lst -MMD -MP -MF .dep/ghash_ctmul32.o.d src/rand/hash/ghash_ctmul32.c -o objdir-CWLITEARM/src/rand/hash/ghash_ctmul32.o\n",
      ".\n",
      "Compiling C: src/rand/hash/ghash_ctmul64.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/ghash_ctmul64.lst -MMD -MP -MF .dep/ghash_ctmul64.o.d src/rand/hash/ghash_ctmul64.c -o objdir-CWLITEARM/src/rand/hash/ghash_ctmul64.o\n",
      ".\n",
      "Compiling C: src/rand/hash/ghash_ctmul.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/ghash_ctmul.lst -MMD -MP -MF .dep/ghash_ctmul.o.d src/rand/hash/ghash_ctmul.c -o objdir-CWLITEARM/src/rand/hash/ghash_ctmul.o\n",
      ".\n",
      "Compiling C: src/rand/hash/ghash_pclmul.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/ghash_pclmul.lst -MMD -MP -MF .dep/ghash_pclmul.o.d src/rand/hash/ghash_pclmul.c -o objdir-CWLITEARM/src/rand/hash/ghash_pclmul.o\n",
      ".\n",
      "Compiling C: src/rand/hash/ghash_pwr8.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/ghash_pwr8.lst -MMD -MP -MF .dep/ghash_pwr8.o.d src/rand/hash/ghash_pwr8.c -o objdir-CWLITEARM/src/rand/hash/ghash_pwr8.o\n",
      ".\n",
      "Compiling C: src/rand/hash/md5.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/md5.lst -MMD -MP -MF .dep/md5.o.d src/rand/hash/md5.c -o objdir-CWLITEARM/src/rand/hash/md5.o\n",
      ".\n",
      "Compiling C: src/rand/hash/md5sha1.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/md5sha1.lst -MMD -MP -MF .dep/md5sha1.o.d src/rand/hash/md5sha1.c -o objdir-CWLITEARM/src/rand/hash/md5sha1.o\n",
      ".\n",
      "Compiling C: src/rand/hash/mgf1.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/mgf1.lst -MMD -MP -MF .dep/mgf1.o.d src/rand/hash/mgf1.c -o objdir-CWLITEARM/src/rand/hash/mgf1.o\n",
      ".\n",
      "Compiling C: src/rand/hash/multihash.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/multihash.lst -MMD -MP -MF .dep/multihash.o.d src/rand/hash/multihash.c -o objdir-CWLITEARM/src/rand/hash/multihash.o\n",
      ".\n",
      "Compiling C: src/rand/hash/sha1.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/sha1.lst -MMD -MP -MF .dep/sha1.o.d src/rand/hash/sha1.c -o objdir-CWLITEARM/src/rand/hash/sha1.o\n",
      ".\n",
      "Compiling C: src/rand/hash/sha2big.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/sha2big.lst -MMD -MP -MF .dep/sha2big.o.d src/rand/hash/sha2big.c -o objdir-CWLITEARM/src/rand/hash/sha2big.o\n",
      ".\n",
      "Compiling C: src/rand/hash/sha2small.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/sha2small.lst -MMD -MP -MF .dep/sha2small.o.d src/rand/hash/sha2small.c -o objdir-CWLITEARM/src/rand/hash/sha2small.o\n",
      ".\n",
      "Compiling C: .././simpleserial/simpleserial.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/simpleserial.lst -MMD -MP -MF .dep/simpleserial.o.d .././simpleserial/simpleserial.c -o objdir-CWLITEARM/simpleserial.o\n",
      ".\n",
      "Compiling C: .././hal//stm32f3/stm32f3_hal.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/stm32f3_hal.lst -MMD -MP -MF .dep/stm32f3_hal.o.d .././hal//stm32f3/stm32f3_hal.c -o objdir-CWLITEARM/stm32f3_hal.o\n"
     ]
    },
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "In file included from .././hal//stm32f3/stm32f3xx_hal_def.h:49,\n",
      "                 from .././hal//stm32f3/stm32f3xx_hal_rcc.h:47,\n",
      "                 from .././hal//stm32f3/stm32f3_hal.c:4:\n",
      ".././hal//stm32f3/Legacy/stm32_hal_legacy.h:452:11: warning: \"GPIO_SPEED_HIGH\" redefined\n",
      "  452 |  #define  GPIO_SPEED_HIGH   GPIO_SPEED_FREQ_HIGH\n",
      "      |           ^~~~~~~~~~~~~~~\n",
      ".././hal//stm32f3/Legacy/stm32_hal_legacy.h:439:10: note: this is the location of the previous definition\n",
      "  439 | #define  GPIO_SPEED_HIGH                          GPIO_SPEED_FREQ_VERY_HIGH\n",
      "      |          ^~~~~~~~~~~~~~~\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      ".\n",
      "Compiling C: .././hal//stm32f3/stm32f3_hal_lowlevel.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/stm32f3_hal_lowlevel.lst -MMD -MP -MF .dep/stm32f3_hal_lowlevel.o.d .././hal//stm32f3/stm32f3_hal_lowlevel.c -o objdir-CWLITEARM/stm32f3_hal_lowlevel.o\n"
     ]
    },
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "In file included from .././hal//stm32f3/stm32f3xx_hal_def.h:49,\n",
      "                 from .././hal//stm32f3/stm32f3xx_hal_rcc.h:47,\n",
      "                 from .././hal//stm32f3/stm32f3_hal_lowlevel.c:40:\n",
      ".././hal//stm32f3/Legacy/stm32_hal_legacy.h:452:11: warning: \"GPIO_SPEED_HIGH\" redefined\n",
      "  452 |  #define  GPIO_SPEED_HIGH   GPIO_SPEED_FREQ_HIGH\n",
      "      |           ^~~~~~~~~~~~~~~\n",
      ".././hal//stm32f3/Legacy/stm32_hal_legacy.h:439:10: note: this is the location of the previous definition\n",
      "  439 | #define  GPIO_SPEED_HIGH                          GPIO_SPEED_FREQ_VERY_HIGH\n",
      "      |          ^~~~~~~~~~~~~~~\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      ".\n",
      "Compiling C: .././hal//stm32f3/stm32f3_sysmem.c\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I.  -g -I./inc -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -gdwarf-2 -DSTM32F4 -DCORTEX_M4 -mthumb -mcpu=cortex-m4 -mfpu=fpv4-sp-d16   -DSS_VER=SS_VER_1_1 -DSTM32F303xC -DSTM32F3 -DSTM32 -DDEBUG -DHAL_TYPE=HAL_stm32f3 -DPLATFORM=CWLITEARM -DSS_VER=SS_VER_1_1 -DF_CPU=7372800UL -DSS_VER_2_0=2 -DSS_VER_2_1=3 -DSS_VER_1_1=1 -DSS_VER_1_0=0 -O2 -funsigned-char -funsigned-bitfields -fshort-enums -Wall -Wstrict-prototypes -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ -std=gnu99 -Wno-discarded-qualifiers -Wno-unused-function -Wno-unused-variable -Wno-strict-prototypes -Wno-missing-prototypes -Wno-pointer-sign -Wno-unused-value -Wno-implicit-function-declaration  -Wa,-adhlns=objdir-CWLITEARM/stm32f3_sysmem.lst -MMD -MP -MF .dep/stm32f3_sysmem.o.d .././hal//stm32f3/stm32f3_sysmem.c -o objdir-CWLITEARM/stm32f3_sysmem.o\n",
      ".\n",
      "Assembling: .././hal//stm32f3/stm32f3_startup.S\n",
      "arm-none-eabi-gcc -c -mcpu=cortex-m4 -I. -x assembler-with-cpp -mthumb -mfloat-abi=soft -fmessage-length=0 -ffunction-sections -DF_CPU=7372800 -Wa,-gstabs,-adhlns=objdir-CWLITEARM/stm32f3_startup.lst -I.././simpleserial/ -I.././hal/ -I.././hal/ -I.././hal//stm32f3 -I.././hal//stm32f3/CMSIS -I.././hal//stm32f3/CMSIS/core -I.././hal//stm32f3/CMSIS/device -I.././hal//stm32f4/Legacy -I.././simpleserial/ -I.././crypto/ .././hal//stm32f3/stm32f3_startup.S -o objdir-CWLITEARM/stm32f3_startup.o\n",
      ".\n",
      "LINKING:\n"
     ]
    },
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "/usr/lib/gcc/arm-none-eabi/14.2.0/../../../../arm-none-eabi/bin/ld: /usr/lib/gcc/arm-none-eabi/14.2.0/../../../../arm-none-eabi/lib/thumb/v7e-m/nofp/libg_nano.a(libc_a-closer.o): in function `_close_r':\n",
      "/build/arm-none-eabi-newlib/src/build-nano/arm-none-eabi/thumb/v7e-m/nofp/newlib/../../../../../../newlib-4.5.0.20241231/newlib/libc/reent/closer.c:47:(.text._close_r+0xc): warning: _close is not implemented and will always fail\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "    simpleserial_sca_rsa-CWLITEARM.elf .../usr/lib/gcc/arm-none-eabi/14.2.0/../../../../arm-none-eabi/bin/ld: /usr/lib/gcc/arm-none-eabi/14.2.0/../../../../arm-none-eabi/lib/thumb/v7e-m/nofp/libg_nano.a(libc_a-closer.o): note: the message above does not take linker garbage collection into account\n"
     ]
    },
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "/usr/lib/gcc/arm-none-eabi/14.2.0/../../../../arm-none-eabi/bin/ld: /usr/lib/gcc/arm-none-eabi/14.2.0/../../../../arm-none-eabi/lib/thumb/v7e-m/nofp/libg_nano.a(libc_a-fstatr.o): in function `_fstat_r':\n",
      "/build/arm-none-eabi-newlib/src/build-nano/arm-none-eabi/thumb/v7e-m/nofp/newlib/../../../../../../newlib-4.5.0.20241231/newlib/libc/reent/fstatr.c:55:(.text._fstat_r+0xe): warning: _fstat is not implemented and will always fail\n",
      "/usr/lib/gcc/arm-none-eabi/14.2.0/../../../../arm-none-eabi/bin/ld: /usr/lib/gcc/arm-none-eabi/14.2.0/../../../../arm-none-eabi/lib/thumb/v7e-m/nofp/libg_nano.a(libc_a-signalr.o): in function `_getpid_r':\n",
      "/build/arm-none-eabi-newlib/src/build-nano/arm-none-eabi/thumb/v7e-m/nofp/newlib/../../../../../../newlib-4.5.0.20241231/newlib/libc/reent/signalr.c:83:(.text._getpid_r+0x0): warning: _getpid is not implemented and will always fail\n",
      "/usr/lib/gcc/arm-none-eabi/14.2.0/../../../../arm-none-eabi/bin/ld: /usr/lib/gcc/arm-none-eabi/14.2.0/../../../../arm-none-eabi/lib/thumb/v7e-m/nofp/libg_nano.a(libc_a-gettimeofdayr.o): in function `_gettimeofday_r':\n",
      "/build/arm-none-eabi-newlib/src/build-nano/arm-none-eabi/thumb/v7e-m/nofp/newlib/../../../../../../newlib-4.5.0.20241231/newlib/libc/reent/gettimeofdayr.c:62:(.text._gettimeofday_r+0xe): warning: _gettimeofday is not implemented and will always fail\n",
      "/usr/lib/gcc/arm-none-eabi/14.2.0/../../../../arm-none-eabi/bin/ld: /usr/lib/gcc/arm-none-eabi/14.2.0/../../../../arm-none-eabi/lib/thumb/v7e-m/nofp/libg_nano.a(libc_a-isattyr.o): in function `_isatty_r':\n",
      "/build/arm-none-eabi-newlib/src/build-nano/arm-none-eabi/thumb/v7e-m/nofp/newlib/../../../../../../newlib-4.5.0.20241231/newlib/libc/reent/isattyr.c:52:(.text._isatty_r+0xc): warning: _isatty is not implemented and will always fail\n",
      "/usr/lib/gcc/arm-none-eabi/14.2.0/../../../../arm-none-eabi/bin/ld: /usr/lib/gcc/arm-none-eabi/14.2.0/../../../../arm-none-eabi/lib/thumb/v7e-m/nofp/libg_nano.a(libc_a-signalr.o): in function `_kill_r':\n",
      "/build/arm-none-eabi-newlib/src/build-nano/arm-none-eabi/thumb/v7e-m/nofp/newlib/../../../../../../newlib-4.5.0.20241231/newlib/libc/reent/signalr.c:53:(.text._kill_r+0xe): warning: _kill is not implemented and will always fail\n",
      "/usr/lib/gcc/arm-none-eabi/14.2.0/../../../../arm-none-eabi/bin/ld: /usr/lib/gcc/arm-none-eabi/14.2.0/../../../../arm-none-eabi/lib/thumb/v7e-m/nofp/libg_nano.a(libc_a-lseekr.o): in function `_lseek_r':\n",
      "/build/arm-none-eabi-newlib/src/build-nano/arm-none-eabi/thumb/v7e-m/nofp/newlib/../../../../../../newlib-4.5.0.20241231/newlib/libc/reent/lseekr.c:49:(.text._lseek_r+0x10): warning: _lseek is not implemented and will always fail\n",
      "/usr/lib/gcc/arm-none-eabi/14.2.0/../../../../arm-none-eabi/bin/ld: /usr/lib/gcc/arm-none-eabi/14.2.0/../../../../arm-none-eabi/lib/thumb/v7e-m/nofp/libg_nano.a(libc_a-readr.o): in function `_read_r':\n",
      "/build/arm-none-eabi-newlib/src/build-nano/arm-none-eabi/thumb/v7e-m/nofp/newlib/../../../../../../newlib-4.5.0.20241231/newlib/libc/reent/readr.c:49:(.text._read_r+0x10): warning: _read is not implemented and will always fail\n",
      "/usr/lib/gcc/arm-none-eabi/14.2.0/../../../../arm-none-eabi/bin/ld: /usr/lib/gcc/arm-none-eabi/14.2.0/../../../../arm-none-eabi/lib/thumb/v7e-m/nofp/libg_nano.a(libc_a-writer.o): in function `_write_r':\n",
      "/build/arm-none-eabi-newlib/src/build-nano/arm-none-eabi/thumb/v7e-m/nofp/newlib/../../../../../../newlib-4.5.0.20241231/newlib/libc/reent/writer.c:49:(.text._write_r+0x10): warning: _write is not implemented and will always fail\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "/usr/lib/gcc/arm-none-eabi/14.2.0/../../../../arm-none-eabi/bin/ld: /usr/lib/gcc/arm-none-eabi/14.2.0/../../../../arm-none-eabi/lib/thumb/v7e-m/nofp/libg_nano.a(libc_a-fstatr.o): note: the message above does not take linker garbage collection into account\n",
      "/usr/lib/gcc/arm-none-eabi/14.2.0/../../../../arm-none-eabi/bin/ld: /usr/lib/gcc/arm-none-eabi/14.2.0/../../../../arm-none-eabi/lib/thumb/v7e-m/nofp/libg_nano.a(libc_a-signalr.o): note: the message above does not take linker garbage collection into account\n",
      "/usr/lib/gcc/arm-none-eabi/14.2.0/../../../../arm-none-eabi/bin/ld: /usr/lib/gcc/arm-none-eabi/14.2.0/../../../../arm-none-eabi/lib/thumb/v7e-m/nofp/libg_nano.a(libc_a-gettimeofdayr.o): note: the message above does not take linker garbage collection into account\n",
      "/usr/lib/gcc/arm-none-eabi/14.2.0/../../../../arm-none-eabi/bin/ld: /usr/lib/gcc/arm-none-eabi/14.2.0/../../../../arm-none-eabi/lib/thumb/v7e-m/nofp/libg_nano.a(libc_a-isattyr.o): note: the message above does not take linker garbage collection into account\n",
      "/usr/lib/gcc/arm-none-eabi/14.2.0/../../../../arm-none-eabi/bin/ld: /usr/lib/gcc/arm-none-eabi/14.2.0/../../../../arm-none-eabi/lib/thumb/v7e-m/nofp/libg_nano.a(libc_a-signalr.o): note: the message above does not take linker garbage collection into account\n",
      "/usr/lib/gcc/arm-none-eabi/14.2.0/../../../../arm-none-eabi/bin/ld: /usr/lib/gcc/arm-none-eabi/14.2.0/../../../../arm-none-eabi/lib/thumb/v7e-m/nofp/libg_nano.a(libc_a-lseekr.o): note: the message above does not take linker garbage collection into account\n",
      "/usr/lib/gcc/arm-none-eabi/14.2.0/../../../../arm-none-eabi/bin/ld: /usr/lib/gcc/arm-none-eabi/14.2.0/../../../../arm-none-eabi/lib/thumb/v7e-m/nofp/libg_nano.a(libc_a-readr.o): note: the message above does not take linker garbage collection into account\n",
      "/usr/lib/gcc/arm-none-eabi/14.2.0/../../../../arm-none-eabi/bin/ld: /usr/lib/gcc/arm-none-eabi/14.2.0/../../../../arm-none-eabi/lib/thumb/v7e-m/nofp/libg_nano.a(libc_a-writer.o): note: the message above does not take linker garbage collection into account\n"
     ]
    },
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "/usr/lib/gcc/arm-none-eabi/14.2.0/../../../../arm-none-eabi/bin/ld: warning: simpleserial_sca_rsa-CWLITEARM.elf has a LOAD segment with RWX permissions\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Done!\n",
      ".\n",
      "Creating load file for Flash: simpleserial_sca_rsa-CWLITEARM.hex\n",
      "arm-none-eabi-objcopy -O ihex -R .eeprom -R .fuse -R .lock -R .signature simpleserial_sca_rsa-CWLITEARM.elf simpleserial_sca_rsa-CWLITEARM.hex\n",
      ".\n",
      "Creating load file for Flash: simpleserial_sca_rsa-CWLITEARM.bin\n",
      "arm-none-eabi-objcopy -O binary -R .eeprom -R .fuse -R .lock -R .signature simpleserial_sca_rsa-CWLITEARM.elf simpleserial_sca_rsa-CWLITEARM.bin\n",
      ".\n",
      "Creating load file for EEPROM: simpleserial_sca_rsa-CWLITEARM.eep\n",
      "arm-none-eabi-objcopy -j .eeprom --set-section-flags=.eeprom=\"alloc,load\" \\\n",
      "--change-section-lma .eeprom=0 --no-change-warnings -O ihex simpleserial_sca_rsa-CWLITEARM.elf simpleserial_sca_rsa-CWLITEARM.eep || exit 0\n",
      ".\n",
      "Creating Extended Listing: simpleserial_sca_rsa-CWLITEARM.lss\n",
      "arm-none-eabi-objdump -h -S -z simpleserial_sca_rsa-CWLITEARM.elf > simpleserial_sca_rsa-CWLITEARM.lss\n",
      ".\n",
      "Creating Symbol Table: simpleserial_sca_rsa-CWLITEARM.sym\n",
      "arm-none-eabi-nm -n simpleserial_sca_rsa-CWLITEARM.elf > simpleserial_sca_rsa-CWLITEARM.sym\n",
      "Size after:\n",
      "   text\t   data\t    bss\t    dec\t    hex\tfilename\n",
      "  94224\t    100\t   1784\t  96108\t  1776c\tsimpleserial_sca_rsa-CWLITEARM.elf\n",
      "+--------------------------------------------------------\n",
      "+ Built for platform CW-Lite Arm \\(STM32F3\\) with:\n",
      "+ CRYPTO_TARGET = NONE\n",
      "+ CRYPTO_OPTIONS = \n",
      "+--------------------------------------------------------\n"
     ]
    }
   ],
   "source": [
    "%%bash -s \"$SS_VER\" \"$PLATFORM\" \"$CRYPTO_TARGET\"\n",
    "rm -rf objdir-$2 objdir .dep\n",
    "make SS_VER=$1 PLATFORM=$2 CRYPTO_TARGET=$3"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 271,
   "id": "6cadde2e-e999-47ac-8b17-7f74fecd6f14",
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Detected known STMF32: STM32F302xB(C)/303xB(C)\n",
      "Extended erase (0x44), this can take ten seconds or more\n",
      "Attempting to program 94331 bytes at 0x8000000\n",
      "STM32F Programming flash...\n",
      "STM32F Reading flash...\n",
      "Verified flash OK, 94331 bytes\n"
     ]
    }
   ],
   "source": [
    "HEXFILE = \"./simpleserial_sca_rsa-\" + PLATFORM + \".hex\"\n",
    "cw.program_target(scope, prog, HEXFILE)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 267,
   "id": "6c2d06ae-10bd-4705-b0f1-6ef5b79a3835",
   "metadata": {},
   "outputs": [],
   "source": [
    "import os\n",
    "import numpy as np\n",
    "import matplotlib.pyplot as plt\n",
    "from scipy import stats\n",
    "\n",
    "DATA_LEN=128\n",
    "RESP_LEN=128\n",
    "NUM_TRACES = 2000\n",
    "textin_array = []\n",
    "textin_array = [os.urandom(DATA_LEN) for _ in range(NUM_TRACES)]\n"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 214,
   "id": "4d1ec888-235f-4c67-93b2-561b155d4a71",
   "metadata": {},
   "outputs": [],
   "source": [
    "fixed = os.urandom(DATA_LEN)\n",
    "fixed_hex = fixed.hex()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 268,
   "id": "a3e92166-f6e0-44a0-b6a8-6f3e94f72870",
   "metadata": {
    "scrolled": true
   },
   "outputs": [
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 2000/2000 [37:05<00:00,  1.11s/it]\n"
     ]
    }
   ],
   "source": [
    "from tqdm import tqdm\n",
    "group_0 = []\n",
    "CMD_TEST_0 = 'a'\n",
    "CMD_TEST_1 = 'b'\n",
    "CMD_TEST_2 = 'c'\n",
    "scope.adc.samples = 24400\n",
    "scope.adc.decimate = 15\n",
    "scope.clock.adc_src = 'clkgen_x1'\n",
    "scope.gain.db = 30\n",
    "#scope.adc.offset = 1000\n",
    "#scope.adc.timeout = 50\n",
    "for i in tqdm(range(len(textin_array))):\n",
    "    target.flush()\n",
    "    scope.arm()\n",
    "    target.simpleserial_write(CMD_TEST_2,fixed)\n",
    "    scope.capture()\n",
    "    res = target.simpleserial_read('r', RESP_LEN,timeout=0)\n",
    "    group_0.append(scope.get_last_trace())\n",
    "    #print(res)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 105,
   "id": "8e931b47-9929-4627-99ac-037d98980c3a",
   "metadata": {},
   "outputs": [
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 100/100 [01:21<00:00,  1.23it/s]\n"
     ]
    }
   ],
   "source": [
    "from tqdm import tqdm\n",
    "group_1 = []\n",
    "CMD_TEST_0 = 'a'\n",
    "CMD_TEST_1 = 'b'\n",
    "CMD_TEST_2 = 'c'\n",
    "scope.adc.samples = 24400\n",
    "scope.adc.decimate = 15\n",
    "scope.clock.adc_src = 'clkgen_x1'\n",
    "scope.gain.db = 30\n",
    "#scope.adc.offset = 1000\n",
    "#scope.adc.timeout = 50\n",
    "for i in tqdm(range(len(textin_array))):\n",
    "    target.flush()\n",
    "    scope.arm()\n",
    "    target.simpleserial_write(CMD_TEST_2,textin_array[i])\n",
    "    scope.capture()\n",
    "    res = target.simpleserial_read('r', RESP_LEN,timeout=0)\n",
    "    group_1.append(scope.get_last_trace())"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 246,
   "id": "b5db92e8-9a3a-4acb-aba1-c612ab8861f9",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "False"
      ]
     },
     "execution_count": 246,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "target.flush()\n",
    "scope.arm()\n",
    "target.simpleserial_write('e',fixed)\n",
    "scope.capture()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 272,
   "id": "2b4f9eb9-3df1-4d46-ace2-20e0d3174cbc",
   "metadata": {
    "scrolled": true
   },
   "outputs": [
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 2000/2000 [37:05<00:00,  1.11s/it]\n"
     ]
    }
   ],
   "source": [
    "from tqdm import tqdm\n",
    "group_2 = []\n",
    "CMD_TEST_0 = 'a'\n",
    "CMD_TEST_1 = 'b'\n",
    "CMD_TEST_2 = 'c'\n",
    "scope.adc.samples = 24400\n",
    "scope.adc.decimate = 15\n",
    "scope.clock.adc_src = 'clkgen_x1'\n",
    "scope.gain.db = 30\n",
    "#scope.adc.offset = 1000\n",
    "#scope.adc.timeout = 50\n",
    "for i in tqdm(range(len(textin_array))):\n",
    "   \n",
    "    #target.simpleserial_read('r', RESP_LEN)\n",
    "\n",
    "    target.flush()\n",
    "    scope.arm()\n",
    "    target.simpleserial_write(CMD_TEST_2,fixed)\n",
    "    scope.capture()\n",
    "    res = target.simpleserial_read('r', RESP_LEN,timeout=0)\n",
    "    group_2.append(scope.get_last_trace())\n",
    "    #print(res)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 221,
   "id": "8ca424ed-9271-450d-8d74-a787a591a093",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "image/png": "[encoded data, 52040 characters]",
      "text/plain": [
       "<Figure size 640x480 with 1 Axes>"
      ]
     },
     "metadata": {},
     "output_type": "display_data"
    }
   ],
   "source": [
    "for i in range(10):\n",
    "    plt.plot(group_0[i])\n",
    "plt.show()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 263,
   "id": "9dddeffe-2740-43ae-b7f7-9adc61e4fb8b",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "image/png": "[encoded data, 51636 characters]",
      "text/plain": [
       "<Figure size 640x480 with 1 Axes>"
      ]
     },
     "metadata": {},
     "output_type": "display_data"
    }
   ],
   "source": [
    "for i in range(10):\n",
    "    plt.plot(group_2[i])\n",
    "plt.show()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 30,
   "id": "309a5594-2d3d-4843-9133-9bb10cc4a0ae",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "image/png": "[encoded data, 49040 characters]",
      "text/plain": [
       "<Figure size 640x480 with 1 Axes>"
      ]
     },
     "metadata": {},
     "output_type": "display_data"
    }
   ],
   "source": [
    "for i in range(10):\n",
    "    plt.plot(group_1[i])\n",
    "plt.show()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 303,
   "id": "a76ae9dd-65a6-4955-bc83-dd0c94731a9f",
   "metadata": {},
   "outputs": [],
   "source": [
    "np.save(\"group_0\" + \".npy\", group_0[0]) \n",
    "np.save(\"group_1\" + \".npy\", group_1[0])  \n",
    "np.save(\"group_2\" + \".npy\", group_2[0])  "
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 130,
   "id": "b5bac870-98d7-458e-b76a-7a4a3ffe2eae",
   "metadata": {},
   "outputs": [],
   "source": [
    "group_0 = np.asarray(group_0)\n",
    "group_1 = np.asarray(group_1)\n",
    "threshold= 4.5\n",
    "time_points = group_0.shape[1]\n",
    "t_values = np.zeros(time_points)\n",
    "    \n",
    "    # Compute t-test for each time sample.\n",
    "for t in range(time_points):\n",
    "    fixed_sample = group_0[:, t]\n",
    "    random_sample = group_1[:, t]\n",
    "    # Use Welch's t-test (does not assume equal variances)\n",
    "    t_val, _ = stats.ttest_ind(fixed_sample, random_sample, equal_var=False)\n",
    "    t_values[t] = t_val\n",
    "    \n",
    "# Identify time points with significant leakage.\n",
    "significant_idxs = np.where(np.abs(t_values) >= threshold)[0]"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 131,
   "id": "783995d1-538c-4df8-b491-1d29d927d5c9",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "image/png": "[encoded data, 49152 characters]",
      "text/plain": [
       "<Figure size 1000x400 with 1 Axes>"
      ]
     },
     "metadata": {},
     "output_type": "display_data"
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Significant time points (|t| >= threshold): []\n"
     ]
    }
   ],
   "source": [
    "# Plot the t-values over time.\n",
    "plt.figure(figsize=(10, 4))\n",
    "plt.plot(abs(t_values), label='t-value')\n",
    "plt.axhline(y=4.5, color='r', linestyle='--', label='Threshold')\n",
    "#plt.axhline(y=-4.5, color='r', linestyle='--')\n",
    "plt.xlabel(\"Time Sample\")\n",
    "plt.ylabel(\"t-value\")\n",
    "plt.title(\"TVLA: t-test between group_0 and group_1 across time \" + str(fixed_sample.size) + \" traces\")\n",
    "plt.legend()\n",
    "plt.grid(True)\n",
    "#title = \"TVLA_mod_rand_1000_1024_FULL_GRP1\"\n",
    "title = \"TVLA_test13_1000_1024_FULL_GRP1\"\n",
    "plt.savefig(title, dpi=300, bbox_inches=\"tight\")\n",
    "plt.show()\n",
    "np.save(title + \".npy\", abs(t_values))  \n",
    "print(\"Significant time points (|t| >= threshold):\", significant_idxs)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 273,
   "id": "17c6d408-80d0-4af6-98e2-e4cb7f772e24",
   "metadata": {},
   "outputs": [],
   "source": [
    "group_0 = np.asarray(group_0)\n",
    "group_2 = np.asarray(group_2)\n",
    "threshold= 4.5\n",
    "time_points = group_0.shape[1]\n",
    "t_values = np.zeros(time_points)\n",
    "    \n",
    "    # Compute t-test for each time sample.\n",
    "for t in range(time_points):\n",
    "    fixed_sample = group_0[:, t]\n",
    "    random_sample = group_2[:, t]\n",
    "    # Use Welch's t-test (does not assume equal variances)\n",
    "    t_val, _ = stats.ttest_ind(fixed_sample, random_sample, equal_var=False)\n",
    "    t_values[t] = t_val\n",
    "    \n",
    "# Identify time points with significant leakage.\n",
    "significant_idxs = np.where(np.abs(t_values) >= threshold)[0]"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 276,
   "id": "a9e423d9-85c9-43e4-9c0b-efe6223ffec8",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "image/png": "[encoded data, 67796 characters]",
      "text/plain": [
       "<Figure size 1000x400 with 1 Axes>"
      ]
     },
     "metadata": {},
     "output_type": "display_data"
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Significant time points (|t| >= threshold): [  467   685  1024  1400  1644  2500  2721  2723  2917  2924  3345  3347\n",
      "  3366  3394  3507  3775  4111  4112  4281  4381  4492  4657  4712  4988\n",
      "  5253  5587  5635  5637  5644  5665  5667  5694  5708  5709  5728  5732\n",
      "  5740  5746  5748  5760  5840  5867  5874  5900  5928  5989  5992  6033\n",
      "  6042  6044  6059  6060  6073  6104  6125  6134  6145  6151  6152  6154\n",
      "  6253  6281  6315  6333  6346  6347  6455  6481  6540  6542  6553  6559\n",
      "  6580  6591  6609  6634  6635  6640  6642  6663  6667  6668  6685  6726\n",
      "  6754  6813  6815  6816  6818  6835  6864  6866  6877  6890  6922  6928\n",
      "  6940  7004  7020  7029  7060  7072  7160  7163  7183  7185  7187  7190\n",
      "  7355  7461  7513  7523  7543  7629  7712  7782  7786  7787  7788  7792\n",
      "  7793  7794  7795  7799  7853  7868  7873  7888  7922  7927  7946  7952\n",
      "  7961  7977  7978  7996  8029  8081  8116  8121  8140  8167  8173  8177\n",
      "  8190  8195  8203  8205  8216  8231  8253  8263  8264  8265  8296  8323\n",
      "  8327  8388  8407  8430  8435  8441  8450  8461  8468  8488  8526  8550\n",
      "  8559  8573  8608  8662  8675  8685  8694  8703  8734  8736  8737  8738\n",
      "  8739  8743  8744  8745  8749  8750  8776  8796  8798  8803  8804  8805\n",
      "  8810  8838  8857  8879  8915  8947  8948  8955  8970  8976  8994  8995\n",
      "  8999  9001  9028  9050  9062  9067  9070  9072  9108  9133  9155  9192\n",
      "  9205  9421  9427  9456  9594  9645  9652  9703  9757  9758  9790  9835\n",
      "  9856  9894  9932  9997 10054 10066 10087 10103 10107 10125 10265 10273\n",
      " 10299 10307 10308 10312 10313 10321 10323 10325 10334 10368 10370 10398\n",
      " 10467 10472 10477 10481 10518 10520 10549 10569 10572 10618 10630 10656\n",
      " 10667 10687 10699 10720 10732 10733 10753 10801 10803 10812 10814 10880\n",
      " 10931 10970 10977 10986 10998 11003 11021 11087 11092 11093 11108 11125\n",
      " 11156 11159 11212 11214 11237 11277 11287 11288 11314 11316 11321 11328\n",
      " 11489 11501 11598 11601 11606 11608 11688 11740 11744 11823 11832 11881\n",
      " 11889 11893 11894 11901 11904 11915 11927 11932 11942 11943 11985 12011\n",
      " 12017 12020 12028 12066 12071 12074 12076 12097 12130 12132 12144 12155\n",
      " 12198 12204 12232 12242 12255 12277 12285 12290 12296 12311 12337 12342\n",
      " 12347 12385 12411 12418 12419 12454 12471 12477 12515 12528 12533 12540\n",
      " 12563 12569 12598 12610 12615 12649 12671 12678 12688 12736 12787 12791\n",
      " 12796 12809 12860 12914 12926 12948 12951 13020 13030 13110 13115 13121\n",
      " 13135 13137 13168 13180 13181 13188 13198 13202 13231 13237 13259 13265\n",
      " 13285 13440 13512 13521 13533 13552 13564 13572 13585 13735 13829 14008\n",
      " 14010 14055 14068 14120 14140 14159 14229 14244 14249 14287 14344 14356\n",
      " 14364 14371 14390 14392 14393 14396 14398 14399 14400 14402 14404 14405\n",
      " 14491 14497 14499 14531 14560 14606 14644 14660 14662 14663 14675 14730\n",
      " 14733 14742 14744 14756 14765 14781 14782 14800 14872 14877 14879 14928\n",
      " 14968 14976 14997 14999 15015 15023 15073 15086 15141 15158 15192 15193\n",
      " 15244 15250 15254 15265 15267 15272 15308 15331 15352 15373 15528 15538\n",
      " 15561 15572 15592 15613 15633 15681 15725 15742 15746 15753 15785 15865\n",
      " 15867 15894 15900 15972 15976 15978 15982 15983 15984 15988 15989 15990\n",
      " 15995 16000 16108 16131 16137 16139 16141 16142 16156 16162 16177 16179\n",
      " 16211 16245 16264 16270 16297 16304 16320 16325 16332 16333 16355 16383\n",
      " 16384 16393 16407 16453 16455 16464 16465 16466 16468 16498 16537 16588\n",
      " 16593 16598 16631 16649 16657 16680 16714 16744 16801 16847 16852 16856\n",
      " 16876 16884 16896 16907 16910 16924 16936 16937 16938 16943 16944 16945\n",
      " 16965 16970 17009 17016 17019 17024 17037 17039 17042 17045 17077 17088\n",
      " 17100 17131 17147 17165 17180 17184 17186 17192 17200 17202 17208 17212\n",
      " 17232 17244 17246 17263 17276 17293 17322 17334 17348 17353 17355 17376\n",
      " 17387 17395 17396 17397 17402 17569 17715 17775 17782 17853 17888 17920\n",
      " 17937 17997 17999 18033 18037 18045 18050 18055 18056 18071 18118 18119\n",
      " 18120 18128 18133 18156 18203 18205 18211 18212 18288 18349 18378 18384\n",
      " 18389 18436 18455 18472 18496 18541 18613 18617 18677 18682 18699 18709\n",
      " 18728 18743 18791 18796 18798 18807 18830 18895 18916 18981 18985 19014\n",
      " 19088 19119 19151 19168 19206 19207 19249 19257 19276 19292 19306 19309\n",
      " 19310 19319 19347 19373 19424 19441 19445 19461 19492 20139 20255 20533\n",
      " 20537 20583 20585 20592 20788 20857 20859 21073 21074 21132 21477 21479\n",
      " 21488 22232 22314 22561 22604 22653 22834 22836 22974 23101 23110 23241\n",
      " 23580 24361]\n"
     ]
    }
   ],
   "source": [
    "# Plot the t-values over time.\n",
    "plt.figure(figsize=(10, 4))\n",
    "plt.plot(abs(t_values), label='t-value')\n",
    "plt.axhline(y=4.5, color='r', linestyle='--', label='Threshold')\n",
    "#plt.axhline(y=-4.5, color='r', linestyle='--')\n",
    "plt.xlabel(\"Time Sample\")\n",
    "plt.ylabel(\"t-value\")\n",
    "plt.title(\"TVLA: t-test between group_0 and group_2 across time \" + str(fixed_sample.size) + \" traces\")\n",
    "plt.legend()\n",
    "plt.grid(True)\n",
    "#title = \"TVLA_mod_rand_1000_1024_FULL_GRP1\"\n",
    "title = \"TVLA_test16_1000_1024_FULL_GRP2\"\n",
    "plt.savefig(title, dpi=300, bbox_inches=\"tight\")\n",
    "plt.show()\n",
    "np.save(title + \".npy\", abs(t_values))  \n",
    "print(\"Significant time points (|t| >= threshold):\", significant_idxs)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 135,
   "id": "8295c71d-52f9-4346-82d5-0d55dc24477f",
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Adjusted α_TH (Šidák): 0.00000041\n",
      "Interpolated paper-recommended |t|-threshold: 4.9606\n",
      "Number of leaky points above threshold: 0\n"
     ]
    }
   ],
   "source": [
    "import numpy as np\n",
    "from scipy.stats import t\n",
    "\n",
    "# Assume group_0 and group_1 are already defined\n",
    "# Example inputs\n",
    "alpha = 0.01  # Overall significance level\n",
    "\n",
    "nA = group_0.shape[0]\n",
    "nB = group_2.shape[0]\n",
    "n_L = group_0.shape[1]  # number of trace points\n",
    "\n",
    "# Step 1: Compute per-test adjusted significance level\n",
    "alpha_TH = 1 - (1 - alpha) ** (1 / n_L)\n",
    "\n",
    "# Step 2: Compute sample means and variances per point\n",
    "meanA = np.mean(group_0, axis=0)\n",
    "meanB = np.mean(group_1, axis=0)\n",
    "varA = np.var(group_0, axis=0, ddof=1)\n",
    "varB = np.var(group_2, axis=0, ddof=1)\n",
    "\n",
    "# Step 3: Welch-Satterthwaite degrees of freedom per point\n",
    "sA = varA / nA\n",
    "sB = varB / nB\n",
    "numerator = (sA + sB) ** 2\n",
    "denominator = (sA**2) / (nA - 1) + (sB**2) / (nB - 1)\n",
    "df_welch = numerator / denominator\n",
    "\n",
    "# Step 4: Compute t-statistics\n",
    "t_stats = (meanA - meanB) / np.sqrt(sA + sB)\n",
    "\n",
    "# --- NEW PART: Interpolate paper-recommended threshold ---\n",
    "def interpolate_tvla_threshold(n_L, alpha=0.01):\n",
    "    table_nL = np.array([1e4, 1e5])\n",
    "    if alpha == 0.01:\n",
    "        table_thresholds = np.array([4.891, 5.326])\n",
    "    elif alpha == 0.001:\n",
    "        table_thresholds = np.array([5.327, 5.731])\n",
    "    else:\n",
    "        raise ValueError(\"Only α = 0.01 or 0.001 are supported.\")\n",
    "    return np.interp(n_L, table_nL, table_thresholds)\n",
    "\n",
    "TH_paper = interpolate_tvla_threshold(n_L, alpha=alpha)\n",
    "\n",
    "# Step 5: Find points exceeding threshold (potential leakage)\n",
    "leaky_points = np.abs(t_stats) > TH_paper\n",
    "\n",
    "# --- Output ---\n",
    "print(f\"Adjusted α_TH (Šidák): {alpha_TH:.8f}\")\n",
    "print(f\"Interpolated paper-recommended |t|-threshold: {TH_paper:.4f}\")\n",
    "print(f\"Number of leaky points above threshold: {np.sum(leaky_points)}\")\n",
    "\n"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "id": "34fa0374-6028-43fc-b851-d062f7b1d635",
   "metadata": {},
   "outputs": [],
   "source": []
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3 (ipykernel)",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.9.5"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 5
}
