src/luos.c
static error_return_t Luos_ReadAlias(uint16_t local_id, uint8_t *alias)
{
    uint32_t addr = ADDRESS_ALIASES_FLASH + (local_id * (MAX_ALIAS_SIZE + 1));
    LuosHAL_FlashReadLuosMemoryInfo(addr, 16, (uint8_t *)alias);
    // Check name integrity
    if ((((alias[0] < 'A') | (alias[0] > 'Z')) & ((alias[0] < 'a') | (alias[0] > 'z'))) | (alias[0] == '\0'))
    {
        return FAILED;
    }
    else
    {
        return SUCCEED;
    }
}
/******************************************************************************
 * @brief read alias from flash
 * @param position in the route table
 * @param alias to store
 * @return error
 ******************************************************************************/
@brief read alias from flash
@param position in the route table
@param alias to store
@return error
@brief read alias from flash @param position in the route table @param alias to store @return error
static error_return_t Luos_ReadAlias(uint16_t local_id, uint8_t *alias)
{
    uint32_t addr = ADDRESS_ALIASES_FLASH + (local_id * (MAX_ALIAS_SIZE + 1));
    LuosHAL_FlashReadLuosMemoryInfo(addr, 16, (uint8_t *)alias);
    if ((((alias[0] < 'A') | (alias[0] > 'Z')) & ((alias[0] < 'a') | (alias[0] > 'z'))) | (alias[0] == '\0'))
    {
        return FAILED;
    }
    else
    {
        return SUCCEED;
    }
}
static error_return_t Luos_ReadAlias ( uint16_t local_id , uint8_t * alias ) { uint32_t addr = ADDRESS_ALIASES_FLASH + ( local_id * ( MAX_ALIAS_SIZE + 1 ) ) ; LuosHAL_FlashReadLuosMemoryInfo ( addr , 16 , ( uint8_t * ) alias ) ; if ( ( ( ( alias [ 0 ] < ' ' ) | ( alias [ 0 ] > ' ' ) ) & ( ( alias [ 0 ] < ' ' ) | ( alias [ 0 ] > ' ' ) ) ) | ( alias [ 0 ] == ' \0 ' ) ) { return FAILED ; } else { return SUCCEED ; } }
@brief read alias from flash
 @param position in the route table
 @param alias to store
 @return error
@brief read alias from flash @param position in the route table @param alias to store @return error
// Check name integrity