Jump to content

Component: FTDI (FT800) (FT800) (Misc)

From Flowcode Help
Revision as of 18:59, 16 November 2021 by Wiki bot (talk | contribs) (Created page with "{| style="width:50%" |- | width="20%" style="color:gray;" | Author | MatrixTSL |- | width="20%" style="color:gray;" | Version | 2.0 |- | width="20%" style="color:gray;...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Author MatrixTSL
Version 2.0
Category Misc


FTDI (FT800) component

The FT800 provides a powerful feature set in a small package to create dynamic HMI interfaces. The device supports line by line graphics rendering to 1/16 of a pixel on displays with resolution up to 512 x 512 with 262K colours. The chip includes a touch controller for sensing touch feedback from a TFT display with a resistive touch panel as well as a sound synthesizer and audio playback with a PWM output to drive a speaker.

Detailed description

No detailed description exists yet for this component

Examples

No additional examples

Downloadable macro reference

IncrementCommandOffset
Adds commandSize to the currentOffset. Checks for 4K ring-buffer offset roll-over  
- UINT currentOffset
graphics processor command list pointer 
- BYTE commandSize
number of bytes to increment the offset 
- UINT Return


MemRead16
Reads a single unsigned int from the FT800 internal address space 
- ULONG Address
 
- UINT Return


MemRead8
Reads a single data byte from the FT800 internal address space 
- ULONG Address
 
- BYTE Return


MemRead32
Reads a single unsigned long from the FT800 internal address space 
- ULONG Address
 
- ULONG Return


MemWrite16
Writes a unsigned int value to the FT800 internal address space 
- ULONG Address
 
- UINT Data
 
- VOID Return


MemWrite8
Writes a byte value to the FT800 internal address space 
- ULONG Address
 
- BYTE Data
 
- VOID Return


CommandWrite
Sends FT800 command 
- BYTE Command
 
- VOID Return


MemWrite32
Writes a unsigned long value to the FT800 internal address space 
- ULONG Address
 
- ULONG Data
 
- VOID Return


Initialise
System initialization routines. Executed once on reset. Returns 0 if device not detected or 1 if device is correctly initialised. 
- BYTE Return


ReadFileLength
Returns the number of bytes in the current sector that are used by the current open file. Return = 512 - Sector is filled with file data Return < 512 - Last sector of the file, Retval specifies how many bytes of data are remaining in the sector 
[[File:]] - Return


OpenFile
Searches for and opens a file for reading or writing from within the current directory on the disk. Returns 0 for success. 
- STRING Filename
8.3 filename of the file we are trying to open e.g. "file.txt" 
- BYTE Return


WriteFileSector
 
- BYTE Return


AppendStringToFile
 
- STRING Data_String
 
- BYTE Return


ReadFileSize
Reads the entire size of the current file in bytes. 
- ULONG Return


ReadFileLength
Returns the number of bytes in the current sector that are used by the current open file. Return = 512 - Sector is filled with file data Return < 512 - Last sector of the file, Retval specifies how many bytes of data are remaining in the sector 
[[File:]] - Return


OpenFile
Searches for and opens a file for reading or writing from within the current directory on the disk. Returns 0 for success. 
- STRING Filename
8.3 filename of the file we are trying to open e.g. "file.txt" 
- BYTE Return


WriteFileSector
Overwrites the current sector on the memory card with the contents of the local sector buffer. See write_byte_to_buffer function. Return = 0 - File sector written successfully. Return > 0 - File sector write error 
- BYTE Return


SetFileIndex
Sets the current file index and used to switch between several open file streams. Default = 0.  
- BYTE File_Index
File index ranges from 0 to (Max Concurrent Files - 1) 
- VOID Return


AppendStringToFile
Adds the contents of the data string parameter to the end of the currently open file. Returns 0 for success. 
- STRING Data_String
Data to append to the end of the file 
- BYTE Return


SetByte
 
- ULONG Int
 
- BYTE Ix
 
- BYTE Value
 
- VOID Return


ReadFileSize
Reads the entire size of the current file in bytes. 
- ULONG Return


GetByte
Gets a byte from an int 
- ULONG Int
 
- BYTE Ix
 
- BYTE Return


SetTimeAndDate
Sets the current time and date. Time = (Hour << 11) + (Min << 5) + (Sec >> 1) Date = (YearFrom1980 << 9) + (Month << 5) + (Day) Additional details can be found here: http://www.maverick-os.dk/FileSystemFormats/FAT16_FileSystem.html#TimeFormat 
- UINT Time
Sets the current Time in FAT Time format hhhhhmmmmmmsssss - S=Secs/2 
- UINT Date
Sets the current Date in FAT Date format yyyyyyymmmmddddd - Y=Years since 1980 
- VOID Return


Initialise
Attempts to communicate with the SD card and if successful sets up the file system. Returns 0 for success.  
- BYTE Return



Property reference

Properties
Channel
SPI Channel selector 
Prescale
Prescale option selector 
MOSI
SPI Data Out Pin SDO - Also Known as Master Out Slave In (MOSI) when used in Master mode. 
MISO
SPI Data In Pin SDI - Also Known as Master In Slave Out (MISO) when used in Master mode. 
CLK
SPI Clock Pin CLK - The Clock signal is driven by the SPI master. 
Power Pin
 
CS Pin
 
Width
Active width of LCD display 
Height
Active height of LCD display 
HCycle
Total number of clocks per line 
HOffset
Start of active line 
HSync0
Start of horizontal sync pulse 
HSync1
End of horizontal sync pulse 
VCycle
Total number of lines per screen 
VOffset
Start of active screen 
VSync0
Start of vertical sync pulse 
VSync1
End of vertical sync pulse 
PixelClock
Pixel Clock  
Swizzle
Define RGB output pins 
Clock Polarity
Define active edge of PCLK  
Connections
Simulations
Scope Traces
Selects if the scope traces are automatically generated or not 
Console Data
Selects if the console data is automatically generated or not 
API