IOsetting / stc8prog

Open Source STC8G/STC8H ISP flash tool
Apache License 2.0
62 stars 26 forks source link

无法在树莓派上使用 #6

Open nowboychen opened 2 years ago

nowboychen commented 2 years ago

不管使用32位系统还是64位系统,编译完成后运行后只有帮助信息,无法进入正常烧写过程。而使用stcgal没有任何问题。

egan-ru commented 2 years ago

Write more information: Which command to run you are using and with which operating system. You should pass command line arguments to download the firmware.

HookeLiu commented 11 months ago

我也遇到了同样的问题. 另外也尝试了加sudo, 仍无效.

Snipaste_2023-11-25_18-55-00

Hardware: OrangePi ZERO2W, STC8H4K64TL OS: Orange Pi 1.0.0 Jammy (Linux 6.1.31-sun50iw9 #1.0.0 SMP Thu Sep 7 17:20:45 CST 2023 aarch64 GNU/Linux) Version: stc8prog 1.4

$ stcgal -P stc8 -p /dev/ttyS2 -D ~/work/xxx.hex  
Waiting for MCU, please cycle power: <- Packet data: 00
<- Packet data: 46 B9 68 00 38 50 02 3C E6 80 59 30 01 FF EF BF AD FF 12 AA D5 FE 74 55 00 F8 34 03 8C 87 22 42 1F 21 1D 1A 01 00 00 FE 04 A0 23 02 04 81 0F 01 74 A7 DF 3D 56 6C 9E 13 E0 16
done
Target model:
  Name: STC8H4K64TL
  Magic: F834
  Code flash: 63.5 KB
  EEPROM flash: 0.5 KB
Target frequency: 37.546 MHz
Target BSL version: 7.4.3U
Target wakeup frequency: 35.975 KHz
Target ref. voltage: 1184 mV
Target mfg. date: 2023-02-04
$ ./stc8prog -p /dev/ttyS2 -f ~/work/xxx.hex  
Usage: stc8prog [options]...
  -h, --help                    display this message
  -p, --port <device>           set device path
  -s, --speed <baud>            set download baudrate
  -r, --reset <msec>            make reset sequence by pulling low dtr
  -r, --reset <cmd> [args] ;    command to perform reset or power cycle
  -f, --flash <file>            flash chip with data from hex file
  -e, --erase                   erase the entire chip
  -d, --debug                   enable debug output
  -v, --version                 display version information

Baudrate options:
   4800, 9600, 19200, 38400, 57600, 115200, 230400, 460800, 500000, 576000,
   921600, 1000000, 1152000, 1500000, 2000000, 2500000, 3000000, 3500000,
   4000000
DTR reset options:
   Min: 1,
   Max: 1000,
$ ./stc8prog -v                                                   
stc8prog 1.4
Copyright(c) 2022 IOsetting <iosetting@outlook.com>
Licensed under the Apache License, Version 2.0
IOsetting commented 11 months ago

It seems there is a bug when running in ARM system. I will check this when I got the environment.