- Samsung Galaxy S26 - szeret, nem szeret
- Samsung Galaxy A54 - türelemjáték
- One mobilszolgáltatások
- Külföldi prepaid SIM-ek itthon
- Szivárognak a OnePlus Nord CE6 Lite specifikációi
- iPhone topik
- Jolla és SailfishOS tapasztalatcsere
- Android alkalmazások - szoftver kibeszélő topik
- Apple iPhone 13 - hízott, de jól áll neki!
- Vivo X300 - kicsiben jobban megéri
Új hozzászólás Aktív témák
-
tototos
addikt
Sziasztok!
Egy kis macro segítség kellene. A következő sorokat szeretném kiváltani macroval:
task_Function[0] = task1;
task_Function[1] = task2;
task_Function[2] = task3;
task_Function[3] = task4;
task_Function[4] = task5;
task_Function[5] = task6;
task_Function[6] = task7;
static portTASK_FUNCTION(task1,params){
portTickType xLastWakeTime;
const portTickType xFrequency = RTOS_tasks[0].period_ldu32 / portTICK_RATE_MS;
// Initialize the xLastWakeTime variable with the current time.
xLastWakeTime = xTaskGetTickCount();
while(1)
{
RTOS_tasks[0].taskFunction(params);
// Wait for the next cycle.
vTaskDelayUntil( &xLastWakeTime, xFrequency );
}
}
static portTASK_FUNCTION(task2,params){
portTickType xLastWakeTime;
const portTickType xFrequency = RTOS_tasks[1].period_ldu32 / portTICK_RATE_MS;
// Initialize the xLastWakeTime variable with the current time.
xLastWakeTime = xTaskGetTickCount();
while(1)
{
RTOS_tasks[1].taskFunction(params);
// Wait for the next cycle.
vTaskDelayUntil( &xLastWakeTime, xFrequency );
}
}
static portTASK_FUNCTION(task3,params){
portTickType xLastWakeTime;
const portTickType xFrequency = RTOS_tasks[2].period_ldu32 / portTICK_RATE_MS;
// Initialize the xLastWakeTime variable with the current time.
xLastWakeTime = xTaskGetTickCount();
while(1)
{
RTOS_tasks[2].taskFunction(params);
// Wait for the next cycle.
vTaskDelayUntil( &xLastWakeTime, xFrequency );
}
}
static portTASK_FUNCTION(task4,params){
portTickType xLastWakeTime;
const portTickType xFrequency = RTOS_tasks[3].period_ldu32 / portTICK_RATE_MS;
// Initialize the xLastWakeTime variable with the current time.
xLastWakeTime = xTaskGetTickCount();
while(1)
{
RTOS_tasks[3].taskFunction(params);
// Wait for the next cycle.
vTaskDelayUntil( &xLastWakeTime, xFrequency );
}
}
static portTASK_FUNCTION(task5,params){
portTickType xLastWakeTime;
const portTickType xFrequency = RTOS_tasks[4].period_ldu32 / portTICK_RATE_MS;
// Initialize the xLastWakeTime variable with the current time.
xLastWakeTime = xTaskGetTickCount();
while(1)
{
RTOS_tasks[4].taskFunction(params);
// Wait for the next cycle.
vTaskDelayUntil( &xLastWakeTime, xFrequency );
}
}
static portTASK_FUNCTION(task6,params){
portTickType xLastWakeTime;
const portTickType xFrequency = RTOS_tasks[5].period_ldu32 / portTICK_RATE_MS;
// Initialize the xLastWakeTime variable with the current time.
xLastWakeTime = xTaskGetTickCount();
while(1)
{
RTOS_tasks[5].taskFunction(params);
// Wait for the next cycle.
vTaskDelayUntil( &xLastWakeTime, xFrequency );
}
}
static portTASK_FUNCTION(task7,params){
portTickType xLastWakeTime;
const portTickType xFrequency = RTOS_tasks[6].period_ldu32 / portTICK_RATE_MS;
// Initialize the xLastWakeTime variable with the current time.
xLastWakeTime = xTaskGetTickCount();
while(1)
{
RTOS_tasks[6].taskFunction(params);
// Wait for the next cycle.
vTaskDelayUntil( &xLastWakeTime, xFrequency );
}
}Meg lehet ezt valósítani? Köszi.
Új hozzászólás Aktív témák
● olvasd el a téma összefoglalót!
● ha kódot szúrsz be, használd a PROGRAMKÓD formázási funkciót!
- Dell XPS 13 9310 i7-1185G7 16GB 512GB 13" FHD+ 1 év garancia
- Samsung Galaxy S24 Ultra 512GB,Újszerű,Dobozaval,12 hónap garanciával
- Lenovo IdeaPad Slim 3 Ryzen 7 8840HS 15" FHD+ 16GB 1000GB Teljeskörű garancia
- Dell Precision 3571 i7-12700H 32GB 1000GB FHD RTX T600 4GB 1 év teljeskörű garancia
- Dell Precision 3571 i7-12700H 16GB 512GB FHD RTX T600 4GB 1 év teljeskörű garancia
- Honor Magic6 Pro 512GB, Kártyafüggetlen, 1 Év Garanciával
- Samsung Galaxy Z Fold6 12/256GB Silver Shadow használt, karcmentes 6 hónap garancia
- Transcend 512GB NVME SSD // 100% // Számla // Garancia //
- HIBÁTLAN iPhone 13 Pro Max 256GB Sierra Blue -1 ÉV GARANCIA - Kártyafüggetlen, MS4302
- AKCIÓ! Palit Gaming Pro RTX 3070 Ti 8GB videokártya garanciával hibátlan működéssel
Állásajánlatok
Cég: Laptopműhely Bt.
Város: Budapest

