Sunday, March 18, 2018

Sunday, February 25, 2018

Cortex-M3/M4 Debugging

Good post to change Imprecise abort to Precise by disabling buffering ((DISDEFWBUF bit in ACTLR register)
http://chmorgan.blogspot.in/2013/06/debugging-imprecise-bus-access-fault-on.html

In your OS, specially in Cortex-M3/M4 a good step would be disabling of nested interrupts by setting same interrupt priority level for all interrupts.

Bus fault (imprecise error) occurs in peak busy state, if number of bits for PRIORITY GROUP and PRIORITY LEVEL are not properly set in n4ixxxx.c.

Saturday, February 17, 2018

CCS Project settings

New-> CCS Project -> Target = K2GEVM


VFP -> vfplib
Remove NEON
C:\X\INC
n4e7aal.lib
C:\X\LIB\ARM\CCS7
10063
10068
__RESET
"STACK=0x800FC000"
Unaligned access = off
enum_type = int

For debugger,

select new -> Target configuration -> Select Board Target Name. (Not CPu name, then only all the board configuration will be available). For example, AM437x Starter Kit, it will be SK_AM4374.
Then, use the device configuration in Debug window.

Thursday, February 1, 2018

NIOS Quartus Prime GCC version

Quartus Prime Lite and Standard version seems to be stopped in 19.1. Only Quartus Pro seems to be released 19.2, 19.1 etc. For you, only the GCC version matters. So, just build and keep the libraries for different version of GCC available till the latest version. Also, the pro edition seems to be supporting only Family 10 FPGAs like Arria 10, Cyclone 10 and Stratix 10.

GCC 12.2.1 (Quartus Prime v23.2 Pro) - Last version. In v24.1, there is no Nios II
GCC 11.3.1 (Quartus Prime v22.3 Pro)
GCC 11.2.1 (Quartus Prime v22.1 Pro, v22.2 Pro)
GCC 10.3.1 (Quartus Prime v21.4 Pro) 
GCC 10.3.1 (Quartus Prime v21.3 Pro/ v21.1 lite/ v21.1 standard)
GCC 10.2.1 (Quartus Prime v21.2 Pro)
GCC 10.2.1 (Quartus Prime v21.1 Pro) - Kosu PC
GCC 10.2.1 (Quartus Prime v20.4 Pro)  - Prashant PC
GCC 10.1.1 (Quartus Prime v20.3 Pro)  - Prashant PC
GCC 10.1.1 (Quartus Prime v20.1.1 lite)  - Tarur
GCC 9.3.1 (Quartus Prime v20.2 Pro)  - Prashant PC
GCC 9.2.1 (Quartus Prime v20.1 Pro)  -    " (able to install multiple versions)
GCC 8.3.1 (Quartus Prime v19.4 Pro)  - Installed in Prashant PC.
GCC 8.3.1 (Quartus Prime v19.3 Pro)  - Use 19.4 pro
GCC 8.3.1 (Quartus Prime v19.2 Pro)  - Use 19.4 pro
GCC 8.3.1 (Quartus Prime v19.1 lite)  - Use 19.4 pro
GCC 7.3.1 (Quartus Prime v19.1 Pro) - Subash computer
GCC 7.3.1 (Quartus Prime v18.1 Pro) - Use 19.1 pro
                       ↑ Pro
GCC 5.3.0 (Quartus Prime v18.1 Lite and Std) - Do not know how to download Std. Lite in my Computer
GCC 5.3.0 (Quartus Prime v17.1)  - (No. 18.1 is used instead)
 GCC 5.2.0 (Quartus Prime v16.0)  - Nav computer
 GCC 4.9.2 (Quartus Prime v15.1)  - Eli computer
 GCC 4.8.3 (Quartus II v14.1)     - Takur computer
 GCC 4.7.3 (Quartus II v13.1)     - Eli computer
 GCC 4.1.2 (Quartus II v10.0 ~ v13.0 SP1) - Eli computer

Reference design

Serial is tested with dev.

Max 10 reference design is taken from server. UART is not checked. May be there is no reference design that supports UART. -DUART is not used.

18.1 and other release notes:
https://www.intel.cn/content/www/cn/zh/programmable/documentation/lro1465407474833.html
https://www.intel.com/content/www/us/en/programmable/documentation/lro1465407474833.html

Installation from Quartus Prime 19.2 Pro....
https://kiazhi.github.io/blog/The-easy-way-to-get-Ubuntu-18.04-distro-environment-on-Windows/
https://superuser.com/questions/1359633/apt-get-install-is-not-working-in-wsl
https://www.intel.com/content/altera-www/global/en_us/index/support/support-resources/knowledge-base/tools/2019/why-does-the-nios--ii-not-installed-after-full-installation-of-t.html

For Arria 10,

 jtagconfig.exe --setparam 1 JtagClock 16M

/devices/10AS066H1(.|ES)|10AS066H2|..@1#USB-1
/devices/5M(1270ZF324|2210Z)|EPM2210@3#USB-1
/devices/5M(1270ZF324|2210Z)|EPM2210@4#USB-1

As mentioned in the PDF of Example Application Ethernet project folder,

nios2-download  -g a10_fpga_sgmii_enet1.elf && nios2-terminal.exe

https://www.intel.com/content/altera-www/global/en_us/index/support/support-resources/knowledge-base/embedded/2019/error--failed-to-execute--wsl---create-this-bsp-no-make.html



Sunday, December 10, 2017

EVMK2G

Software:

http://www.tij.co.jp/tool/jp/processor-sdk-k2g

Wiki:
http://processors.wiki.ti.com/index.php/66AK2G02_GP_EVM_Hardware_Setup

ARM Cortex-A15
http://processors.wiki.ti.com/index.php/Processor_SDK_Bare_Metal_Examples

About using TI compiler for Cortex-A15

https://e2e.ti.com/support/development_tools/compiler/f/343/t/382886

https://e2e.ti.com/support/development_tools/compiler/f/343/t/599102

Timer interrupt occurs only in non-secure mode

The CPU may be in insecure mode. Please look at SCR.NS bit.

MRC p15, 0, <Rt>, c1, c1, 0; Read Secure Configuration Register data
MCR p15, 0, <Rt>, c1, c1, 0; Write Secure Configuration Register data

The initialization script file had changed the CPU to non-secure mode. Also, the GIC had been configured (IGROUP registers) to interrupt only in non-secure mode.

66AK2G UART0 Interrupt does not occur in ARM core

UART0 interrupt needs to be configured as edge.

Ethernet subsystem
https://lxr.missinglinkelectronics.com/uboot/arch/arm/mach-keystone/include/mach/hardware-k2g.h#L69

https://lxr.missinglinkelectronics.com/linux/drivers/net/ethernet/ti/netcp_ethss.c

http://processors.wiki.ti.com/index.php/Linux_Core_NetCP_User%27s_Guide

U-Boot
https://lxr.missinglinkelectronics.com/uboot/drivers/dma/keystone_nav.c#L50
https://lxr.missinglinkelectronics.com/uboot/drivers/net/keystone_net.c#L503
https://lxr.missinglinkelectronics.com/uboot/include/configs/k2g_evm.h#L84
https://github.com/RobertCNelson/u-boot/blob/master/board/ti/ks2_evm/mux-k2g.h
https://lxr.missinglinkelectronics.com/uboot/board/ti/ks2_evm/board_k2g.c

KeyStone Architecture Multicore Navigator
http://www.ti.com/lit/ug/sprugr9h/sprugr9h.pdf
http://processors.wiki.ti.com/images/f/f0/Eindhoven_JAN_12-06_MulticoreNavigator.pdf

Multicast
http://processors.wiki.ti.com/index.php/Linux_Core_CPSW_User's_Guide

Cache Invalidate Issue:
http://software-dl.ti.com/dsps/dsps_public_sw/sdo_sb/targetcontent/sysbios/6_42_03_35/exports/bios_6_42_03_35/docs/cdoc/ti/sysbios/family/arm/a15/Cache.html
https://elixir.free-electrons.com/linux/latest/source/arch/arm/mm/proc-v7.S
https://e2e.ti.com/support/embedded/tirtos/f/355/t/544363

reload fails when cache is enabled Cortex-a15
https://e2e.ti.com/support/development_tools/code_composer_studio/f/81/t/619005