An error pin? Topic is solved

All technical discussions and projects around startKIT
User avatar
aclassifier
Respected Member
Posts: 483
Joined: Wed Apr 25, 2012 8:52 pm
Contact:

Post by aclassifier »

infiniteimprobability wrote:
I only want this to happen in flashed code.
Try this..

Code: Select all

 int boot_from_jtag = ((getps(XS1_PS_BOOT_CONFIG) & 0x4) >> 2);
  if (!boot_from_jtag) { stuff that is only done when flashed }
Thanks a lot! I will, when Cristmas doesn't call on me so much!


View Solution
User avatar
aclassifier
Respected Member
Posts: 483
Joined: Wed Apr 25, 2012 8:52 pm
Contact:

Post by aclassifier »

I havent't tried your last suggestions, but here's this, probably some syntax error?

Code: Select all

../src/f_conversions.xc:83:28: error: asm output operand lacks `='
        asm(" ecallf %0" : "r" (0));
                           ^
../src/f_conversions.xc:83:28: error: lvalue required for asm output operand
henk
Respected Member
Posts: 347
Joined: Wed Jan 27, 2016 5:21 pm

Post by henk »

the : should be ::
User avatar
aclassifier
Respected Member
Posts: 483
Joined: Wed Apr 25, 2012 8:52 pm
Contact:

Post by aclassifier »

Thanks:

_Aquarium.xe [xCORE Application]
xCORE Debugger (22:55 22.12.16) (Suspended)
tile[0] core[0] (Suspended)
tile[0] core[1] (Suspended)
tile[0] core[2] (Suspended)
tile[0] core[3] (Suspended)
tile[0] core[4] (Suspended: Signal 'ET_ECALL' received. Description: Application exception.)
5 ambient_light_sensor_ALS_PDIC243_to_string_ok() f_conversions.xc:83 0x0001274a
4 adafruit_display_ssd1306_128x32_i2c() adafruit_display_ssd1306_128x32_i2c.xc:349 0x00011798
3 test_and_display.select.case.4() _Aquarium.xc:142 0x000113ba
2 __main__main_tile_0_combined_tile_0_0() 0x00013c70
1 __start_core() 0x00016f44
xgdb (22:55 22.12.16)
/Users/teig/workspace/_Aquarium/bin/_Aquarium.xe (22:55 22.12.16)

However, the installExceptionHandler and myExceptionHandler is a separate means to do private matters and then have the core(s) stop. The above does standard run-time crash.

Thanks for the help, Henk! Happy Christmas!
User avatar
aclassifier
Respected Member
Posts: 483
Joined: Wed Apr 25, 2012 8:52 pm
Contact:

Post by aclassifier »

By the way, this spawned a new post at https://www.xcore.com/forum/viewtopic.php?f=7&t=5089
User avatar
aclassifier
Respected Member
Posts: 483
Joined: Wed Apr 25, 2012 8:52 pm
Contact:

Post by aclassifier »

I don't seem find any thread where resetting (restarting) the startKIT in sw is described.
--
Øyvind Teig
Trondheim (Norway)
https://www.teigfam.net/oyvind/home/
User avatar
aclassifier
Respected Member
Posts: 483
Joined: Wed Apr 25, 2012 8:52 pm
Contact:

Post by aclassifier »

The above getps(XS1_PS_BOOT_CONFIG) yields 0x8001011e both when debug and flashed. So boot_from_jtag doesn't work.

I haven't found any documentation on the registers. Where is it? https://www.xmos.com/download/private/A ... 32A%29.pdf isn't it?

I get the myExceptionHandler to run ok but I haven't figured out how to restart the processor. I have searched.

on tile[0]: installExceptionHandler(); // Works only per tile. Don't know how to place one per tile, since
on tile[0].core[0]: installExceptionHandler(); // error: statement placed on a core must be call to combinable function

In other words, rather confused!
--
Øyvind Teig
Trondheim (Norway)
https://www.teigfam.net/oyvind/home/
User avatar
aclassifier
Respected Member
Posts: 483
Joined: Wed Apr 25, 2012 8:52 pm
Contact:

Post by aclassifier »

By the way, since it was mentioned in this thread. No, there is no watcdog on the startKIT processor. See https://www.xcore.com/viewtopic.php?f=44&t=5738
--
Øyvind Teig
Trondheim (Norway)
https://www.teigfam.net/oyvind/home/
Post Reply