Coder Social home page Coder Social logo

openipc / chaos_calmer Goto Github PK

View Code? Open in Web Editor NEW

This project forked from zigfisher/openipc-1.0

189.0 10.0 22.0 907.17 MB

OpenIPC 1.0 (OpenWRT-based), not maintained anymore

Home Page: https://openipc.org

License: GNU General Public License v2.0

Makefile 11.49% Awk 0.02% Shell 4.76% C 76.76% Assembly 2.19% C++ 0.08% M4 0.97% CMake 0.01% Perl 1.53% Lex 0.05% Yacc 0.10% Python 0.12% Roff 1.94%
hisilicon hi35xx ipcam openipc zftlab xm anyka openwrt

chaos_calmer's Introduction

OpenIPC v1.0 (stable, OpenWrt based)

Alternative firmware for IP cameras based on the HiSilicon (and other) SoC's

More information about project on our website openipc.org

CI status GitHub repo size GitHub issues GitHub pull requests License


Supporting

If you like our work, please consider supporting us on Opencollective or PayPal or YooMoney.

Backers Backers

Backers

Thanks a lot !!!

OpenCollective donate button PayPal donate button YooMoney donate button


Pre-built images

Latest development build

Building status SoC U-Boot Kernel Rootfs Maintainer
Hi3516Cv100 images Hi3516CV100 uboot kernel rootfs IZ+SS+DI
Hi3516Cv200 images Hi3516CV200 uboot kernel rootfs IZ
Hi3516Cv300 images Hi3516CV300 uboot kernel rootfs IZ+DI
Hi3516Ev100 images Hi3516EV100 uboot kernel rootfs IZ+DI
Hi3518Av100 images Hi3518AV100 uboot kernel rootfs IZ+SS+DI
Hi3518Cv100 images Hi3518CV100 uboot kernel rootfs IZ+SS+DI
Hi3518Ev100 images Hi3518EV100 uboot kernel rootfs IZ+SS+DI
Hi3518Ev200 images Hi3518EV200 uboot kernel rootfs IZ
Hi3518Ev201 images Hi3518EV201 uboot kernel rootfs IZ

How to flash to target hardware

  1. Backup your original flash firmware (use TFTP or Telnet method whether you prefer)

  2. Download U-Boot, kernel and rootfs images to your TFTP server

  3. Flash U-Boot

sf probe 0 ; sf lock 0
mw.b 0x82000000 ff 0x50000
tftp 0x82000000 openwrt-hi35xx-16cv300-u-boot.bin
sf erase 0x0 0x50000
sf write ${fileaddr} 0x0 ${filesize}
reset
  1. Flash Linux kernel
sf probe 0 ; sf lock 0
mw.b 0x82000000 ff 0x200000
tftp 0x82000000 openwrt-hi35xx-16cv300-default-uImage
sf erase 0x50000 0x200000
sf write ${fileaddr} 0x50000 ${filesize}
  1. Flash rootfs
sf probe 0 ; sf lock 0
mw.b 0x82000000 ff 0x500000
tftp 0x82000000 openwrt-hi35xx-16cv300-default-root.squashfs
sf erase 0x250000 0x500000
sf write ${fileaddr} 0x250000 ${filesize}

Build manually

Build on Linux machine

Usage example for Debian (8 or 9)/Ubuntu

git clone --depth=1 https://github.com/OpenIPC/chaos_calmer.git OpenIPC
cd OpenIPC
./Project_OpenIPC.sh update
./Project_OpenIPC.sh 18ev200_zftlab_rotek

Ready to flash images will be located at bin/hi35xx/openwrt-hi35xx-*

Or use Docker for building

FROM debian:stretch

RUN DEBIAN_FRONTEND=noninteractive apt-get update \
    && apt-get --no-install-recommends -y install bc bison build-essential \
    ca-certificates cmake cpio curl dos2unix file flex gawk gcc-multilib \
    gettext gettext-base git intltool libc6-dev liblocale-gettext-perl \
    libncurses-dev libssl-dev locales mc openssl python rsync subversion \
    time tofrodos unzip upx wget zlib1g-dev \
    && localedef -i en_US -c -f UTF-8 -A /usr/share/locale/locale.alias \
    en_US.UTF-8 && rm -rf /var/lib/apt/lists/*

ENV LANG en_US.utf8

WORKDIR /src/openipc

RUN git clone --depth=1 https://github.com/OpenIPC/chaos_calmer.git /src/openipc
RUN ./Project_OpenIPC.sh update
RUN ./Project_OpenIPC.sh 18ev200_DEFAULT  # <= Change this ID to you profile

Commercial Support

Commercial support for OpenIPC is available.

Please contact OpenIPC Inc. to inquire further.

chaos_calmer's People

Contributors

acoul avatar blogic avatar claudyus avatar cultcom avatar ecsv avatar embeem avatar ffainelli avatar glevand avatar grozzie2 avatar hauke avatar jk-ozlabs avatar jow- avatar juhosg avatar kaloz avatar kanjimonster avatar larsclausen avatar ldir-edb0 avatar lperkov avatar mkrkn avatar neocturne avatar pnd10 avatar rmilecki avatar rwhitby avatar ryd avatar sbyx avatar ssharshunov avatar teknoraver avatar widgetii avatar wigyori avatar zigfisher avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

chaos_calmer's Issues

i2c error

I'm trying to use this firmware on a ip cam with soc hi3518ev200

Looking inside original filesystem i found
/mnt/mtd/ipc/modules/load3518e -i -sensor ar0130
So it is using your default sensor ar0130

I set this inside uboot
setenv bootcmd 'setenv bootargs totalmem=64M mem=40M sensor=ar0130 hieth.mdioifu=0 hieth.mdioifd=0 phyaddru=0 phyaddrd=1 console=ttyAMA0,115200; tftp 0x82000000 openwrt-hisilicon-armv5tej-3.4.35-initramfs-uImage; bootm 0x82000000'

The camera is booting correctly, i can access the shell via serial and load LUCI in my browser

But during boot i see a lot of these messages

[   45.562448] hi_i2c_wait_txfifo_notfull->241: 
[   45.566651] abort! last int_raw_status: 0x750!
[   45.571415] 
[   45.572917] hi_i2c_abortprocess->87: 
[   45.576406] tx_abrt_src is 1.
[   45.579545] 
[   45.581685] hi_i2c_wait_txfifo_notfull->241: 
[   45.585888] abort! last int_raw_status: 0x750!
[   45.590646] 
[   45.592147] hi_i2c_abortprocess->87: 
[   45.595636] tx_abrt_src is 1.
[   45.598775] 
[   45.600926] hi_i2c_wait_txfifo_notfull->241: 
[   45.605131] abort! last int_raw_status: 0x750!
[   45.609752] 
[   45.611393] hi_i2c_abortprocess->87: 
[   45.614888] tx_abrt_src is 1.
[   45.618027] 
[   45.620098] hi_i2c_wait_txfifo_notfull->241: 
[   45.624441] abort! last int_raw_status: 0x750!
[   45.629066] 
[   45.630625] hi_i2c_abortprocess->87: 
[   45.634117] tx_abrt_src is 1.

And if i load http://192.168.1.10:8080/image.jpg it fails
Do I have to pass additional boot arguments?
For example i had to pass phyaddru=0 phyaddrd=1 insted of phyaddru=1 phyaddrd=2 to get network working
Maybe the i2c is mapped on different addresses too?
Where can I investigate?

If i run hisi-load.sh it prints some messages but then it hangs

root@OpenIPC_HI35xx:/# hisi-load.sh 

=====================

Sensor table:
 9m034
 ar0130 (ok), ar0230, ar0237
 imx222 (ok)
 jxf22, jxh62
 mn34222
 ov2718, ov9712, ov9732, ov9750, ov9752
 sc1045, sc1135, sc1145, sc2035, sc2045, sc2135, sc2235

=====================

Current options:
 - processor: hi3518ev200
 - total memory: 64M
 - linux memory: 40M
 - sensor: ar0130
 - mem_start: 0x80000000
 - mmz_start: 0x82800000
 - mmz_size: 24M

=====================

[  891.295235] unload adec.ko ...OK!
[  891.315789] unload aenc.ko ...OK!
[  891.336334] unload ao.ko ...OK!
[  891.356749] unload ai.ko ...OK!
[  891.374276] unload hi3518e_aio.ko ...OK!
[  891.392432] acodec exited!
Remove audio...
module is not loaded
[  891.426004] unload sensor_i2c.ko ...OK!
[  891.446789] unload pwm.ko ...OK!
[  891.466752] unload ive.ko for Hi3518EV200...OK!
[  891.488065] unload rc.ko ...OK!
[  891.508196] unload jpege.ko ...OK!
[  891.528512] unload h264e.ko ...OK!
[  891.548561] unload chnl.ko for Hi3518EV200...OK!

At this point I have to reboot the camera by removing power, because it does not exit even if i press ctrl+C

Thank you very much for this amazing project!

problem booting hi3518ev100

I'm unable to boot with all the network interfaces for my board (hi3518ev100) after updating with openIPC. Could you please help. Here is the output I'm getting

U-Boot 2010.06-dirty (Jul 10 2021 - 19:39:09)

Check spi flash controller v350... Found
Spi(cs1) ID: 0xC2 0x20 0x17 0xC2 0x20 0x17
Spi(cs1): Block:64KB Chip:8MB Name:"MX25L6406E"
MMC:   MMC FLASH INIT: No card on slot!
In:    serial
Out:   serial
Err:   serial
Detected RAM size: 64Mb
*No SD card found!
USB:   scanning bus for devices... 1 USB Device(s) found
0 Storage Device(s) found
USB:   scanning bus for devices... 1 USB Device(s) found
0 Storage Device(s) found
Hit any key to stop autoboot:  0
8192 KiB hi_sfc at 0:0 is now current device

## Booting kernel from Legacy Image at 82000000 ...
   Image Name:   OpenIPC.org | Linux-3.0.8
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    1315464 Bytes = 1.3 MiB
   Load Address: 80008000
   Entry Point:  80008000
   Loading Kernel Image ... OK
OK

Starting kernel ...

Uncompressing Linux... done, booting the kernel.
[    0.000000] Linux version 3.0.8 (runner@fv-az139-878) (gcc version 4.8.3 (OpenWrt/Linaro GCC 4.8-2014.04 latest-178-g157e03c47e) ) #1 Sat Jul 10 19:35:39 UTC 2021
[    0.000000] CPU: ARM926EJ-S [41069265] revision 5 (ARMv5TEJ), cr=00053177
[    0.000000] CPU: VIVT data cache, VIVT instruction cache
[    0.000000] Machine: hi3518
[    0.000000] Memory policy: ECC disabled, Data cache writeback
[    0.000000] AXI bus clock 200000000.
[    0.000000] Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 8128
[    0.000000] Kernel command line: totalmem=64M mem=32M ethaddr=00:12:14:1e:52:fd phyaddru= phyaddrd= sensor=auto linux_cmd=version console=ttyAMA0,115200 panic=20 root=/dev/mtdblock3 rootfstype=squashfs mtdparts=hi_sfc:256k(boot),64k(env),2048k(kernel),5120k(rootfs),-(rootfs_data)
[    0.000000] PID hash table entries: 128 (order: -3, 512 bytes)
[    0.000000] Dentry cache hash table entries: 4096 (order: 2, 16384 bytes)
[    0.000000] Inode-cache hash table entries: 2048 (order: 1, 8192 bytes)
[    0.000000] Memory: 32MB = 32MB total
[    0.000000] Memory: 28956k/28956k available, 3812k reserved, 0K highmem
[    0.000000] Virtual kernel memory layout:
[    0.000000]     vector  : 0xffff0000 - 0xffff1000   (   4 kB)
[    0.000000]     fixmap  : 0xfff00000 - 0xfffe0000   ( 896 kB)
[    0.000000]     DMA     : 0xffc00000 - 0xffe00000   (   2 MB)
[    0.000000]     vmalloc : 0xc2800000 - 0xfe000000   ( 952 MB)
[    0.000000]     lowmem  : 0xc0000000 - 0xc2000000   (  32 MB)
[    0.000000]     modules : 0xbf000000 - 0xc0000000   (  16 MB)
[    0.000000]       .init : 0xc0008000 - 0xc0024000   ( 112 kB)
[    0.000000]       .text : 0xc0024000 - 0xc0340000   (3184 kB)
[    0.000000]       .data : 0xc0340000 - 0xc0357220   (  93 kB)
[    0.000000]        .bss : 0xc0357244 - 0xc03680f8   (  68 kB)
[    0.000000] SLUB: Genslabs=13, HWalign=32, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
[    0.000000] NR_IRQS:128 nr_irqs:128 128
[    0.000000] sched_clock: 32 bits at 100MHz, resolution 10ns, wraps every 42949ms
[    0.000067] Calibrating delay loop... 218.72 BogoMIPS (lpj=1093632)
[    0.070080] pid_max: default: 32768 minimum: 301
[    0.070505] Mount-cache hash table entries: 512
[    0.071712] CPU: Testing write buffer coherency: ok
[    0.076428] NET: Registered protocol family 16
[    0.091386] Serial: AMBA PL011 UART driver
[    0.091724] uart:0: ttyAMA0 at MMIO 0x20080000 (irq = 5) is a PL011 rev2
[    0.307866] console [ttyAMA0] enabled
[    0.312560] uart:1: ttyAMA1 at MMIO 0x20090000 (irq = 5) is a PL011 rev2
[    0.363658] bio: create slab <bio-0> at 0
[    0.385147] SCSI subsystem initialized
[    0.392579] usbcore: registered new interface driver usbfs
[    0.398835] usbcore: registered new interface driver hub
[    0.405246] usbcore: registered new device driver usb
[    0.418245] cfg80211: Calling CRDA to update world regulatory domain
[    0.425407] Switching to clocksource timer1
[    0.438831] NET: Registered protocol family 2
[    0.443579] IP route cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.451194] TCP established hash table entries: 1024 (order: 1, 8192 bytes)
[    0.458372] TCP bind hash table entries: 1024 (order: 0, 4096 bytes)
[    0.464899] TCP: Hash tables configured (established 1024 bind 1024)
[    0.471295] TCP reno registered
[    0.474468] UDP hash table entries: 256 (order: 0, 4096 bytes)
[    0.480456] UDP-Lite hash table entries: 256 (order: 0, 4096 bytes)
[    0.487481] NET: Registered protocol family 1
[    0.492802] RPC: Registered named UNIX socket transport module.
[    0.498746] RPC: Registered udp transport module.
[    0.503542] RPC: Registered tcp transport module.
[    0.508257] RPC: Registered tcp NFSv4.1 backchannel transport module.
[    0.562744] squashfs: version 4.0 (2009/01/31) Phillip Lougher
[    0.572073] JFFS2 version 2.2. (NAND) (SUMMARY)  © 2001-2006 Red Hat, Inc.
[    0.583581] msgmni has been set to 56
[    0.588371] io scheduler noop registered
[    0.592405] io scheduler deadline registered (default)
[    0.597876] io scheduler cfq registered
[    0.635571] brd: module loaded
[    0.643514] Spi id table Version 1.22
[    0.648829] Spi(cs1) ID: 0xC2 0x20 0x17 0xC2 0x20 0x17
[    0.654138] SPI FLASH start_up_mode is 3 Bytes
[    0.658598] Spi(cs1):
[    0.660840] Block:64KB
[    0.663293] Chip:8MB
[    0.665565] Name:"MX25L6406E"
[    0.668718] spi size: 8MB
[    0.671370] chip num: 1
[    0.673869] 5 cmdlinepart partitions found on MTD device hi_sfc
[    0.679796] Creating 5 MTD partitions on "hi_sfc":
[    0.684650] 0x000000000000-0x000000040000 : "boot"
[    0.693803] 0x000000040000-0x000000050000 : "env"
[    0.702790] 0x000000050000-0x000000250000 : "kernel"
[    0.712109] 0x000000250000-0x000000750000 : "rootfs"
[    0.721466] 0x000000750000-0x000000800000 : "rootfs_data"
[    0.750995] Fixed MDIO Bus: probed
[    1.122502] himii: probed
[    1.240100] PHY himii:01 not found
[    1.243528] hieth:hieth_platdev_probe_port:688:
[    1.247975] connect to phy_device himii:01 failed!
[    1.253803] hieth:hieth_plat_driver_probe:817:
[    1.258173] no dev probed!
[    1.261127]
[    1.293058] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[    1.300009] hiusb-ehci hiusb-ehci.0: HIUSB EHCI
[    1.305817] hiusb-ehci hiusb-ehci.0: new USB bus registered, assigned bus number 1
[    1.313864] hiusb-ehci hiusb-ehci.0: irq 15, io mem 0x100b0000
[    1.330124] hiusb-ehci hiusb-ehci.0: USB 0.0 started, EHCI 1.00
[    1.338433] hub 1-0:1.0: USB hub found
[    1.342346] hub 1-0:1.0: 1 port detected
[    1.349258] platform rtc-hi3518: rtc core: registered rtc-hi3518 as rtc0
[    1.362612] TCP cubic registered
[    1.365870] NET: Registered protocol family 17
[    1.370744] 802.1Q VLAN Support v1.8
[    1.376834] registered taskstats version 1
[    1.381304] platform rtc-hi3518: setting system clock to 1970-01-01 00:00:00 UTC (0)
▒[    1.394388] VFS: Mounted root (squashfs filesystem) readonly on device 31:3.
[    1.401731] Freeing init memory: 112K
[    2.103500] init: Console is alive
[    3.670666] Initializing USB Mass Storage driver...
[    3.676455] usbcore: registered new interface driver usb-storage
[    3.682563] USB Mass Storage support registered.
[    4.200713] init: - preinit -
get_chip_id35180100() got unexpected 0xffffffff for 3518?v100
Check kernel modules loaded
Press the [f] key and hit [enter] to enter failsafe mode
Press the [1], [2], [3] or [4] key and hit [enter] to select the debug level
Failed to connect to ubus
Please press Enter to activate this console.
get_chip_id35180100() got unexpected 0xffffffff for 3518?v100


BusyBox v1.23.2 (2021-07-10 19:23:08 UTC) built-in shell (ash)


 ___                  _  ___  ___
/   \ ___  ___  _  _ | ||   \/  _|
| | ||   \/ _ \| \| || || | || |
| | || | |  __/| \\ || ||  _/| |_
\___/|  _/\___||_|\_||_||_|  \___|.ORG    v21.04.10.2
     |_|


OpenIPC is asking for your help to support development cost and long-term maintenance
of what we believe will serve a fundamental role in the advancement of a stable, flexible
and most importantly, Open IP Network Camera Framework for users worldwide.

Your contribution will help us advance development proposals forward, and interact with
the community on a regular basis.

  https://openipc.org/sponsor/



root@OpenIPC:/# Start autoupdate system

root@OpenIPC_HI35xx:/# ifconfig
lo        Link encap:Local Loopback
          inet addr:127.0.0.1  Mask:255.0.0.0
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:864 errors:0 dropped:0 overruns:0 frame:0
          TX packets:864 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:70848 (69.1 KiB)  TX bytes:70848 (69.1 KiB)

Here is my ipctool result before I updated it

# ./ipctool
---
board:
  vendor: Xiongmai
  model: HI3518E_50H10L_S39
chip:
  vendor: HiSilicon
  model: 3518EV100
ethernet:
  mac: "00:12:14:1e:52:fd"
  u-mdio-phyaddr: 1
  phy-id: 0x02430c54
  d-mdio-phyaddr: 0
  phy-mode: rmii
rom:
  - type: nor
    block: 64K
    partitions:
      - name: boot
        size: 0x40000
        sha1: efb6ac6b
        contains:
          - name: uboot-env
            offset: 0x30000
      - name: romfs
        size: 0x370000
        path: /,cramfs
        sha1: aba95348
      - name: user
        size: 0x280000
        path: /usr,squashfs
        sha1: ac368e66
      - name: web
        size: 0x140000
        path: /mnt/web,squashfs
        sha1: 7fa09492
      - name: custom
        size: 0x40000
        path: /mnt/custom,squashfs
        sha1: f49d3706
      - name: mtd
        size: 0x50000
        path: /mnt/mtd,jffs2,rw
    size: 8M
    addr-mode: 3-byte
ram:
  total: 64M
  media: 21M
firmware:
  u-boot: "2010.06 (Apr 07 2012 - 17:11:2)"
  kernel: "3.0.8 (Sat Aug 15 16:51:10 CST 2015)"
  toolchain: gcc version 4.4.1 (Hisilicon_v100(gcc4.4-290+uclibc_0.9.32.1+eabi+linuxpthread))
  sdk: "Hi3518_MPP_V1.0.8.0  (Feb 25 2014, 10:55:54)"
  god-app: /usr/bin/Sofia
sensors:
- vendor: Sony
  model: IMX224
  control:
    bus: 0
    type: i2c
    addr: 0x34
  data:
    type: DC
  clock: 24MHz
#

Still "chaos calmer" in 2021?

"Chaos Calmer" was a 15.05 (i.e., year 2015) release of OpenWRT: https://openwrt.org/releases/15.05/notes-15.05 . The latest OpenWRT release as of now is 19.07: https://openwrt.org/releases/start.

Is this repository really based on the 2015 fork of OpenWRT? What relation OpenIPC project has with the upstream OpenWRT in general?

(And sorry for dumb questions - but these would be first question a more or less advanced user (i.e. someone who's familiar with OpenWRT) would have. Thanks.)

Feature request hi1131

Looking to build a Hisilicon Hi1131 low-power Wi-Fi chip module - it's impossible to find any sources for it.
I have a cheap doorbell EKEN v5 - based on hi3518ev200, without any wired connection, only hi1131 WIFI.
After successful building and flashing with OpenIPC - now it's a serial port accessible only :)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.