- four seven segment able to count from 0 to 9999
- external push putton when pressed number pn seven segment increased by 1 with each putton pressed until reash to 9999
seven_segment_counter_task.mp4
- four seven segment able to count from 0 to 9999
- there are three push putton control the stow watch
seven_segment_Stop_watch.task.mp4
there are three object face a boy hole ,ramp and wall and there are three senatio faced aboy
- if aboy found ahole in the raw he dropped from ahole to next raw
- if aboy faced a ramp and above the ramp there is ahole he jump through the ramp and the hole to upper raw
- if aboy faced the wall and there is no holes or ramp on his way he crashed and the game end and print game over on lcd
LCD_running.boy.task.mp4
- analog to digital converter sense the analog volt from 0 to 5 volt
- lcd that show the voltage in volt or mvolt
- push putton control the showing value in volt or mvolt on lcd
ADC.with.lcd.show.voltage.task.mp4
- potenshowmeter to control the required volume
- analog to digital converter sense the range of value indicated to the required volume
- lcd show the indicated volume
ADC.volume.show.lcd.mp4
-
The program starts with initializing the LCD and keypad and initializing the calculator to start accepting inputs for the first operand
-
Every operand can consist of 5 digits and have a maximum of 65,535 because the variable is an unsigned 16-bit integer
-
The program doesn't support floats or negative values. If you make a subtraction operation, the program checks which operand is bigger and calculates the difference between them, avoiding negative values
calculator.task.mp4
TASK7.ALARM.WITH.SELECTED.TIME.mp4
TASK8.STOP.WATCH.USING.TIMER.mp4
is used to control the internal peripherals, as well as the reset signals and clock distribution. The RCC gets several internal (LSI, HSI and CSI) and external (LSE and HSE) clocks. They are used as clock sources for the hardware blocks, either directly or indirectly, via the PLL that allow to achieve high frequencies. There are three
- HSI oscillator clock
- HSE oscillator clock
- PLL clock
a. first argument enable selected clock through RCC clock control register (RCC_CR) and configuar th first argument as the system clock through (RCC_CFGR)
b.second argumen disable selected clock through RCC clock control register (RCC_CR)
a.this function check if passed clock in argument is enabled or not if enabled return 1 in check_clk_on_flag argument and vise versa
a.enable clock through RCC clock control register (RCC_CR) for HEI,HSE and PLL but not configuar the system clock
PLL_VCO = (HSE_VALUE or HSI_VALUE / PLL_M) * PLL_N
COPY_u8M=16 : PLL_M division to 16 to get the comparison frequency1 MHz
Copy_u16N =192 PLL_N 192*1MHZ (192),
Copy_u8SrcPll=0 ---0: HSI clock selected as PLL
SYSCLK = PLL_VCO / PLL_P
Copy_u8P=1 (VCO/ PLLP(2))
this function enable clock on selected bus in the first argument
and the preioheral we want enable clock on it in the second argument
this function disable clock on selected bus in the first argument
and the preioheral we want disable clock on it in the second argument
The clocks are divided with the new prescaler factor from 1 to 16 AHB cycles after HPRE write.
is a pin on an IC (Integrated Circuit). It can be used for driving loads, reading digital and analog signals, controlling external components, generating triggers for external devices etc. Each of the general-purpose I/O ports has two 32-bit configuration registers, two 32-bit data registers, a 32-bit set/reset register , a 16-bit reset register and a 32-bit locking register.
Input floating
Input pull-up
Input-pull-down Analog
Output open-drain
Output push-pull
Alternate function push-pull
Alternate function open-drain
GpioPinCfg_t led_configuraion={GPIO_MODE_u64_OUTPUT_PP,GPIO_PUPD_u32_FLOATING,GPIO_SPEED_LOW,GPIO_PIN_01,GPIO_PORT_B};
GpioPinCfg_t led_configuraion={GPIO_MODE_u64_INPUT,GPIO_PUPD_u32_PULL_UP,GPIO_SPEED_MEDIUM,GPIO_PIN_00,GPIO_PORT_B};
when i set pin1 in portB as input pullup we notice the regesters are changed except IDR that suppose it deected high as he connected on pullup but the regester value and passed argument not channged i thought that KEIL no support directly changed in hardware pullup input mode
SysTick is a simple timer that is part of the NVIC controller in the Cortex-M microprocessor. Its intended purpose is to provide a periodic interrupt
The systick a 24-bit system timer, SysTick, that counts down from the reload value to zero, reloads the value in the STK_LOAD register on the next clock edge, then counts down on subsequent clocks
working on AHP/8 prescaller so we need cont 2000 to reach 1 ms so i made counter for COUNTER_MS variable that every ISR for SYSTICK decressed and when this var reach to zero that mean reach the required
ms timing and we can take action
Enables the counter. When ENABLE the counter loads the RELOAD value from the LOAD register and then counts down. On reaching 0, it sets the COUNTFLAG to 1 and optionally asserts the SysTick depending on the value of TICKINT. It then loads the RELOAD
value again, and begins counting.
ISR_SYSTICK is excuted after COUNTER_MS reached to zero after excuted the output pin2 in PORTB become HIGH
tacking another action when COUNTER_MS become zero and after excuted the callBack function i Disable STK Interrupt and Stop Timer