-
Notifications
You must be signed in to change notification settings - Fork 2
Using Barebox Via JTAG On RDU2 Board
To set up access to host's filesystem via JTAG do the following in Barebox command line:
mkdir /mnt/host
mount -t smhfs /dev/null /mnt/host
After this all of the files from OpenOCD's current working directory should be accesible at '/mnt/host'
To permanently program fuses with a MAC address do the following:
> ocotp0.sense_enable=1
> ocotp0.permanent_write_enable=1
> ocotp0.mac_addr=ec:fa:aa:aa:bb:cc
To read the contents of EERPOM into a file on the host do:
> cp /dev/eeprom0 /mnt/host/eeprom-dump.bin
To write the contents of a file on a host into EERPOM do:
> cp /mnt/host/eeprom-dump.bin /dev/eeprom0
To read the card inserted into slot J8 do:
> mmc1.probe=1
After that you can access device as a whole via '/dev/mmc1' and its individual partitions via `/dev/mmc1.n' where 'n' is a partition number. For example:
> cp /dev/mmc1 /mnt/host/mmc1.bin
should copy the contents of SD card in slot J8 into a file 'mmc1.bin'
Replace 'mmc1' with 'mmc2' for SD slot J9 and with 'mmc3' for eMMC.
SPI NOR flash can be accessed via '/dev/m25p0' device. To erase the device do the following:
> erase /dev/m25p0
To write do:
> cp /mnt/host/data.bin /dev/m25p0
To read do:
> cp /dev/m25p0 /mnt/host/data.bin
To program SPI NOR flash with barebox image do the following:
-
Copy '/images/barebox-zii-imx6q-rdu2.img' to a SD card (FAT partition is recommended)
-
Insert SD card into SD slot J8
-
In barebox prompt do:
mmc1.probe=1 mkdir /mnt/sd mount /dev/mmc1.0 /mnt/sd erase /dev/m25p0.barebox cp /mnt/sd/barebox-zii-imx6q-rdu2.img /dev/m25p0.barebox
* Configure PIC MCU to bootstrap i.MX6 from SPI NOR
### Programming SPI NOR Flash With Barebox Image (via SD Semihosting)
To program SPI NOR flash with barebox image do the following:
* Copy '<barebox>/images/barebox-zii-imx6q-rdu2.img' to '<openocd>'
* In barebox prompt do:
mkdir /mnt/host mount -t smhfs /dev/null /mnt/host erase /dev/m25p0.barebox cp /mnt/host/barebox-zii-imx6q-rdu2.img /dev/m25p0.barebox
* Configure PIC MCU to bootstrap i.MX6 from SPI NOR
### Reading Measurements From TEMPMON IP Block
The readings from that sensors are available via:
hwmon
### Reading Measurements From LM75 Sensor Connected To i.MX6
The readings from that sensors are available via:
hwmon
### Accessing SATA Drive
To detect the drive connected via SATA do:
ata0.probe=1
After that you can access device as a whole via '/dev/ata0'
For example:
cp /dev/ata0 /mnt/host/ata0.bin
should copy the contents of SATA into a file 'ata0.bin'
### Performing MMDC Calibration
MMDC calibration commands are available in IRAM bootable image and can be accessed as follows:
mmdc -t dqs # For DQS calibration mmdc -t write-level # For write-level calibration mmdc -p # For printing results of the calibration