BRT Community

Please login or register.

Login with username, password and session length
Advanced search  

News:

Welcome to the Bridgetek Community!

Please read our Welcome Note

Technical Support enquires
please contact the team
@ Bridgetek Support

Please refer to our website for detailed information on all our products - Bridgetek - Bridging Technology

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Messages - Rudolph

Pages: 1 ... 19 20 [21] 22 23 ... 27
301
Discussion - EVE / Re: UTF-8 Encoding Error
« on: May 08, 2020, 09:40:32 AM »
When putting both the .glyph and the .xfont into the FLASH, the address setup in EAB is not used anyways.
EAB adapts the address contained in the .xfont file automatically to whatever the .glyph ends up at.

See: http://www.brtcommunity.com/index.php?topic=26.msg93#msg93

Okay, you still need to either load the .xfont file from FLASH to RAM-G or use the changed .xfont file that is written
when creating the .bin for the FLASH.

302
Discussion - EVE / Re: UTF-8 Encoding Error
« on: April 29, 2020, 06:11:36 PM »
When I try to convert Symbola.ttf with EAB 1.4 to extended format, a size of 12 and "Full Unicode Characters" I get this in the "Result" window:
"unknown freetype error"
According to Fontrdop Symbola has 7956 glyphs.

When I switch to a NotoSans-Regular.ttf with 3246 glyphs it takes a while but completes.
Two issues though.
The reported amount of characters in the .xfont file is always 0x00010000.
And the compression ratio when I zip the resulting NotoSans-Regular_12_ASTC.glyph is really high:
1473 kB -> 96 kB

Sure, this is not fair since zip can work with the complete set at once.
But when I open the NotoSans-Regular_12_ASTC.glyph in a hex-editor it looks like this:

0000 FC FD FF FF FF FF FF FF 00 00 00 00 00 00 FF FF ................
0010 FC FD FF FF FF FF FF FF 00 00 00 00 00 00 FF FF ................
0020 66 68 18 80 46 18 18 10 18 10 7F 7F 28 10 04 28 fh..F.......(..(
0030 07 0A 11 00 00 80 5F 5C 61 33 13 20 84 00 11 42 ......_\a3. ...B
0040 66 00 00 B6 01 00 00 40 00 00 00 00 00 00 00 00 f......@........
0050 66 00 00 30 00 00 00 00 00 00 00 C0 00 00 00 80 f..0............
0060 FC FD FF FF FF FF FF FF 00 00 00 00 00 00 FF FF ................
0070 FC FD FF FF FF FF FF FF 00 00 00 00 00 00 FF FF ................
0080 FC FD FF FF FF FF FF FF 00 00 00 00 00 00 FF FF ................
0090 FC FD FF FF FF FF FF FF 00 00 00 00 00 00 FF FF ................
00A0 FC FD FF FF FF FF FF FF 00 00 00 00 00 00 FF FF ................
00B0 FC FD FF FF FF FF FF FF 00 00 00 00 00 00 FF FF ................
00C0 FC FD FF FF FF FF FF FF 00 00 00 00 00 00 FF FF ................
00D0 FC FD FF FF FF FF FF FF 00 00 00 00 00 00 FF FF ................

Is this really compressed?


The example works, sort of, it displays the arrow.
But it deletes the Symbola_85_ASTC.glyph and Symbola_85_ASTC.xfont files in the resources dir when you start it.
Under "Content" it shows errors.





303
Discussion - EVE / Re: UTF-8 Encoding Error
« on: April 09, 2020, 10:16:43 AM »
As the 25th of march has passed now, any ETA for the new EAB?
I would not mind giving a beta a spin if it shows up in the "Test and Review Area".

304
Discussion - EVE / Re: BRT AN 033 BT81X Series Programming Guide
« on: April 08, 2020, 06:05:24 PM »
But what is the reason for the escalation?

We went from:

Code: [Select]
1. Send Host command “CLKEXT” to FT81X, if an external clock is used.
2. Send Host command “ACTIVE” to enable the clock to the FT81X. FT81X starts its selfdiagnosis process and may take up to 300ms. Alternatively, read REG_ID repeatedly until
0x7C is read.
3. Configure video timing registers, except REG_PCLK

to

Code: [Select]
1. Send host command “CLKEXT” if the PLL input is from external crystal oscillator or external
clock.
2. Send host command “CLKSEL” to select system clock frequency if the non-default system
clock is to be used.
By default the system clock is set to 60MHz. However, 72MHz is recommended for better performance.
3. Send Host command “ACTIVE” and wait for at least 300 milliseconds.
4. Read REG_ID till it is 0x7C
5. Read REG_CPUREST till EVE goes into the working status.
6. Configure display control timing registers, except REG_PCLK

and now

Code: [Select]
1. Send host command “CLKEXT” if the PLL input is from external crystal oscillator or external
clock.
2. Send host command “CLKSEL” to select system clock frequency if the non-default system
clock is to be used.
By default the system clock is set to 60MHz. However, 72MHz is recommended for better performance.
3. Send Host command “ACTIVE” and wait for at least 300 milliseconds. Ensure that there is
no SPI access during this time.
4. Read REG_ID till it is 0x7C
5. Read REG_CPUREST till EVE goes into the working status.
6. Configure display control timing registers, except REG_PCLK

To repeat my question:
Why has this changed to a fixed 300ms?
And why was this made stricter now and forbids SPI access during this time?

I am doing this now and it works just fine:

Code: [Select]
0. drive PD_N low, wait 6ms, drive PD_N high, wait 21 ms
1. Send Host command “CLKEXT” to FT81X, if an external clock is used.
2. If we have a BT81x: Send host command “CLKSEL”
3. Send Host command “ACTIVE” to enable the clock
4. Read REG_ID till it is 0x7C or exit if 400ms have passed
5. Read REG_CPUREST till EVE goes into the working status or exit if 50ms have passed
6. Tell BT81x that it runs at 72MHz
7. Reconfigure or patch the touch-controller if necessary
8. disable the backlight
9. Configure video timing registers, except REG_PCLK

I could throw in a delay_ms(40) between 3 and 4 to leave EVE alone for a moment, based on my above measurements.
But 300ms does really not seem to be necessary, it even is excessive for the FT81x.
And I never had an issue with reading REG_ID directly after ACTIVE.


305
Discussion - EVE / Re: BRT AN 033 BT81X Series Programming Guide
« on: April 01, 2020, 06:34:18 PM »
Okay, read-only would be back to the FT81x documentation.  :)

I saw this before and just hooked up my Logik Analyzer again to verify it,
EVE does not respond at all on the SPI during reset.

BT815_startup_01.png : just zoomed out from the end of the Power-Down Delay to the first couple of responses
BT815_startup_02.png : zoom-in on the first access with CLKEXT, CLKSEL and ACTIVE
BT815_startup_03.png : zoom-in on the SPI traffic before the first response
BT815_startup_04.png : zoom-in on the first two responses.
The first answer from EVE is the 0x7c my code is waiting for.
After that my code starts to read REG_CPURESET and the answer is 0x02 which means that the touch-controller is not done resetting.

Looks a bit like it EVE is locked but then at least host commands CLKEXT, CLKSEL and ACTIVE are working.

This makes me wonder what happens if I send EVE more host commands right after ACTIVE. :)
But then, it works now, no need to break it on purpose. :)

306
Discussion - EVE / BRT AN 033 BT81X Series Programming Guide
« on: March 31, 2020, 07:50:43 PM »
I noticed that version 1.2 has been released and when I checked the revision history I "only" lists clarifications for CMD_ANIMFRAME.
When I compared that to version 1.1 I found that the new document has fewer pages as well.
So I sent it thru a diff tool.

Some reformating, minor fixes, excellent.
The offset for REG_SPI_WIDTH is still wrong though.


Then I found this in chapter 2.4 on page 15:
3. Send Host command “ACTIVE” and wait for at least 300 milliseconds. Ensure that there is
no SPI access during this time.
4. Read REG_ID till it is 0x7C

This is from the version 1.1:
3. Send Host command “ACTIVE” and wait for at least 300 milliseconds.
4. Read REG_ID till it is 0x7C

And for comparision, this is from the FT81x guide 1.2:
2. Send Host command “ACTIVE” to enable the clock to the FT81X. FT81X starts its selfdiagnosis process and may take up to 300ms.
 Alternatively, read REG_ID repeatedly until 0x7C is read.

Why has this changed to a fixed 300ms and why was this made stricter now and forbids SPI access during this time?

I am using this for years now:
Code: [Select]
while(chipid != 0x7C) /* if chipid is not 0x7c, continue to read it until it is, EVE needs a moment for it's power on self-test and configuration */
{
DELAY_MS(1);
chipid = EVE_memRead8(REG_ID);
timeout++;
if(timeout > 400)
{
return 0;
}
}

And i works just fine with BT81x as well, I only increased the timeout to 400ms.

But for this post I went a step ahead and measured how long a couple of displays actually need:

EVE2-35G: 69
EVE3-35G: 42
EVE3-35G initialised as EVE2-35G: 75
EVE3-43G: 42
EVE3-43G initialised as EVE2-43G: 69
RiFT43: 42
EVE2-50G: 77
EVE3-50G: 42
EVE3-50G initialised as EVE2-50G: 72

No, these are not all my displays but the pattern is obvious.
FT81x need less than 80ms.
BT815 need less than 45ms since I set their clock to 72MHz.
And when I use a BT815 like a FT813 the startup delay becomes very similar.

Is there any compelling reason why I still should switch to a fixed delay of 300ms with no SPI access?

307
Discussion - EVE / Re: 812 vs 813 display differences?
« on: March 22, 2020, 10:40:34 PM »
Regarding the display, FT810, FT811, FT812 and FT813 are all the same, with FT810 and FT811 supporting only 6 bits per color.
Also the BT815 and BT816 can be used with the same code, the step from EVE2 to EVE3 is an expansion as opposed to the more severe changes from EVE1 to EVE2.
The touch engine in the FT811/FT813 works in compatibility mode after reset with single touch only.

And regarding the NHD-5.0 displays, I just opened the two datasheets.
The display parameters and electrical characteristics are identical.
And the schematics only differ in regards of the touch.

So yes, it should work to just swap the displays.

308
Discussion - EVE / CMD_GETMATRIX
« on: March 01, 2020, 09:24:13 PM »
Hello,

why is this command named *GET*MATRIX?
This is not all what it does and it definately does not do the opposite of what SETMATRIX does.

GETMATRIX should be named SETMATRIX.
And the one that is now named SETMATRIX should be named ACTIVATEMATRIX.
And maybe a counter-part to what the current GETMATRIX does is missing.

That is if I am not completely wrong here.

309
Test and Review Area / Re: BRT_AN_025 Beta - Portable MCU library for EVE
« on: February 25, 2020, 10:01:26 PM »
Hello,

Thanks,
It is good to get your thoughts on the code and we'll certainly go through and review your concerns and recommendations.

Just keep in mind that I am not trying to be rude here or attacking you.
But with Englisch not beeing my native language I sometimes struggle to write as polite as I intend to.
So if I overstep somewhere, please point it out to me.

Quote
The STM32 one was built using the Keil uVision IDE.

Okay, I was wrong, it does indeed compile just fine without any change when using Keil uVision IDE.
I just can not test it.

Edit: and Keil really is a tad bit to intrusive for me.

What made me believe that it probably would not build is for example the chip-select functions
in EVE_MCU_STM32.c.
These look like this:
Code: [Select]
inline void MCU_CSlow(void)
{
  HAL_GPIO_WritePin(GPIOB, GPIO_PIN_6, GPIO_PIN_RESET); //lo
  //Nop();
}

Having a function declared as "inline" from within a .c file usually does not work.

The function in my EVE_MCU_ATSAMC21.c is this:
Code: [Select]
void MCU_CSlow(void)
{
PORT->Group[EVE_CS_PORT].OUTCLR.reg = EVE_CS;
}

And it will not compile when I put "inline" in front of it.
Well, I am using GCC and the Keil µVision IDE uses the ARM compiler, maybe that is it.

There are other issues though.
Why is eve_example.h defining the platform_calib_xxx() functions that are in main.c?
Why is MCU.h defining MCU_Setup() that is in main.c?
Why are so many modules over-including files they do not even need?
Why is EVE_MCU_STM32.c setting up the system clock?
What is the purpose of all these byte-swapping functions and why are they in EVE_MCU_xx.c?

Quote
This library does use SPI burst writes and so the address is only sent once and the commands are then streamed over SPI And so it works in a similar way to your library.

We thought our functions here...
EVE_LIB_BeginCoProList(); // CS low and send address
commands
EVE_LIB_EndCoProList(); // CS high and update REG_CMD_WRITE
EVE_LIB_AwaitCoProEmpty();     // Wait pointers becoming equal

... were quite similar to your functions here...
EVE_start_cmd_burst(); EVE_end_cmd_burst(); EVE_cmd_start(); 

You are right, I hooked up a logic-analyzer and attached two logfiles.
I created these with a Logic 16 from Saleae.
This clearly shows now that you actually are using a command-burst.
I assumed wrongly your version does not burst since it put the execution times so much closer together
when I switched it off for my version.

Unfortunately this makes the different in speed quite a lot bigger.
With my version commands are transfered in 248µs plus 7,16µs for the command to execute.
With your version I get a command, sometimes two or more of 14µs before the burst, 337µs for the commands and
13.34µs for the command to execute.

Oh yes, I do not check if the command-fifo is ready.
This is because apart from loading images it is always ready to accept more data as soon as you execute the fifo.
EVE just is this fast to execute the fifo, there is not much of a chance to be faster.
The only thing that I found so far that really takes time is decoding .png images.
And then there is that I am only writing every 20ms to the FIFO and always check for the execution time
during development of a HMI.

The command to execute is of course only the write to REG_CMD_WRITE.
For your version I right now have the sequence 0xb0 0x20 0xfc 0xec 0x08 0x00 0x00 on the screen.
It takes 1.58µs from chip-select-low to the first rising clock.
The gaps between the bytes are: 0.66µs, 0.76µs, 2.48µs, 0.68µs and 0.76µs.
And the time from the last falling clock to the rising chip select is 1.34µs.

For my version I ended up with the sequence 0xb0 0x20 0xfc 0x84 0x07.
Okay, first difference, I only write REG_CMD_WRITE as 16 bits - as the valid range is 12 bits anyways.
It takes 0.44µs from chip-select-low to the first rising clock.
The gaps between the bytes are: 0.66µs, 0.68µs, 0.9µs and 0.82µs.
And the time from the last falling clock to the rising chip select is 0.56µs.

I would like to know what you measure with your system, preferably of course with the STM32 and
runnning the SPI at 12MHz. :-)

This is my start-command:
Code: [Select]
/* order the command co-processor to start processing its FIFO queue and do not wait for completion */
void EVE_cmd_start(void)
{
uint32_t ftAddress;

#if defined (EVE_DMA)
if(EVE_dma_busy)
{
return; /* just do nothing if a dma transfer is in progress */
}
#endif

ftAddress = REG_CMD_WRITE; /* this changes between EVE 80x and 81x, so as a constant at compile-time the compiler should happily optimize away the following bit-shifting */

EVE_cs_set();
spi_transmit((uint8_t)(ftAddress >> 16) | MEM_WRITE); /* send Memory Write plus high address byte */
spi_transmit((uint8_t)(ftAddress >> 8)); /* send middle address byte */
spi_transmit((uint8_t)(ftAddress));      /* send low address byte */
spi_transmit((uint8_t)(cmdOffset));      /* send data low byte */
spi_transmit((uint8_t)(cmdOffset >> 8)); /* send data high byte */
EVE_cs_clear();
}

All of the code at the bottom is replaced with inline code though.
There is no function beeing called.
It sure does cost a couple kB of code extra but I worry about that if I actually run out of memory. :-)
And with the BT81x this is even less of an issue.

Quote
We may have some duplication however. There could be cases where this is needed (e.g. if you execute a command and then want to perform other register or memory actions when complete rather than send a new co-pro list) and so we do check for the completion of the commands at the end of the list as well as at the start. We may be able to optimise this however to make it run faster.

Sure, my code does read the touch registers every 5 ms and as you can see in my test-code I usually read the size of the display list right before building a new one in order to be able to keep an eye on its size.
The TFT_touch() function in my current project does check if EVE is busy, mostly due to my use of DMA,
but also because the little overhead does no harm there since the function has a very short runtime overall.
And it uses a CMD_TRACK for a slider with my EVE_cmd_execute() function for this which waits for completion of the command.
But when I check this with the logic-analyzer I usually see the command, the write to REG_CMD_WRITE and only a single read of REG_CMD_READ since EVE executes this faster than I can check if she is busy.
So for this I could even change to EVE_cmd_start() since building the next display list is at least a return-from-function and a call-function away.
But then again, the usually <50µs for the touch function are neglectable in comparison with building the display list.
My current project has a display list that takes >1ms to build, even without any SPI transfers due to DMA.

310
Test and Review Area / Re: BRT_AN_025 Beta - Portable MCU library for EVE
« on: February 21, 2020, 04:03:22 PM »
Since this looks nothing like the EVE HAL 2.0 but is very close to my own library, is it planned to add an exporter for this to the EVE Screen Editor?


Edit: I started to port an example to a platform that I can actually use to test this.
And my first feedback really is - what the heck?

Edit: I ported it now, sort of,  and I seriously doubt that the STM32 example even compiles.
Your library has quite some issues and I would not really call it portable code.
What goes where, which include is used for what, this is a mess so far.

Please provide a sample project that builds with PlatformIO.


Anyways, I modified the eve_display() function in eve_example.c:

Code: [Select]
#define BRT_LOGO_W 147
#define BRT_LOGO_H 60

void eve_display(void)
{
uint32_t counter = 0;

EVE_LIB_BeginCoProList();
EVE_CMD_DLSTART();
EVE_CLEAR_COLOR_RGB(0, 0, 0);
EVE_CLEAR(1,1,1);
EVE_COLOR_RGB(255, 255, 255);

EVE_CMD_NUMBER(120, 460, 28, EVE_OPT_RIGHTX|5, num_profile_a); /* duration in µs for this function */

EVE_CMD_NUMBER(70, 100, 28, EVE_OPT_RIGHTX|5, BRT_LOGO_W);
EVE_CMD_NUMBER(70, 130, 28, EVE_OPT_RIGHTX|5, BRT_LOGO_H);

EVE_BEGIN(EVE_BEGIN_BITMAPS);
EVE_CMD_SETBITMAP(0, EVE_FORMAT_RGB565, BRT_LOGO_W, BRT_LOGO_H);

// Set origin on canvas using EVE_VERTEX_TRANSLATE.
EVE_VERTEX_TRANSLATE_X(((EVE_DISP_WIDTH/2)-(BRT_LOGO_W/2)) * 16);
EVE_VERTEX2II(0, 0, 0, 0);
EVE_VERTEX_TRANSLATE_X(0);

EVE_CMD_TEXT(EVE_DISP_WIDTH/2, BRT_LOGO_H+10, 29, EVE_OPT_CENTERX, "Touch the counter");

EVE_TAG(100);
EVE_COLOR_RGB(255, 0, 0);

EVE_CMD_NUMBER(400, 240, 30, EVE_OPT_CENTER|5, counter);

EVE_DISPLAY();
EVE_CMD_SWAP();
EVE_LIB_EndCoProList();
EVE_LIB_AwaitCoProEmpty();
}

Not to make it display a fancier list but to allow to call it from main() every 20ms.
I also removed the touch as I am using an EVE2-35G for the test and it uses a GT911 which I
did not want to patch into your library.

I also removed the custom font and the use of bitmap-handle 7 for the logo in order to not have
to add this to my own code as well.

I completely replaced main.c with my own and used the same code to init the core, the timer and the SPI in both projects.
Same toolchain, same optimisation level (-O2).
And of course I am using one hardware, for this test a board I designed with an ATSAMC21E18A, this is a Cortex-M0+ running at 48MHz.
Oh yes, I also disabled DMA for my own library.

Now when I run your version with the function above the number printed for the var num_profile_a is 942.
It takes 942µs to run the function once.

There is one optimisation, remove the last line: "EVE_LIB_AwaitCoProEmpty();".
This is completely safe, for one it is part of "EVE_LIB_BeginCoProList();" anyways and then the function
is now called only once every 20ms and not anymore as fast as the controller could make the loop.

Without the line the time spend in the function drops to 372µs.

In my own library this looks like this:
Code: [Select]
#define BRT_LOGO_W 147
#define BRT_LOGO_H 60

void TFT_display(void)
{
uint32_t counter = 0;

if(tft_active != 0)
{
EVE_start_cmd_burst(); /* start writing to the cmd-fifo as one stream of bytes, only sending the address once */

EVE_cmd_dl(CMD_DLSTART); /* start the display list */
EVE_cmd_dl(DL_CLEAR_RGB | BLACK); /* set the default clear color to black */
EVE_cmd_dl(DL_CLEAR | CLR_COL | CLR_STN | CLR_TAG); /* clear the screen - this and the previous prevent artifacts between lists, Attributes are the color, stencil and tag buffers */

EVE_cmd_dl(DL_COLOR_RGB | WHITE);

EVE_cmd_number(120, 460, 28, EVE_OPT_RIGHTX|5, num_profile_a); /* duration in µs for this function */

EVE_cmd_number(70, 100, 28, EVE_OPT_RIGHTX|5, BRT_LOGO_W);
EVE_cmd_number(70, 130, 28, EVE_OPT_RIGHTX|5, BRT_LOGO_H);

EVE_cmd_dl(DL_BEGIN | EVE_BITMAPS);
EVE_cmd_setbitmap(MEM_LOGO, EVE_RGB565, BRT_LOGO_W, BRT_LOGO_H);

// Set origin on canvas using EVE_VERTEX_TRANSLATE.
EVE_cmd_dl(VERTEX_TRANSLATE_X(((EVE_HSIZE/2)-(BRT_LOGO_W/2)) * 16));
EVE_cmd_dl(VERTEX2II(0, 0, 0, 0));
EVE_cmd_dl(VERTEX_TRANSLATE_X(0));

EVE_cmd_text(EVE_HSIZE/2, BRT_LOGO_H+10, 29, EVE_OPT_CENTERX, "Touch the counter");

EVE_cmd_dl(TAG(100));
EVE_cmd_dl(DL_COLOR_RGB | RED);
EVE_cmd_number(400, 240, 30, EVE_OPT_CENTER|5, counter);

EVE_cmd_dl(DL_DISPLAY); /* instruct the graphics processor to show the list */
EVE_cmd_dl(CMD_SWAP); /* make this list active */

EVE_end_cmd_burst(); /* stop writing to the cmd-fifo */
EVE_cmd_start(); /* order the command co-processor to start processing its FIFO queue but do not wait for completion */
}
}

This also shows why I asked about the EVE Screen Editor output, I could almost directly use that. :-)
And I already plan to add more functions to replace the EVE_cmd_dl() calls.

This takes 259µs to execute.
When I remove the EVE_start_cmd_burst()/EVE_end_cmd_burst() lines this goes up to 351µs.

What this does is described in the comment: /* start writing to the cmd-fifo as one stream of bytes, only sending the address once */
This removes three bytes of overhead from every command by not sending the adress in the FIFO over and over again.

When I also make the function wait for the FIFO to be empty the time goes up to 917µs.

So  my library is 25µs faster under the same conditions, 21µs without waiting and 113µs with the litte burst-trick.
Sure, this is not much but this also is a very short display llist.

And just for the kicks since I can not do this with your library.  8)
When I enable DMA by setting "EVE_DMA" in my EVE_target.h and not changing anything else, the time drops to 82µs.

To be totally unfair that is 942µs for your example and 82µs for my version.  :o

311
There are several issues with your code.

The first is that there is no way to tell how often this will be called.
If this is called directly from the arduino loop() function it will be called way too often per second.
You need to limit your calls to less what the framerate is, for example to once per 20ms.

The next thing is that this will only draw one rectangle which bounces around.

And the last issue is that for a low value of average, all if()s will be true.
Whatever the value of "average" actually is, it is not defined or changed in the function.

Start smaller?

Code: [Select]
Ft_Gpu_CoCmd_Dlstart(phost);
Ft_App_WrCoCmd_Buffer(phost, CLEAR(1, 1, 1));


Ft_App_WrCoCmd_Buffer(phost, BEGIN(RECTS));

Ft_App_WrCoCmd_Buffer(phost, COLOR_RGB(255, 255, 255));
Ft_App_WrCoCmd_Buffer(phost, VERTEX2F(10 * 16,  10 * 16));
Ft_App_WrCoCmd_Buffer(phost, VERTEX2F(90 *16, 90 * 16));

Ft_App_WrCoCmd_Buffer(phost, COLOR_RGB(255, 0, 0));
Ft_App_WrCoCmd_Buffer(phost, VERTEX2F(100 * 16,  10 * 16));
Ft_App_WrCoCmd_Buffer(phost, VERTEX2F(190 *16, 100 * 16));

Ft_App_WrCoCmd_Buffer(phost, COLOR_RGB(0, 255, 0));
Ft_App_WrCoCmd_Buffer(phost, VERTEX2F(200 * 16,  10 * 16));
Ft_App_WrCoCmd_Buffer(phost, VERTEX2F(290 *16, 100 * 16));

Ft_App_WrCoCmd_Buffer(phost, COLOR_RGB(0, 0, 255));
Ft_App_WrCoCmd_Buffer(phost, VERTEX2F(300 * 16,  10 * 16));
Ft_App_WrCoCmd_Buffer(phost, VERTEX2F(390 *16, 100 * 16));

Ft_App_WrCoCmd_Buffer(phost, END());


Ft_App_WrCoCmd_Buffer(phost, DISPLAY());
Ft_Gpu_CoCmd_Swap(phost);
Ft_App_Flush_Co_Buffer(phost);
Ft_Gpu_Hal_WaitCmdfifo_empty(phost);


I was doing some tests with Arduino earlier this evening anyways and also uploaded
a new Arduino example using PlatformIO to my Github-Repository: https://github.com/RudolphRiedel/FT800-FT813

The attached archive is a very slightly modified version of this.
platformio.ini: changed env, platform and board
EVE_config.h: activated EVE_NHD_50
EVE_target.h: changed EVE_CS in line 851 to "10" to match the New Haven NHD-FT81x-SHIELD

It builds just fine in Visual Studio Code using the PlatformIO plugin.
And as the main file is named src.ino in also can be opened with the Arduino IDE and builds just fine for the Due.

I can not test it however as I do not have a Due, the shield or the display.

Apart from the touch however it should work fine.
The reason why the touch probably is not working is because I do not have calibration data for the display.

Edit: I forgot to change the "SPI.setClockDivider(SPI_CLOCK_DIV2);" in src.ino
But as it turns out, this is defined as "11" for the Due and does not mean clock divided by two. :-)
This can be replaced with
Code: [Select]
SPI.setClockDivider(8); to speed things up a little.

312
Discussion - EVE / Re: issue with EVE Asset Builder 1.2.0
« on: February 11, 2020, 08:12:18 PM »
Well, as I wrote, I already avoid dithering by converting my images with the image convert tool:
https://brtchip.com/wp-content/uploads/Utilities/Image%20Convert%20Tool%20V0.9.1.zip

It would be nice though to use the EVE Asset Builder instead as it is supposed to be used.

I just tried the "EVE Image Conversion Utility 0.9.5" which is included in "eab_tools.exe".
And while it shows the same effect that the dithering hinders it's zlib compression for legacy formats,
converting to at least ASTC 8x8 is not effected by the dithering option.


313
Discussion - EVE / Re: The Christmas list for BT82X
« on: January 22, 2020, 06:13:04 PM »
There is very little that we know of the BT817 so far, and I know better than asking before the show. :-)


"4th generation EVE products supporting 24-bit interface and up to 1280x800 pixels"

This by itself is not exactly a new feature, you can have that with the FT813 already.
You do need a RGB/LVDS converter chip though as you will not find a TFT with 1280x800
and RGB interface.
I would find an integrated LVDS interfaces a lot more exciting.  8)

"Fully compatible to BT815 with 50% performance enhancement"

This is what makes the 1280x800 above a whole lot more interesting.
*If* this translates to 108MHz clock and *if* nothing is changed about the clock-system,
this means that REG_PCLK = 2 results in a pixel-clock of 54 MHz.
One display with 1280x800 I just found has typical 823 lines and 1440 clocks per line.
So at 54MHz pixel-clock this would give us 45 frames per second - rather sweet.
If such a board is carefully designed and really allows REG_PCLK = 2.

"Supports for non-square pixel TFT panel"

I can not really put my finger on what this really means.
That you can put in a small factor by which the image is stretched in X or Y direction in order
to make circles appear as circles on panels with non-square pixels?

"Support colour palettes, object creation, anti-aliasing, bimap transformation alpha masking and widgets drawing"

Core features of EVE, no doubt, but not exactly news?

"Capacitive and resistive touch options available"

For the EVE family overall? Or does this mean there also is a BT818?

314
Discussion - EVE / Re: The Christmas list for BT82X
« on: January 21, 2020, 06:09:42 PM »
I have annother one to wish for.  :)

Unless I am missing something, using CMD_PROGRESS, CMD_SLIDER or CMD_SCROLLBAR are bit weird to use vertically.
The top position is, the bottom is max.
So for CMD_SLIDER and CMD_SCROLLBAR I always have to use position = max - current.
And well, that works okay, no big deal.

But CMD_PROGRESS does not really work.
You can not fill up the bar from bottom to top to for example indicate water level or battery power.
Yes, okay, you can invert the colors but filling the bar looks strange as it is rounded.

So my suggestion is to add an OPT_REVERSE for CMD_PROGRESS, CMD_SLIDER or CMD_SCROLLBAR to not only have them work from left to right and from top to bottom, but from right to left and from bottom to top as well.

315
Discussion - EVE / issue with EVE Asset Builder 1.2.0
« on: January 20, 2020, 05:33:17 PM »
Edit: I am not sure where my head was yesterday evening.

Converting images with the EVE Asset Builder v1.2.0 to ARGB1555 with compression results in rather large files and I suspect this is due to dithering beeing turned on by default.

I attached an archive with two button images that I converted using the image convert tool and EAB.
The result from EAB is very similar to what "img_cvt.exe" produces when not switching dithering off.
And the result with dithering off is a lot smaller.

I am using .png images for GUI elements and logos in order to not get compression related noise
in my images, this is kind of pointless when the converter deliberately adds noise.

Can we please have a checkbox in EAB to disable the dithering?
Preferably so that dithering is off by default, please.

Does the converter use dithering for BT81x ASTC images as well? If so - why???

Pages: 1 ... 19 20 [21] 22 23 ... 27