VRLinuxShelfFido

From VentureResearchWiki
Jump to navigation Jump to search

BOARD SETUP[edit | edit source]

VR Linux Shelf Board 1.1,1.2,1.3 loading - Fido Image (kernel 3.14)

Initial Nand Image (u-boot,kernel,fs)[edit | edit source]

  • power-on or reboot device
  • Keep pressing the space-bar until prompt "U-Boot#"
  • Copy and paste the following commands (pressing enter after each line, waiting until "U-Boot#" appears showing the board is ready for next command)
save
setenv serverip 192.168.19.35
bootp
tftp ${loadaddr} zImage-vr-am33v2-linuxshelf-20170728.bin
  • Load the Board image for the correct Board and module combination. Current Modules = F modules (See #Alternate_Board_Images for other options)
tftp ${fdtaddr} zImage-vr-am33v2-linuxshelf-F-20170728.dtb
  • Copy and paste the following commands (pressing enter after each line)
setenv serverip 192.168.19.35
setenv rootpath /srv/nfs/vr-am33-m2mreader
setenv nfsopts nolock,mountproto=tcp,proto=tcp
run netargs
bootz ${loadaddr} - ${fdtaddr}
  • Board will reboot automatically

Filesystem[edit | edit source]

  1. Login after bootup
username root
password rfid4ever_vr

"root@vr-preboot:~#"

  • Copy and paste the following commands (pressing enter after each line)
wget http://readonly:secret@svn.crm.ventureresearch.com/svn/linux/testing/vr-am33v2-linuxshelf/vr-prefirstrun-fido.sh -O /tmp/vr-prefirstrun.sh
  • Load the Standard Development image:
sh /tmp/vr-prefirstrun.sh vr-am33v2-linuxshelf 20170728 venture-image-vrreader vr
  • Follow on-screen prompts to complete filesystem setup:
    1. Scan Variscite MFC Number (and write on Board sheet)
    2. Variscite Letter Designation
    3. Board Configuration (noted on Board Label)
  • Board will reboot automatically

Provisioning[edit | edit source]

  • Login after bootup
username root
  • Copy and paste the following commands (pressing enter after each line)
wget http://readonly:secret@svn.crm.ventureresearch.com/svn/linux/testing/vr-am33v2-linuxshelf/vr-firstrun.sh -O /tmp/vr-firstrun.sh
sh /tmp/vr-firstrun.sh
  • Follow on-screen prompts to complete board provisioning:
    1. Scan Wi-Fi MAC Address
    2. Last 5 digits of Parent VRSN
  • Board will reboot automatically

Board Test[edit | edit source]

  • Run the Board Test for the specific board as listed on the Board Label (ex: Shlef Board 1.3d)


Extra Instructions (>special use only<)[edit | edit source]

Alternate_Board_Images[edit | edit source]

A modules tftp ${fdtaddr} zImage-vr-am33v2-linuxshelf-A-20170728.dtb
B modules tftp ${fdtaddr} zImage-vr-am33v2-linuxshelf-B-20170728.dtb
E modules tftp ${fdtaddr} zImage-vr-am33v2-linuxshelf-E-20170728.dtb

old u-boot to new u-boot[edit | edit source]

bootp
tftp ${loadaddr} u-boot-vr-am33v2-linuxshelf-20170728.bin
nand erase 0x000c0000 0x00100000
nand erase 0x00260000 0x00020000
nand write ${loadaddr} 0x000c0000 0x00100000

tftp ${loadaddr} MLO-vr-am33v2-linuxshelf-20170728.bin
nand erase 0x00000000 0x00080000
nand write ${loadaddr} 0x00000000 0x00020000
nand write ${loadaddr} 0x00020000 0x00020000
nand write ${loadaddr} 0x00040000 0x00020000
nand write ${loadaddr} 0x00060000 0x00020000

reset

SD Card reloading / reflashing[edit | edit source]

setup sd card

grep -q mmcblk0p1 /proc/self/mounts && umount /dev/mmcblk0p1 
echo 8192,,83,- | sfdisk --force -q -uS -D -H 255 -S 63 /dev/mmcblk0 

wait 5 seconds

[ ! -x /sbin/mkfs.ext4 ] && opkg install e2fsprogs-mke2fs 
mkfs.ext4 -E stride=1,stripe_width=1024 -b 4096 -L opt /dev/mmcblk0p1 
sed -i 's-^/dev/mmcblk0p1-#/dev/mmcblk0p1-g' /etc/fstab 
echo "/dev/mmcblk0p1  /opt  auto  defaults,noatime,sync,auto  0  0" >> /etc/fstab 
rm -fr /opt/
mkdir -p /opt
mount /dev/mmcblk0p1 && mkdir -p /opt/log

OpenVPN connect[edit | edit source]

manual connection to OpenVPN server

systemctl start openvpn@venture

Wi-Fi setup[edit | edit source]

setup mac address

calibrator set nvs_mac /lib/firmware/ti-connectivity/wl1271-nvs.bin 00:50:C2:7C:57:XX
calibrator get nvs_mac /lib/firmware/ti-connectivity/wl1271-nvs.bin

rfid setup (8 PORT)[edit | edit source]

nc localhost 2020
set mux 1 2 3 4 5 6 7 8
commit
commit
exit

rfid setup (6 PORT)[edit | edit source]

nc localhost 2020
set mux 1 2 3 4 5 7
commit
commit
exit

rfid setup (4 PORT)[edit | edit source]

nc localhost 2020
set mux 1 3 5 7
commit
exit

board testing[edit | edit source]

wget http://readonly:secret@svn.crm.ventureresearch.com/svn/linux/testing/vr-am33-shelf/BIST_SHLFRDR.sh -O /home/user/BIST_SHLFRDR.sh
sh /home/user/BIST_SHLFRDR.sh vr-am33-shelf-BIST

done with board

JASONP STUFF[edit | edit source]

Updating Board Version (example: 5.1.4)

opkg update && opkg upgrade && opkg remove vrfrv2-linux-event-can-cont && opkg install vrfrv2-linux-event-5.1

curl -L -F hostname=$HOSTNAME http://openvpn/genclientkey | tar xzvC /etc/openvpn
wget http://readonly:secret@svn.crm.ventureresearch.com/svn/linux/testing/vr-am33-shelf/vr-bbrun.sh -O /home/user/vr-bbrun.sh
wget http://readonly:secret@svn.crm.ventureresearch.com/svn/linux/testing/vr-am33-shelf/vr-smallrun.sh -O /home/user/vr-smallrun.sh
sh /home/user/BIST_SHLFRDR.sh


wget http://readonly:secret@svn.crm.ventureresearch.com/svn/linux/testing/vr-am33-shelf/vr-smallrun.sh -O /home/user/vr-smallrun.sh

sh /home/user/vr-smallrun.sh

wget http://readonly:secret@svn.crm.ventureresearch.com/svn/linux/testing/vr-am33-shelf/vr-update-run.sh -O /home/user/vr-update-run.sh

sh /home/user/vr-update-run.sh

-- enter board revision when asked...

Helmer Temp interface commands[edit | edit source]

stty -F /var/run/vrgpio/uart raw speed 9600 -crtscts cs8 -parenb -cstopb; echo $? -- setup
echo -e "\x00\x02\x0A\xA0\x01\x00\xFE\xFF\x57\xFD\x01\x03" > /var/run/vrgpio/uart -- light on
echo -e "\x00\x02\x0A\xA0\x01\x00\xFF\xFF\x56\xFD\x00\x03" > /var/run/vrgpio/uart -- light off