hi I want to add these scripts to init.rc but I get the error that init.rc doesnt support echo.
echo device > /sys/devices/platform/usbc.0/mode
what is the right way to do such a thing in init.rc?
You could probably use write
for that. Something like:
write /sys/devices/platform/usbc.0/mode ${device}
Or if you literally want to write the string "device":
write /sys/devices/platform/usbc.0/mode "device"
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.