2024-05-13 16:40:39 +02:00
|
|
|
|
ARM GAS C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s page 1
|
2024-05-12 14:08:58 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 .cpu cortex-m4
|
|
|
|
|
2 .arch armv7e-m
|
|
|
|
|
3 .fpu fpv4-sp-d16
|
|
|
|
|
4 .eabi_attribute 27, 1
|
|
|
|
|
5 .eabi_attribute 28, 1
|
|
|
|
|
6 .eabi_attribute 20, 1
|
|
|
|
|
7 .eabi_attribute 21, 1
|
|
|
|
|
8 .eabi_attribute 23, 3
|
|
|
|
|
9 .eabi_attribute 24, 1
|
|
|
|
|
10 .eabi_attribute 25, 1
|
|
|
|
|
11 .eabi_attribute 26, 1
|
|
|
|
|
12 .eabi_attribute 30, 1
|
|
|
|
|
13 .eabi_attribute 34, 1
|
|
|
|
|
14 .eabi_attribute 18, 4
|
|
|
|
|
15 .file "PCA9535D_Driver.c"
|
|
|
|
|
16 .text
|
|
|
|
|
17 .Ltext0:
|
|
|
|
|
18 .cfi_sections .debug_frame
|
|
|
|
|
19 .file 1 "Core/Src/PCA9535D_Driver.c"
|
|
|
|
|
20 .section .text.PCA9535_init,"ax",%progbits
|
|
|
|
|
21 .align 1
|
|
|
|
|
22 .global PCA9535_init
|
|
|
|
|
23 .syntax unified
|
|
|
|
|
24 .thumb
|
|
|
|
|
25 .thumb_func
|
|
|
|
|
27 PCA9535_init:
|
|
|
|
|
28 .LVL0:
|
|
|
|
|
29 .LFB130:
|
|
|
|
|
1:Core/Src/PCA9535D_Driver.c **** /**
|
|
|
|
|
2:Core/Src/PCA9535D_Driver.c **** * @file PCA9535D_Driver.c
|
|
|
|
|
3:Core/Src/PCA9535D_Driver.c **** *
|
|
|
|
|
4:Core/Src/PCA9535D_Driver.c **** * Driver Software for the PCA9535D Port exteneder Peripheral
|
|
|
|
|
5:Core/Src/PCA9535D_Driver.c **** *
|
|
|
|
|
6:Core/Src/PCA9535D_Driver.c **** * @author Maximilian Mönikes
|
|
|
|
|
7:Core/Src/PCA9535D_Driver.c **** */
|
|
|
|
|
8:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
9:Core/Src/PCA9535D_Driver.c **** #include "PCA9535D_Driver.h"
|
|
|
|
|
10:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
11:Core/Src/PCA9535D_Driver.c **** static I2C_HandleTypeDef* pcai2c;
|
|
|
|
|
12:Core/Src/PCA9535D_Driver.c **** static uint8_t deviceadr = 0;
|
|
|
|
|
13:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
14:Core/Src/PCA9535D_Driver.c **** static uint8_t gpioa_shadow_reg_out = 0;
|
|
|
|
|
15:Core/Src/PCA9535D_Driver.c **** static uint8_t gpiob_shadow_reg_out = 0;
|
|
|
|
|
16:Core/Src/PCA9535D_Driver.c **** static uint8_t gpioa_shadow_reg_dir = 0xFF;
|
|
|
|
|
17:Core/Src/PCA9535D_Driver.c **** static uint8_t gpiob_shadow_reg_dir = 0xFF;
|
|
|
|
|
18:Core/Src/PCA9535D_Driver.c **** static uint8_t gpioa_shadow_reg_inv = 0;
|
|
|
|
|
19:Core/Src/PCA9535D_Driver.c **** static uint8_t gpiob_shadow_reg_inv = 0;
|
|
|
|
|
20:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
21:Core/Src/PCA9535D_Driver.c **** /**@brief Initalize the PCA9535 Port extender
|
|
|
|
|
22:Core/Src/PCA9535D_Driver.c **** *
|
|
|
|
|
23:Core/Src/PCA9535D_Driver.c **** * All GPIOs are Initialized as Inputs with normal Polarity
|
|
|
|
|
24:Core/Src/PCA9535D_Driver.c **** *
|
|
|
|
|
25:Core/Src/PCA9535D_Driver.c **** * @param hi2c Pointer to I2C Handle struct for the peripheral in
|
|
|
|
|
26:Core/Src/PCA9535D_Driver.c **** * @param subaddress of the port expander
|
|
|
|
|
27:Core/Src/PCA9535D_Driver.c **** * @retval none
|
|
|
|
|
28:Core/Src/PCA9535D_Driver.c **** */
|
|
|
|
|
29:Core/Src/PCA9535D_Driver.c ****
|
2024-05-13 16:40:39 +02:00
|
|
|
|
ARM GAS C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s page 2
|
2024-05-12 14:08:58 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
30:Core/Src/PCA9535D_Driver.c **** void PCA9535_init(I2C_HandleTypeDef* hi2c, uint8_t subadr) {
|
|
|
|
|
30 .loc 1 30 60 view -0
|
|
|
|
|
31 .cfi_startproc
|
|
|
|
|
32 @ args = 0, pretend = 0, frame = 8
|
|
|
|
|
33 @ frame_needed = 0, uses_anonymous_args = 0
|
|
|
|
|
34 .loc 1 30 60 is_stmt 0 view .LVU1
|
|
|
|
|
35 0000 10B5 push {r4, lr}
|
|
|
|
|
36 .cfi_def_cfa_offset 8
|
|
|
|
|
37 .cfi_offset 4, -8
|
|
|
|
|
38 .cfi_offset 14, -4
|
|
|
|
|
39 0002 84B0 sub sp, sp, #16
|
|
|
|
|
40 .cfi_def_cfa_offset 24
|
|
|
|
|
41 0004 0446 mov r4, r0
|
|
|
|
|
31:Core/Src/PCA9535D_Driver.c **** pcai2c = hi2c;
|
|
|
|
|
42 .loc 1 31 3 is_stmt 1 view .LVU2
|
|
|
|
|
43 .loc 1 31 10 is_stmt 0 view .LVU3
|
|
|
|
|
44 0006 0F4B ldr r3, .L3
|
|
|
|
|
45 0008 1860 str r0, [r3]
|
|
|
|
|
32:Core/Src/PCA9535D_Driver.c **** deviceadr = PCA_I2C_BASE_ADDRESS | (subadr << 1);
|
|
|
|
|
46 .loc 1 32 3 is_stmt 1 view .LVU4
|
|
|
|
|
47 .loc 1 32 46 is_stmt 0 view .LVU5
|
|
|
|
|
48 000a 4FEA410C lsl ip, r1, #1
|
|
|
|
|
49 .loc 1 32 36 view .LVU6
|
|
|
|
|
50 000e 4CF0400C orr ip, ip, #64
|
|
|
|
|
51 0012 5FFA8CFC uxtb ip, ip
|
|
|
|
|
52 .loc 1 32 13 view .LVU7
|
|
|
|
|
53 0016 0C4B ldr r3, .L3+4
|
|
|
|
|
54 0018 83F800C0 strb ip, [r3]
|
|
|
|
|
33:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
34:Core/Src/PCA9535D_Driver.c **** uint8_t initalizationconfig[7] = {0x02, 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF};
|
|
|
|
|
55 .loc 1 34 3 is_stmt 1 view .LVU8
|
|
|
|
|
56 .loc 1 34 11 is_stmt 0 view .LVU9
|
|
|
|
|
57 001c 0B4B ldr r3, .L3+8
|
|
|
|
|
58 001e 93E80300 ldm r3, {r0, r1}
|
|
|
|
|
59 .LVL1:
|
|
|
|
|
60 .loc 1 34 11 view .LVU10
|
|
|
|
|
61 0022 0290 str r0, [sp, #8]
|
|
|
|
|
62 0024 ADF80C10 strh r1, [sp, #12] @ movhi
|
|
|
|
|
63 0028 090C lsrs r1, r1, #16
|
|
|
|
|
64 002a 8DF80E10 strb r1, [sp, #14]
|
|
|
|
|
35:Core/Src/PCA9535D_Driver.c **** HAL_I2C_Master_Transmit(pcai2c, deviceadr, initalizationconfig, 7, 1000);
|
|
|
|
|
65 .loc 1 35 3 is_stmt 1 view .LVU11
|
|
|
|
|
66 002e 4FF47A73 mov r3, #1000
|
|
|
|
|
67 0032 0093 str r3, [sp]
|
|
|
|
|
68 0034 0723 movs r3, #7
|
|
|
|
|
69 0036 02AA add r2, sp, #8
|
|
|
|
|
70 0038 6146 mov r1, ip
|
|
|
|
|
71 003a 2046 mov r0, r4
|
|
|
|
|
72 003c FFF7FEFF bl HAL_I2C_Master_Transmit
|
|
|
|
|
73 .LVL2:
|
|
|
|
|
36:Core/Src/PCA9535D_Driver.c **** }
|
|
|
|
|
74 .loc 1 36 1 is_stmt 0 view .LVU12
|
|
|
|
|
75 0040 04B0 add sp, sp, #16
|
|
|
|
|
76 .cfi_def_cfa_offset 8
|
|
|
|
|
77 @ sp needed
|
|
|
|
|
78 0042 10BD pop {r4, pc}
|
|
|
|
|
79 .LVL3:
|
2024-05-13 16:40:39 +02:00
|
|
|
|
ARM GAS C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s page 3
|
2024-05-12 14:08:58 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
80 .L4:
|
|
|
|
|
81 .loc 1 36 1 view .LVU13
|
|
|
|
|
82 .align 2
|
|
|
|
|
83 .L3:
|
|
|
|
|
84 0044 00000000 .word pcai2c
|
|
|
|
|
85 0048 00000000 .word deviceadr
|
|
|
|
|
86 004c 00000000 .word .LANCHOR0
|
|
|
|
|
87 .cfi_endproc
|
|
|
|
|
88 .LFE130:
|
|
|
|
|
90 .section .text.PCA9535_setGPIOPinDirection,"ax",%progbits
|
|
|
|
|
91 .align 1
|
|
|
|
|
92 .global PCA9535_setGPIOPinDirection
|
|
|
|
|
93 .syntax unified
|
|
|
|
|
94 .thumb
|
|
|
|
|
95 .thumb_func
|
|
|
|
|
97 PCA9535_setGPIOPinDirection:
|
|
|
|
|
98 .LVL4:
|
|
|
|
|
99 .LFB131:
|
|
|
|
|
37:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
38:Core/Src/PCA9535D_Driver.c **** void PCA9535_setGPIOPinDirection(uint8_t Port, uint8_t pin, uint8_t state) {
|
|
|
|
|
100 .loc 1 38 76 is_stmt 1 view -0
|
|
|
|
|
101 .cfi_startproc
|
|
|
|
|
102 @ args = 0, pretend = 0, frame = 8
|
|
|
|
|
103 @ frame_needed = 0, uses_anonymous_args = 0
|
|
|
|
|
104 .loc 1 38 76 is_stmt 0 view .LVU15
|
|
|
|
|
105 0000 00B5 push {lr}
|
|
|
|
|
106 .cfi_def_cfa_offset 4
|
|
|
|
|
107 .cfi_offset 14, -4
|
|
|
|
|
108 0002 85B0 sub sp, sp, #20
|
|
|
|
|
109 .cfi_def_cfa_offset 24
|
|
|
|
|
39:Core/Src/PCA9535D_Driver.c **** if (Port == PC9535_PORTA) {
|
|
|
|
|
110 .loc 1 39 3 is_stmt 1 view .LVU16
|
|
|
|
|
111 .loc 1 39 6 is_stmt 0 view .LVU17
|
|
|
|
|
112 0004 20BB cbnz r0, .L6
|
|
|
|
|
113 .LBB2:
|
|
|
|
|
40:Core/Src/PCA9535D_Driver.c **** if (state)
|
|
|
|
|
114 .loc 1 40 5 is_stmt 1 view .LVU18
|
|
|
|
|
115 .loc 1 40 8 is_stmt 0 view .LVU19
|
|
|
|
|
116 0006 D2B1 cbz r2, .L7
|
|
|
|
|
41:Core/Src/PCA9535D_Driver.c **** gpioa_shadow_reg_dir |= (1 << pin);
|
|
|
|
|
117 .loc 1 41 7 is_stmt 1 view .LVU20
|
|
|
|
|
118 .loc 1 41 34 is_stmt 0 view .LVU21
|
|
|
|
|
119 0008 0122 movs r2, #1
|
|
|
|
|
120 .LVL5:
|
|
|
|
|
121 .loc 1 41 34 view .LVU22
|
|
|
|
|
122 000a 8A40 lsls r2, r2, r1
|
|
|
|
|
123 .loc 1 41 28 view .LVU23
|
|
|
|
|
124 000c 2349 ldr r1, .L13
|
|
|
|
|
125 .LVL6:
|
|
|
|
|
126 .loc 1 41 28 view .LVU24
|
|
|
|
|
127 000e 0B78 ldrb r3, [r1] @ zero_extendqisi2
|
|
|
|
|
128 0010 1343 orrs r3, r3, r2
|
|
|
|
|
129 0012 0B70 strb r3, [r1]
|
|
|
|
|
130 .L8:
|
|
|
|
|
42:Core/Src/PCA9535D_Driver.c **** else
|
|
|
|
|
43:Core/Src/PCA9535D_Driver.c **** gpioa_shadow_reg_dir &= ~(1 << pin);
|
|
|
|
|
44:Core/Src/PCA9535D_Driver.c ****
|
2024-05-13 16:40:39 +02:00
|
|
|
|
ARM GAS C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s page 4
|
2024-05-12 14:08:58 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
45:Core/Src/PCA9535D_Driver.c **** uint8_t data[2] = {CONFIGURATION_REG_BASE_ADDRESS, gpioa_shadow_reg_dir};
|
|
|
|
|
131 .loc 1 45 5 is_stmt 1 view .LVU25
|
|
|
|
|
132 .loc 1 45 13 is_stmt 0 view .LVU26
|
|
|
|
|
133 0014 0623 movs r3, #6
|
|
|
|
|
134 0016 8DF80C30 strb r3, [sp, #12]
|
|
|
|
|
135 001a 204B ldr r3, .L13
|
|
|
|
|
136 001c 1B78 ldrb r3, [r3] @ zero_extendqisi2
|
|
|
|
|
137 001e 8DF80D30 strb r3, [sp, #13]
|
|
|
|
|
46:Core/Src/PCA9535D_Driver.c **** HAL_I2C_Master_Transmit(pcai2c, deviceadr, data, 2, 1000);
|
|
|
|
|
138 .loc 1 46 5 is_stmt 1 view .LVU27
|
|
|
|
|
139 0022 4FF47A73 mov r3, #1000
|
|
|
|
|
140 0026 0093 str r3, [sp]
|
|
|
|
|
141 0028 0223 movs r3, #2
|
|
|
|
|
142 002a 03AA add r2, sp, #12
|
|
|
|
|
143 002c 1C49 ldr r1, .L13+4
|
|
|
|
|
144 002e 0978 ldrb r1, [r1] @ zero_extendqisi2
|
|
|
|
|
145 0030 1C48 ldr r0, .L13+8
|
|
|
|
|
146 .LVL7:
|
|
|
|
|
147 .loc 1 46 5 is_stmt 0 view .LVU28
|
|
|
|
|
148 0032 0068 ldr r0, [r0]
|
|
|
|
|
149 0034 FFF7FEFF bl HAL_I2C_Master_Transmit
|
|
|
|
|
150 .LVL8:
|
|
|
|
|
151 .L5:
|
|
|
|
|
152 .LBE2:
|
|
|
|
|
47:Core/Src/PCA9535D_Driver.c **** } else if (Port == PC9535_PORTB) {
|
|
|
|
|
48:Core/Src/PCA9535D_Driver.c **** if (state)
|
|
|
|
|
49:Core/Src/PCA9535D_Driver.c **** gpiob_shadow_reg_dir |= (1 << pin);
|
|
|
|
|
50:Core/Src/PCA9535D_Driver.c **** else
|
|
|
|
|
51:Core/Src/PCA9535D_Driver.c **** gpiob_shadow_reg_dir &= ~(1 << pin);
|
|
|
|
|
52:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
53:Core/Src/PCA9535D_Driver.c **** uint8_t data[2] = {CONFIGURATION_REG_BASE_ADDRESS | 1,
|
|
|
|
|
54:Core/Src/PCA9535D_Driver.c **** gpiob_shadow_reg_dir};
|
|
|
|
|
55:Core/Src/PCA9535D_Driver.c **** HAL_I2C_Master_Transmit(pcai2c, deviceadr, data, 2, 1000);
|
|
|
|
|
56:Core/Src/PCA9535D_Driver.c **** }
|
|
|
|
|
57:Core/Src/PCA9535D_Driver.c **** }
|
|
|
|
|
153 .loc 1 57 1 view .LVU29
|
|
|
|
|
154 0038 05B0 add sp, sp, #20
|
|
|
|
|
155 .cfi_remember_state
|
|
|
|
|
156 .cfi_def_cfa_offset 4
|
|
|
|
|
157 @ sp needed
|
|
|
|
|
158 003a 5DF804FB ldr pc, [sp], #4
|
|
|
|
|
159 .LVL9:
|
|
|
|
|
160 .L7:
|
|
|
|
|
161 .cfi_restore_state
|
|
|
|
|
162 .LBB3:
|
|
|
|
|
43:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
163 .loc 1 43 7 is_stmt 1 view .LVU30
|
|
|
|
|
43:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
164 .loc 1 43 35 is_stmt 0 view .LVU31
|
|
|
|
|
165 003e 0123 movs r3, #1
|
|
|
|
|
166 0040 8B40 lsls r3, r3, r1
|
|
|
|
|
43:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
167 .loc 1 43 28 view .LVU32
|
|
|
|
|
168 0042 DB43 mvns r3, r3
|
|
|
|
|
169 0044 5BB2 sxtb r3, r3
|
|
|
|
|
170 0046 1549 ldr r1, .L13
|
|
|
|
|
171 .LVL10:
|
2024-05-13 16:40:39 +02:00
|
|
|
|
ARM GAS C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s page 5
|
2024-05-12 14:08:58 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
43:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
172 .loc 1 43 28 view .LVU33
|
|
|
|
|
173 0048 0A78 ldrb r2, [r1] @ zero_extendqisi2
|
|
|
|
|
174 .LVL11:
|
|
|
|
|
43:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
175 .loc 1 43 28 view .LVU34
|
|
|
|
|
176 004a 1340 ands r3, r3, r2
|
|
|
|
|
177 004c 0B70 strb r3, [r1]
|
|
|
|
|
178 004e E1E7 b .L8
|
|
|
|
|
179 .LVL12:
|
|
|
|
|
180 .L6:
|
|
|
|
|
43:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
181 .loc 1 43 28 view .LVU35
|
|
|
|
|
182 .LBE3:
|
|
|
|
|
47:Core/Src/PCA9535D_Driver.c **** } else if (Port == PC9535_PORTB) {
|
|
|
|
|
183 .loc 1 47 10 is_stmt 1 view .LVU36
|
|
|
|
|
47:Core/Src/PCA9535D_Driver.c **** } else if (Port == PC9535_PORTB) {
|
|
|
|
|
184 .loc 1 47 13 is_stmt 0 view .LVU37
|
|
|
|
|
185 0050 0128 cmp r0, #1
|
|
|
|
|
186 0052 F1D1 bne .L5
|
|
|
|
|
187 .LBB4:
|
|
|
|
|
48:Core/Src/PCA9535D_Driver.c **** gpiob_shadow_reg_dir |= (1 << pin);
|
|
|
|
|
188 .loc 1 48 5 is_stmt 1 view .LVU38
|
|
|
|
|
48:Core/Src/PCA9535D_Driver.c **** gpiob_shadow_reg_dir |= (1 << pin);
|
|
|
|
|
189 .loc 1 48 8 is_stmt 0 view .LVU39
|
|
|
|
|
190 0054 C2B1 cbz r2, .L10
|
|
|
|
|
49:Core/Src/PCA9535D_Driver.c **** else
|
|
|
|
|
191 .loc 1 49 7 is_stmt 1 view .LVU40
|
|
|
|
|
49:Core/Src/PCA9535D_Driver.c **** else
|
|
|
|
|
192 .loc 1 49 34 is_stmt 0 view .LVU41
|
|
|
|
|
193 0056 0122 movs r2, #1
|
|
|
|
|
194 .LVL13:
|
|
|
|
|
49:Core/Src/PCA9535D_Driver.c **** else
|
|
|
|
|
195 .loc 1 49 34 view .LVU42
|
|
|
|
|
196 0058 8A40 lsls r2, r2, r1
|
|
|
|
|
49:Core/Src/PCA9535D_Driver.c **** else
|
|
|
|
|
197 .loc 1 49 28 view .LVU43
|
|
|
|
|
198 005a 1349 ldr r1, .L13+12
|
|
|
|
|
199 .LVL14:
|
|
|
|
|
49:Core/Src/PCA9535D_Driver.c **** else
|
|
|
|
|
200 .loc 1 49 28 view .LVU44
|
|
|
|
|
201 005c 0B78 ldrb r3, [r1] @ zero_extendqisi2
|
|
|
|
|
202 005e 1343 orrs r3, r3, r2
|
|
|
|
|
203 0060 0B70 strb r3, [r1]
|
|
|
|
|
204 .L11:
|
|
|
|
|
53:Core/Src/PCA9535D_Driver.c **** gpiob_shadow_reg_dir};
|
|
|
|
|
205 .loc 1 53 5 is_stmt 1 view .LVU45
|
|
|
|
|
53:Core/Src/PCA9535D_Driver.c **** gpiob_shadow_reg_dir};
|
|
|
|
|
206 .loc 1 53 13 is_stmt 0 view .LVU46
|
|
|
|
|
207 0062 0723 movs r3, #7
|
|
|
|
|
208 0064 8DF80C30 strb r3, [sp, #12]
|
|
|
|
|
209 0068 0F4B ldr r3, .L13+12
|
|
|
|
|
210 006a 1B78 ldrb r3, [r3] @ zero_extendqisi2
|
|
|
|
|
211 006c 8DF80D30 strb r3, [sp, #13]
|
|
|
|
|
55:Core/Src/PCA9535D_Driver.c **** }
|
|
|
|
|
212 .loc 1 55 5 is_stmt 1 view .LVU47
|
|
|
|
|
213 0070 4FF47A73 mov r3, #1000
|
2024-05-13 16:40:39 +02:00
|
|
|
|
ARM GAS C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s page 6
|
2024-05-12 14:08:58 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
214 0074 0093 str r3, [sp]
|
|
|
|
|
215 0076 0223 movs r3, #2
|
|
|
|
|
216 0078 03AA add r2, sp, #12
|
|
|
|
|
217 007a 0949 ldr r1, .L13+4
|
|
|
|
|
218 007c 0978 ldrb r1, [r1] @ zero_extendqisi2
|
|
|
|
|
219 007e 0948 ldr r0, .L13+8
|
|
|
|
|
220 .LVL15:
|
|
|
|
|
55:Core/Src/PCA9535D_Driver.c **** }
|
|
|
|
|
221 .loc 1 55 5 is_stmt 0 view .LVU48
|
|
|
|
|
222 0080 0068 ldr r0, [r0]
|
|
|
|
|
223 0082 FFF7FEFF bl HAL_I2C_Master_Transmit
|
|
|
|
|
224 .LVL16:
|
|
|
|
|
225 .LBE4:
|
|
|
|
|
226 .loc 1 57 1 view .LVU49
|
|
|
|
|
227 0086 D7E7 b .L5
|
|
|
|
|
228 .LVL17:
|
|
|
|
|
229 .L10:
|
|
|
|
|
230 .LBB5:
|
|
|
|
|
51:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
231 .loc 1 51 7 is_stmt 1 view .LVU50
|
|
|
|
|
51:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
232 .loc 1 51 35 is_stmt 0 view .LVU51
|
|
|
|
|
233 0088 0123 movs r3, #1
|
|
|
|
|
234 008a 8B40 lsls r3, r3, r1
|
|
|
|
|
51:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
235 .loc 1 51 28 view .LVU52
|
|
|
|
|
236 008c DB43 mvns r3, r3
|
|
|
|
|
237 008e 5BB2 sxtb r3, r3
|
|
|
|
|
238 0090 0549 ldr r1, .L13+12
|
|
|
|
|
239 .LVL18:
|
|
|
|
|
51:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
240 .loc 1 51 28 view .LVU53
|
|
|
|
|
241 0092 0A78 ldrb r2, [r1] @ zero_extendqisi2
|
|
|
|
|
242 .LVL19:
|
|
|
|
|
51:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
243 .loc 1 51 28 view .LVU54
|
|
|
|
|
244 0094 1340 ands r3, r3, r2
|
|
|
|
|
245 0096 0B70 strb r3, [r1]
|
|
|
|
|
246 0098 E3E7 b .L11
|
|
|
|
|
247 .L14:
|
|
|
|
|
248 009a 00BF .align 2
|
|
|
|
|
249 .L13:
|
|
|
|
|
250 009c 00000000 .word gpioa_shadow_reg_dir
|
|
|
|
|
251 00a0 00000000 .word deviceadr
|
|
|
|
|
252 00a4 00000000 .word pcai2c
|
|
|
|
|
253 00a8 00000000 .word gpiob_shadow_reg_dir
|
|
|
|
|
254 .LBE5:
|
|
|
|
|
255 .cfi_endproc
|
|
|
|
|
256 .LFE131:
|
|
|
|
|
258 .section .text.PCA9535_setGPIOPinOutput,"ax",%progbits
|
|
|
|
|
259 .align 1
|
|
|
|
|
260 .global PCA9535_setGPIOPinOutput
|
|
|
|
|
261 .syntax unified
|
|
|
|
|
262 .thumb
|
|
|
|
|
263 .thumb_func
|
|
|
|
|
265 PCA9535_setGPIOPinOutput:
|
|
|
|
|
266 .LVL20:
|
2024-05-13 16:40:39 +02:00
|
|
|
|
ARM GAS C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s page 7
|
2024-05-12 14:08:58 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
267 .LFB132:
|
|
|
|
|
58:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
59:Core/Src/PCA9535D_Driver.c **** void PCA9535_setGPIOPinOutput(uint8_t Port, uint8_t pin, uint8_t state) {
|
|
|
|
|
268 .loc 1 59 73 is_stmt 1 view -0
|
|
|
|
|
269 .cfi_startproc
|
|
|
|
|
270 @ args = 0, pretend = 0, frame = 8
|
|
|
|
|
271 @ frame_needed = 0, uses_anonymous_args = 0
|
|
|
|
|
272 .loc 1 59 73 is_stmt 0 view .LVU56
|
|
|
|
|
273 0000 00B5 push {lr}
|
|
|
|
|
274 .cfi_def_cfa_offset 4
|
|
|
|
|
275 .cfi_offset 14, -4
|
|
|
|
|
276 0002 85B0 sub sp, sp, #20
|
|
|
|
|
277 .cfi_def_cfa_offset 24
|
|
|
|
|
60:Core/Src/PCA9535D_Driver.c **** if (Port == PC9535_PORTA) {
|
|
|
|
|
278 .loc 1 60 3 is_stmt 1 view .LVU57
|
|
|
|
|
279 .loc 1 60 6 is_stmt 0 view .LVU58
|
|
|
|
|
280 0004 18BB cbnz r0, .L16
|
|
|
|
|
281 .LBB6:
|
|
|
|
|
61:Core/Src/PCA9535D_Driver.c **** if (state)
|
|
|
|
|
282 .loc 1 61 5 is_stmt 1 view .LVU59
|
|
|
|
|
283 .loc 1 61 8 is_stmt 0 view .LVU60
|
|
|
|
|
284 0006 CAB1 cbz r2, .L17
|
|
|
|
|
62:Core/Src/PCA9535D_Driver.c **** gpioa_shadow_reg_out |= (1 << pin);
|
|
|
|
|
285 .loc 1 62 7 is_stmt 1 view .LVU61
|
|
|
|
|
286 .loc 1 62 34 is_stmt 0 view .LVU62
|
|
|
|
|
287 0008 0122 movs r2, #1
|
|
|
|
|
288 .LVL21:
|
|
|
|
|
289 .loc 1 62 34 view .LVU63
|
|
|
|
|
290 000a 8A40 lsls r2, r2, r1
|
|
|
|
|
291 .loc 1 62 28 view .LVU64
|
|
|
|
|
292 000c 2249 ldr r1, .L23
|
|
|
|
|
293 .LVL22:
|
|
|
|
|
294 .loc 1 62 28 view .LVU65
|
|
|
|
|
295 000e 0B78 ldrb r3, [r1] @ zero_extendqisi2
|
|
|
|
|
296 0010 1343 orrs r3, r3, r2
|
|
|
|
|
297 0012 0B70 strb r3, [r1]
|
|
|
|
|
298 .L18:
|
|
|
|
|
63:Core/Src/PCA9535D_Driver.c **** else
|
|
|
|
|
64:Core/Src/PCA9535D_Driver.c **** gpioa_shadow_reg_out &= ~(1 << pin);
|
|
|
|
|
65:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
66:Core/Src/PCA9535D_Driver.c **** uint8_t data[2] = {OUTPUT_REG_BASE_ADDRESS, gpioa_shadow_reg_out};
|
|
|
|
|
299 .loc 1 66 5 is_stmt 1 view .LVU66
|
|
|
|
|
300 .loc 1 66 13 is_stmt 0 view .LVU67
|
|
|
|
|
301 0014 0223 movs r3, #2
|
|
|
|
|
302 0016 8DF80C30 strb r3, [sp, #12]
|
|
|
|
|
303 001a 1F4A ldr r2, .L23
|
|
|
|
|
304 001c 1278 ldrb r2, [r2] @ zero_extendqisi2
|
|
|
|
|
305 001e 8DF80D20 strb r2, [sp, #13]
|
|
|
|
|
67:Core/Src/PCA9535D_Driver.c **** HAL_I2C_Master_Transmit(pcai2c, deviceadr, data, 2, 1000);
|
|
|
|
|
306 .loc 1 67 5 is_stmt 1 view .LVU68
|
|
|
|
|
307 0022 4FF47A72 mov r2, #1000
|
|
|
|
|
308 0026 0092 str r2, [sp]
|
|
|
|
|
309 0028 03AA add r2, sp, #12
|
|
|
|
|
310 002a 1C49 ldr r1, .L23+4
|
|
|
|
|
311 002c 0978 ldrb r1, [r1] @ zero_extendqisi2
|
|
|
|
|
312 002e 1C48 ldr r0, .L23+8
|
|
|
|
|
313 .LVL23:
|
2024-05-13 16:40:39 +02:00
|
|
|
|
ARM GAS C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s page 8
|
2024-05-12 14:08:58 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
314 .loc 1 67 5 is_stmt 0 view .LVU69
|
|
|
|
|
315 0030 0068 ldr r0, [r0]
|
|
|
|
|
316 0032 FFF7FEFF bl HAL_I2C_Master_Transmit
|
|
|
|
|
317 .LVL24:
|
|
|
|
|
318 .L15:
|
|
|
|
|
319 .LBE6:
|
|
|
|
|
68:Core/Src/PCA9535D_Driver.c **** } else if (Port == PC9535_PORTB) {
|
|
|
|
|
69:Core/Src/PCA9535D_Driver.c **** if (state)
|
|
|
|
|
70:Core/Src/PCA9535D_Driver.c **** gpiob_shadow_reg_out |= (1 << pin);
|
|
|
|
|
71:Core/Src/PCA9535D_Driver.c **** else
|
|
|
|
|
72:Core/Src/PCA9535D_Driver.c **** gpiob_shadow_reg_out &= ~(1 << pin);
|
|
|
|
|
73:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
74:Core/Src/PCA9535D_Driver.c **** uint8_t data[2] = {OUTPUT_REG_BASE_ADDRESS | 1, gpiob_shadow_reg_out};
|
|
|
|
|
75:Core/Src/PCA9535D_Driver.c **** HAL_I2C_Master_Transmit(pcai2c, deviceadr, data, 2, 1000);
|
|
|
|
|
76:Core/Src/PCA9535D_Driver.c **** }
|
|
|
|
|
77:Core/Src/PCA9535D_Driver.c **** }
|
|
|
|
|
320 .loc 1 77 1 view .LVU70
|
|
|
|
|
321 0036 05B0 add sp, sp, #20
|
|
|
|
|
322 .cfi_remember_state
|
|
|
|
|
323 .cfi_def_cfa_offset 4
|
|
|
|
|
324 @ sp needed
|
|
|
|
|
325 0038 5DF804FB ldr pc, [sp], #4
|
|
|
|
|
326 .LVL25:
|
|
|
|
|
327 .L17:
|
|
|
|
|
328 .cfi_restore_state
|
|
|
|
|
329 .LBB7:
|
|
|
|
|
64:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
330 .loc 1 64 7 is_stmt 1 view .LVU71
|
|
|
|
|
64:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
331 .loc 1 64 35 is_stmt 0 view .LVU72
|
|
|
|
|
332 003c 0123 movs r3, #1
|
|
|
|
|
333 003e 8B40 lsls r3, r3, r1
|
|
|
|
|
64:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
334 .loc 1 64 28 view .LVU73
|
|
|
|
|
335 0040 DB43 mvns r3, r3
|
|
|
|
|
336 0042 5BB2 sxtb r3, r3
|
|
|
|
|
337 0044 1449 ldr r1, .L23
|
|
|
|
|
338 .LVL26:
|
|
|
|
|
64:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
339 .loc 1 64 28 view .LVU74
|
|
|
|
|
340 0046 0A78 ldrb r2, [r1] @ zero_extendqisi2
|
|
|
|
|
341 .LVL27:
|
|
|
|
|
64:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
342 .loc 1 64 28 view .LVU75
|
|
|
|
|
343 0048 1340 ands r3, r3, r2
|
|
|
|
|
344 004a 0B70 strb r3, [r1]
|
|
|
|
|
345 004c E2E7 b .L18
|
|
|
|
|
346 .LVL28:
|
|
|
|
|
347 .L16:
|
|
|
|
|
64:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
348 .loc 1 64 28 view .LVU76
|
|
|
|
|
349 .LBE7:
|
|
|
|
|
68:Core/Src/PCA9535D_Driver.c **** } else if (Port == PC9535_PORTB) {
|
|
|
|
|
350 .loc 1 68 10 is_stmt 1 view .LVU77
|
|
|
|
|
68:Core/Src/PCA9535D_Driver.c **** } else if (Port == PC9535_PORTB) {
|
|
|
|
|
351 .loc 1 68 13 is_stmt 0 view .LVU78
|
|
|
|
|
352 004e 0128 cmp r0, #1
|
2024-05-13 16:40:39 +02:00
|
|
|
|
ARM GAS C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s page 9
|
2024-05-12 14:08:58 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
353 0050 F1D1 bne .L15
|
|
|
|
|
354 .LBB8:
|
|
|
|
|
69:Core/Src/PCA9535D_Driver.c **** gpiob_shadow_reg_out |= (1 << pin);
|
|
|
|
|
355 .loc 1 69 5 is_stmt 1 view .LVU79
|
|
|
|
|
69:Core/Src/PCA9535D_Driver.c **** gpiob_shadow_reg_out |= (1 << pin);
|
|
|
|
|
356 .loc 1 69 8 is_stmt 0 view .LVU80
|
|
|
|
|
357 0052 C2B1 cbz r2, .L20
|
|
|
|
|
70:Core/Src/PCA9535D_Driver.c **** else
|
|
|
|
|
358 .loc 1 70 7 is_stmt 1 view .LVU81
|
|
|
|
|
70:Core/Src/PCA9535D_Driver.c **** else
|
|
|
|
|
359 .loc 1 70 34 is_stmt 0 view .LVU82
|
|
|
|
|
360 0054 0122 movs r2, #1
|
|
|
|
|
361 .LVL29:
|
|
|
|
|
70:Core/Src/PCA9535D_Driver.c **** else
|
|
|
|
|
362 .loc 1 70 34 view .LVU83
|
|
|
|
|
363 0056 8A40 lsls r2, r2, r1
|
|
|
|
|
70:Core/Src/PCA9535D_Driver.c **** else
|
|
|
|
|
364 .loc 1 70 28 view .LVU84
|
|
|
|
|
365 0058 1249 ldr r1, .L23+12
|
|
|
|
|
366 .LVL30:
|
|
|
|
|
70:Core/Src/PCA9535D_Driver.c **** else
|
|
|
|
|
367 .loc 1 70 28 view .LVU85
|
|
|
|
|
368 005a 0B78 ldrb r3, [r1] @ zero_extendqisi2
|
|
|
|
|
369 005c 1343 orrs r3, r3, r2
|
|
|
|
|
370 005e 0B70 strb r3, [r1]
|
|
|
|
|
371 .L21:
|
|
|
|
|
74:Core/Src/PCA9535D_Driver.c **** HAL_I2C_Master_Transmit(pcai2c, deviceadr, data, 2, 1000);
|
|
|
|
|
372 .loc 1 74 5 is_stmt 1 view .LVU86
|
|
|
|
|
74:Core/Src/PCA9535D_Driver.c **** HAL_I2C_Master_Transmit(pcai2c, deviceadr, data, 2, 1000);
|
|
|
|
|
373 .loc 1 74 13 is_stmt 0 view .LVU87
|
|
|
|
|
374 0060 0323 movs r3, #3
|
|
|
|
|
375 0062 8DF80C30 strb r3, [sp, #12]
|
|
|
|
|
376 0066 0F4B ldr r3, .L23+12
|
|
|
|
|
377 0068 1B78 ldrb r3, [r3] @ zero_extendqisi2
|
|
|
|
|
378 006a 8DF80D30 strb r3, [sp, #13]
|
|
|
|
|
75:Core/Src/PCA9535D_Driver.c **** }
|
|
|
|
|
379 .loc 1 75 5 is_stmt 1 view .LVU88
|
|
|
|
|
380 006e 4FF47A73 mov r3, #1000
|
|
|
|
|
381 0072 0093 str r3, [sp]
|
|
|
|
|
382 0074 0223 movs r3, #2
|
|
|
|
|
383 0076 03AA add r2, sp, #12
|
|
|
|
|
384 0078 0849 ldr r1, .L23+4
|
|
|
|
|
385 007a 0978 ldrb r1, [r1] @ zero_extendqisi2
|
|
|
|
|
386 007c 0848 ldr r0, .L23+8
|
|
|
|
|
387 .LVL31:
|
|
|
|
|
75:Core/Src/PCA9535D_Driver.c **** }
|
|
|
|
|
388 .loc 1 75 5 is_stmt 0 view .LVU89
|
|
|
|
|
389 007e 0068 ldr r0, [r0]
|
|
|
|
|
390 0080 FFF7FEFF bl HAL_I2C_Master_Transmit
|
|
|
|
|
391 .LVL32:
|
|
|
|
|
392 .LBE8:
|
|
|
|
|
393 .loc 1 77 1 view .LVU90
|
|
|
|
|
394 0084 D7E7 b .L15
|
|
|
|
|
395 .LVL33:
|
|
|
|
|
396 .L20:
|
|
|
|
|
397 .LBB9:
|
|
|
|
|
72:Core/Src/PCA9535D_Driver.c ****
|
2024-05-13 16:40:39 +02:00
|
|
|
|
ARM GAS C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s page 10
|
2024-05-12 14:08:58 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
398 .loc 1 72 7 is_stmt 1 view .LVU91
|
|
|
|
|
72:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
399 .loc 1 72 35 is_stmt 0 view .LVU92
|
|
|
|
|
400 0086 0123 movs r3, #1
|
|
|
|
|
401 0088 8B40 lsls r3, r3, r1
|
|
|
|
|
72:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
402 .loc 1 72 28 view .LVU93
|
|
|
|
|
403 008a DB43 mvns r3, r3
|
|
|
|
|
404 008c 5BB2 sxtb r3, r3
|
|
|
|
|
405 008e 0549 ldr r1, .L23+12
|
|
|
|
|
406 .LVL34:
|
|
|
|
|
72:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
407 .loc 1 72 28 view .LVU94
|
|
|
|
|
408 0090 0A78 ldrb r2, [r1] @ zero_extendqisi2
|
|
|
|
|
409 .LVL35:
|
|
|
|
|
72:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
410 .loc 1 72 28 view .LVU95
|
|
|
|
|
411 0092 1340 ands r3, r3, r2
|
|
|
|
|
412 0094 0B70 strb r3, [r1]
|
|
|
|
|
413 0096 E3E7 b .L21
|
|
|
|
|
414 .L24:
|
|
|
|
|
415 .align 2
|
|
|
|
|
416 .L23:
|
|
|
|
|
417 0098 00000000 .word gpioa_shadow_reg_out
|
|
|
|
|
418 009c 00000000 .word deviceadr
|
|
|
|
|
419 00a0 00000000 .word pcai2c
|
|
|
|
|
420 00a4 00000000 .word gpiob_shadow_reg_out
|
|
|
|
|
421 .LBE9:
|
|
|
|
|
422 .cfi_endproc
|
|
|
|
|
423 .LFE132:
|
|
|
|
|
425 .section .text.PCA9535_invertGPIOPinPolarity,"ax",%progbits
|
|
|
|
|
426 .align 1
|
|
|
|
|
427 .global PCA9535_invertGPIOPinPolarity
|
|
|
|
|
428 .syntax unified
|
|
|
|
|
429 .thumb
|
|
|
|
|
430 .thumb_func
|
|
|
|
|
432 PCA9535_invertGPIOPinPolarity:
|
|
|
|
|
433 .LVL36:
|
|
|
|
|
434 .LFB133:
|
|
|
|
|
78:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
79:Core/Src/PCA9535D_Driver.c **** void PCA9535_invertGPIOPinPolarity(uint8_t Port, uint8_t pin, uint8_t state) {
|
|
|
|
|
435 .loc 1 79 78 is_stmt 1 view -0
|
|
|
|
|
436 .cfi_startproc
|
|
|
|
|
437 @ args = 0, pretend = 0, frame = 8
|
|
|
|
|
438 @ frame_needed = 0, uses_anonymous_args = 0
|
|
|
|
|
439 .loc 1 79 78 is_stmt 0 view .LVU97
|
|
|
|
|
440 0000 00B5 push {lr}
|
|
|
|
|
441 .cfi_def_cfa_offset 4
|
|
|
|
|
442 .cfi_offset 14, -4
|
|
|
|
|
443 0002 85B0 sub sp, sp, #20
|
|
|
|
|
444 .cfi_def_cfa_offset 24
|
|
|
|
|
80:Core/Src/PCA9535D_Driver.c **** if (Port == PC9535_PORTA) {
|
|
|
|
|
445 .loc 1 80 3 is_stmt 1 view .LVU98
|
|
|
|
|
446 .loc 1 80 6 is_stmt 0 view .LVU99
|
|
|
|
|
447 0004 20BB cbnz r0, .L26
|
|
|
|
|
448 .LBB10:
|
|
|
|
|
81:Core/Src/PCA9535D_Driver.c **** if (state)
|
2024-05-13 16:40:39 +02:00
|
|
|
|
ARM GAS C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s page 11
|
2024-05-12 14:08:58 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
449 .loc 1 81 5 is_stmt 1 view .LVU100
|
|
|
|
|
450 .loc 1 81 8 is_stmt 0 view .LVU101
|
|
|
|
|
451 0006 D2B1 cbz r2, .L27
|
|
|
|
|
82:Core/Src/PCA9535D_Driver.c **** gpioa_shadow_reg_inv |= (1 << pin);
|
|
|
|
|
452 .loc 1 82 7 is_stmt 1 view .LVU102
|
|
|
|
|
453 .loc 1 82 34 is_stmt 0 view .LVU103
|
|
|
|
|
454 0008 0122 movs r2, #1
|
|
|
|
|
455 .LVL37:
|
|
|
|
|
456 .loc 1 82 34 view .LVU104
|
|
|
|
|
457 000a 8A40 lsls r2, r2, r1
|
|
|
|
|
458 .loc 1 82 28 view .LVU105
|
|
|
|
|
459 000c 2349 ldr r1, .L33
|
|
|
|
|
460 .LVL38:
|
|
|
|
|
461 .loc 1 82 28 view .LVU106
|
|
|
|
|
462 000e 0B78 ldrb r3, [r1] @ zero_extendqisi2
|
|
|
|
|
463 0010 1343 orrs r3, r3, r2
|
|
|
|
|
464 0012 0B70 strb r3, [r1]
|
|
|
|
|
465 .L28:
|
|
|
|
|
83:Core/Src/PCA9535D_Driver.c **** else
|
|
|
|
|
84:Core/Src/PCA9535D_Driver.c **** gpioa_shadow_reg_inv &= ~(1 << pin);
|
|
|
|
|
85:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
86:Core/Src/PCA9535D_Driver.c **** uint8_t data[2] = {INPUT_POLARITY_INVERSION_REG_BASE_ADDRESS,
|
|
|
|
|
466 .loc 1 86 5 is_stmt 1 view .LVU107
|
|
|
|
|
467 .loc 1 86 13 is_stmt 0 view .LVU108
|
|
|
|
|
468 0014 0423 movs r3, #4
|
|
|
|
|
469 0016 8DF80C30 strb r3, [sp, #12]
|
|
|
|
|
470 001a 204B ldr r3, .L33
|
|
|
|
|
471 001c 1B78 ldrb r3, [r3] @ zero_extendqisi2
|
|
|
|
|
472 001e 8DF80D30 strb r3, [sp, #13]
|
|
|
|
|
87:Core/Src/PCA9535D_Driver.c **** gpioa_shadow_reg_inv};
|
|
|
|
|
88:Core/Src/PCA9535D_Driver.c **** HAL_I2C_Master_Transmit(pcai2c, deviceadr, data, 2, 1000);
|
|
|
|
|
473 .loc 1 88 5 is_stmt 1 view .LVU109
|
|
|
|
|
474 0022 4FF47A73 mov r3, #1000
|
|
|
|
|
475 0026 0093 str r3, [sp]
|
|
|
|
|
476 0028 0223 movs r3, #2
|
|
|
|
|
477 002a 03AA add r2, sp, #12
|
|
|
|
|
478 002c 1C49 ldr r1, .L33+4
|
|
|
|
|
479 002e 0978 ldrb r1, [r1] @ zero_extendqisi2
|
|
|
|
|
480 0030 1C48 ldr r0, .L33+8
|
|
|
|
|
481 .LVL39:
|
|
|
|
|
482 .loc 1 88 5 is_stmt 0 view .LVU110
|
|
|
|
|
483 0032 0068 ldr r0, [r0]
|
|
|
|
|
484 0034 FFF7FEFF bl HAL_I2C_Master_Transmit
|
|
|
|
|
485 .LVL40:
|
|
|
|
|
486 .L25:
|
|
|
|
|
487 .LBE10:
|
|
|
|
|
89:Core/Src/PCA9535D_Driver.c **** } else if (Port == PC9535_PORTB) {
|
|
|
|
|
90:Core/Src/PCA9535D_Driver.c **** if (state)
|
|
|
|
|
91:Core/Src/PCA9535D_Driver.c **** gpiob_shadow_reg_inv |= (1 << pin);
|
|
|
|
|
92:Core/Src/PCA9535D_Driver.c **** else
|
|
|
|
|
93:Core/Src/PCA9535D_Driver.c **** gpiob_shadow_reg_inv &= ~(1 << pin);
|
|
|
|
|
94:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
95:Core/Src/PCA9535D_Driver.c **** uint8_t data[2] = {INPUT_POLARITY_INVERSION_REG_BASE_ADDRESS | 1,
|
|
|
|
|
96:Core/Src/PCA9535D_Driver.c **** gpiob_shadow_reg_inv};
|
|
|
|
|
97:Core/Src/PCA9535D_Driver.c **** HAL_I2C_Master_Transmit(pcai2c, deviceadr, data, 2, 1000);
|
|
|
|
|
98:Core/Src/PCA9535D_Driver.c **** }
|
|
|
|
|
99:Core/Src/PCA9535D_Driver.c **** }
|
2024-05-13 16:40:39 +02:00
|
|
|
|
ARM GAS C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s page 12
|
2024-05-12 14:08:58 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
488 .loc 1 99 1 view .LVU111
|
|
|
|
|
489 0038 05B0 add sp, sp, #20
|
|
|
|
|
490 .cfi_remember_state
|
|
|
|
|
491 .cfi_def_cfa_offset 4
|
|
|
|
|
492 @ sp needed
|
|
|
|
|
493 003a 5DF804FB ldr pc, [sp], #4
|
|
|
|
|
494 .LVL41:
|
|
|
|
|
495 .L27:
|
|
|
|
|
496 .cfi_restore_state
|
|
|
|
|
497 .LBB11:
|
|
|
|
|
84:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
498 .loc 1 84 7 is_stmt 1 view .LVU112
|
|
|
|
|
84:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
499 .loc 1 84 35 is_stmt 0 view .LVU113
|
|
|
|
|
500 003e 0123 movs r3, #1
|
|
|
|
|
501 0040 8B40 lsls r3, r3, r1
|
|
|
|
|
84:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
502 .loc 1 84 28 view .LVU114
|
|
|
|
|
503 0042 DB43 mvns r3, r3
|
|
|
|
|
504 0044 5BB2 sxtb r3, r3
|
|
|
|
|
505 0046 1549 ldr r1, .L33
|
|
|
|
|
506 .LVL42:
|
|
|
|
|
84:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
507 .loc 1 84 28 view .LVU115
|
|
|
|
|
508 0048 0A78 ldrb r2, [r1] @ zero_extendqisi2
|
|
|
|
|
509 .LVL43:
|
|
|
|
|
84:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
510 .loc 1 84 28 view .LVU116
|
|
|
|
|
511 004a 1340 ands r3, r3, r2
|
|
|
|
|
512 004c 0B70 strb r3, [r1]
|
|
|
|
|
513 004e E1E7 b .L28
|
|
|
|
|
514 .LVL44:
|
|
|
|
|
515 .L26:
|
|
|
|
|
84:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
516 .loc 1 84 28 view .LVU117
|
|
|
|
|
517 .LBE11:
|
|
|
|
|
89:Core/Src/PCA9535D_Driver.c **** } else if (Port == PC9535_PORTB) {
|
|
|
|
|
518 .loc 1 89 10 is_stmt 1 view .LVU118
|
|
|
|
|
89:Core/Src/PCA9535D_Driver.c **** } else if (Port == PC9535_PORTB) {
|
|
|
|
|
519 .loc 1 89 13 is_stmt 0 view .LVU119
|
|
|
|
|
520 0050 0128 cmp r0, #1
|
|
|
|
|
521 0052 F1D1 bne .L25
|
|
|
|
|
522 .LBB12:
|
|
|
|
|
90:Core/Src/PCA9535D_Driver.c **** gpiob_shadow_reg_inv |= (1 << pin);
|
|
|
|
|
523 .loc 1 90 5 is_stmt 1 view .LVU120
|
|
|
|
|
90:Core/Src/PCA9535D_Driver.c **** gpiob_shadow_reg_inv |= (1 << pin);
|
|
|
|
|
524 .loc 1 90 8 is_stmt 0 view .LVU121
|
|
|
|
|
525 0054 C2B1 cbz r2, .L30
|
|
|
|
|
91:Core/Src/PCA9535D_Driver.c **** else
|
|
|
|
|
526 .loc 1 91 7 is_stmt 1 view .LVU122
|
|
|
|
|
91:Core/Src/PCA9535D_Driver.c **** else
|
|
|
|
|
527 .loc 1 91 34 is_stmt 0 view .LVU123
|
|
|
|
|
528 0056 0122 movs r2, #1
|
|
|
|
|
529 .LVL45:
|
|
|
|
|
91:Core/Src/PCA9535D_Driver.c **** else
|
|
|
|
|
530 .loc 1 91 34 view .LVU124
|
|
|
|
|
531 0058 8A40 lsls r2, r2, r1
|
2024-05-13 16:40:39 +02:00
|
|
|
|
ARM GAS C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s page 13
|
2024-05-12 14:08:58 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
91:Core/Src/PCA9535D_Driver.c **** else
|
|
|
|
|
532 .loc 1 91 28 view .LVU125
|
|
|
|
|
533 005a 1349 ldr r1, .L33+12
|
|
|
|
|
534 .LVL46:
|
|
|
|
|
91:Core/Src/PCA9535D_Driver.c **** else
|
|
|
|
|
535 .loc 1 91 28 view .LVU126
|
|
|
|
|
536 005c 0B78 ldrb r3, [r1] @ zero_extendqisi2
|
|
|
|
|
537 005e 1343 orrs r3, r3, r2
|
|
|
|
|
538 0060 0B70 strb r3, [r1]
|
|
|
|
|
539 .L31:
|
|
|
|
|
95:Core/Src/PCA9535D_Driver.c **** gpiob_shadow_reg_inv};
|
|
|
|
|
540 .loc 1 95 5 is_stmt 1 view .LVU127
|
|
|
|
|
95:Core/Src/PCA9535D_Driver.c **** gpiob_shadow_reg_inv};
|
|
|
|
|
541 .loc 1 95 13 is_stmt 0 view .LVU128
|
|
|
|
|
542 0062 0523 movs r3, #5
|
|
|
|
|
543 0064 8DF80C30 strb r3, [sp, #12]
|
|
|
|
|
544 0068 0F4B ldr r3, .L33+12
|
|
|
|
|
545 006a 1B78 ldrb r3, [r3] @ zero_extendqisi2
|
|
|
|
|
546 006c 8DF80D30 strb r3, [sp, #13]
|
|
|
|
|
97:Core/Src/PCA9535D_Driver.c **** }
|
|
|
|
|
547 .loc 1 97 5 is_stmt 1 view .LVU129
|
|
|
|
|
548 0070 4FF47A73 mov r3, #1000
|
|
|
|
|
549 0074 0093 str r3, [sp]
|
|
|
|
|
550 0076 0223 movs r3, #2
|
|
|
|
|
551 0078 03AA add r2, sp, #12
|
|
|
|
|
552 007a 0949 ldr r1, .L33+4
|
|
|
|
|
553 007c 0978 ldrb r1, [r1] @ zero_extendqisi2
|
|
|
|
|
554 007e 0948 ldr r0, .L33+8
|
|
|
|
|
555 .LVL47:
|
|
|
|
|
97:Core/Src/PCA9535D_Driver.c **** }
|
|
|
|
|
556 .loc 1 97 5 is_stmt 0 view .LVU130
|
|
|
|
|
557 0080 0068 ldr r0, [r0]
|
|
|
|
|
558 0082 FFF7FEFF bl HAL_I2C_Master_Transmit
|
|
|
|
|
559 .LVL48:
|
|
|
|
|
560 .LBE12:
|
|
|
|
|
561 .loc 1 99 1 view .LVU131
|
|
|
|
|
562 0086 D7E7 b .L25
|
|
|
|
|
563 .LVL49:
|
|
|
|
|
564 .L30:
|
|
|
|
|
565 .LBB13:
|
|
|
|
|
93:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
566 .loc 1 93 7 is_stmt 1 view .LVU132
|
|
|
|
|
93:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
567 .loc 1 93 35 is_stmt 0 view .LVU133
|
|
|
|
|
568 0088 0123 movs r3, #1
|
|
|
|
|
569 008a 8B40 lsls r3, r3, r1
|
|
|
|
|
93:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
570 .loc 1 93 28 view .LVU134
|
|
|
|
|
571 008c DB43 mvns r3, r3
|
|
|
|
|
572 008e 5BB2 sxtb r3, r3
|
|
|
|
|
573 0090 0549 ldr r1, .L33+12
|
|
|
|
|
574 .LVL50:
|
|
|
|
|
93:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
575 .loc 1 93 28 view .LVU135
|
|
|
|
|
576 0092 0A78 ldrb r2, [r1] @ zero_extendqisi2
|
|
|
|
|
577 .LVL51:
|
|
|
|
|
93:Core/Src/PCA9535D_Driver.c ****
|
2024-05-13 16:40:39 +02:00
|
|
|
|
ARM GAS C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s page 14
|
2024-05-12 14:08:58 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
578 .loc 1 93 28 view .LVU136
|
|
|
|
|
579 0094 1340 ands r3, r3, r2
|
|
|
|
|
580 0096 0B70 strb r3, [r1]
|
|
|
|
|
581 0098 E3E7 b .L31
|
|
|
|
|
582 .L34:
|
|
|
|
|
583 009a 00BF .align 2
|
|
|
|
|
584 .L33:
|
|
|
|
|
585 009c 00000000 .word gpioa_shadow_reg_inv
|
|
|
|
|
586 00a0 00000000 .word deviceadr
|
|
|
|
|
587 00a4 00000000 .word pcai2c
|
|
|
|
|
588 00a8 00000000 .word gpiob_shadow_reg_inv
|
|
|
|
|
589 .LBE13:
|
|
|
|
|
590 .cfi_endproc
|
|
|
|
|
591 .LFE133:
|
|
|
|
|
593 .section .text.PCA9535_readGPIOPinInput,"ax",%progbits
|
|
|
|
|
594 .align 1
|
|
|
|
|
595 .global PCA9535_readGPIOPinInput
|
|
|
|
|
596 .syntax unified
|
|
|
|
|
597 .thumb
|
|
|
|
|
598 .thumb_func
|
|
|
|
|
600 PCA9535_readGPIOPinInput:
|
|
|
|
|
601 .LVL52:
|
|
|
|
|
602 .LFB134:
|
|
|
|
|
100:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
101:Core/Src/PCA9535D_Driver.c **** uint8_t PCA9535_readGPIOPinInput(uint8_t Port, uint8_t pin) {
|
|
|
|
|
603 .loc 1 101 61 is_stmt 1 view -0
|
|
|
|
|
604 .cfi_startproc
|
|
|
|
|
605 @ args = 0, pretend = 0, frame = 8
|
|
|
|
|
606 @ frame_needed = 0, uses_anonymous_args = 0
|
|
|
|
|
607 .loc 1 101 61 is_stmt 0 view .LVU138
|
|
|
|
|
608 0000 10B5 push {r4, lr}
|
|
|
|
|
609 .cfi_def_cfa_offset 8
|
|
|
|
|
610 .cfi_offset 4, -8
|
|
|
|
|
611 .cfi_offset 14, -4
|
|
|
|
|
612 0002 84B0 sub sp, sp, #16
|
|
|
|
|
613 .cfi_def_cfa_offset 24
|
|
|
|
|
614 0004 0C46 mov r4, r1
|
|
|
|
|
102:Core/Src/PCA9535D_Driver.c **** if (Port == PC9535_PORTA) {
|
|
|
|
|
615 .loc 1 102 3 is_stmt 1 view .LVU139
|
|
|
|
|
616 .loc 1 102 6 is_stmt 0 view .LVU140
|
|
|
|
|
617 0006 F0B1 cbz r0, .L39
|
|
|
|
|
618 0008 0346 mov r3, r0
|
|
|
|
|
103:Core/Src/PCA9535D_Driver.c **** uint8_t command = INPUT_REG_BASE_ADDRESS;
|
|
|
|
|
104:Core/Src/PCA9535D_Driver.c **** HAL_I2C_Master_Transmit(pcai2c, deviceadr, &command, 1, 1000);
|
|
|
|
|
105:Core/Src/PCA9535D_Driver.c **** } else if (Port == PC9535_PORTB) {
|
|
|
|
|
619 .loc 1 105 10 is_stmt 1 view .LVU141
|
|
|
|
|
620 .loc 1 105 13 is_stmt 0 view .LVU142
|
|
|
|
|
621 000a 0128 cmp r0, #1
|
|
|
|
|
622 000c 2BD0 beq .L40
|
|
|
|
|
623 .LVL53:
|
|
|
|
|
624 .L37:
|
|
|
|
|
106:Core/Src/PCA9535D_Driver.c **** uint8_t command = INPUT_REG_BASE_ADDRESS | 1;
|
|
|
|
|
107:Core/Src/PCA9535D_Driver.c **** HAL_I2C_Master_Transmit(pcai2c, deviceadr, &command, 1, 1000);
|
|
|
|
|
108:Core/Src/PCA9535D_Driver.c **** }
|
|
|
|
|
109:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
110:Core/Src/PCA9535D_Driver.c **** uint8_t reval = 0;
|
|
|
|
|
625 .loc 1 110 3 is_stmt 1 view .LVU143
|
2024-05-13 16:40:39 +02:00
|
|
|
|
ARM GAS C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s page 15
|
2024-05-12 14:08:58 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
626 .loc 1 110 11 is_stmt 0 view .LVU144
|
|
|
|
|
627 000e 0023 movs r3, #0
|
|
|
|
|
628 0010 8DF80F30 strb r3, [sp, #15]
|
|
|
|
|
111:Core/Src/PCA9535D_Driver.c **** HAL_I2C_Master_Receive(pcai2c, deviceadr, &reval, 1, 1000);
|
|
|
|
|
629 .loc 1 111 3 is_stmt 1 view .LVU145
|
|
|
|
|
630 0014 4FF47A73 mov r3, #1000
|
|
|
|
|
631 0018 0093 str r3, [sp]
|
|
|
|
|
632 001a 0123 movs r3, #1
|
|
|
|
|
633 001c 0DF10F02 add r2, sp, #15
|
|
|
|
|
634 0020 1849 ldr r1, .L41
|
|
|
|
|
635 0022 0978 ldrb r1, [r1] @ zero_extendqisi2
|
|
|
|
|
636 0024 1848 ldr r0, .L41+4
|
|
|
|
|
637 0026 0068 ldr r0, [r0]
|
|
|
|
|
638 0028 FFF7FEFF bl HAL_I2C_Master_Receive
|
|
|
|
|
639 .LVL54:
|
|
|
|
|
112:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
113:Core/Src/PCA9535D_Driver.c **** reval &= (1 << pin);
|
|
|
|
|
640 .loc 1 113 3 view .LVU146
|
|
|
|
|
641 .loc 1 113 15 is_stmt 0 view .LVU147
|
|
|
|
|
642 002c 0123 movs r3, #1
|
|
|
|
|
643 002e A340 lsls r3, r3, r4
|
|
|
|
|
644 .loc 1 113 9 view .LVU148
|
|
|
|
|
645 0030 9DF80F00 ldrb r0, [sp, #15] @ zero_extendqisi2
|
|
|
|
|
646 0034 1840 ands r0, r0, r3
|
|
|
|
|
647 0036 8DF80F00 strb r0, [sp, #15]
|
|
|
|
|
114:Core/Src/PCA9535D_Driver.c **** reval = reval >> (pin);
|
|
|
|
|
648 .loc 1 114 3 is_stmt 1 view .LVU149
|
|
|
|
|
649 .loc 1 114 17 is_stmt 0 view .LVU150
|
|
|
|
|
650 003a 2041 asrs r0, r0, r4
|
|
|
|
|
651 .loc 1 114 9 view .LVU151
|
|
|
|
|
652 003c C0B2 uxtb r0, r0
|
|
|
|
|
653 003e 8DF80F00 strb r0, [sp, #15]
|
|
|
|
|
115:Core/Src/PCA9535D_Driver.c **** return reval;
|
|
|
|
|
654 .loc 1 115 3 is_stmt 1 view .LVU152
|
|
|
|
|
116:Core/Src/PCA9535D_Driver.c **** }
|
|
|
|
|
655 .loc 1 116 1 is_stmt 0 view .LVU153
|
|
|
|
|
656 0042 04B0 add sp, sp, #16
|
|
|
|
|
657 .cfi_remember_state
|
|
|
|
|
658 .cfi_def_cfa_offset 8
|
|
|
|
|
659 @ sp needed
|
|
|
|
|
660 0044 10BD pop {r4, pc}
|
|
|
|
|
661 .LVL55:
|
|
|
|
|
662 .L39:
|
|
|
|
|
663 .cfi_restore_state
|
|
|
|
|
664 .LBB14:
|
|
|
|
|
103:Core/Src/PCA9535D_Driver.c **** HAL_I2C_Master_Transmit(pcai2c, deviceadr, &command, 1, 1000);
|
|
|
|
|
665 .loc 1 103 5 is_stmt 1 view .LVU154
|
|
|
|
|
103:Core/Src/PCA9535D_Driver.c **** HAL_I2C_Master_Transmit(pcai2c, deviceadr, &command, 1, 1000);
|
|
|
|
|
666 .loc 1 103 13 is_stmt 0 view .LVU155
|
|
|
|
|
667 0046 0023 movs r3, #0
|
|
|
|
|
668 0048 8DF80E30 strb r3, [sp, #14]
|
|
|
|
|
104:Core/Src/PCA9535D_Driver.c **** } else if (Port == PC9535_PORTB) {
|
|
|
|
|
669 .loc 1 104 5 is_stmt 1 view .LVU156
|
|
|
|
|
670 004c 4FF47A73 mov r3, #1000
|
|
|
|
|
671 0050 0093 str r3, [sp]
|
|
|
|
|
672 0052 0123 movs r3, #1
|
|
|
|
|
673 0054 0DF10E02 add r2, sp, #14
|
2024-05-13 16:40:39 +02:00
|
|
|
|
ARM GAS C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s page 16
|
2024-05-12 14:08:58 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
674 0058 0A49 ldr r1, .L41
|
|
|
|
|
675 .LVL56:
|
|
|
|
|
104:Core/Src/PCA9535D_Driver.c **** } else if (Port == PC9535_PORTB) {
|
|
|
|
|
676 .loc 1 104 5 is_stmt 0 view .LVU157
|
|
|
|
|
677 005a 0978 ldrb r1, [r1] @ zero_extendqisi2
|
|
|
|
|
678 005c 0A48 ldr r0, .L41+4
|
|
|
|
|
679 .LVL57:
|
|
|
|
|
104:Core/Src/PCA9535D_Driver.c **** } else if (Port == PC9535_PORTB) {
|
|
|
|
|
680 .loc 1 104 5 view .LVU158
|
|
|
|
|
681 005e 0068 ldr r0, [r0]
|
|
|
|
|
682 0060 FFF7FEFF bl HAL_I2C_Master_Transmit
|
|
|
|
|
683 .LVL58:
|
|
|
|
|
684 .LBE14:
|
|
|
|
|
685 0064 D3E7 b .L37
|
|
|
|
|
686 .LVL59:
|
|
|
|
|
687 .L40:
|
|
|
|
|
688 .LBB15:
|
|
|
|
|
106:Core/Src/PCA9535D_Driver.c **** HAL_I2C_Master_Transmit(pcai2c, deviceadr, &command, 1, 1000);
|
|
|
|
|
689 .loc 1 106 5 is_stmt 1 view .LVU159
|
|
|
|
|
106:Core/Src/PCA9535D_Driver.c **** HAL_I2C_Master_Transmit(pcai2c, deviceadr, &command, 1, 1000);
|
|
|
|
|
690 .loc 1 106 13 is_stmt 0 view .LVU160
|
|
|
|
|
691 0066 8DF80E00 strb r0, [sp, #14]
|
|
|
|
|
107:Core/Src/PCA9535D_Driver.c **** }
|
|
|
|
|
692 .loc 1 107 5 is_stmt 1 view .LVU161
|
|
|
|
|
693 006a 4FF47A72 mov r2, #1000
|
|
|
|
|
694 006e 0092 str r2, [sp]
|
|
|
|
|
695 0070 0DF10E02 add r2, sp, #14
|
|
|
|
|
696 0074 0349 ldr r1, .L41
|
|
|
|
|
697 .LVL60:
|
|
|
|
|
107:Core/Src/PCA9535D_Driver.c **** }
|
|
|
|
|
698 .loc 1 107 5 is_stmt 0 view .LVU162
|
|
|
|
|
699 0076 0978 ldrb r1, [r1] @ zero_extendqisi2
|
|
|
|
|
700 0078 0348 ldr r0, .L41+4
|
|
|
|
|
701 .LVL61:
|
|
|
|
|
107:Core/Src/PCA9535D_Driver.c **** }
|
|
|
|
|
702 .loc 1 107 5 view .LVU163
|
|
|
|
|
703 007a 0068 ldr r0, [r0]
|
|
|
|
|
704 007c FFF7FEFF bl HAL_I2C_Master_Transmit
|
|
|
|
|
705 .LVL62:
|
|
|
|
|
107:Core/Src/PCA9535D_Driver.c **** }
|
|
|
|
|
706 .loc 1 107 5 view .LVU164
|
|
|
|
|
707 0080 C5E7 b .L37
|
|
|
|
|
708 .L42:
|
|
|
|
|
709 0082 00BF .align 2
|
|
|
|
|
710 .L41:
|
|
|
|
|
711 0084 00000000 .word deviceadr
|
|
|
|
|
712 0088 00000000 .word pcai2c
|
|
|
|
|
713 .LBE15:
|
|
|
|
|
714 .cfi_endproc
|
|
|
|
|
715 .LFE134:
|
|
|
|
|
717 .section .text.PCA9535_setGPIOPortDirection,"ax",%progbits
|
|
|
|
|
718 .align 1
|
|
|
|
|
719 .global PCA9535_setGPIOPortDirection
|
|
|
|
|
720 .syntax unified
|
|
|
|
|
721 .thumb
|
|
|
|
|
722 .thumb_func
|
|
|
|
|
724 PCA9535_setGPIOPortDirection:
|
2024-05-13 16:40:39 +02:00
|
|
|
|
ARM GAS C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s page 17
|
2024-05-12 14:08:58 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
725 .LVL63:
|
|
|
|
|
726 .LFB135:
|
|
|
|
|
117:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
118:Core/Src/PCA9535D_Driver.c **** void PCA9535_setGPIOPortDirection(uint8_t Port, uint8_t bitmask) {
|
|
|
|
|
727 .loc 1 118 66 is_stmt 1 view -0
|
|
|
|
|
728 .cfi_startproc
|
|
|
|
|
729 @ args = 0, pretend = 0, frame = 8
|
|
|
|
|
730 @ frame_needed = 0, uses_anonymous_args = 0
|
|
|
|
|
731 .loc 1 118 66 is_stmt 0 view .LVU166
|
|
|
|
|
732 0000 00B5 push {lr}
|
|
|
|
|
733 .cfi_def_cfa_offset 4
|
|
|
|
|
734 .cfi_offset 14, -4
|
|
|
|
|
735 0002 85B0 sub sp, sp, #20
|
|
|
|
|
736 .cfi_def_cfa_offset 24
|
|
|
|
|
119:Core/Src/PCA9535D_Driver.c **** uint8_t command[2] = {0x00, bitmask};
|
|
|
|
|
737 .loc 1 119 3 is_stmt 1 view .LVU167
|
|
|
|
|
738 .loc 1 119 11 is_stmt 0 view .LVU168
|
|
|
|
|
739 0004 0023 movs r3, #0
|
|
|
|
|
740 0006 8DF80C30 strb r3, [sp, #12]
|
|
|
|
|
741 000a 8DF80D10 strb r1, [sp, #13]
|
|
|
|
|
120:Core/Src/PCA9535D_Driver.c **** if (Port == PC9535_PORTA) {
|
|
|
|
|
742 .loc 1 120 3 is_stmt 1 view .LVU169
|
|
|
|
|
743 .loc 1 120 6 is_stmt 0 view .LVU170
|
|
|
|
|
744 000e 90B9 cbnz r0, .L44
|
|
|
|
|
121:Core/Src/PCA9535D_Driver.c **** gpioa_shadow_reg_dir = bitmask;
|
|
|
|
|
745 .loc 1 121 5 is_stmt 1 view .LVU171
|
|
|
|
|
746 .loc 1 121 26 is_stmt 0 view .LVU172
|
|
|
|
|
747 0010 0D4B ldr r3, .L47
|
|
|
|
|
748 0012 1970 strb r1, [r3]
|
|
|
|
|
122:Core/Src/PCA9535D_Driver.c **** command[0] = CONFIGURATION_REG_BASE_ADDRESS;
|
|
|
|
|
749 .loc 1 122 5 is_stmt 1 view .LVU173
|
|
|
|
|
750 .loc 1 122 16 is_stmt 0 view .LVU174
|
|
|
|
|
751 0014 0623 movs r3, #6
|
|
|
|
|
752 0016 8DF80C30 strb r3, [sp, #12]
|
|
|
|
|
753 .L45:
|
|
|
|
|
123:Core/Src/PCA9535D_Driver.c **** } else if (Port == PC9535_PORTB) {
|
|
|
|
|
124:Core/Src/PCA9535D_Driver.c **** gpiob_shadow_reg_dir = bitmask;
|
|
|
|
|
125:Core/Src/PCA9535D_Driver.c **** command[0] = CONFIGURATION_REG_BASE_ADDRESS | 1;
|
|
|
|
|
126:Core/Src/PCA9535D_Driver.c **** }
|
|
|
|
|
127:Core/Src/PCA9535D_Driver.c **** HAL_I2C_Master_Transmit(pcai2c, deviceadr, command, 2, 1000);
|
|
|
|
|
754 .loc 1 127 3 is_stmt 1 view .LVU175
|
|
|
|
|
755 001a 4FF47A73 mov r3, #1000
|
|
|
|
|
756 001e 0093 str r3, [sp]
|
|
|
|
|
757 0020 0223 movs r3, #2
|
|
|
|
|
758 0022 03AA add r2, sp, #12
|
|
|
|
|
759 0024 0949 ldr r1, .L47+4
|
|
|
|
|
760 .LVL64:
|
|
|
|
|
761 .loc 1 127 3 is_stmt 0 view .LVU176
|
|
|
|
|
762 0026 0978 ldrb r1, [r1] @ zero_extendqisi2
|
|
|
|
|
763 0028 0948 ldr r0, .L47+8
|
|
|
|
|
764 .LVL65:
|
|
|
|
|
765 .loc 1 127 3 view .LVU177
|
|
|
|
|
766 002a 0068 ldr r0, [r0]
|
|
|
|
|
767 002c FFF7FEFF bl HAL_I2C_Master_Transmit
|
|
|
|
|
768 .LVL66:
|
|
|
|
|
128:Core/Src/PCA9535D_Driver.c **** }
|
|
|
|
|
769 .loc 1 128 1 view .LVU178
|
2024-05-13 16:40:39 +02:00
|
|
|
|
ARM GAS C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s page 18
|
2024-05-12 14:08:58 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
770 0030 05B0 add sp, sp, #20
|
|
|
|
|
771 .cfi_remember_state
|
|
|
|
|
772 .cfi_def_cfa_offset 4
|
|
|
|
|
773 @ sp needed
|
|
|
|
|
774 0032 5DF804FB ldr pc, [sp], #4
|
|
|
|
|
775 .LVL67:
|
|
|
|
|
776 .L44:
|
|
|
|
|
777 .cfi_restore_state
|
|
|
|
|
123:Core/Src/PCA9535D_Driver.c **** } else if (Port == PC9535_PORTB) {
|
|
|
|
|
778 .loc 1 123 10 is_stmt 1 view .LVU179
|
|
|
|
|
123:Core/Src/PCA9535D_Driver.c **** } else if (Port == PC9535_PORTB) {
|
|
|
|
|
779 .loc 1 123 13 is_stmt 0 view .LVU180
|
|
|
|
|
780 0036 0128 cmp r0, #1
|
|
|
|
|
781 0038 EFD1 bne .L45
|
|
|
|
|
124:Core/Src/PCA9535D_Driver.c **** command[0] = CONFIGURATION_REG_BASE_ADDRESS | 1;
|
|
|
|
|
782 .loc 1 124 5 is_stmt 1 view .LVU181
|
|
|
|
|
124:Core/Src/PCA9535D_Driver.c **** command[0] = CONFIGURATION_REG_BASE_ADDRESS | 1;
|
|
|
|
|
783 .loc 1 124 26 is_stmt 0 view .LVU182
|
|
|
|
|
784 003a 064B ldr r3, .L47+12
|
|
|
|
|
785 003c 1970 strb r1, [r3]
|
|
|
|
|
125:Core/Src/PCA9535D_Driver.c **** }
|
|
|
|
|
786 .loc 1 125 5 is_stmt 1 view .LVU183
|
|
|
|
|
125:Core/Src/PCA9535D_Driver.c **** }
|
|
|
|
|
787 .loc 1 125 16 is_stmt 0 view .LVU184
|
|
|
|
|
788 003e 0723 movs r3, #7
|
|
|
|
|
789 0040 8DF80C30 strb r3, [sp, #12]
|
|
|
|
|
790 0044 E9E7 b .L45
|
|
|
|
|
791 .L48:
|
|
|
|
|
792 0046 00BF .align 2
|
|
|
|
|
793 .L47:
|
|
|
|
|
794 0048 00000000 .word gpioa_shadow_reg_dir
|
|
|
|
|
795 004c 00000000 .word deviceadr
|
|
|
|
|
796 0050 00000000 .word pcai2c
|
|
|
|
|
797 0054 00000000 .word gpiob_shadow_reg_dir
|
|
|
|
|
798 .cfi_endproc
|
|
|
|
|
799 .LFE135:
|
|
|
|
|
801 .section .text.PCA9535_setGPIOPortOutput,"ax",%progbits
|
|
|
|
|
802 .align 1
|
|
|
|
|
803 .global PCA9535_setGPIOPortOutput
|
|
|
|
|
804 .syntax unified
|
|
|
|
|
805 .thumb
|
|
|
|
|
806 .thumb_func
|
|
|
|
|
808 PCA9535_setGPIOPortOutput:
|
|
|
|
|
809 .LVL68:
|
|
|
|
|
810 .LFB136:
|
|
|
|
|
129:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
130:Core/Src/PCA9535D_Driver.c **** void PCA9535_setGPIOPortOutput(uint8_t Port, uint8_t bitmask) {
|
|
|
|
|
811 .loc 1 130 63 is_stmt 1 view -0
|
|
|
|
|
812 .cfi_startproc
|
|
|
|
|
813 @ args = 0, pretend = 0, frame = 8
|
|
|
|
|
814 @ frame_needed = 0, uses_anonymous_args = 0
|
|
|
|
|
815 .loc 1 130 63 is_stmt 0 view .LVU186
|
|
|
|
|
816 0000 00B5 push {lr}
|
|
|
|
|
817 .cfi_def_cfa_offset 4
|
|
|
|
|
818 .cfi_offset 14, -4
|
|
|
|
|
819 0002 85B0 sub sp, sp, #20
|
|
|
|
|
820 .cfi_def_cfa_offset 24
|
2024-05-13 16:40:39 +02:00
|
|
|
|
ARM GAS C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s page 19
|
2024-05-12 14:08:58 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
131:Core/Src/PCA9535D_Driver.c **** uint8_t command[2] = {0x00, bitmask};
|
|
|
|
|
821 .loc 1 131 3 is_stmt 1 view .LVU187
|
|
|
|
|
822 .loc 1 131 11 is_stmt 0 view .LVU188
|
|
|
|
|
823 0004 0023 movs r3, #0
|
|
|
|
|
824 0006 8DF80C30 strb r3, [sp, #12]
|
|
|
|
|
825 000a 8DF80D10 strb r1, [sp, #13]
|
|
|
|
|
132:Core/Src/PCA9535D_Driver.c **** if (Port == PC9535_PORTA) {
|
|
|
|
|
826 .loc 1 132 3 is_stmt 1 view .LVU189
|
|
|
|
|
827 .loc 1 132 6 is_stmt 0 view .LVU190
|
|
|
|
|
828 000e 90B9 cbnz r0, .L50
|
|
|
|
|
133:Core/Src/PCA9535D_Driver.c **** gpioa_shadow_reg_out = bitmask;
|
|
|
|
|
829 .loc 1 133 5 is_stmt 1 view .LVU191
|
|
|
|
|
830 .loc 1 133 26 is_stmt 0 view .LVU192
|
|
|
|
|
831 0010 0D4B ldr r3, .L53
|
|
|
|
|
832 0012 1970 strb r1, [r3]
|
|
|
|
|
134:Core/Src/PCA9535D_Driver.c **** command[0] = OUTPUT_REG_BASE_ADDRESS;
|
|
|
|
|
833 .loc 1 134 5 is_stmt 1 view .LVU193
|
|
|
|
|
834 .loc 1 134 16 is_stmt 0 view .LVU194
|
|
|
|
|
835 0014 0223 movs r3, #2
|
|
|
|
|
836 0016 8DF80C30 strb r3, [sp, #12]
|
|
|
|
|
837 .L51:
|
|
|
|
|
135:Core/Src/PCA9535D_Driver.c **** } else if (Port == PC9535_PORTB) {
|
|
|
|
|
136:Core/Src/PCA9535D_Driver.c **** gpiob_shadow_reg_out = bitmask;
|
|
|
|
|
137:Core/Src/PCA9535D_Driver.c **** command[0] = OUTPUT_REG_BASE_ADDRESS | 1;
|
|
|
|
|
138:Core/Src/PCA9535D_Driver.c **** }
|
|
|
|
|
139:Core/Src/PCA9535D_Driver.c **** HAL_I2C_Master_Transmit(pcai2c, deviceadr, command, 2, 1000);
|
|
|
|
|
838 .loc 1 139 3 is_stmt 1 view .LVU195
|
|
|
|
|
839 001a 4FF47A73 mov r3, #1000
|
|
|
|
|
840 001e 0093 str r3, [sp]
|
|
|
|
|
841 0020 0223 movs r3, #2
|
|
|
|
|
842 0022 03AA add r2, sp, #12
|
|
|
|
|
843 0024 0949 ldr r1, .L53+4
|
|
|
|
|
844 .LVL69:
|
|
|
|
|
845 .loc 1 139 3 is_stmt 0 view .LVU196
|
|
|
|
|
846 0026 0978 ldrb r1, [r1] @ zero_extendqisi2
|
|
|
|
|
847 0028 0948 ldr r0, .L53+8
|
|
|
|
|
848 .LVL70:
|
|
|
|
|
849 .loc 1 139 3 view .LVU197
|
|
|
|
|
850 002a 0068 ldr r0, [r0]
|
|
|
|
|
851 002c FFF7FEFF bl HAL_I2C_Master_Transmit
|
|
|
|
|
852 .LVL71:
|
|
|
|
|
140:Core/Src/PCA9535D_Driver.c **** }
|
|
|
|
|
853 .loc 1 140 1 view .LVU198
|
|
|
|
|
854 0030 05B0 add sp, sp, #20
|
|
|
|
|
855 .cfi_remember_state
|
|
|
|
|
856 .cfi_def_cfa_offset 4
|
|
|
|
|
857 @ sp needed
|
|
|
|
|
858 0032 5DF804FB ldr pc, [sp], #4
|
|
|
|
|
859 .LVL72:
|
|
|
|
|
860 .L50:
|
|
|
|
|
861 .cfi_restore_state
|
|
|
|
|
135:Core/Src/PCA9535D_Driver.c **** } else if (Port == PC9535_PORTB) {
|
|
|
|
|
862 .loc 1 135 10 is_stmt 1 view .LVU199
|
|
|
|
|
135:Core/Src/PCA9535D_Driver.c **** } else if (Port == PC9535_PORTB) {
|
|
|
|
|
863 .loc 1 135 13 is_stmt 0 view .LVU200
|
|
|
|
|
864 0036 0128 cmp r0, #1
|
|
|
|
|
865 0038 EFD1 bne .L51
|
2024-05-13 16:40:39 +02:00
|
|
|
|
ARM GAS C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s page 20
|
2024-05-12 14:08:58 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
136:Core/Src/PCA9535D_Driver.c **** command[0] = OUTPUT_REG_BASE_ADDRESS | 1;
|
|
|
|
|
866 .loc 1 136 5 is_stmt 1 view .LVU201
|
|
|
|
|
136:Core/Src/PCA9535D_Driver.c **** command[0] = OUTPUT_REG_BASE_ADDRESS | 1;
|
|
|
|
|
867 .loc 1 136 26 is_stmt 0 view .LVU202
|
|
|
|
|
868 003a 064B ldr r3, .L53+12
|
|
|
|
|
869 003c 1970 strb r1, [r3]
|
|
|
|
|
137:Core/Src/PCA9535D_Driver.c **** }
|
|
|
|
|
870 .loc 1 137 5 is_stmt 1 view .LVU203
|
|
|
|
|
137:Core/Src/PCA9535D_Driver.c **** }
|
|
|
|
|
871 .loc 1 137 16 is_stmt 0 view .LVU204
|
|
|
|
|
872 003e 0323 movs r3, #3
|
|
|
|
|
873 0040 8DF80C30 strb r3, [sp, #12]
|
|
|
|
|
874 0044 E9E7 b .L51
|
|
|
|
|
875 .L54:
|
|
|
|
|
876 0046 00BF .align 2
|
|
|
|
|
877 .L53:
|
|
|
|
|
878 0048 00000000 .word gpioa_shadow_reg_out
|
|
|
|
|
879 004c 00000000 .word deviceadr
|
|
|
|
|
880 0050 00000000 .word pcai2c
|
|
|
|
|
881 0054 00000000 .word gpiob_shadow_reg_out
|
|
|
|
|
882 .cfi_endproc
|
|
|
|
|
883 .LFE136:
|
|
|
|
|
885 .section .text.PCA9535_invertGPIOPortPolarity,"ax",%progbits
|
|
|
|
|
886 .align 1
|
|
|
|
|
887 .global PCA9535_invertGPIOPortPolarity
|
|
|
|
|
888 .syntax unified
|
|
|
|
|
889 .thumb
|
|
|
|
|
890 .thumb_func
|
|
|
|
|
892 PCA9535_invertGPIOPortPolarity:
|
|
|
|
|
893 .LVL73:
|
|
|
|
|
894 .LFB137:
|
|
|
|
|
141:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
142:Core/Src/PCA9535D_Driver.c **** void PCA9535_invertGPIOPortPolarity(uint8_t Port, uint8_t bitmask) {
|
|
|
|
|
895 .loc 1 142 68 is_stmt 1 view -0
|
|
|
|
|
896 .cfi_startproc
|
|
|
|
|
897 @ args = 0, pretend = 0, frame = 8
|
|
|
|
|
898 @ frame_needed = 0, uses_anonymous_args = 0
|
|
|
|
|
899 .loc 1 142 68 is_stmt 0 view .LVU206
|
|
|
|
|
900 0000 00B5 push {lr}
|
|
|
|
|
901 .cfi_def_cfa_offset 4
|
|
|
|
|
902 .cfi_offset 14, -4
|
|
|
|
|
903 0002 85B0 sub sp, sp, #20
|
|
|
|
|
904 .cfi_def_cfa_offset 24
|
|
|
|
|
143:Core/Src/PCA9535D_Driver.c **** uint8_t command[2] = {0x00, bitmask};
|
|
|
|
|
905 .loc 1 143 3 is_stmt 1 view .LVU207
|
|
|
|
|
906 .loc 1 143 11 is_stmt 0 view .LVU208
|
|
|
|
|
907 0004 0023 movs r3, #0
|
|
|
|
|
908 0006 8DF80C30 strb r3, [sp, #12]
|
|
|
|
|
909 000a 8DF80D10 strb r1, [sp, #13]
|
|
|
|
|
144:Core/Src/PCA9535D_Driver.c **** if (Port == PC9535_PORTA) {
|
|
|
|
|
910 .loc 1 144 3 is_stmt 1 view .LVU209
|
|
|
|
|
911 .loc 1 144 6 is_stmt 0 view .LVU210
|
|
|
|
|
912 000e 90B9 cbnz r0, .L56
|
|
|
|
|
145:Core/Src/PCA9535D_Driver.c **** gpioa_shadow_reg_inv = bitmask;
|
|
|
|
|
913 .loc 1 145 5 is_stmt 1 view .LVU211
|
|
|
|
|
914 .loc 1 145 26 is_stmt 0 view .LVU212
|
|
|
|
|
915 0010 0D4B ldr r3, .L59
|
2024-05-13 16:40:39 +02:00
|
|
|
|
ARM GAS C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s page 21
|
2024-05-12 14:08:58 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
916 0012 1970 strb r1, [r3]
|
|
|
|
|
146:Core/Src/PCA9535D_Driver.c **** command[0] = INPUT_POLARITY_INVERSION_REG_BASE_ADDRESS;
|
|
|
|
|
917 .loc 1 146 5 is_stmt 1 view .LVU213
|
|
|
|
|
918 .loc 1 146 16 is_stmt 0 view .LVU214
|
|
|
|
|
919 0014 0423 movs r3, #4
|
|
|
|
|
920 0016 8DF80C30 strb r3, [sp, #12]
|
|
|
|
|
921 .L57:
|
|
|
|
|
147:Core/Src/PCA9535D_Driver.c **** } else if (Port == PC9535_PORTB) {
|
|
|
|
|
148:Core/Src/PCA9535D_Driver.c **** gpiob_shadow_reg_inv = bitmask;
|
|
|
|
|
149:Core/Src/PCA9535D_Driver.c **** command[0] = INPUT_POLARITY_INVERSION_REG_BASE_ADDRESS | 1;
|
|
|
|
|
150:Core/Src/PCA9535D_Driver.c **** }
|
|
|
|
|
151:Core/Src/PCA9535D_Driver.c **** HAL_I2C_Master_Transmit(pcai2c, deviceadr, command, 2, 1000);
|
|
|
|
|
922 .loc 1 151 3 is_stmt 1 view .LVU215
|
|
|
|
|
923 001a 4FF47A73 mov r3, #1000
|
|
|
|
|
924 001e 0093 str r3, [sp]
|
|
|
|
|
925 0020 0223 movs r3, #2
|
|
|
|
|
926 0022 03AA add r2, sp, #12
|
|
|
|
|
927 0024 0949 ldr r1, .L59+4
|
|
|
|
|
928 .LVL74:
|
|
|
|
|
929 .loc 1 151 3 is_stmt 0 view .LVU216
|
|
|
|
|
930 0026 0978 ldrb r1, [r1] @ zero_extendqisi2
|
|
|
|
|
931 0028 0948 ldr r0, .L59+8
|
|
|
|
|
932 .LVL75:
|
|
|
|
|
933 .loc 1 151 3 view .LVU217
|
|
|
|
|
934 002a 0068 ldr r0, [r0]
|
|
|
|
|
935 002c FFF7FEFF bl HAL_I2C_Master_Transmit
|
|
|
|
|
936 .LVL76:
|
|
|
|
|
152:Core/Src/PCA9535D_Driver.c **** }
|
|
|
|
|
937 .loc 1 152 1 view .LVU218
|
|
|
|
|
938 0030 05B0 add sp, sp, #20
|
|
|
|
|
939 .cfi_remember_state
|
|
|
|
|
940 .cfi_def_cfa_offset 4
|
|
|
|
|
941 @ sp needed
|
|
|
|
|
942 0032 5DF804FB ldr pc, [sp], #4
|
|
|
|
|
943 .LVL77:
|
|
|
|
|
944 .L56:
|
|
|
|
|
945 .cfi_restore_state
|
|
|
|
|
147:Core/Src/PCA9535D_Driver.c **** } else if (Port == PC9535_PORTB) {
|
|
|
|
|
946 .loc 1 147 10 is_stmt 1 view .LVU219
|
|
|
|
|
147:Core/Src/PCA9535D_Driver.c **** } else if (Port == PC9535_PORTB) {
|
|
|
|
|
947 .loc 1 147 13 is_stmt 0 view .LVU220
|
|
|
|
|
948 0036 0128 cmp r0, #1
|
|
|
|
|
949 0038 EFD1 bne .L57
|
|
|
|
|
148:Core/Src/PCA9535D_Driver.c **** command[0] = INPUT_POLARITY_INVERSION_REG_BASE_ADDRESS | 1;
|
|
|
|
|
950 .loc 1 148 5 is_stmt 1 view .LVU221
|
|
|
|
|
148:Core/Src/PCA9535D_Driver.c **** command[0] = INPUT_POLARITY_INVERSION_REG_BASE_ADDRESS | 1;
|
|
|
|
|
951 .loc 1 148 26 is_stmt 0 view .LVU222
|
|
|
|
|
952 003a 064B ldr r3, .L59+12
|
|
|
|
|
953 003c 1970 strb r1, [r3]
|
|
|
|
|
149:Core/Src/PCA9535D_Driver.c **** }
|
|
|
|
|
954 .loc 1 149 5 is_stmt 1 view .LVU223
|
|
|
|
|
149:Core/Src/PCA9535D_Driver.c **** }
|
|
|
|
|
955 .loc 1 149 16 is_stmt 0 view .LVU224
|
|
|
|
|
956 003e 0523 movs r3, #5
|
|
|
|
|
957 0040 8DF80C30 strb r3, [sp, #12]
|
|
|
|
|
958 0044 E9E7 b .L57
|
|
|
|
|
959 .L60:
|
2024-05-13 16:40:39 +02:00
|
|
|
|
ARM GAS C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s page 22
|
2024-05-12 14:08:58 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
960 0046 00BF .align 2
|
|
|
|
|
961 .L59:
|
|
|
|
|
962 0048 00000000 .word gpioa_shadow_reg_inv
|
|
|
|
|
963 004c 00000000 .word deviceadr
|
|
|
|
|
964 0050 00000000 .word pcai2c
|
|
|
|
|
965 0054 00000000 .word gpiob_shadow_reg_inv
|
|
|
|
|
966 .cfi_endproc
|
|
|
|
|
967 .LFE137:
|
|
|
|
|
969 .section .text.PCA9535_readGPIOPortInput,"ax",%progbits
|
|
|
|
|
970 .align 1
|
|
|
|
|
971 .global PCA9535_readGPIOPortInput
|
|
|
|
|
972 .syntax unified
|
|
|
|
|
973 .thumb
|
|
|
|
|
974 .thumb_func
|
|
|
|
|
976 PCA9535_readGPIOPortInput:
|
|
|
|
|
977 .LVL78:
|
|
|
|
|
978 .LFB138:
|
|
|
|
|
153:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
154:Core/Src/PCA9535D_Driver.c **** uint8_t PCA9535_readGPIOPortInput(uint8_t Port) {
|
|
|
|
|
979 .loc 1 154 49 is_stmt 1 view -0
|
|
|
|
|
980 .cfi_startproc
|
|
|
|
|
981 @ args = 0, pretend = 0, frame = 8
|
|
|
|
|
982 @ frame_needed = 0, uses_anonymous_args = 0
|
|
|
|
|
983 .loc 1 154 49 is_stmt 0 view .LVU226
|
|
|
|
|
984 0000 70B5 push {r4, r5, r6, lr}
|
|
|
|
|
985 .cfi_def_cfa_offset 16
|
|
|
|
|
986 .cfi_offset 4, -16
|
|
|
|
|
987 .cfi_offset 5, -12
|
|
|
|
|
988 .cfi_offset 6, -8
|
|
|
|
|
989 .cfi_offset 14, -4
|
|
|
|
|
990 0002 84B0 sub sp, sp, #16
|
|
|
|
|
991 .cfi_def_cfa_offset 32
|
|
|
|
|
155:Core/Src/PCA9535D_Driver.c **** uint8_t command = 0;
|
|
|
|
|
992 .loc 1 155 3 is_stmt 1 view .LVU227
|
|
|
|
|
993 .loc 1 155 11 is_stmt 0 view .LVU228
|
|
|
|
|
994 0004 0023 movs r3, #0
|
|
|
|
|
995 0006 8DF80F30 strb r3, [sp, #15]
|
|
|
|
|
156:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
157:Core/Src/PCA9535D_Driver.c **** if (Port == PC9535_PORTB)
|
|
|
|
|
996 .loc 1 157 3 is_stmt 1 view .LVU229
|
|
|
|
|
997 .loc 1 157 6 is_stmt 0 view .LVU230
|
|
|
|
|
998 000a 0128 cmp r0, #1
|
|
|
|
|
999 000c 03D0 beq .L62
|
|
|
|
|
158:Core/Src/PCA9535D_Driver.c **** command |= INPUT_REG_BASE_ADDRESS;
|
|
|
|
|
159:Core/Src/PCA9535D_Driver.c **** else if (Port == PC9535_PORTA)
|
|
|
|
|
1000 .loc 1 159 8 is_stmt 1 view .LVU231
|
|
|
|
|
1001 .loc 1 159 11 is_stmt 0 view .LVU232
|
|
|
|
|
1002 000e 10B9 cbnz r0, .L62
|
|
|
|
|
160:Core/Src/PCA9535D_Driver.c **** command |= INPUT_REG_BASE_ADDRESS | 1;
|
|
|
|
|
1003 .loc 1 160 5 is_stmt 1 view .LVU233
|
|
|
|
|
1004 .loc 1 160 13 is_stmt 0 view .LVU234
|
|
|
|
|
1005 0010 0123 movs r3, #1
|
|
|
|
|
1006 0012 8DF80F30 strb r3, [sp, #15]
|
|
|
|
|
1007 .L62:
|
|
|
|
|
161:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
162:Core/Src/PCA9535D_Driver.c **** HAL_I2C_Master_Transmit(pcai2c, deviceadr, &command, 1, 1000);
|
|
|
|
|
1008 .loc 1 162 3 is_stmt 1 view .LVU235
|
2024-05-13 16:40:39 +02:00
|
|
|
|
ARM GAS C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s page 23
|
2024-05-12 14:08:58 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1009 0016 0D4D ldr r5, .L64
|
|
|
|
|
1010 0018 0D4C ldr r4, .L64+4
|
|
|
|
|
1011 001a 4FF47A76 mov r6, #1000
|
|
|
|
|
1012 001e 0096 str r6, [sp]
|
|
|
|
|
1013 0020 0123 movs r3, #1
|
|
|
|
|
1014 0022 0DF10F02 add r2, sp, #15
|
|
|
|
|
1015 0026 2978 ldrb r1, [r5] @ zero_extendqisi2
|
|
|
|
|
1016 0028 2068 ldr r0, [r4]
|
|
|
|
|
1017 .LVL79:
|
|
|
|
|
1018 .loc 1 162 3 is_stmt 0 view .LVU236
|
|
|
|
|
1019 002a FFF7FEFF bl HAL_I2C_Master_Transmit
|
|
|
|
|
1020 .LVL80:
|
|
|
|
|
163:Core/Src/PCA9535D_Driver.c **** uint8_t reval = 0;
|
|
|
|
|
1021 .loc 1 163 3 is_stmt 1 view .LVU237
|
|
|
|
|
1022 .loc 1 163 11 is_stmt 0 view .LVU238
|
|
|
|
|
1023 002e 0023 movs r3, #0
|
|
|
|
|
1024 0030 8DF80E30 strb r3, [sp, #14]
|
|
|
|
|
164:Core/Src/PCA9535D_Driver.c **** HAL_I2C_Master_Receive(pcai2c, deviceadr, &reval, 1, 1000);
|
|
|
|
|
1025 .loc 1 164 3 is_stmt 1 view .LVU239
|
|
|
|
|
1026 0034 0096 str r6, [sp]
|
|
|
|
|
1027 0036 0123 movs r3, #1
|
|
|
|
|
1028 0038 0DF10E02 add r2, sp, #14
|
|
|
|
|
1029 003c 2978 ldrb r1, [r5] @ zero_extendqisi2
|
|
|
|
|
1030 003e 2068 ldr r0, [r4]
|
|
|
|
|
1031 0040 FFF7FEFF bl HAL_I2C_Master_Receive
|
|
|
|
|
1032 .LVL81:
|
|
|
|
|
165:Core/Src/PCA9535D_Driver.c ****
|
|
|
|
|
166:Core/Src/PCA9535D_Driver.c **** return reval;
|
|
|
|
|
1033 .loc 1 166 3 view .LVU240
|
|
|
|
|
167:Core/Src/PCA9535D_Driver.c **** }
|
|
|
|
|
1034 .loc 1 167 1 is_stmt 0 view .LVU241
|
|
|
|
|
1035 0044 9DF80E00 ldrb r0, [sp, #14] @ zero_extendqisi2
|
|
|
|
|
1036 0048 04B0 add sp, sp, #16
|
|
|
|
|
1037 .cfi_def_cfa_offset 16
|
|
|
|
|
1038 @ sp needed
|
|
|
|
|
1039 004a 70BD pop {r4, r5, r6, pc}
|
|
|
|
|
1040 .L65:
|
|
|
|
|
1041 .align 2
|
|
|
|
|
1042 .L64:
|
|
|
|
|
1043 004c 00000000 .word deviceadr
|
|
|
|
|
1044 0050 00000000 .word pcai2c
|
|
|
|
|
1045 .cfi_endproc
|
|
|
|
|
1046 .LFE138:
|
|
|
|
|
1048 .section .bss.gpiob_shadow_reg_inv,"aw",%nobits
|
|
|
|
|
1051 gpiob_shadow_reg_inv:
|
|
|
|
|
1052 0000 00 .space 1
|
|
|
|
|
1053 .section .bss.gpioa_shadow_reg_inv,"aw",%nobits
|
|
|
|
|
1056 gpioa_shadow_reg_inv:
|
|
|
|
|
1057 0000 00 .space 1
|
|
|
|
|
1058 .section .data.gpiob_shadow_reg_dir,"aw"
|
|
|
|
|
1061 gpiob_shadow_reg_dir:
|
|
|
|
|
1062 0000 FF .byte -1
|
|
|
|
|
1063 .section .data.gpioa_shadow_reg_dir,"aw"
|
|
|
|
|
1066 gpioa_shadow_reg_dir:
|
|
|
|
|
1067 0000 FF .byte -1
|
|
|
|
|
1068 .section .bss.gpiob_shadow_reg_out,"aw",%nobits
|
|
|
|
|
1071 gpiob_shadow_reg_out:
|
2024-05-13 16:40:39 +02:00
|
|
|
|
ARM GAS C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s page 24
|
2024-05-12 14:08:58 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1072 0000 00 .space 1
|
|
|
|
|
1073 .section .bss.gpioa_shadow_reg_out,"aw",%nobits
|
|
|
|
|
1076 gpioa_shadow_reg_out:
|
|
|
|
|
1077 0000 00 .space 1
|
|
|
|
|
1078 .section .bss.deviceadr,"aw",%nobits
|
|
|
|
|
1081 deviceadr:
|
|
|
|
|
1082 0000 00 .space 1
|
|
|
|
|
1083 .section .bss.pcai2c,"aw",%nobits
|
|
|
|
|
1084 .align 2
|
|
|
|
|
1087 pcai2c:
|
|
|
|
|
1088 0000 00000000 .space 4
|
|
|
|
|
1089 .section .rodata
|
|
|
|
|
1090 .align 2
|
|
|
|
|
1091 .set .LANCHOR0,. + 0
|
|
|
|
|
1092 .LC0:
|
|
|
|
|
1093 0000 02000000 .ascii "\002\000\000\000\000\377\377"
|
|
|
|
|
1093 00FFFF
|
|
|
|
|
1094 .text
|
|
|
|
|
1095 .Letext0:
|
|
|
|
|
1096 .file 2 "c:\\users\\nived\\appdata\\roaming\\code\\user\\globalstorage\\bmd.stm32-for-vscode\\@xpa
|
|
|
|
|
1097 .file 3 "c:\\users\\nived\\appdata\\roaming\\code\\user\\globalstorage\\bmd.stm32-for-vscode\\@xpa
|
|
|
|
|
1098 .file 4 "Drivers/CMSIS/Device/ST/STM32F3xx/Include/stm32f302xc.h"
|
|
|
|
|
1099 .file 5 "Drivers/STM32F3xx_HAL_Driver/Inc/stm32f3xx_hal_def.h"
|
|
|
|
|
1100 .file 6 "Drivers/STM32F3xx_HAL_Driver/Inc/stm32f3xx_hal_dma.h"
|
|
|
|
|
1101 .file 7 "Drivers/STM32F3xx_HAL_Driver/Inc/stm32f3xx_hal_i2c.h"
|
2024-05-13 16:40:39 +02:00
|
|
|
|
ARM GAS C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s page 25
|
2024-05-12 14:08:58 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
DEFINED SYMBOLS
|
|
|
|
|
*ABS*:00000000 PCA9535D_Driver.c
|
2024-05-13 16:40:39 +02:00
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:21 .text.PCA9535_init:00000000 $t
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:27 .text.PCA9535_init:00000000 PCA9535_init
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:84 .text.PCA9535_init:00000044 $d
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:1087 .bss.pcai2c:00000000 pcai2c
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:1081 .bss.deviceadr:00000000 deviceadr
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:91 .text.PCA9535_setGPIOPinDirection:00000000 $t
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:97 .text.PCA9535_setGPIOPinDirection:00000000 PCA9535_setGPIOPinDirection
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:250 .text.PCA9535_setGPIOPinDirection:0000009c $d
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:1066 .data.gpioa_shadow_reg_dir:00000000 gpioa_shadow_reg_dir
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:1061 .data.gpiob_shadow_reg_dir:00000000 gpiob_shadow_reg_dir
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:259 .text.PCA9535_setGPIOPinOutput:00000000 $t
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:265 .text.PCA9535_setGPIOPinOutput:00000000 PCA9535_setGPIOPinOutput
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:417 .text.PCA9535_setGPIOPinOutput:00000098 $d
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:1076 .bss.gpioa_shadow_reg_out:00000000 gpioa_shadow_reg_out
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:1071 .bss.gpiob_shadow_reg_out:00000000 gpiob_shadow_reg_out
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:426 .text.PCA9535_invertGPIOPinPolarity:00000000 $t
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:432 .text.PCA9535_invertGPIOPinPolarity:00000000 PCA9535_invertGPIOPinPolarity
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:585 .text.PCA9535_invertGPIOPinPolarity:0000009c $d
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:1056 .bss.gpioa_shadow_reg_inv:00000000 gpioa_shadow_reg_inv
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:1051 .bss.gpiob_shadow_reg_inv:00000000 gpiob_shadow_reg_inv
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:594 .text.PCA9535_readGPIOPinInput:00000000 $t
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:600 .text.PCA9535_readGPIOPinInput:00000000 PCA9535_readGPIOPinInput
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:711 .text.PCA9535_readGPIOPinInput:00000084 $d
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:718 .text.PCA9535_setGPIOPortDirection:00000000 $t
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:724 .text.PCA9535_setGPIOPortDirection:00000000 PCA9535_setGPIOPortDirection
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:794 .text.PCA9535_setGPIOPortDirection:00000048 $d
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:802 .text.PCA9535_setGPIOPortOutput:00000000 $t
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:808 .text.PCA9535_setGPIOPortOutput:00000000 PCA9535_setGPIOPortOutput
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:878 .text.PCA9535_setGPIOPortOutput:00000048 $d
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:886 .text.PCA9535_invertGPIOPortPolarity:00000000 $t
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:892 .text.PCA9535_invertGPIOPortPolarity:00000000 PCA9535_invertGPIOPortPolarity
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:962 .text.PCA9535_invertGPIOPortPolarity:00000048 $d
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:970 .text.PCA9535_readGPIOPortInput:00000000 $t
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:976 .text.PCA9535_readGPIOPortInput:00000000 PCA9535_readGPIOPortInput
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:1043 .text.PCA9535_readGPIOPortInput:0000004c $d
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:1052 .bss.gpiob_shadow_reg_inv:00000000 $d
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:1057 .bss.gpioa_shadow_reg_inv:00000000 $d
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:1072 .bss.gpiob_shadow_reg_out:00000000 $d
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:1077 .bss.gpioa_shadow_reg_out:00000000 $d
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:1082 .bss.deviceadr:00000000 $d
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:1084 .bss.pcai2c:00000000 $d
|
|
|
|
|
C:\Users\nived\AppData\Local\Temp\ccYA9Eni.s:1090 .rodata:00000000 $d
|
2024-05-12 14:08:58 +02:00
|
|
|
|
|
|
|
|
|
UNDEFINED SYMBOLS
|
|
|
|
|
HAL_I2C_Master_Transmit
|
|
|
|
|
HAL_I2C_Master_Receive
|