Hello!
I am trying to drive a laser range finder with an UART on a XS1-L16-128. I use XS1_PORT_1E port for RX and XS1_PORT_1A for TX.
I am suffering a really strange thing. My application works PERFECTLY fine when I just run it, however, if I flash the app into my XMOS it gets stuck and the application does not execute as it should and as it did when running.
As far as I know, the UART starts ok but it hangs after a first command is sent. Same for other operations, (checked with LEDs), they hang after some time of operation.
Any ideas?
:)
Thanks on advance!
App works when xruning but not when xflashing (SOLVED)
App works when xruning but not when xflashing (SOLVED)
Last edited by atena on Mon May 12, 2014 10:39 am, edited 1 time in total.
- infiniteimprobability
- XCore Legend
- Posts: 1126
- Joined: Thu May 27, 2010 10:08 am
- Contact:
Which hardware are you running on?
If it is the slicekit then you may want to check you have set the SPI mux properly (controlls access to ports 1A - D).. Might be causing Rx to not be routed out to the headers..
If it is the slicekit then you may want to check you have set the SPI mux properly (controlls access to ports 1A - D).. Might be causing Rx to not be routed out to the headers..
Thanks for the answer!
I am using SOMANET hardware. But that is fine, it basically consists on 2 XDLinked L16 and the ports are correctly configured. As I said, the app works perfectly when running, and it is the same HW configuration that when flashed.
I am using SOMANET hardware. But that is fine, it basically consists on 2 XDLinked L16 and the ports are correctly configured. As I said, the app works perfectly when running, and it is the same HW configuration that when flashed.
Solved,
it apparently takes longer to initialise the UARTs when booting from the flash, so introducing a delay before the range finder thread starts solves the problem.
it apparently takes longer to initialise the UARTs when booting from the flash, so introducing a delay before the range finder thread starts solves the problem.
- infiniteimprobability
- XCore Legend
- Posts: 1126
- Joined: Thu May 27, 2010 10:08 am
- Contact:
Glad it's fixed! Thanks for posting your solution.