Sfoglia il codice sorgente

Merge pull request #1 from zxmarcos/master

lcdFree
pull/54/head
cail 7 anni fa
committed by GitHub
parent
commit
c0425001b8
2 ha cambiato i file con 18 aggiunte e 0 eliminazioni
  1. +16
    -0
      devLib/lcd.c
  2. +2
    -0
      devLib/lcd.h

+ 16
- 0
devLib/lcd.c Vedi File

@@ -498,3 +498,19 @@ int lcdInit (const int rows, const int cols, const int bits,

return lcdFd ;
}


/*
* lcdFree:
* Free a LCD handle.
*********************************************************************************
*/

void lcdFree (const int fd)
{
if ((fd >= 0) && (fd < MAX_LCDS))
{
free(lcds[fd]);
lcds[fd] = NULL;
}
}

+ 2
- 0
devLib/lcd.h Vedi File

@@ -47,6 +47,8 @@ extern int lcdInit (const int rows, const int cols, const int bits,
const int d0, const int d1, const int d2, const int d3, const int d4,
const int d5, const int d6, const int d7);

extern void lcdFree (const int fd);

#ifdef __cplusplus
}
#endif

Caricamento…
Annulla
Salva