Using burst_ind branch, the code switches to a higher speed in function serial_up_to_eleven like this:<div><br></div><div><div>int serial_up_to_eleven(void)</div><div>{</div><div><span class="Apple-tab-span" style="white-space:pre">        </span>int rv;</div>
<div><br></div><div><span class="Apple-tab-span" style="white-space:pre">     </span>/* Attempt custom baudrate */</div><div><span class="Apple-tab-span" style="white-space:pre">        </span>rv = osmo_serial_set_custom_baudrate(dnload.serial_fd.fd, 406250);</div>
<div><span class="Apple-tab-span" style="white-space:pre">      </span>if (rv == 0)</div><div><span class="Apple-tab-span" style="white-space:pre">         </span>return 0;</div><div><br></div><div>#ifdef I_HAVE_A_CP210x /* and I know what I'm doing, I swear ! */</div>
<div><span class="Apple-tab-span" style="white-space:pre">      </span>/* Try closest standard baudrate (CP210x reprogrammed adapters) */</div><div><span class="Apple-tab-span" style="white-space:pre">   </span>rv = osmo_serial_set_baudrate(dnload.serial_fd.fd, B460800);</div>
<div><span class="Apple-tab-span" style="white-space:pre">      </span>if (rv == 0)</div><div><span class="Apple-tab-span" style="white-space:pre">         </span>return 0;</div><div>#endif</div></div><div>etc....</div><div><br></div>
<div>If the first attempt to switch to 406250 succeeds, the function exits and never reaches the I_HAVE_A_CP210x code which would switch to a higher speed!</div><div><br></div><div>Is this a bug? Or is the lower speed good enough for burst_ind? In which case why bother with the I_HAVE_A_CP210x option?</div>
<div><br></div><div>Or have I missed something obvious?</div><div><br></div><div>B.</div><div><br></div>