This commit is contained in:
2025-09-18 17:11:38 +03:00
commit b0c9a05db7
127 changed files with 268753 additions and 0 deletions

BIN
1 Normal file

Binary file not shown.

0
![[AD7686.pdf]].md Normal file
View File

51
0x1111_descrtxt.txt Normal file
View File

@ -0,0 +1,51 @@
Структура команды 0х1111 в результате удаления табличных значений тока
претерпела изменения.
Изначально размер комнады был 426 байт (или 213 16-ти битных слов), после удаления табличных значений
структура команды выглядит следующим образом:
|-------|------------|-------------|--------------------------------------|
| Номер | Название | Код | Расшифровка |
| слова | | | |
|-------|------------|-------------|--------------------------------------|
| 0 | Header | 0x1111 | Заголовок |
| 1 | Setup | 0xXXXX | Биты настроек |
| 2 | LD1_temp | 16bit float | Температура лазера 1 |
| 3 | LD2_temp | 16bit float | Температура лазера 1 |
| 4 | Reserved | 0x0000 | Зарезервировано |
| 5 | Reserved | 0x0000 | Зарезервировано |
| 6 | Reserved | 0x0000 | Зарезервировано |
| 7 | P_temp1 | 16bit float | Пропорциональный коэффициент для ЛМ1 |
| 8 | I_temp1 | 16bit float | Интегальный коэффициент для ЛМ1 |
| 9 | P_temp2 | 16bit float | Пропорциональный коэффициент для ЛМ2 |
| 10 | I_temp2 | 16bit float | Интегальный коэффициент для ЛМ2 |
| 11 | Message_ID | 16bit uint | Номер сообщения |
| 12 | LD1_curr | 16bit float | Ток лазера 1 |
| 13 | LD2_curr | 16bit float | Ток лазера 2 |
| 14 | CRC | 16bit uint | Контрольная сумма |
|-------|------------|-------------|--------------------------------------|
Таким образом размер команды 0x1111 теперь -- 30 байт (или 15 16-ти битных слов).
Команда TRANS_ENABLE так же изменилась:
|-------|------------|-------------|----------------------------------------------------------------------------------------------------------|
| Номер | Название | Код | Расшифровка |
| слова | | | |
|-------|------------|-------------|----------------------------------------------------------------------------------------------------------|
| 0 | Header | 0x1111 | Заголовок |
| 1 | P_1 | 16bit float | Фототок мониторного фотодиода ЛМ1 |
| 2 | P_2 | 16bit float | Фототок мониторного фотодиода ЛМ2 |
| 3 | TO_LSB | 16bit uint | Основной таймер (младшие два байта) |
| 4 | TO_MSB | 16bit uint | Основной таймер (старшие два байта) |
| 5 | T_LM1 | 16bit uint | Температура ЛМ1 |
| 6 | T_LM2 | 16bit uint | Температура ЛМ2 |
| 7 | T_EXT1 | 16bit uint | Температура 1-го внешнего термистора |
| 8 | T_EXT2 | 16bit uint | Температура 2-го внешнего термистора |
| 9 | 3V3MON | 16bit uint | Напряжение 3,3 В |
| 10 | 5V1MON | 16bit uint | Напряжение питания драйверов Пельтье и внешних датчиков температуры |
| 11 | 5V2MON | 16bit uint | Напряжение питания драйверов тока лазера, внутренних датчиков температуры, усилителей мониторного канала |
| 12 | 7V0MON | 16bit uint | Входное напряжение питания |
| 13 | Message_ID | 16bit uint | Номер сообщения |
| 14 | CRC | 16bit uint | Контрольная сумма |
|-------|------------|-------------|----------------------------------------------------------------------------------------------------------|

28
0x7777_task_command.txt Normal file
View File

@ -0,0 +1,28 @@
|-------|-------------|-------------|--------------------------------------------------------------|
| Номер | Название | Код | Расшифровка |
| слова | | | |
|-------|-------------|-------------|--------------------------------------------------------------|
| 0 | Header | 0x7777 | Заголовок |
| 1 | Setup | 0xXXXX | Биты настроек (как в 0х1111) |
| 2 | TaskType | 16bit uint | 0х1 -- меняется ток лазера 1 |
| | | | 0х2 -- меняется ток лазера 2 |
| | | | 0х3 -- меняется температура лазера 1 |
| | | | 0х4 -- меняется температура лазера 2 |
| 3 | chngd_p_min | 16bit uint | Минимальное значение изменяемого параметра (mA или C) |
| 4 | chngd_p_max | 16bit uint | Максимальное значение изменяемого параметра (mA или C) |
| 5 | delta_p | 16bit uint | Шаг дискретизации изменяемого параметра (mA или C) |
| 6 | delta_t | 16bit uint | Дискретныфй шаг по времени (мкс) |
| 7 | fixed_param | 16bit uint | Значение другого параметра лазера с изменяемым параметром |
| 8 | I_fixed | 16bit uint | Значение тока для лазера с фиксированными параметрами |
| 9 | T_fixed | 16bit uint | Значение температуры для лазера с фиксированными параметрами |
| 10 | Tau | 16bit uint | Значение тау (время релаксации, миллисекунды) |
| 11 | P_temp1 | 16bit float | Пропорциональный коэффициент для ЛМ1 |
| 12 | I_temp1 | 16bit float | Интегальный коэффициент для ЛМ1 |
| 13 | P_temp2 | 16bit float | Пропорциональный коэффициент для ЛМ2 |
| 14 | I_temp2 | 16bit float | Интегальный коэффициент для ЛМ2 |
| 15 | CRC | 16bit uint | Контрольная сумма |
|-------|-------------|-------------|--------------------------------------------------------------|
Таким образом размер команды 0x7777 теперь -- 32 байт (или 15 16-ти битных слов).

Binary file not shown.

Binary file not shown.

BIN
AD7686 1.pdf Normal file

Binary file not shown.

BIN
AD7686 2.pdf Normal file

Binary file not shown.

BIN
AD7686.pdf Normal file

Binary file not shown.

BIN
AD8571.pdf Normal file

Binary file not shown.

BIN
AD8655_8656.pdf Normal file

Binary file not shown.

78
ADC_software-hardware.md Normal file
View File

@ -0,0 +1,78 @@
## problems
[[баг с размещением большого буфера не в тот регион памяти]]
## hardware
подключение
(OUT_10) -- ADC_clock -> DI_SYN1
Фазы обеих клоков будем обнулять в начале цикла ЛЧМ.
#### BP9 (OUT_11) -- Modulation -> Mach-Zander
TIM11_CH1
Тактирование от APB2 (184 MHz). Желаемая частота -- 1 МГц. => Prescaler =1, ARR = 91, OCR1=22
Подключим его через драйвер к модулятору Маха-Цандера.
#### BP8 (OUT_10) -- ADC_clock -> DI_SYN1
TIM4_CH3
Тактирование от APB1 (92 MHz). Желаемая частота -- 2 МГц. => Prescaler = 0, ARR = 45, OCR3=22
Подключим его к DI_SYN1.
#### PD7 (TASK_TRG) -- trigger -> DI_SYN2
![[Pasted image 20250711184438.png]]
![[Pasted image 20250711184407.png]]
## software
1. После перенастройки модуля надо сбрасывать приемный буфер на ПК. Сейчас сброс через полное вычитывание данных вникуда.
Логическая таблица задает порядок опроса и параметры опрашиваемых физических каналов. Данные с физических каналов затем поступают по SPORT0 в порядке опроса.
Алгоритм работы:
1. Приняли команду о начале работы (напр. усреднение) с ПК. Настроили state machine.
2. Обработка данных
3. Отправка данных hdma_send_req_start(). Поднимается флаг **"данные отправляются, передающий буффер занят"**
4. При окончании отправки вызывается обработчик hdma_send_done(), в котором сбрасываем флаг **"данные отправляются, передающий буффер занят"**
Вернул ПО blackfin в оригинальное состояние (git checkout). Bf не возвращает данные. При попытке запуска через x502studio -- возникает ошибка с каналами:
![[Pasted image 20250916221016.png]]
Причем если подключить ноут к сети, то вылетает быстрее.
Однажды перед вылетом была получена такая картина:
![[Pasted image 20250916220932.png]]
Подключение -- syn1 (тактирование АПЦ), syn2 (запуск), X1 -- сигнал (треугольник). Видно, что в процессе поменялись местами каналы 1 и 2. WTF?
Настройки:
![[Pasted image 20250916221400.png]]
Проблема воспроизводима: ![[Pasted image 20250916221611.png]]
![[Pasted image 20250916221856.png]]
Воспроизведение:
| ошибка | sync freq mode | sync start mode | пр. условия | |
| ------ | -------------------------- | --------------- | -------------------------------------------------------------------------- | ---------------------------------------------- |
| да | syn1 rise | syn2 rise | | |
| да | syn1 rise | internal | | |
| нет | internal | internal | | |
| нет | int | syn1 rise | | |
| нет | syn2 rise (низкая частота) | int | | |
| да | syn2 rise (ВЧ) (F>0.5 MHz) | int | | F=730 kHz ![[Pasted image 20250917153156.png]] |
| да | syn2 rise (ВЧ) (F=730 kHz) | int | вход канала 2 -- заземлен (внутренне):![[Pasted image 20250917161724.png]] | ![[Pasted image 20250917161645.png]] |
Эксперимент:
1. 1 канал подключен к генератору с треугольным сигналом
2. 2,3,4,5 каналы -- заземлены (внешне проводами к GND32)
результат:
3. sync start mode -- internal
| | sync freq mode | результат | |
| ------------------------------------------------ | -------------- | ------------------------------------------------------------------ | ---------------------------------------------------- |
| | INTernal | всё ОК | |
| | SYN1_RISE | каналы 1-5 путаются. Ранее аналогично путались и все другие каналы | ![[Pasted image 20250917193217.png]]![[newplot.png]] |
| после промежутка времени (неизвестное событие?): | то же | каналы перестали путаться. Большие помехи | ![[Pasted image 20250917193401.png]] |
| | INTernal | всё ОК | ![[newplot(1).png]] |
| | SYN2_RISE | ОК | ![[Pasted image 20250917193951.png]] |
| | SYN1_RISE | | ![[Pasted image 20250917194104.png]] |
| | SYN1_FALL | | ![[Pasted image 20250917194134.png]] |

36
Bit Setting in C.md Normal file
View File

@ -0,0 +1,36 @@
#### Setting a bit
Use the bitwise OR operator ( | ) to set a bit.
```c
number |= 1 << x;
```
That will set bit x.
#### Clearing a bit
Use the bitwise AND operator (&) to clear a bit.
```c
number &= ~(1 << x);
```
That will clear bit x. You must invert the bit string with the bitwise NOT operator (~), then AND it.
#### Toggling a bit
The XOR operator (^) can be used to toggle a bit.
```c
number ^= 1 << x;
```
That will toggle bit x.
### Checking a bit
To check a bit, shift the number x to the right, then bitwise AND it:
```c
bit = (number >> x) & 1;
```
That will put the value of bit x into the variable bit.
#### Changing the nth bit to x
Setting the nth bit to either 1 or 0 can be achieved with the following:
```c
number ^= (-x ^ number) & (1 << n);
```
Bit n will be set if x is 1, and cleared if x is 0.

File diff suppressed because one or more lines are too long

View File

@ -0,0 +1,2 @@
<html><head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8"><script>window.__CF$cv$params={r:'9611ac95dcba48d2',t:'MTc1MjgzODUxMS4wMDAwMDA='};var a=document.createElement('script');a.nonce='582b130f-281b-40ed-a5b1-c830c3300d60';a.src='/cdn-cgi/challenge-platform/scripts/jsd/main.js';document.getElementsByTagName('head')[0].appendChild(a);</script><script src="a_data/main.js"></script></head><body></body></html>

File diff suppressed because one or more lines are too long

View File

@ -0,0 +1 @@
._codemirror_176lt_1 .cm-editor{border:none;border-radius:0;flex:1;font-size:14px}._codemirror_176lt_1 .cm-scroller{scrollbar-color:var(--main-surface-tertiary) transparent}._codemirror_176lt_1 .cm-scroller:hover{scrollbar-color:var(--gray-200) transparent}.dark ._codemirror_176lt_1 .cm-scroller:hover{scrollbar-color:var(--gray-600) transparent}._codemirror_176lt_1 .cm-focused{outline:none}._codemirror_176lt_1._preview_176lt_26 .cm-content{padding:1rem 0 2rem!important}._codemirror_176lt_1:not(._preview_176lt_26) .cm-content{padding:1rem 0 50vh!important}._codemirror_176lt_1 .cm-activeLineGutter{background-color:var(--bg-primary)}._codemirror_176lt_1 .cm-gutters{background-color:transparent;color:var(--text-quaternary)}[dir=ltr] ._codemirror_176lt_1 .cm-gutters{border-right:none;padding-left:12px;padding-right:2px}[dir=rtl] ._codemirror_176lt_1 .cm-gutters{border-left:none;padding-left:2px;padding-right:12px}[dir=ltr] ._codemirror_176lt_1 .cm-gutters .cm-lineNumbers{padding-right:0}[dir=rtl] ._codemirror_176lt_1 .cm-gutters .cm-lineNumbers{padding-left:0}._codemirror_176lt_1 .cm-foldGutter .cm-gutterElement{align-items:center;display:flex;justify-content:center}._codemirror_176lt_1 .cm-line.streaming-line-overlay{position:relative}._codemirror_176lt_1 .cm-line.streaming-line-overlay:before{content:"";height:100%;pointer-events:none;position:absolute;top:0;width:100%;z-index:1}[dir=ltr] ._codemirror_176lt_1 .cm-line.streaming-line-overlay:before{left:0}[dir=rtl] ._codemirror_176lt_1 .cm-line.streaming-line-overlay:before{right:0}._codemirror_176lt_1 .cm-deletedChunk del{text-decoration:none}

View File

@ -0,0 +1 @@
._modelCursor_1knkf_1{display:inline-block;height:0;position:relative;width:0}._modelCursor_1knkf_1:after{content:none}

File diff suppressed because one or more lines are too long

View File

@ -0,0 +1 @@
@keyframes fade-in{0%{opacity:0}to{opacity:1}}.teleprompter{overflow:visible;position:relative}.teleprompter-inner{align-content:flex-start;display:flex;flex-wrap:wrap;inset:0;position:absolute}.teleprompter-word{animation:fade-in var(--fade,.5s) cubic-bezier(.37,.55,.86,.88) forwards;opacity:0;white-space:pre}@keyframes dot-fade{0%,to{opacity:.5}50%{opacity:1}}.animate-dot-fade{animation:dot-fade 1s ease-in-out infinite}

View File

@ -0,0 +1 @@
._override-strong-color_y6grp_1 strong{color:inherit!important}._main_5jn6z_1.ProseMirror li p{margin:0}._main_5jn6z_1.ProseMirror:focus-visible{outline:none}._main_5jn6z_1.ProseMirror .ProseMirror-separator{display:none}._main_5jn6z_1.ProseMirror td p,._main_5jn6z_1.ProseMirror th p{margin:0}[dir=ltr] ._main_5jn6z_1.ProseMirror td{padding-left:.75rem}[dir=rtl] ._main_5jn6z_1.ProseMirror td{padding-right:.75rem}._main_5jn6z_1.ProseMirror h1,._main_5jn6z_1.ProseMirror h2,._main_5jn6z_1.ProseMirror h3{line-height:normal}._main_5jn6z_1.ProseMirror p .selection-highlight{padding-bottom:.28em;padding-top:.28em}._main_5jn6z_1.ProseMirror pre:has(>code){border-radius:4px;font-size:1rem;line-height:1.4;padding-bottom:calc(.5rem + 4px);padding-top:calc(.5rem + 4px)}[dir=ltr] ._main_5jn6z_1.ProseMirror pre:has(>code){padding-left:calc(.5rem + 6px);padding-right:calc(.5rem + 2px)}[dir=rtl] ._main_5jn6z_1.ProseMirror pre:has(>code){padding-left:calc(.5rem + 2px);padding-right:calc(.5rem + 6px)}._main_5jn6z_1.ProseMirror:is(.dark *) pre:has(>code){background-color:#1e1e1e}._main_5jn6z_1.ProseMirror:not(.dark *) pre:has(>code){background-color:var(--main-surface-secondary)}

File diff suppressed because one or more lines are too long

Binary file not shown.

BIN
Mach-Zander_driver.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 727 KiB

263972
Mach-Zander_voltage_plot.html Normal file

File diff suppressed because one or more lines are too long

BIN
Mach-Zehnder modulator.pdf Normal file

Binary file not shown.

Binary file not shown.

After

Width:  |  Height:  |  Size: 100 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 201 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 99 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.4 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 43 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 308 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 89 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 74 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 81 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 316 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 39 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 257 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 438 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 300 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 312 KiB

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 292 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 255 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 178 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 178 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 278 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 208 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 290 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 140 KiB

BIN
R31c (aka REF31xx).pdf Normal file

Binary file not shown.

BIN
RigolDS0 1.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 135 KiB

BIN
RigolDS0 2.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 86 KiB

BIN
RigolDS0.bmp Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 MiB

BIN
RigolDS0.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 124 KiB

BIN
RigolDS1 1.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 106 KiB

BIN
RigolDS1.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 103 KiB

BIN
RigolDS10.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 98 KiB

BIN
RigolDS11.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 98 KiB

BIN
RigolDS12.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 99 KiB

BIN
RigolDS13.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 99 KiB

BIN
RigolDS14.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 98 KiB

BIN
RigolDS16.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 67 KiB

BIN
RigolDS17.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 66 KiB

BIN
RigolDS2 1.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 91 KiB

BIN
RigolDS2.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 115 KiB

BIN
RigolDS20.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 84 KiB

BIN
RigolDS23.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 179 KiB

BIN
RigolDS24.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 158 KiB

BIN
RigolDS25.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 136 KiB

BIN
RigolDS26.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 99 KiB

BIN
RigolDS3.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 81 KiB

BIN
RigolDS4.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 90 KiB

BIN
RigolDS5 1.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 74 KiB

BIN
RigolDS5.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 94 KiB

BIN
RigolDS6 1.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 73 KiB

BIN
RigolDS6.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 153 KiB

BIN
RigolDS7.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 114 KiB

BIN
RigolDS8 1.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 63 KiB

BIN
RigolDS8.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 153 KiB

BIN
RigolDS9 1.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 100 KiB

BIN
RigolDS9.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 76 KiB

BIN
TPH2501_GBW_120M.pdf Normal file

Binary file not shown.

View File

@ -0,0 +1,6 @@
#
## Проблема
## Анализ
## Решение

0
Untitled.md Normal file
View File

BIN
Upper_layer_described.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 MiB

6
Welcome.md Normal file
View File

@ -0,0 +1,6 @@
[[Железо]]
[[Задачи]]
[[анализ кода for_stm32_cubeide]]
[[код for_stm32_2023_12_08]]
[[Кодовая база]]
[[laser diode module]]

BIN
ad5541a.pdf Normal file

Binary file not shown.

BIN
ad623.pdf Normal file

Binary file not shown.

Some files were not shown because too many files have changed in this diff Show More