Unable to connect

Post any software related questions or comments here. This is also the place to ask for help if you can't figure out how to do something in Wave59.
abacaba
Posts: 145
Joined: Sat Aug 15, 2015 5:02 pm
Contact:

Unable to connect

Post by abacaba » Wed Jan 04, 2023 12:49 pm

After installing the new TWS 1.20.1.6 version required by them for CBOE data, I am unable to connect using broker interface. Price data comes through via API but chart trading is not available. I've reviewed all settings -- all check out. I'll open a ticket. Anyone else having this problem?
tws connection lost.PNG
tws connection lost.PNG (15.39 KiB) Viewed 67147 times

sbank
Posts: 177
Joined: Tue Jul 21, 2015 9:35 pm
Contact:

Re: Unable to connect

Post by sbank » Wed Jan 04, 2023 5:46 pm

I see the same problem with any version greater than 9.x of TWS. (I use DTN IQfeed for my data so I haven't been forced to upgrade yet...)

lexa007
Posts: 18
Joined: Sun Jan 15, 2017 6:17 am
Contact:

Re: Unable to connect

Post by lexa007 » Fri Aug 18, 2023 6:06 am

Did you manage to solve the issue? As i am having the same problem with IB

sbank
Posts: 177
Joined: Tue Jul 21, 2015 9:35 pm
Contact:

Re: Unable to connect

Post by sbank » Mon Aug 21, 2023 12:39 pm

I was able to solve this on my own.

I ended up going through the IB API section line by line a toggling everything. (Ofcourse the setting that fixed it was at the bottom.)

Here is a screenshot of TWS 10.23. Everything works *except* I cannot use the "quick" button in Wave59. It is not a huge concern for me since I am not a scalper, but I did find that functionality useful at times.
2023-07-31_12-28-31.png
2023-07-31_12-28-31.png (250.76 KiB) Viewed 66656 times

lexa007
Posts: 18
Joined: Sun Jan 15, 2017 6:17 am
Contact:

Re: Unable to connect

Post by lexa007 » Tue Aug 22, 2023 8:15 am

sbank wrote:
Mon Aug 21, 2023 12:39 pm
I was able to solve this on my own.

I ended up going through the IB API section line by line a toggling everything. (Ofcourse the setting that fixed it was at the bottom.)

Here is a screenshot of TWS 10.23. Everything works *except* I cannot use the "quick" button in Wave59. It is not a huge concern for me since I am not a scalper, but I did find that functionality useful at times.

2023-07-31_12-28-31.png

You are a star mate! Thank you very much!!

lexa007
Posts: 18
Joined: Sun Jan 15, 2017 6:17 am
Contact:

Re: Unable to connect

Post by lexa007 » Thu Aug 24, 2023 6:09 am

sbank wrote:
Mon Aug 21, 2023 12:39 pm
I was able to solve this on my own.

I ended up going through the IB API section line by line a toggling everything. (Ofcourse the setting that fixed it was at the bottom.)

Here is a screenshot of TWS 10.23. Everything works *except* I cannot use the "quick" button in Wave59. It is not a huge concern for me since I am not a scalper, but I did find that functionality useful at times.

2023-07-31_12-28-31.png
Yes there seems to be a transmit issue with market orders. IBPLACEORDER transmits limit orders but not market ones. The market order is placed in IB but never transmits but i think this is an IB issue. Just to update

sbank
Posts: 177
Joined: Tue Jul 21, 2015 9:35 pm
Contact:

Re: Unable to connect

Post by sbank » Thu Aug 24, 2023 5:02 pm

My QScripts are able to place Market orders (FWIW). ¯\_(ツ)_/¯

lexa007
Posts: 18
Joined: Sun Jan 15, 2017 6:17 am
Contact:

Re: Unable to connect

Post by lexa007 » Thu Aug 24, 2023 5:37 pm

sbank wrote:
Thu Aug 24, 2023 5:02 pm
My QScripts are able to place Market orders (FWIW). ¯\_(ツ)_/¯
Mine not! It would be great for the small community that is left, if you could share an example code? You have been very helpful thus far!

sbank
Posts: 177
Joined: Tue Jul 21, 2015 9:35 pm
Contact:

Re: Unable to connect

Post by sbank » Fri Aug 25, 2023 2:18 pm

Ya know, you might be on to something about all market orders. I looked at all my code, and I place limit orders, wait, then convert to market if the order doesn't fill.

Here is my boilerplate code I use for everything (this is out of Earik's Mechanical Trading book):

Code: Select all

if (barnum == barsback) {                                                                                                                                               
    bs=0;                                                            
    signal=0;
    gomarket_hour=15;
    gomarket_minute=59;
    gomarket_second=40;
}
position = ib_marketposition();

# implement trading system
if ((signal>0) and (bs<=0)) {
   buy(1,close,"market","onebar");
   bs=1;
   
   # live orders
   if ((position <= 0) and (autotrade == true)){
        contracts = cts + abs(position);
        IB_CancelAll();
        ref=IB_PlaceOrder("buy",contracts,close,"limit","day","");
        ib_gomarketattime(ref,year,month,day,gomarket_hour,gomarket_minute,gomarket_second);
   }
}
This is for daily bars. Make sure you set the chart up with the option to "run scripts 1 minute before the close."

lexa007
Posts: 18
Joined: Sun Jan 15, 2017 6:17 am
Contact:

Re: Unable to connect

Post by lexa007 » Thu Sep 14, 2023 8:05 am

Image

Market orders no longer works with W59....has to be MKT PRT, however that need Earik to update the software.
Attachments
combine_images.jpg
combine_images.jpg (275.97 KiB) Viewed 64961 times
combine_images.jpg
combine_images.jpg (275.97 KiB) Viewed 64961 times

Post Reply

Who is online

Users browsing this forum: No registered users and 3 guests