FreeHIL
Loading...
Searching...
No Matches
FH_DO_Init_H.c File Reference

File Map:
FH_Root, Section FH_Perif, FH_DO (Digital Output), Cmd (Command), Init, Init_H (Init Health)
Functions in this file, verify the health of the different message frames related to DO (Digital Output) More...

#include "../../../../../../../FH_Embedded/FH_Root/FH_Perif/FH_DO/Cmd/Init/Init_H/FH_DO_Init_H.h"
#include "../../../../../../../FH_Embedded/FH_Root/FH_General/FH_GeneralFunctions/FH_GeneralFunctions.h"
#include "../../../../../../../FH_Embedded/FH_Setup/FH_DeviceAddress/FH_DeviceAddress.h"

Go to the source code of this file.

Functions

FH_ErrorInfo FH_DO_Init_H (FH_RFCommunication_Message *fh_RFCommunication_Message)
 This function verifies the health of FH_DO_Commands_Init command.
FH_ErrorInfo FH_DO_InitMULTI_H (FH_RFCommunication_Message *fh_RFCommunication_Message)
 This function verifies the health of FH_DO_Commands_InitMULTI command.

Detailed Description

File Map:
FH_Root, Section FH_Perif, FH_DO (Digital Output), Cmd (Command), Init, Init_H (Init Health)
Functions in this file, verify the health of the different message frames related to DO (Digital Output)

Attention
FH user could left this file intact

SPDX-License-Identifier: Apache-2.0

Copyright 2026 Vahid Hasirchi

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

For more information refer to FreeHIL.com

Definition in file FH_DO_Init_H.c.

Function Documentation

◆ FH_DO_Init_H()

FH_ErrorInfo FH_DO_Init_H ( FH_RFCommunication_Message * fh_RFCommunication_Message)

This function verifies the health of FH_DO_Commands_Init command.

Parameters
fh_RFCommunication_MessageThe message frame set by RobotFramework
  ==============================================================================
                        ##### RobotFramework Example #####
  ==============================================================================
  @{MessageData} =    Create List    ${DO01}
  &{Message}     =    Create Dictionary    DeviceAddress=${DeviceAddress_01}    Function=${Function_DO}    Command=${DO_Commands_Init}    Data=@{MessageData}
  ${Result}    SendMessage    &{Message}

  Comments:

  DO01 => It indicates the Digital Output 01
  DeviceAddress_01 => It shall be equal to the address of the device: FH_RFCommunication_DeviceAddress
  Function_DO => It is the function in the message frame
  DO_Commands_Init => It is the command of the function in the message frame
Returns
FH_ErrorInfo is returned

Definition at line 68 of file FH_DO_Init_H.c.

References FH_ErrorInfo::error_code, FH_DO_MaxPeripheralNumber, FH_DO_MinCommandSize_Init, FH_ERROR_MessageFrame, FH_ERROR_OK, FH_ResetErrorInfo(), and fh_RFCommunication_Message.

Referenced by FH_DO_ProcessCommand_Init().

◆ FH_DO_InitMULTI_H()

FH_ErrorInfo FH_DO_InitMULTI_H ( FH_RFCommunication_Message * fh_RFCommunication_Message)

This function verifies the health of FH_DO_Commands_InitMULTI command.

Parameters
fh_RFCommunication_MessageThe message frame set by RobotFramework
  ==============================================================================
                        ##### RobotFramework Example #####
  ==============================================================================
  @{MessageData} =    Create List    FF    FF    FF    FF    FF    FF    FF    FF
  &{Message}     =    Create Dictionary    DeviceAddress=${DeviceAddress_01}    Function=${Function_DO}    Command=${DO_Commands_InitMULTI}    Data=@{MessageData}
  ${Result}    SendMessage    &{Message}

  Comments:

  FF    FF    FF    FF    FF    FF    FF    FF => Example data as the first 8 parameters of the Data in the message frame utilized as mask (In this example it means all 64 digital outputs shall be initialized)
  DeviceAddress_01 => It shall be equal to the address of the device: FH_RFCommunication_DeviceAddress
  Function_DO => It is the function in the message frame
  DO_Commands_InitMULTI => It is the command of the function in the message frame
Returns
FH_ErrorInfo is returned

Definition at line 122 of file FH_DO_Init_H.c.

References FH_ErrorInfo::error_code, FH_DO_MinCommandSize_InitMULTI, FH_ERROR_MessageFrame, FH_ERROR_OK, FH_ResetErrorInfo(), and fh_RFCommunication_Message.

Referenced by FH_DO_ProcessCommand_InitMULTI().