Does anyone have this problem with FT800 / Gameduino?

General questions about Firewing...

Does anyone have this problem with FT800 / Gameduino?

Postby Coccoliso » Wed Sep 09, 2015 10:54 am

Hi,
I found a set of widgets that crashes the command list.
Removing the comment from any of the lines in the example the next instruction (the CMD_TEXT) is not executed and is not executed even the test on the tag.

Code: Select all
clock = 80
#option _gccOptimise = Os
#option FT_MODEL = GAMEDUINO      ' enable for Gameduino 2
imports Ft800

Sub Main()
   Ft.SelfCalibrate()
   dim i as byte
   while true
      ft.Clear()
      tagmask(0)     
      CMD_SCROLLBAR(12, 26, 16, 160, 0, 120, 60, 480)
      CMD_GAUGE(353, 46, 36, 0, 4, 8, 40, 100)
      CMD_CLOCK(437, 46, 36, 0, 13, 51, 17, 0)
      CMD_NUMBER(442, 150, 28, 0, 42)
      '  CMD_PROGRESS(115, 57, 180, 12, 0, 20, 100)
      '  CMD_SLIDER(112, 114, 80, 8, 0, 30, 100)
      '  CMD_DIAL(429, 221, 36, 0, 6144)
      '  CMD_SPINNER(346, 221, 0, 0)
      '  CMD_TOGGLE(220, 168, 40, 27, 0, 0, "on" & cchar(255) & "off")
      ft.cmd_text(240, 136, 31, OPT_CENTER, "Hello world")
     
      i = Ft.GetTag() 
      Ft.cmd_text(15, 240, 27, 0, "Selected Tag : " + cstr(i))       
      Ft.Swap()       
   end while
End Sub


I tried it on Gameduino and EVE and the result is the same.
The only thing I noticed is that in the source of cmd_dial is missing the 2 postincrement ( but does not solve it by putting it ).
Has anyone found something similar and/or solved?
User avatar
Coccoliso
 
Posts: 128
Joined: Sat Sep 27, 2014 10:02 am

Re: Does anyone have this problem with FT800 / Gameduino?

Postby Jerry Messina » Sat Sep 12, 2015 10:21 am

Did you ever have any luck with this?

I uncommented the code lines, looked at the compiler output and it looks ok on the surface.

I even ran it in the simulator and all the code is there/"working". I don't know what it would do on real hdw.
Jerry Messina
 
Posts: 255
Joined: Thu Feb 14, 2013 10:16 am

Re: Does anyone have this problem with FT800 / Gameduino?

Postby Coccoliso » Sun Sep 13, 2015 5:29 am

Hi Jerry.
If I remove the comment to one of the command lines the cmd_text is not executed.
Strange.
Than the original library have enabled the sound with the two lines that I found in a post.

Other test..
now I use the original FW FT800.bas library and the result is the same.
User avatar
Coccoliso
 
Posts: 128
Joined: Sat Sep 27, 2014 10:02 am

Re: Does anyone have this problem with FT800 / Gameduino?

Postby Jerry Messina » Sun Sep 13, 2015 9:56 am

I'm just running the code in MPSIM, and for me the calls to cmd_text ARE getting executed.

I wonder if maybe they're just not doing the correct thing because of one of the previous calls? I wouldn't see that since I'm not running with an FT800.
Jerry Messina
 
Posts: 255
Joined: Thu Feb 14, 2013 10:16 am

Re: Does anyone have this problem with FT800 / Gameduino?

Postby Coccoliso » Sun Jan 29, 2017 4:48 pm

Hi at all,

was an issue that I raised and that led me to change needs to go around ..
but today I had a little time to try again led to solution of the enigma.
In these subs he loses command buffer alignment
- cmd_progress
- cmd_slider
- cmd_dial
- cmd_track
and any subsequent instruction in the buffer is ignored until the next cycle.

Code: Select all
'********************************************************************************
'* Name    :                                                                    *
'* Purpose :                                                                    *
'********************************************************************************
public sub cmd_progress(x as short, y as short, w as short, h as short, options as ushort, val as ushort, range as ushort)
   cmd(FT_CMD_PROGRESS)
   wr16(RAM_CMD+cmd_offset, x)
   cmd_increment2()
   wr16(RAM_CMD+cmd_offset, y)
   cmd_increment2()
   wr16(RAM_CMD+cmd_offset, w)
   cmd_increment2()
   wr16(RAM_CMD+cmd_offset, h)
   cmd_increment2()
   wr16(RAM_CMD+cmd_offset, options)
   cmd_increment2()
   wr16(RAM_CMD+cmd_offset, val)
   cmd_increment2()
   wr16(RAM_CMD+cmd_offset, range)
   cmd_increment2()   
   wr16(RAM_CMD+cmd_offset, 0)               // 29/1/2017 
   cmd_increment2()                          // 29/1/2017
end sub

'********************************************************************************
'* Name    :                                                                    *
'* Purpose :                                                                    *
'********************************************************************************
public sub cmd_slider(x as short, y as short, w as ushort, h as ushort, options as ushort, val as ushort, range as ushort)
   cmd(FT_CMD_SLIDER)
   wr16(RAM_CMD+cmd_offset, x)
   cmd_increment2()
   wr16(RAM_CMD+cmd_offset, y)
   cmd_increment2()
   wr16(RAM_CMD+cmd_offset, w)
   cmd_increment2()
   wr16(RAM_CMD+cmd_offset, h)
   cmd_increment2()
   wr16(RAM_CMD+cmd_offset, options)
   cmd_increment2()
   wr16(RAM_CMD+cmd_offset, val)
   cmd_increment2()
   wr16(RAM_CMD+cmd_offset, range)
   cmd_increment2()
   wr16(RAM_CMD+cmd_offset, 0)         // 29/1/2017
   cmd_increment2()                    // 29/1/2017
end sub

'********************************************************************************
'* Name    :                                                                    *
'* Purpose :                                                                    *
'********************************************************************************
public sub cmd_dial(x as short, y as short, r as short, options as ushort, val as ushort)
   cmd(FT_CMD_DIAL)
   wr16(RAM_CMD+cmd_offset, x)
   cmd_increment2()
   wr16(RAM_CMD+cmd_offset, y)
   cmd_increment2()
   wr16(RAM_CMD+cmd_offset, r)
   cmd_increment2()
   wr16(RAM_CMD+cmd_offset, options)
   cmd_increment2()
   wr16(RAM_CMD+cmd_offset, val)
   cmd_increment2()                    // 29/1/2017
   wr16(RAM_CMD+cmd_offset, 0)         // 29/1/2017
   cmd_increment2()                    // 29/1/2017
end sub

'********************************************************************************
'* Name    :                                                                    *
'* Purpose :                                                                    *
'********************************************************************************
public sub cmd_track(x as short, y as short, w as ushort, h as ushort, tag as byte)
   cmd(FT_CMD_TRACK)
   wr16(RAM_CMD+cmd_offset, x)
   cmd_increment2()
   wr16(RAM_CMD+cmd_offset, y)
   cmd_increment2()
   wr16(RAM_CMD+cmd_offset, w)
   cmd_increment2()
   wr16(RAM_CMD+cmd_offset, h)
   cmd_increment2()
   wr16(RAM_CMD+cmd_offset, tag)
   cmd_increment2()     
   wr16(RAM_CMD+cmd_offset, 0)      // 29/1/2017
   cmd_increment2()                 // 29/1/2017
end sub




changing the sub as above now I can use more objects and also the tracking works.
Still remains a problem with cmd_spinner
User avatar
Coccoliso
 
Posts: 128
Joined: Sat Sep 27, 2014 10:02 am


Return to Questions

Who is online

Users browsing this forum: No registered users and 1 guest

cron

x