<div dir="ltr"><div>trying putty with following Setting:</div><div><br></div><div>connect to COM1</div><div>baud 9600</div><div>data bits 8</div><div>stop bits 1 (or 2)</div><div>parity None</div><div>flow control XON / XOFF ( didn't Play with this Setting)</div><div><br></div><div><br></div><div>gave only "?"-Symbols when I wanted to write in the cmd-like window</div><div><br></div><div>now I am confused....</div><div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">2016-08-16 16:27 GMT+02:00 Philipp Mühlmann <span dir="ltr"><<a href="mailto:p.muehlmann@gmail.com" target="_blank">p.muehlmann@gmail.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div>OK,</div><div><br></div><div>it seems I need stopbit = 2; // at leas a working C-code has this setting</div><div><br></div><div><br></div><div>so:</div><div><br></div><div> h = openserial(1," 9600,n,8,2");</div><div><br></div><div>but with this, I get as a result the command back as a string when I use "readserial()"</div><div><br></div><div><br></div><div>Example:</div><div><br></div><div>h = openserial(1," 9600,n,8,2");</div><div><br></div><div>ret = writeserial(h, " *A_r_106_0 " );<br><br>result = readserial(h);</div><div><br></div><div>closeserial(h);</div><div><br></div><div><br></div><div>result is: A_r_106_0 as a string, but I expect it to be the Firmware Version</div><div class="gmail_extra"><br></div><div class="gmail_extra"><br></div><div class="gmail_extra">so to your questions:</div><span><div class="gmail_extra">
<br>
- Are you sure you have set the serial port correctly (delimiter, baud rate, parity, ...) ?</div></span><div class="gmail_extra"> -> Yes</div><span><div class="gmail_extra"><br></div><div class="gmail_extra"><br>
- Are you sure your controller is supposed to answer something to this command ?</div></span><div class="gmail_extra"> -> Yes</div><span><div class="gmail_extra"><br>
- Is the syntax for passing the arguments correct (separator in particular that can be nothing, blank or even comma) ?<br>
</div></span><div class="gmail_extra"> -> not 100% sure about that.</div><div class="gmail_extra"> -> here a link to the description of the Controller...chapter 3.12</div><div class="gmail_extra"><br></div><div class="gmail_extra"><span style="color:black;font-family:"Tahoma","sans-serif";font-size:10pt"> <a href="http://www.west-l.ru/uploads/tdpdf/ca2010-cable_eng_bro.pdf" target="_blank"><font color="#0000ff">http://www.west-l.ru/uploads/<wbr>tdpdf/ca2010-cable_eng_bro.pdf</font></a></span></div><span><div class="gmail_extra"><br></div><div class="gmail_extra"><br></div><div class="gmail_extra"><br></div><div class="gmail_extra">- Do you have a command without arguments that returns a known value (like *IDN? or *SN? that should return a string with the id of the controller) ?<br>
</div></span><div class="gmail_extra"> -> Yes, e.g.: firmeware</div><div class="gmail_extra"><br></div><div class="gmail_extra"><br></div><div class="gmail_extra"><span>- Did you try to connect to your controller using hyperterminal or putty to see whether the problem comes from Scilab?<br></span>
-> I used the C-coded Software for testing and it can connect to the controler reading and writing values from/on it.</div><span><div class="gmail_extra"><br></div><div class="gmail_extra"><br></div><div class="gmail_extra"><br></div><div class="gmail_extra"><br>-- <br></div><div class="gmail_extra"><div data-smartmail="gmail_signature"><div dir="ltr"><div>In Kanada is' ka' na' da. Sonst wär' Kanada Jemanda.</div><div><br></div><div>There we have the salad.</div></div></div>
</div></span></div>
</blockquote></div><br><br clear="all"><br>-- <br><div class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div>In Kanada is' ka' na' da. Sonst wär' Kanada Jemanda.</div><div><br></div><div>There we have the salad.</div></div></div>
</div>